public final class ClassicFtpFileSystem extends FtpFileSystem
FtpFileSystem for files residing on a FTP server| Modifier and Type | Method and Description |
|---|---|
void |
awaitCommandCompletion()
Awaits for the underlying
client to complete any pending commands. |
void |
changeToBaseDir()
Changes the
client's current working directory to the base path |
protected org.mule.extension.file.common.api.lock.PathLock |
createLock(Path path,
Object... params) |
void |
disconnect()
Severs the connection by invoking
FTPClient.logout() and FTPClient.disconnect() on the provided
client. |
Class<? extends org.mule.extension.file.common.api.FileAttributes> |
getAttributesType() |
protected org.mule.extension.file.common.api.command.CopyCommand |
getCopyCommand() |
protected org.mule.extension.file.common.api.command.CreateDirectoryCommand |
getCreateDirectoryCommand() |
protected org.mule.extension.file.common.api.command.DeleteCommand |
getDeleteCommand() |
protected org.mule.extension.file.common.api.command.ListCommand |
getListCommand() |
protected org.mule.extension.file.common.api.command.MoveCommand |
getMoveCommand() |
protected org.mule.extension.file.common.api.command.ReadCommand |
getReadCommand() |
protected org.mule.extension.file.common.api.command.RenameCommand |
getRenameCommand() |
protected org.mule.extension.file.common.api.command.WriteCommand |
getWriteCommand() |
protected boolean |
isConnected() |
InputStream |
retrieveFileContent(org.mule.extension.file.common.api.FileAttributes filePayload)
Returns an InputStream which obtains the content for the file of the given
filePayload. |
void |
setPassiveMode(boolean passive)
|
void |
setResponseTimeout(Integer timeout,
TimeUnit timeUnit)
Sets the data timeout property on the underlying
client |
void |
setTransferMode(FtpTransferMode mode)
Sets the transfer mode on the
client |
validateConnectionpublic void disconnect()
FTPClient.logout() and FTPClient.disconnect() on the provided
client.
Notice that FTPClient.disconnect() will be invoked even if FTPClient.logout() fails. This method will never
throw exception. Any errors will be logged.
disconnect in class FtpFileSystemprotected boolean isConnected()
isConnected in class FtpFileSystempublic void setTransferMode(FtpTransferMode mode)
clientmode - a FtpTransferModepublic void setResponseTimeout(Integer timeout, TimeUnit timeUnit)
clienttimeout - a timeout scalartimeUnit - a TimeUnit which qualifies the timeoutpublic void setPassiveMode(boolean passive)
passive - whether to go passive mode or notpublic InputStream retrieveFileContent(org.mule.extension.file.common.api.FileAttributes filePayload)
filePayload.
The invoked MUST make sure that the returned stream is closed in order for the underlying connection to be closed.
retrieveFileContent in class FtpFileSystemfilePayload - a FileAttributes referencing to a FTP fileInputStreampublic void awaitCommandCompletion()
protected org.mule.extension.file.common.api.lock.PathLock createLock(Path path, Object... params)
createLock in class org.mule.extension.file.common.api.AbstractFileSystemURLPathLock based on the client's connection informationpublic void changeToBaseDir()
client's current working directory to the base pathprotected org.mule.extension.file.common.api.command.ReadCommand getReadCommand()
getReadCommand in class org.mule.extension.file.common.api.AbstractFileSystemprotected org.mule.extension.file.common.api.command.ListCommand getListCommand()
getListCommand in class org.mule.extension.file.common.api.AbstractFileSystemprotected org.mule.extension.file.common.api.command.WriteCommand getWriteCommand()
getWriteCommand in class org.mule.extension.file.common.api.AbstractFileSystemprotected org.mule.extension.file.common.api.command.CopyCommand getCopyCommand()
getCopyCommand in class org.mule.extension.file.common.api.AbstractFileSystemprotected org.mule.extension.file.common.api.command.MoveCommand getMoveCommand()
getMoveCommand in class org.mule.extension.file.common.api.AbstractFileSystemprotected org.mule.extension.file.common.api.command.DeleteCommand getDeleteCommand()
getDeleteCommand in class org.mule.extension.file.common.api.AbstractFileSystemprotected org.mule.extension.file.common.api.command.RenameCommand getRenameCommand()
getRenameCommand in class org.mule.extension.file.common.api.AbstractFileSystemprotected org.mule.extension.file.common.api.command.CreateDirectoryCommand getCreateDirectoryCommand()
getCreateDirectoryCommand in class org.mule.extension.file.common.api.AbstractFileSystempublic Class<? extends org.mule.extension.file.common.api.FileAttributes> getAttributesType()
Copyright © 2003–2017 MuleSoft, Inc.. All rights reserved.