pub struct ChannelUpdate {
pub signature: Vec<u8>,
pub chain_hash: Vec<u8>,
pub chan_id: u64,
pub timestamp: u32,
pub message_flags: u32,
pub channel_flags: u32,
pub time_lock_delta: u32,
pub htlc_minimum_msat: u64,
pub base_fee: u32,
pub fee_rate: u32,
pub htlc_maximum_msat: u64,
pub extra_opaque_data: Vec<u8>,
}
Fields§
§signature: Vec<u8>
The signature that validates the announced data and proves the ownership of node id.
chain_hash: Vec<u8>
The target chain that this channel was opened within. This value should be the genesis hash of the target chain. Along with the short channel ID, this uniquely identifies the channel globally in a blockchain.
chan_id: u64
The unique description of the funding transaction.
timestamp: u32
A timestamp that allows ordering in the case of multiple announcements. We should ignore the message if timestamp is not greater than the last-received.
message_flags: u32
The bitfield that describes whether optional fields are present in this update. Currently, the least-significant bit must be set to 1 if the optional field MaxHtlc is present.
channel_flags: u32
The bitfield that describes additional meta-data concerning how the update is to be interpreted. Currently, the least-significant bit must be set to 0 if the creating node corresponds to the first node in the previously sent channel announcement and 1 otherwise. If the second bit is set, then the channel is set to be disabled.
time_lock_delta: u32
The minimum number of blocks this node requires to be added to the expiry of HTLCs. This is a security parameter determined by the node operator. This value represents the required gap between the time locks of the incoming and outgoing HTLC’s set to this node.
htlc_minimum_msat: u64
The minimum HTLC value which will be accepted.
base_fee: u32
The base fee that must be used for incoming HTLC’s to this particular channel. This value will be tacked onto the required for a payment independent of the size of the payment.
fee_rate: u32
The fee rate that will be charged per millionth of a satoshi.
htlc_maximum_msat: u64
The maximum HTLC value which will be accepted.
extra_opaque_data: Vec<u8>
The set of data that was appended to this message, some of which we may not actually know how to iterate or parse. By holding onto this data, we ensure that we’re able to properly validate the set of signatures that cover these new fields, and ensure we’re able to make upgrades to the network in a forwards compatible manner.
Trait Implementations§
Source§impl Clone for ChannelUpdate
impl Clone for ChannelUpdate
Source§fn clone(&self) -> ChannelUpdate
fn clone(&self) -> ChannelUpdate
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for ChannelUpdate
impl Debug for ChannelUpdate
Source§impl Default for ChannelUpdate
impl Default for ChannelUpdate
Source§fn default() -> ChannelUpdate
fn default() -> ChannelUpdate
Source§impl Message for ChannelUpdate
impl Message for ChannelUpdate
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>
fn decode<B>(buf: B) -> Result<Self, DecodeError>
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
self
.Source§impl PartialEq for ChannelUpdate
impl PartialEq for ChannelUpdate
impl StructuralPartialEq for ChannelUpdate
Auto Trait Implementations§
impl Freeze for ChannelUpdate
impl RefUnwindSafe for ChannelUpdate
impl Send for ChannelUpdate
impl Sync for ChannelUpdate
impl Unpin for ChannelUpdate
impl UnwindSafe for ChannelUpdate
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request