public class ConsoleTransferListener extends AbstractTransferListener
Constructor and Description |
---|
ConsoleTransferListener() |
ConsoleTransferListener(PrintStream out) |
Modifier and Type | Method and Description |
---|---|
protected long |
toKB(long bytes) |
void |
transferCorrupted(TransferEvent event)
Notifies the listener that a checksum validation failed.
|
void |
transferFailed(TransferEvent event)
Notifies the listener about the unsuccessful termination of a transfer.
|
void |
transferInitiated(TransferEvent event)
Notifies the listener about the initiation of a transfer.
|
void |
transferProgressed(TransferEvent event)
Notifies the listener about some progress in the data transfer.
|
void |
transferSucceeded(TransferEvent event)
Notifies the listener about the successful completion of a transfer.
|
transferStarted
public ConsoleTransferListener()
public ConsoleTransferListener(PrintStream out)
public void transferInitiated(TransferEvent event)
TransferListener
transferInitiated
in interface TransferListener
transferInitiated
in class AbstractTransferListener
event
- The event details, must not be null
.public void transferProgressed(TransferEvent event)
TransferListener
transferProgressed
in interface TransferListener
transferProgressed
in class AbstractTransferListener
event
- The event details, must not be null
.public void transferSucceeded(TransferEvent event)
TransferListener
transferSucceeded
in interface TransferListener
transferSucceeded
in class AbstractTransferListener
event
- The event details, must not be null
.public void transferFailed(TransferEvent event)
TransferListener
TransferEvent.getException()
will
provide further information about the failure.transferFailed
in interface TransferListener
transferFailed
in class AbstractTransferListener
event
- The event details, must not be null
.public void transferCorrupted(TransferEvent event)
TransferListener
TransferEvent.getException()
will be of type
ChecksumFailureException
and can be used to query further details about the expected/actual checksums.transferCorrupted
in interface TransferListener
transferCorrupted
in class AbstractTransferListener
event
- The event details, must not be null
.protected long toKB(long bytes)
Copyright © 2010–2022 The Apache Software Foundation. All rights reserved.