Top Description Constructors Methods
org.apache.sshd.sftp.client.extensions.helpers

public Class CopyFileExtensionImpl

extends AbstractSftpClientExtension
implements CopyFileExtension
Class Inheritance
All Implemented Interfaces
org.apache.sshd.sftp.client.extensions.CopyFileExtension, org.apache.sshd.sftp.client.extensions.SftpClientExtension, org.apache.sshd.sftp.client.SftpClientHolder, org.apache.sshd.common.OptionalFeature, org.apache.sshd.common.NamedResource
Imports
java.io.IOException, java.util.Collection, org.apache.sshd.common.util.GenericUtils, org.apache.sshd.common.util.buffer.Buffer, org.apache.sshd.sftp.client.RawSftpClient, .SftpClient, org.apache.sshd.sftp.client.extensions.CopyFileExtension, org.apache.sshd.sftp.common.SftpConstants

Implements the "copy-file" extension
Author
Apache MINA SSHD Project
See Also
DRFAT 00 - section 6

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
copyFile(String
The (remote) file source path
src
,
String
The (remote) file destination path
dst
,
boolean
If true then OK to override destination if exists
overwriteDestination
)

Implements org.apache.sshd.sftp.client.extensions.CopyFileExtension.copyFile.

Inherited from org.apache.sshd.sftp.client.extensions.helpers.AbstractSftpClientExtension:
checkExtendedReplyBuffercheckStatusgetClientgetCommandBuffergetCommandBuffergetCommandBuffergetNameisSupportedputTargetreceivereceivereceivesendsendAndCheckExtendedCommandStatussendExtendedCommandthrowStatusExceptionwrite

Constructor Detail

CopyFileExtensionImplback to summary
public CopyFileExtensionImpl(SftpClient client, RawSftpClient raw, Collection<String> extra)

Method Detail

copyFileback to summary
public void copyFile(String src, String dst, boolean overwriteDestination) throws IOException

Implements org.apache.sshd.sftp.client.extensions.CopyFileExtension.copyFile.

Parameters
src:String

Doc from org.apache.sshd.sftp.client.extensions.CopyFileExtension.copyFile.

The (remote) file source path

dst:String

Doc from org.apache.sshd.sftp.client.extensions.CopyFileExtension.copyFile.

The (remote) file destination path

overwriteDestination:boolean

Doc from org.apache.sshd.sftp.client.extensions.CopyFileExtension.copyFile.

If true then OK to override destination if exists

Annotations
@Override
Exceptions
IOException:

Doc from org.apache.sshd.sftp.client.extensions.CopyFileExtension.copyFile.

If failed to execute the command or extension not supported