Class ChannelTypeFeatures


  • public class ChannelTypeFeatures
    extends Object
    Features used within the channel_type field in an OpenChannel message. A channel is always of some known \"type\", describing the transaction formats used and the exact semantics of our interaction with our peer. Note that because a channel is a specific type which is proposed by the opener and accepted by the counterparty, only required features are allowed here. This is serialized differently from other feature types - it is not prefixed by a length, and thus must only appear inside a TLV where its length is known in advance.
    • Method Detail

      • eq

        public boolean eq​(ChannelTypeFeatures b)
        Checks if two ChannelTypeFeaturess 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.
      • empty

        public static ChannelTypeFeatures empty()
        Create a blank Features with no features set
      • requires_unknown_bits

        public boolean requires_unknown_bits()
        Returns true if this `Features` object contains unknown feature flags which are set as \"required\".
      • write

        public byte[] write()
        Serialize the ChannelTypeFeatures object into a byte array which can be read by ChannelTypeFeatures_read
      • set_static_remote_key_optional

        public void set_static_remote_key_optional()
        Set this feature as optional.
      • set_static_remote_key_required

        public void set_static_remote_key_required()
        Set this feature as required.
      • supports_static_remote_key

        public boolean supports_static_remote_key()
        Checks if this feature is supported.
      • requires_static_remote_key

        public boolean requires_static_remote_key()
        Checks if this feature is required.
      • set_anchors_zero_fee_htlc_tx_optional

        public void set_anchors_zero_fee_htlc_tx_optional()
        Set this feature as optional.
      • set_anchors_zero_fee_htlc_tx_required

        public void set_anchors_zero_fee_htlc_tx_required()
        Set this feature as required.
      • supports_anchors_zero_fee_htlc_tx

        public boolean supports_anchors_zero_fee_htlc_tx()
        Checks if this feature is supported.
      • requires_anchors_zero_fee_htlc_tx

        public boolean requires_anchors_zero_fee_htlc_tx()
        Checks if this feature is required.
      • set_scid_privacy_optional

        public void set_scid_privacy_optional()
        Set this feature as optional.
      • set_scid_privacy_required

        public void set_scid_privacy_required()
        Set this feature as required.
      • supports_scid_privacy

        public boolean supports_scid_privacy()
        Checks if this feature is supported.
      • requires_scid_privacy

        public boolean requires_scid_privacy()
        Checks if this feature is required.
      • set_zero_conf_optional

        public void set_zero_conf_optional()
        Set this feature as optional.
      • set_zero_conf_required

        public void set_zero_conf_required()
        Set this feature as required.
      • supports_zero_conf

        public boolean supports_zero_conf()
        Checks if this feature is supported.
      • requires_zero_conf

        public boolean requires_zero_conf()
        Checks if this feature is required.