#[non_exhaustive]pub enum MarketQuoteError {
Quote(QuoteError),
FeeOutOfRange,
SupplyExhausted,
ExceedsQuoteHeld,
}Expand description
A trade that the program refuses.
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.
Quote(QuoteError)
FeeOutOfRange
SupplyExhausted
real_base_reserves is 0. The program error is ThresholdReached.
ExceedsQuoteHeld
The sell takes more quote from the curve than real_quote_reserves.
Trait Implementations§
Source§impl Clone for MarketQuoteError
impl Clone for MarketQuoteError
impl Copy for MarketQuoteError
Source§impl Debug for MarketQuoteError
impl Debug for MarketQuoteError
Source§impl Display for MarketQuoteError
impl Display for MarketQuoteError
impl Eq for MarketQuoteError
Source§impl Error for MarketQuoteError
impl Error for MarketQuoteError
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()
Source§impl From<QuoteError> for MarketQuoteError
impl From<QuoteError> for MarketQuoteError
Source§fn from(error: QuoteError) -> Self
fn from(error: QuoteError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for MarketQuoteError
impl PartialEq for MarketQuoteError
impl StructuralPartialEq for MarketQuoteError
Auto Trait Implementations§
impl Freeze for MarketQuoteError
impl RefUnwindSafe for MarketQuoteError
impl Send for MarketQuoteError
impl Sync for MarketQuoteError
impl Unpin for MarketQuoteError
impl UnsafeUnpin for MarketQuoteError
impl UnwindSafe for MarketQuoteError
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