Class StoreState

java.lang.Object
net.i2p.router.networkdb.kademlia.StoreState

class StoreState extends Object
Tracks the state of a StoreJob
  • Constructor Details

  • Method Details

    • getTarget

      public Hash getTarget()
    • getData

      public DatabaseEntry getData()
    • getPendingCount

      public int getPendingCount()
      The number of peers pending.
      Since:
      0.9.53 replaces getPending()
    • getAttempted

      public Set<Hash> getAttempted()
      The peers attempted OR skipped. DOES include skipped peers. Use getAttemptedCount for the number of attempts.
    • getAttemptedCount

      public int getAttemptedCount()
      The number of peers attempted. Does not include skipped peers. Do not use getAttempted().size() as that does include skipped peers.
      Since:
      0.9.53
    • getSuccessful

      public Hash getSuccessful()
      Return a successful peer (a random one if more than one was successful) or null.
      Since:
      0.9.53 formerly returned a copy of the Set
    • completed

      public boolean completed()
    • complete

      public void complete(boolean completed)
    • getCompleteCount

      public int getCompleteCount()
    • getWhenStarted

      public long getWhenStarted()
    • getWhenCompleted

      public long getWhenCompleted()
    • addPending

      public void addPending(Hash peer, MessageWrapper.WrappedMessage msg)
    • getPendingMessage

      public MessageWrapper.WrappedMessage getPendingMessage(Hash peer)
    • addPending

      public void addPending(Hash peer)
      Increments attempted count
    • addSkipped

      public void addSkipped(Hash peer)
      we aren't even going to try to contact this peer
    • confirmed

      public long confirmed(Hash peer)
    • replyTimeout

      public void replyTimeout(Hash peer)
    • toString

      public String toString()
      Overrides:
      toString in class Object