public interface ClientPutCallback extends ClientBaseCallback
Modifier and Type | Method and Description |
---|---|
void |
onFailure(InsertException e,
BaseClientPutter state)
Called on failed/canceled insert.
|
void |
onFetchable(BaseClientPutter state)
Called when the inserted data is fetchable (just a hint, don't rely on this).
|
void |
onGeneratedMetadata(Bucket metadata,
BaseClientPutter state)
Called when we are returning metadata rather than a URI.
|
void |
onGeneratedURI(FreenetURI uri,
BaseClientPutter state)
Called when URI is known (e.g.
|
void |
onSuccess(BaseClientPutter state)
Called on successful insert.
|
getRequestClient, onResume
void onGeneratedURI(FreenetURI uri, BaseClientPutter state)
state
- The original BaseClientPutter object which was returned by the .insert() method which
started this insert. Can be casted to the return type of that .insert().void onGeneratedMetadata(Bucket metadata, BaseClientPutter state)
metadata
- Bucket containing the metadata. Persistent if the insert
is persistent. Recipient may keep it, but must eventually free it. The
caller will not free it.state
- The original BaseClientPutter object which was returned by the .insert() method which
started this insert. Can be casted to the return type of that .insert().void onFetchable(BaseClientPutter state)
state
- The original BaseClientPutter object which was returned by the .insert() method which
started this insert. Can be casted to the return type of that .insert().void onSuccess(BaseClientPutter state)
state
- The original BaseClientPutter object which was returned by the .insert() method which
started this insert. Can be casted to the return type of that .insert() (to obtain the Bucket).void onFailure(InsertException e, BaseClientPutter state)
state
- The original BaseClientPutter object which was returned by the .insert() method which
started this insert. Can be casted to the return type of that .insert() (to obtain the Bucket).