java.lang.Object |
↳ |
com.ning.http.client.extra.ResumableRandomAccessFileListener |
Class Overview
A TransferListener
which use a RandomAccessFile for storing the received bytes.
Summary
Public Methods |
long
|
length()
Return the length of previously downloaded bytes.
|
void
|
onAllBytesReceived()
Invoked when all the bytes has been sucessfully transferred.
|
void
|
onBytesReceived(ByteBuffer buffer)
This method uses the last valid bytes written on disk to position a RandomAccessFile, allowing
resumable file download.
|
[Expand]
Inherited Methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait()
|
final
void
|
wait(long arg0)
|
final
void
|
wait(long arg0, int arg1)
|
|
From interface
com.ning.http.client.resumable.ResumableListener
abstract
long
|
length()
Return the length of previously downloaded bytes.
|
abstract
void
|
onAllBytesReceived()
Invoked when all the bytes has been sucessfully transferred.
|
abstract
void
|
onBytesReceived(ByteBuffer byteBuffer)
Invoked when some bytes are available to digest.
|
|
Public Constructors
public
ResumableRandomAccessFileListener
(RandomAccessFile file)
Public Methods
public
long
length
()
Return the length of previously downloaded bytes.
Returns
- the length of previously downloaded bytes
public
void
onAllBytesReceived
()
Invoked when all the bytes has been sucessfully transferred.
public
void
onBytesReceived
(ByteBuffer buffer)
This method uses the last valid bytes written on disk to position a RandomAccessFile, allowing
resumable file download.