Enum lightning::ln::msgs::OptionalField [−][src]
pub enum OptionalField<T> { Present(T), Absent, }
Expand description
Messages could have optional fields to use with extended features
As we wish to serialize these differently from Option
Variants
Optional field is included in message
Optional field is absent in message
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Writes self out to a Vec
Writes self out to a Vec
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
Writes self out to a Vec
Writes self out to a Vec
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<T> RefUnwindSafe for OptionalField<T> where
T: RefUnwindSafe,
impl<T> Send for OptionalField<T> where
T: Send,
impl<T> Sync for OptionalField<T> where
T: Sync,
impl<T> Unpin for OptionalField<T> where
T: Unpin,
impl<T> UnwindSafe for OptionalField<T> where
T: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more