Enum lightning_invoice::Fallback
source · pub enum Fallback {
SegWitProgram {
version: WitnessVersion,
program: Vec<u8>,
},
PubKeyHash(PubkeyHash),
ScriptHash(ScriptHash),
}
Expand description
Fallback address in case no LN payment is possible
Variants§
Trait Implementations§
source§impl Base32Len for Fallback
impl Base32Len for Fallback
source§fn base32_len(&self) -> usize
fn base32_len(&self) -> usize
Calculate the base32 serialized length
source§impl FromBase32 for Fallback
impl FromBase32 for Fallback
§type Err = Bolt11ParseError
type Err = Bolt11ParseError
The associated error which can be returned from parsing (e.g. because of bad padding).
source§fn from_base32(field_data: &[u5]) -> Result<Fallback, Bolt11ParseError>
fn from_base32(field_data: &[u5]) -> Result<Fallback, Bolt11ParseError>
Convert a base32 slice to
Self
.source§impl Ord for Fallback
impl Ord for Fallback
source§impl PartialEq for Fallback
impl PartialEq for Fallback
source§impl PartialOrd for Fallback
impl PartialOrd for Fallback
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl ToBase32 for Fallback
impl ToBase32 for Fallback
source§fn write_base32<W: WriteBase32>(
&self,
writer: &mut W
) -> Result<(), <W as WriteBase32>::Err>
fn write_base32<W: WriteBase32>( &self, writer: &mut W ) -> Result<(), <W as WriteBase32>::Err>
Encode as base32 and write it to the supplied writer
Implementations shouldn’t allocate.
impl Eq for Fallback
impl StructuralEq for Fallback
impl StructuralPartialEq for Fallback
Auto Trait Implementations§
impl RefUnwindSafe for Fallback
impl Send for Fallback
impl Sync for Fallback
impl Unpin for Fallback
impl UnwindSafe for Fallback
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
Mutably borrows from an owned value. Read more