Package org.ldk.structs
Class ChannelReestablish
- java.lang.Object
-
- org.ldk.structs.ChannelReestablish
-
public class ChannelReestablish extends Object
A [`channel_reestablish`] message to be sent to or received from a peer. [`channel_reestablish`]: https://github.com/lightning/bolts/blob/master/02-peer-protocol.md#message-retransmission
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ChannelReestablishclone()Creates a copy of the ChannelReestablishbooleaneq(ChannelReestablish b)Checks if two ChannelReestablishs contain equal inner contents.booleanequals(Object o)protected voidfinalize()byte[]get_channel_id()The channel IDbyte[]get_my_current_per_commitment_point()The sender's per-commitment point for their current commitment transactionOption_ThirtyTwoBytesZget_next_funding_txid()The next funding transaction IDlongget_next_local_commitment_number()The next commitment number for the senderlongget_next_remote_commitment_number()The next commitment number for the recipientbyte[]get_your_last_per_commitment_secret()Proof that the sender knows the per-commitment secret of a specific commitment transaction belonging to the recipientstatic ChannelReestablishof(byte[] channel_id_arg, long next_local_commitment_number_arg, long next_remote_commitment_number_arg, byte[] your_last_per_commitment_secret_arg, byte[] my_current_per_commitment_point_arg, Option_ThirtyTwoBytesZ next_funding_txid_arg)Constructs a new ChannelReestablish given each fieldstatic Result_ChannelReestablishDecodeErrorZread(byte[] ser)Read a ChannelReestablish from a byte array, created by ChannelReestablish_writevoidset_channel_id(byte[] val)The channel IDvoidset_my_current_per_commitment_point(byte[] val)The sender's per-commitment point for their current commitment transactionvoidset_next_funding_txid(Option_ThirtyTwoBytesZ val)The next funding transaction IDvoidset_next_local_commitment_number(long val)The next commitment number for the sendervoidset_next_remote_commitment_number(long val)The next commitment number for the recipientvoidset_your_last_per_commitment_secret(byte[] val)Proof that the sender knows the per-commitment secret of a specific commitment transaction belonging to the recipientbyte[]write()Serialize the ChannelReestablish object into a byte array which can be read by ChannelReestablish_read
-
-
-
Method Detail
-
finalize
protected void finalize() throws Throwable
-
get_channel_id
public byte[] get_channel_id()
The channel ID
-
set_channel_id
public void set_channel_id(byte[] val)
The channel ID
-
get_next_local_commitment_number
public long get_next_local_commitment_number()
The next commitment number for the sender
-
set_next_local_commitment_number
public void set_next_local_commitment_number(long val)
The next commitment number for the sender
-
get_next_remote_commitment_number
public long get_next_remote_commitment_number()
The next commitment number for the recipient
-
set_next_remote_commitment_number
public void set_next_remote_commitment_number(long val)
The next commitment number for the recipient
-
get_your_last_per_commitment_secret
public byte[] get_your_last_per_commitment_secret()
Proof that the sender knows the per-commitment secret of a specific commitment transaction belonging to the recipient
-
set_your_last_per_commitment_secret
public void set_your_last_per_commitment_secret(byte[] val)
Proof that the sender knows the per-commitment secret of a specific commitment transaction belonging to the recipient
-
get_my_current_per_commitment_point
public byte[] get_my_current_per_commitment_point()
The sender's per-commitment point for their current commitment transaction
-
set_my_current_per_commitment_point
public void set_my_current_per_commitment_point(byte[] val)
The sender's per-commitment point for their current commitment transaction
-
get_next_funding_txid
public Option_ThirtyTwoBytesZ get_next_funding_txid()
The next funding transaction ID
-
set_next_funding_txid
public void set_next_funding_txid(Option_ThirtyTwoBytesZ val)
The next funding transaction ID
-
of
public static ChannelReestablish of(byte[] channel_id_arg, long next_local_commitment_number_arg, long next_remote_commitment_number_arg, byte[] your_last_per_commitment_secret_arg, byte[] my_current_per_commitment_point_arg, Option_ThirtyTwoBytesZ next_funding_txid_arg)
Constructs a new ChannelReestablish given each field
-
clone
public ChannelReestablish clone()
Creates a copy of the ChannelReestablish
-
eq
public boolean eq(ChannelReestablish b)
Checks if two ChannelReestablishs 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 ChannelReestablish object into a byte array which can be read by ChannelReestablish_read
-
read
public static Result_ChannelReestablishDecodeErrorZ read(byte[] ser)
Read a ChannelReestablish from a byte array, created by ChannelReestablish_write
-
-