net.i2p.router.networkdb.kademlia
Class SearchState
java.lang.Object
net.i2p.router.networkdb.kademlia.SearchState
- class SearchState
- extends java.lang.Object
Data related to a particular search
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
SearchState
public SearchState(RouterContext context,
Hash key)
getTarget
public Hash getTarget()
getPending
public java.util.Set getPending()
getAttempted
public java.util.Set getAttempted()
getClosestAttempted
public java.util.Set getClosestAttempted(int max)
wasAttempted
public boolean wasAttempted(Hash peer)
getSuccessful
public java.util.Set getSuccessful()
getFailed
public java.util.Set getFailed()
completed
public boolean completed()
complete
public void complete(boolean completed)
getWhenStarted
public long getWhenStarted()
getWhenCompleted
public long getWhenCompleted()
addPending
public void addPending(java.util.Collection pending)
dataFound
public long dataFound(Hash peer)
- how long did it take to get the reply, or -1 if we don't know
replyFound
public long replyFound(Hash peer)
- how long did it take to get the reply, or -1 if we dont know
replyTimeout
public void replyTimeout(Hash peer)
toString
public java.lang.String toString()