public interface SftpProgressMonitor
An application will implement this interface to get information
about a running file transfer, and maybe show it to the user.
For example, it might wrap an ProgressMonitor
.
Additionally, this interface enables the application to stop the
transfer by returning false
from the count
method.
Several of the ChannelSftp
's put
and get
methods
take an object of this type, and will call its methods as defined here.
ChannelSftp
Modifier and Type | Field and Description |
---|---|
static int |
GET
Direction constant for download.
|
static int |
PUT
Direction constant for upload.
|
static long |
UNKNOWN_SIZE |
Modifier and Type | Method and Description |
---|---|
boolean |
count(long count)
Will be called periodically as more data is transfered.
|
void |
end()
Will be called when the transfer ended, either because all the data
was transferred, or because the transfer was cancelled.
|
void |
init(int op,
String src,
String dest,
long max)
Will be called when a new operation starts.
|
static final int PUT
static final int GET
static final long UNKNOWN_SIZE
void init(int op, String src, String dest, long max)
boolean count(long count)
count
- the number of bytes transferred so farvoid end()
This is a simplified version of the inofficial Javadoc created by PaĆlo Ebermann. Have a look at the official homepage.