Package com.ning.http.client.resumable
Interface ResumableAsyncHandler.ResumableProcessor
- All Known Implementing Classes:
PropertiesBasedResumableProcessor
- Enclosing class:
- ResumableAsyncHandler<T>
public static interface ResumableAsyncHandler.ResumableProcessor
An interface to implement in order to manage the way the incomplete file management are handled.
-
Method Summary
Modifier and TypeMethodDescriptionload()Load theMapin memory, contains information about the transferred bytes.voidAssociate a key with the number of bytes sucessfully transferred.voidRemove the key associate value.voidSave the currentMapinstance which contains information about the current transfer state.
-
Method Details
-
put
Associate a key with the number of bytes sucessfully transferred.- Parameters:
key- a key. The recommended way is to use an url.transferredBytes- The number of bytes sucessfully transferred.
-
remove
Remove the key associate value.- Parameters:
key- key from which the value will be discarted
-
save
Save the currentMapinstance which contains information about the current transfer state. This method *only* invoked when the JVM is shutting down.- Parameters:
map-
-
load
Load theMapin memory, contains information about the transferred bytes.- Returns:
Map
-