Class UnsignedNodeAnnouncement


  • public class UnsignedNodeAnnouncement
    extends Object
    The unsigned part of a [`node_announcement`] message. [`node_announcement`]: https://github.com/lightning/bolts/blob/master/07-routing-gossip.md#the-node_announcement-message
    • Method Detail

      • get_features

        public NodeFeatures get_features()
        The advertised features
      • set_features

        public void set_features​(NodeFeatures val)
        The advertised features
      • get_timestamp

        public int get_timestamp()
        A strictly monotonic announcement counter, with gaps allowed
      • set_timestamp

        public void set_timestamp​(int val)
        A strictly monotonic announcement counter, with gaps allowed
      • get_node_id

        public NodeId get_node_id()
        The `node_id` this announcement originated from (don't rebroadcast the `node_announcement` back to this node).
      • set_node_id

        public void set_node_id​(NodeId val)
        The `node_id` this announcement originated from (don't rebroadcast the `node_announcement` back to this node).
      • get_rgb

        public byte[] get_rgb()
        An RGB color for UI purposes
      • set_rgb

        public void set_rgb​(byte[] val)
        An RGB color for UI purposes
      • get_alias

        public NodeAlias get_alias()
        An alias, for UI purposes. This should be sanitized before use. There is no guarantee of uniqueness.
      • set_alias

        public void set_alias​(NodeAlias val)
        An alias, for UI purposes. This should be sanitized before use. There is no guarantee of uniqueness.
      • get_addresses

        public NetAddress[] get_addresses()
        List of addresses on which this node is reachable Returns a copy of the field.
      • set_addresses

        public void set_addresses​(NetAddress[] val)
        List of addresses on which this node is reachable
      • eq

        public boolean eq​(UnsignedNodeAnnouncement b)
        Checks if two UnsignedNodeAnnouncements contain equal inner contents. This ignores pointers and is_owned flags and looks at the values in fields. Two objects with NULL inner values will be considered "equal" here.
      • write

        public byte[] write()
        Serialize the UnsignedNodeAnnouncement object into a byte array which can be read by UnsignedNodeAnnouncement_read