java.lang.Object
net.i2p.router.JobImpl
net.i2p.router.tunnel.pool.TestJob.OnTestReply
All Implemented Interfaces:
Job, ReplyJob
Enclosing class:
TestJob

private class TestJob.OnTestReplyextends JobImpl implements ReplyJob
Handles the reply to one test message.
  • Field Details

    • _successTime

      private long _successTime
      When the reply arrived, zero until it does.
    • _sentMessage

      private OutNetMessage _sentMessage
      The outbound message awaiting its reply.
    • _token

      private final TestJob.RoundToken _token
      The round this reply belongs to.
  • Constructor Details

    • OnTestReply

      public OnTestReply(TestJob.RoundToken token)
      Handle the test reply and report the result.
      Parameters:
      token - the round this callback was created for
  • Method Details

    • getName

      public String getName()
      Store the outbound message sent to the gateway for cleanup.
      Specified by:
      getName in interface Job
      Returns:
      the descriptive name of the task
    • setSentMessage

      public void setSentMessage(OutNetMessage m)
      Remembers the message so its reply can release it.
      Parameters:
      m - the message awaiting a reply
    • runJob

      public void runJob()
      Complete the test, reporting success or failure.
      Specified by:
      runJob in interface Job
    • setMessage

      public void setMessage(I2NPMessage message)
      Record the arrival time of the reply message.
      Specified by:
      setMessage in interface ReplyJob
      Parameters:
      message - the received I2NP message