com.maverick.sftp
Interface FileTransferProgress


public interface FileTransferProgress

Interface for monitoring the state of a file transfer

It should be noted that the total bytes to transfer passed to the started method is an indication of file length and may not be exact for some types of file transfer, for exampel ASCII text mode transfers may add or remove newline characters from the stream and therefore the total bytes transfered may not equal the number expected.

Author:
Lee David Painter

Method Summary
 void completed()
          The transfer has completed.
 boolean isCancelled()
          The transfer is cancelled.
 void progressed(long bytesSoFar)
          The transfer has progressed
 void started(long bytesTotal, java.lang.String remoteFile)
          The transfer has started
 

Method Detail

started

public void started(long bytesTotal,
                    java.lang.String remoteFile)
The transfer has started

Parameters:
bytesTotal -
remoteFile -

isCancelled

public boolean isCancelled()
The transfer is cancelled. Implementations should return true if the user wants to cancel the transfer. The transfer will then be stopped at the next evaluation stage.

Returns:

progressed

public void progressed(long bytesSoFar)
The transfer has progressed

Parameters:
bytesSoFar -

completed

public void completed()
The transfer has completed.



Copyright © 2003 3SP LTD. All Rights Reserved.