pub enum Bolt11SemanticError {
NoPaymentHash,
MultiplePaymentHashes,
NoDescription,
MultipleDescriptions,
NoPaymentSecret,
MultiplePaymentSecrets,
InvalidFeatures,
InvalidRecoveryId,
InvalidSignature,
ImpreciseAmount,
}
Expand description
Errors that may occur when converting a RawBolt11Invoice
to a Bolt11Invoice
. They relate to
the requirements sections in BOLT #11
Variants§
NoPaymentHash
The invoice is missing the mandatory payment hash
MultiplePaymentHashes
The invoice has multiple payment hashes which isn’t allowed
NoDescription
No description or description hash are part of the invoice
MultipleDescriptions
The invoice contains multiple descriptions and/or description hashes which isn’t allowed
NoPaymentSecret
The invoice is missing the mandatory payment secret, which all modern lightning nodes should provide.
MultiplePaymentSecrets
The invoice contains multiple payment secrets
InvalidFeatures
The invoice’s features are invalid
InvalidRecoveryId
The recovery id doesn’t fit the signature/pub key
InvalidSignature
The invoice’s signature is invalid
ImpreciseAmount
The invoice’s amount was not a whole number of millisatoshis
Trait Implementations§
§impl Clone for Bolt11SemanticError
impl Clone for Bolt11SemanticError
§fn clone(&self) -> Bolt11SemanticError
fn clone(&self) -> Bolt11SemanticError
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more§impl Debug for Bolt11SemanticError
impl Debug for Bolt11SemanticError
§impl Display for Bolt11SemanticError
impl Display for Bolt11SemanticError
§impl Error for Bolt11SemanticError
impl Error for Bolt11SemanticError
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
§impl From<Bolt11SemanticError> for InvoiceError
impl From<Bolt11SemanticError> for InvoiceError
§fn from(err: Bolt11SemanticError) -> InvoiceError
fn from(err: Bolt11SemanticError) -> InvoiceError
Converts to this type from the input type.
§impl From<Bolt11SemanticError> for ParseOrSemanticError
impl From<Bolt11SemanticError> for ParseOrSemanticError
§fn from(e: Bolt11SemanticError) -> ParseOrSemanticError
fn from(e: Bolt11SemanticError) -> ParseOrSemanticError
Converts to this type from the input type.
§impl PartialEq for Bolt11SemanticError
impl PartialEq for Bolt11SemanticError
impl Eq for Bolt11SemanticError
impl StructuralPartialEq for Bolt11SemanticError
Auto Trait Implementations§
impl Freeze for Bolt11SemanticError
impl RefUnwindSafe for Bolt11SemanticError
impl Send for Bolt11SemanticError
impl Sync for Bolt11SemanticError
impl Unpin for Bolt11SemanticError
impl UnwindSafe for Bolt11SemanticError
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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>
Wrap the input message
T
in a tonic::Request