public class SingleFileFetcher extends SimpleSingleFileFetcher
Modifier and Type | Class and Description |
---|---|
static class |
SingleFileFetcher.MyUSKFetcherCallback |
cancelled, cooldownWakeupTime, ctx, deleteFetchContext, finished, key
parent
parentGrabArray, persistent, realTimeFlag
Constructor and Description |
---|
SingleFileFetcher(ClientRequester parent,
GetCompletionCallback cb,
ClientMetadata metadata,
ClientKey key,
java.util.List<java.lang.String> metaStrings,
FreenetURI origURI,
int addedMetaStrings,
FetchContext ctx,
boolean deleteFetchContext,
boolean realTimeFlag,
ArchiveContext actx,
ArchiveHandler ah,
Metadata archiveMetadata,
int maxRetries,
int recursionLevel,
boolean dontTellClientGet,
long l,
boolean isEssential,
boolean isFinal,
boolean topDontCompress,
short topCompatibilityMode,
ClientContext context,
boolean hasInitialMetadata)
Create a new SingleFileFetcher and register self.
|
SingleFileFetcher(SingleFileFetcher fetcher,
boolean persistent,
boolean deleteFetchContext,
Metadata newMeta,
GetCompletionCallback callback,
FetchContext ctx2,
ClientContext context)
Copy constructor, modifies a few given fields, don't call schedule().
|
Modifier and Type | Method and Description |
---|---|
static ClientGetState |
create(ClientRequester requester,
GetCompletionCallback cb,
FreenetURI uri,
FetchContext ctx,
ArchiveContext actx,
int maxRetries,
int recursionLevel,
boolean dontTellClientGet,
long l,
boolean isEssential,
boolean isFinal,
ClientContext context,
boolean realTimeFlag,
boolean hasInitialMetadata)
Create a fetcher for a key.
|
protected void |
innerWrapHandleMetadata(boolean notFinalizedSize,
ClientContext context) |
void |
onSuccess(ClientKeyBlock block,
boolean fromStore,
java.lang.Object token,
ClientContext context)
Called when/if the low-level request succeeds.
|
protected void |
onSuccess(FetchResult result,
ClientContext context)
Will be overridden by SingleFileFetcher
|
cancel, extract, getClientGetState, getToken, notFoundInStore, onBlockDecodeError, onFailure, onFailure, onShutdown
chooseKey, countAllKeys, countSendableKeys, getClient, getClientRequest, getContext, getCooldownWakeup, getKey, getPriorityClass, getRequest, getWakeupTime, isCancelled, isEmpty, isSSK, listKeys, makeKeyListener, onChangedFetchContext, onEnterFiniteCooldown, onGotKey, onResume, onSuccess, preRegister, reschedule, retry, schedule, unregister, unregisterAll
clearWakeupTime, getNodeKey, getScheduler, getSender, internalError, isInsert, reduceWakeupTime, translateException
getParentGrabArray, getSchedulerGroup, hashCode, knowsParentGrabArray, objectToString, persistent, realTimeFlag, setParentGrabArray
clone, equals, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
onResume, schedule
public SingleFileFetcher(ClientRequester parent, GetCompletionCallback cb, ClientMetadata metadata, ClientKey key, java.util.List<java.lang.String> metaStrings, FreenetURI origURI, int addedMetaStrings, FetchContext ctx, boolean deleteFetchContext, boolean realTimeFlag, ArchiveContext actx, ArchiveHandler ah, Metadata archiveMetadata, int maxRetries, int recursionLevel, boolean dontTellClientGet, long l, boolean isEssential, boolean isFinal, boolean topDontCompress, short topCompatibilityMode, ClientContext context, boolean hasInitialMetadata) throws FetchException
topCompatibilityMode
- topDontCompress
- hasInitialMetadata
- FetchException
public SingleFileFetcher(SingleFileFetcher fetcher, boolean persistent, boolean deleteFetchContext, Metadata newMeta, GetCompletionCallback callback, FetchContext ctx2, ClientContext context) throws FetchException
FetchException
public void onSuccess(ClientKeyBlock block, boolean fromStore, java.lang.Object token, ClientContext context)
BaseSingleFileFetcher
onSuccess
in class SimpleSingleFileFetcher
protected void onSuccess(FetchResult result, ClientContext context)
SimpleSingleFileFetcher
onSuccess
in class SimpleSingleFileFetcher
protected void innerWrapHandleMetadata(boolean notFinalizedSize, ClientContext context)
public static ClientGetState create(ClientRequester requester, GetCompletionCallback cb, FreenetURI uri, FetchContext ctx, ArchiveContext actx, int maxRetries, int recursionLevel, boolean dontTellClientGet, long l, boolean isEssential, boolean isFinal, ClientContext context, boolean realTimeFlag, boolean hasInitialMetadata) throws java.net.MalformedURLException, FetchException
java.net.MalformedURLException
FetchException