Skip to main content

MatchError

Enum MatchError 

pub enum MatchError {
    OrderNotFound(u64),
    OrderIdOutOfRange {
        order_id: u64,
        max_order_id: u64,
    },
    InvalidPrice(i64),
    InvalidQuantity(u64),
    RestingQuantityOverflow {
        price: i64,
        resting_quantity: u64,
        incoming_quantity: u64,
    },
    DuplicateOrderId(u64),
    BookFull(usize),
    InvalidTimeInForce {
        order_type: &'static str,
        tif: &'static str,
    },
    InconsistentQuantity {
        remaining: u64,
        original: u64,
    },
}

Variants§

§

OrderNotFound(u64)

§

OrderIdOutOfRange

Fields

§order_id: u64
§max_order_id: u64
§

InvalidPrice(i64)

§

InvalidQuantity(u64)

§

RestingQuantityOverflow

Fields

§price: i64
§resting_quantity: u64
§incoming_quantity: u64
§

DuplicateOrderId(u64)

§

BookFull(usize)

§

InvalidTimeInForce

Fields

§order_type: &'static str
§tif: &'static str
§

InconsistentQuantity

Fields

§remaining: u64
§original: u64

Implementations§

§

impl MatchError

pub const fn is_not_found(&self) -> bool

Trait Implementations§

§

impl Clone for MatchError

§

fn clone(&self) -> MatchError

1.0.0 (const: )§

fn clone_from(&mut self, source: &Self)

§

impl Debug for MatchError

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

§

impl Display for MatchError

§

fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result

§

impl Error for MatchError

1.30.0§

fn source(&self) -> Option<&(dyn Error + 'static)>

1.0.0§

fn description(&self) -> &str

👎Deprecated since 1.42.0:

use the Display impl or to_string()

1.0.0§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
§

impl PartialEq for MatchError

§

fn eq(&self, other: &MatchError) -> bool

1.0.0 (const: )§

fn ne(&self, other: &Rhs) -> bool

§

impl Eq for MatchError

§

impl StructuralPartialEq for MatchError

Auto Trait Implementations§

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

§

impl<T> CloneToUninit for T
where T: Clone,

§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
§

impl<T> From<T> for T

§

fn from(t: T) -> T

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

§

fn to_owned(&self) -> T

§

fn clone_into(&self, target: &mut T)

§

impl<T> ToString for T
where T: Display + ?Sized,

§

fn to_string(&self) -> String

§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>