Class Sftp
java.lang.Object
org.springframework.integration.sftp.dsl.Sftp
public final class Sftp
extends java.lang.Object
The factory for SFTP components.
- Since:
- 5.0
-
Method Summary
Modifier and Type Method Description static SftpInboundChannelAdapterSpec
inboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory)
AnSftpInboundChannelAdapterSpec
factory for an inbound channel adapter spec.static SftpInboundChannelAdapterSpec
inboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, java.util.Comparator<java.io.File> receptionOrderComparator)
AnSftpInboundChannelAdapterSpec
factory for an inbound channel adapter spec.static SftpStreamingInboundChannelAdapterSpec
inboundStreamingAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate)
AnSftpStreamingInboundChannelAdapterSpec
factory for an inbound channel adapter spec.static SftpStreamingInboundChannelAdapterSpec
inboundStreamingAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, java.util.Comparator<com.jcraft.jsch.ChannelSftp.LsEntry> receptionOrderComparator)
AnSftpStreamingInboundChannelAdapterSpec
factory for an inbound channel adapter spec.static SftpMessageHandlerSpec
outboundAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate)
Deprecated.in favor ofoutboundAdapter(SftpRemoteFileTemplate)
static SftpMessageHandlerSpec
outboundAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, org.springframework.integration.file.support.FileExistsMode fileExistsMode)
Deprecated.static SftpMessageHandlerSpec
outboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory)
AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.static SftpMessageHandlerSpec
outboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, org.springframework.integration.file.support.FileExistsMode fileExistsMode)
AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.static SftpMessageHandlerSpec
outboundAdapter(SftpRemoteFileTemplate sftpRemoteFileTemplate)
AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.static SftpMessageHandlerSpec
outboundAdapter(SftpRemoteFileTemplate sftpRemoteFileTemplate, org.springframework.integration.file.support.FileExistsMode fileExistsMode)
AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.static SftpOutboundGatewaySpec
outboundGateway(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, java.lang.String command, java.lang.String expression)
Produce aSftpOutboundGatewaySpec
based on theRemoteFileTemplate
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.static SftpOutboundGatewaySpec
outboundGateway(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, org.springframework.integration.file.remote.gateway.AbstractRemoteFileOutboundGateway.Command command, java.lang.String expression)
Produce aSftpOutboundGatewaySpec
based on theRemoteFileTemplate
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.static SftpOutboundGatewaySpec
outboundGateway(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, java.lang.String command, java.lang.String expression)
Produce aSftpOutboundGatewaySpec
based on theSessionFactory
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.static SftpOutboundGatewaySpec
outboundGateway(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, org.springframework.integration.file.remote.gateway.AbstractRemoteFileOutboundGateway.Command command, java.lang.String expression)
Produce aSftpOutboundGatewaySpec
based on theSessionFactory
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.static SftpOutboundGatewaySpec
outboundGateway(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, org.springframework.integration.file.remote.MessageSessionCallback<com.jcraft.jsch.ChannelSftp.LsEntry,?> messageSessionCallback)
Produce aSftpOutboundGatewaySpec
based on theMessageSessionCallback
.
-
Method Details
-
inboundAdapter
public static SftpInboundChannelAdapterSpec inboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory)AnSftpInboundChannelAdapterSpec
factory for an inbound channel adapter spec.- Parameters:
sessionFactory
- the session factory.- Returns:
- the spec.
-
inboundAdapter
public static SftpInboundChannelAdapterSpec inboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, java.util.Comparator<java.io.File> receptionOrderComparator)AnSftpInboundChannelAdapterSpec
factory for an inbound channel adapter spec.- Parameters:
sessionFactory
- the session factory.receptionOrderComparator
- the comparator.- Returns:
- the spec.
-
inboundStreamingAdapter
public static SftpStreamingInboundChannelAdapterSpec inboundStreamingAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate)AnSftpStreamingInboundChannelAdapterSpec
factory for an inbound channel adapter spec.- Parameters:
remoteFileTemplate
- the remote file template.- Returns:
- the spec.
-
inboundStreamingAdapter
public static SftpStreamingInboundChannelAdapterSpec inboundStreamingAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, java.util.Comparator<com.jcraft.jsch.ChannelSftp.LsEntry> receptionOrderComparator)AnSftpStreamingInboundChannelAdapterSpec
factory for an inbound channel adapter spec.- Parameters:
remoteFileTemplate
- the remote file template.receptionOrderComparator
- the comparator.- Returns:
- the spec.
-
outboundAdapter
public static SftpMessageHandlerSpec outboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory)AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.- Parameters:
sessionFactory
- the session factory.- Returns:
- the spec.
-
outboundAdapter
public static SftpMessageHandlerSpec outboundAdapter(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, org.springframework.integration.file.support.FileExistsMode fileExistsMode)AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.- Parameters:
sessionFactory
- the session factory.fileExistsMode
- the file exists mode.- Returns:
- the spec.
-
outboundAdapter
@Deprecated public static SftpMessageHandlerSpec outboundAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate)Deprecated.in favor ofoutboundAdapter(SftpRemoteFileTemplate)
AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.- Parameters:
remoteFileTemplate
- the remote file template.- Returns:
- the spec.
-
outboundAdapter
@Deprecated public static SftpMessageHandlerSpec outboundAdapter(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, org.springframework.integration.file.support.FileExistsMode fileExistsMode)Deprecated.AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.- Parameters:
remoteFileTemplate
- the remote file template.fileExistsMode
- the file exists mode.- Returns:
- the spec.
-
outboundAdapter
public static SftpMessageHandlerSpec outboundAdapter(SftpRemoteFileTemplate sftpRemoteFileTemplate)AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.- Parameters:
sftpRemoteFileTemplate
- the remote file template.- Returns:
- the spec.
- Since:
- 5.4
-
outboundAdapter
public static SftpMessageHandlerSpec outboundAdapter(SftpRemoteFileTemplate sftpRemoteFileTemplate, org.springframework.integration.file.support.FileExistsMode fileExistsMode)AnSftpMessageHandlerSpec
factory for an outbound channel adapter spec.- Parameters:
sftpRemoteFileTemplate
- the remote file template.fileExistsMode
- the file exists mode.- Returns:
- the spec.
- Since:
- 5.4
-
outboundGateway
public static SftpOutboundGatewaySpec outboundGateway(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, org.springframework.integration.file.remote.gateway.AbstractRemoteFileOutboundGateway.Command command, java.lang.String expression)Produce aSftpOutboundGatewaySpec
based on theSessionFactory
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.- Parameters:
sessionFactory
- theSessionFactory
.command
- the command to perform on the FTP.expression
- the remoteFilePath SpEL expression.- Returns:
- the
SftpOutboundGatewaySpec
-
outboundGateway
public static SftpOutboundGatewaySpec outboundGateway(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, java.lang.String command, java.lang.String expression)Produce aSftpOutboundGatewaySpec
based on theSessionFactory
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.- Parameters:
sessionFactory
- theSessionFactory
.command
- the command to perform on the FTP.expression
- the remoteFilePath SpEL expression.- Returns:
- the
SftpOutboundGatewaySpec
- See Also:
RemoteFileTemplate
-
outboundGateway
public static SftpOutboundGatewaySpec outboundGateway(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, org.springframework.integration.file.remote.gateway.AbstractRemoteFileOutboundGateway.Command command, java.lang.String expression)Produce aSftpOutboundGatewaySpec
based on theRemoteFileTemplate
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.- Parameters:
remoteFileTemplate
- theRemoteFileTemplate
to be based on.command
- the command to perform on the SFTP.expression
- the remoteFilePath SpEL expression.- Returns:
- the
SftpOutboundGatewaySpec
- See Also:
RemoteFileTemplate
-
outboundGateway
public static SftpOutboundGatewaySpec outboundGateway(org.springframework.integration.file.remote.RemoteFileTemplate<com.jcraft.jsch.ChannelSftp.LsEntry> remoteFileTemplate, java.lang.String command, java.lang.String expression)Produce aSftpOutboundGatewaySpec
based on theRemoteFileTemplate
,AbstractRemoteFileOutboundGateway.Command
andexpression
for the remoteFilePath.- Parameters:
remoteFileTemplate
- theRemoteFileTemplate
to be based on.command
- the command to perform on the SFTP.expression
- the remoteFilePath SpEL expression.- Returns:
- the
SftpOutboundGatewaySpec
- See Also:
RemoteFileTemplate
-
outboundGateway
public static SftpOutboundGatewaySpec outboundGateway(org.springframework.integration.file.remote.session.SessionFactory<com.jcraft.jsch.ChannelSftp.LsEntry> sessionFactory, org.springframework.integration.file.remote.MessageSessionCallback<com.jcraft.jsch.ChannelSftp.LsEntry,?> messageSessionCallback)Produce aSftpOutboundGatewaySpec
based on theMessageSessionCallback
.- Parameters:
sessionFactory
- theSessionFactory
to connect to.messageSessionCallback
- theMessageSessionCallback
to perform SFTP operation(s) with theMessage
context.- Returns:
- the
SftpOutboundGatewaySpec
- See Also:
MessageSessionCallback
-