java.lang.Object
net.i2p.router.networkdb.kademlia.MessageWrapper.WrappedMessage
Enclosing class:
MessageWrapper

static class MessageWrapper.WrappedMessageextends Object
Wrapper so that we can keep track of the key and tags for later notification to the SKM.
  • Field Details

    • msg

      private GarlicMessage msg
      The wrapped GarlicMessage.
    • skm

      private SessionKeyManager skm
      The session key manager used for wrapping.
    • sentTo

      private PublicKey sentTo
      The recipient's public key.
    • sessionKey

      private SessionKey sessionKey
      The session key used for wrapping.
    • tsh

      private TagSetHandle tsh
      Handle for the delivered tags.
  • Constructor Details

    • WrappedMessage

      WrappedMessage(GarlicMessage msg, SessionKeyManager skm, PublicKey sentTo, SessionKey sentKey, TagSetHandle tsh)
      Wrapped message.
      Parameters:
      msg - the garlic message that was built, to be sent as-is
      skm - the session key manager that owns the session key, notified on ack or failure
      sentTo - the recipient's public key, used when reporting tags
      sentKey - the session key the tags were delivered under, or null if none were sent
      tsh - handle for the delivered tags, or null if none were sent
  • Method Details

    • getMessage

      GarlicMessage getMessage()
      The wrapped I2NP message.
      Returns:
      the garlic message to hand to the transport for delivery
    • acked

      void acked()
      Delivered tags (if any) were acked.
    • fail

      void fail()
      Delivered tags (if any) were not acked.