Struct lightning::chain::channelmonitor::ChannelMonitorUpdate
source · [−]pub struct ChannelMonitorUpdate {
pub update_id: u64,
/* private fields */
}
Expand description
An update generated by the underlying Channel itself which contains some new information the ChannelMonitor should be made aware of.
Fields
update_id: u64
The sequence number of this update. Updates must be replayed in-order according to this sequence number (and updates may panic if they are not). The update_id values are strictly increasing and increase by one for each new update, with one exception specified below.
This sequence number is also used to track up to which points updates which returned ChannelMonitorUpdateErr::TemporaryFailure have been applied to all copies of a given ChannelMonitor when ChannelManager::channel_monitor_updated is called.
The only instance where update_id values are not strictly increasing is the case where we
allow post-force-close updates with a special update ID of CLOSED_CHANNEL_UPDATE_ID
. See
its docs for more details.
Trait Implementations
sourceimpl Clone for ChannelMonitorUpdate
impl Clone for ChannelMonitorUpdate
sourcefn clone(&self) -> ChannelMonitorUpdate
fn clone(&self) -> ChannelMonitorUpdate
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Readable for ChannelMonitorUpdate
impl Readable for ChannelMonitorUpdate
sourceimpl Writeable for ChannelMonitorUpdate
impl Writeable for ChannelMonitorUpdate
sourcefn encode(&self) -> Vec<u8>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A> where
A: Allocator,
fn encode(&self) -> Vec<u8>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A> where
A: Allocator,
A: Allocator,
Writes self out to a Vec
sourcefn serialized_length(&self) -> usize
fn serialized_length(&self) -> usize
Gets the length of this object after it has been serialized. This can be overridden to optimize cases where we prepend an object with its length. Read more
Auto Trait Implementations
impl RefUnwindSafe for ChannelMonitorUpdate
impl Send for ChannelMonitorUpdate
impl Sync for ChannelMonitorUpdate
impl Unpin for ChannelMonitorUpdate
impl UnwindSafe for ChannelMonitorUpdate
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> MaybeReadable for T where
T: Readable,
impl<T> MaybeReadable for T where
T: Readable,
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more