Package org.ldk.structs
Class QueryChannelRange
- java.lang.Object
-
- org.ldk.structs.QueryChannelRange
-
public class QueryChannelRange extends Object
A query_channel_range message is used to query a peer for channel UTXOs in a range of blocks. The recipient of a query makes a best effort to reply to the query using one or more reply_channel_range messages.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description QueryChannelRange
clone()
Creates a copy of the QueryChannelRangeint
end_blocknum()
\n\t * Calculates the overflow safe ending block height for the query.\n\t * Overflow returns `0xffffffff`, otherwise returns `first_blocknum + number_of_blocks`\n\tprotected void
finalize()
byte[]
get_chain_hash()
The genesis hash of the blockchain being queriedint
get_first_blocknum()
The height of the first block for the channel UTXOs being queriedint
get_number_of_blocks()
The number of blocks to include in the query resultsstatic QueryChannelRange
of(byte[] chain_hash_arg, int first_blocknum_arg, int number_of_blocks_arg)
Constructs a new QueryChannelRange given each fieldstatic Result_QueryChannelRangeDecodeErrorZ
read(byte[] ser)
Read a QueryChannelRange from a byte array, created by QueryChannelRange_writevoid
set_chain_hash(byte[] val)
The genesis hash of the blockchain being queriedvoid
set_first_blocknum(int val)
The height of the first block for the channel UTXOs being queriedvoid
set_number_of_blocks(int val)
The number of blocks to include in the query resultsbyte[]
write()
Serialize the QueryChannelRange object into a byte array which can be read by QueryChannelRange_read
-
-
-
Method Detail
-
finalize
protected void finalize() throws Throwable
-
get_chain_hash
public byte[] get_chain_hash()
The genesis hash of the blockchain being queried
-
set_chain_hash
public void set_chain_hash(byte[] val)
The genesis hash of the blockchain being queried
-
get_first_blocknum
public int get_first_blocknum()
The height of the first block for the channel UTXOs being queried
-
set_first_blocknum
public void set_first_blocknum(int val)
The height of the first block for the channel UTXOs being queried
-
get_number_of_blocks
public int get_number_of_blocks()
The number of blocks to include in the query results
-
set_number_of_blocks
public void set_number_of_blocks(int val)
The number of blocks to include in the query results
-
of
public static QueryChannelRange of(byte[] chain_hash_arg, int first_blocknum_arg, int number_of_blocks_arg)
Constructs a new QueryChannelRange given each field
-
clone
public QueryChannelRange clone()
Creates a copy of the QueryChannelRange
-
end_blocknum
public int end_blocknum()
\n\t * Calculates the overflow safe ending block height for the query.\n\t * Overflow returns `0xffffffff`, otherwise returns `first_blocknum + number_of_blocks`\n\t
-
read
public static Result_QueryChannelRangeDecodeErrorZ read(byte[] ser)
Read a QueryChannelRange from a byte array, created by QueryChannelRange_write
-
write
public byte[] write()
Serialize the QueryChannelRange object into a byte array which can be read by QueryChannelRange_read
-
-