All Implemented Interfaces:
Serializable, DataStructure

public class RouterIdentityextends KeysAndCert
Defines the unique identifier of a router, including any certificate or public key.

As of 0.9.9 this data structure is immutable after the two keys and the certificate are set; attempts to change them will throw an IllegalStateException.

See Also:
  • Constructor Details

    • RouterIdentity

      public RouterIdentity()
      Both keys and the certificate are inherited from KeysAndCert and stay null until readBytes() or a subclass sets them, so a fresh identity carries no identity yet.
  • Method Details

    • isHidden

      public boolean isHidden()
      This router specified that they should not be used as a part of a tunnel, nor queried for the netDb, and that disclosure of their contact information should be limited.

      This is ONLY if the certificate is a hidden type. Hidden mode may also be specified with a capability in the RouterInfo.

      Not recommended for direct use. Use of RouterInfo.isHidden() (which calls this) is preferred.

      Returns:
      true if the certificate type limits this router's reachability
    • equals

      public boolean equals(Object o)
      Description copied from class: KeysAndCert
      Compares this KeysAndCert with another object for equality.
      Overrides:
      equals in class KeysAndCert
    • hashCode

      public int hashCode()
      Description copied from class: KeysAndCert
      The signing key has enough randomness in it to use it by itself for speed.
      Overrides:
      hashCode in class KeysAndCert