Class Pong


  • public class Pong
    extends Object
    A [`pong`] message to be sent to or received from a peer. [`pong`]: https://github.com/lightning/bolts/blob/master/01-messaging.md#the-ping-and-pong-messages
    • Method Detail

      • get_byteslen

        public short get_byteslen()
        The pong packet size. This field is not sent on the wire. byteslen zeros are sent.
      • set_byteslen

        public void set_byteslen​(short val)
        The pong packet size. This field is not sent on the wire. byteslen zeros are sent.
      • of

        public static Pong of​(short byteslen_arg)
        Constructs a new Pong given each field
      • clone

        public Pong clone()
        Creates a copy of the Pong
        Overrides:
        clone in class Object
      • eq

        public boolean eq​(Pong b)
        Checks if two Pongs 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 Pong object into a byte array which can be read by Pong_read
      • read

        public static Result_PongDecodeErrorZ read​(byte[] ser)
        Read a Pong from a byte array, created by Pong_write