#[non_exhaustive]pub enum PaymentError {
UnsupportedPaymentType,
LedgerUnreachable {
ledger: Principal,
},
LedgerWithdrawFromError {
ledger: Principal,
error: WithdrawFromError,
},
LedgerTransferFromError {
ledger: Principal,
error: TransferFromError,
},
InsufficientFunds {
needed: TokenAmount,
available: TokenAmount,
},
InvalidPatron,
}Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
UnsupportedPaymentType
LedgerUnreachable
LedgerWithdrawFromError
LedgerTransferFromError
InsufficientFunds
InvalidPatron
Trait Implementations§
Source§impl CandidType for PaymentError
impl CandidType for PaymentError
Source§impl Clone for PaymentError
impl Clone for PaymentError
Source§fn clone(&self) -> PaymentError
fn clone(&self) -> PaymentError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PaymentError
impl Debug for PaymentError
Source§impl<'de> Deserialize<'de> for PaymentError
impl<'de> Deserialize<'de> for PaymentError
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for PaymentError
impl PartialEq for PaymentError
Source§fn eq(&self, other: &PaymentError) -> bool
fn eq(&self, other: &PaymentError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for PaymentError
impl StructuralPartialEq for PaymentError
Auto Trait Implementations§
impl Freeze for PaymentError
impl RefUnwindSafe for PaymentError
impl Send for PaymentError
impl Sync for PaymentError
impl Unpin for PaymentError
impl UnsafeUnpin for PaymentError
impl UnwindSafe for PaymentError
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