pub enum CreateOrderKind {
MarketSwap,
MarketIncrease,
MarketDecrease,
LimitSwap,
LimitIncrease,
LimitDecrease,
StopLossDecrease,
}Expand description
Create Order Kind.
Variants§
MarketSwap
Market Swap.
MarketIncrease
Market Increase.
MarketDecrease
Market Decrease.
LimitSwap
Limit Swap.
LimitIncrease
Limit Increase.
LimitDecrease
Limit Decrease.
StopLossDecrease
Stop-loss Decrease.
Implementations§
Source§impl CreateOrderKind
impl CreateOrderKind
Sourcepub fn is_increase(&self) -> bool
pub fn is_increase(&self) -> bool
Returns whether the order kind is “increase”.
Sourcepub fn is_decrease(&self) -> bool
pub fn is_decrease(&self) -> bool
Returns whether the ordr kind is “decrease”.
Trait Implementations§
Source§impl Clone for CreateOrderKind
impl Clone for CreateOrderKind
Source§fn clone(&self) -> CreateOrderKind
fn clone(&self) -> CreateOrderKind
Returns a duplicate 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 moreSource§impl Debug for CreateOrderKind
impl Debug for CreateOrderKind
Source§impl<'de> Deserialize<'de> for CreateOrderKind
impl<'de> Deserialize<'de> for CreateOrderKind
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 From<CreateOrderKind> for OrderKind
impl From<CreateOrderKind> for OrderKind
Source§fn from(kind: CreateOrderKind) -> Self
fn from(kind: CreateOrderKind) -> Self
Converts to this type from the input type.
Source§impl FromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
impl FromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
Source§impl OptionFromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
impl OptionFromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
Source§impl RefFromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
impl RefFromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
Source§type Abi = <JsType as RefFromWasmAbi>::Abi
type Abi = <JsType as RefFromWasmAbi>::Abi
The Wasm ABI type references to
Self are recovered from.Source§type Anchor = SelfOwner<CreateOrderKind>
type Anchor = SelfOwner<CreateOrderKind>
The type that holds the reference to
Self for the duration of the
invocation of the function that has an &Self parameter. This is
required to ensure that the lifetimes don’t persist beyond one function
call, and so that they remain anonymous.Source§impl Serialize for CreateOrderKind
impl Serialize for CreateOrderKind
Source§impl Tsify for CreateOrderKind
impl Tsify for CreateOrderKind
const DECL: &'static str = "/**\n * Create Order Kind.\n */\nexport type CreateOrderKind = \"MarketSwap\" | \"MarketIncrease\" | \"MarketDecrease\" | \"LimitSwap\" | \"LimitIncrease\" | \"LimitDecrease\" | \"StopLossDecrease\";"
const SERIALIZATION_CONFIG: SerializationConfig
Source§impl VectorFromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
impl VectorFromWasmAbi for CreateOrderKindwhere
Self: DeserializeOwned,
type Abi = <JsType as VectorFromWasmAbi>::Abi
unsafe fn vector_from_abi(js: Self::Abi) -> Box<[Self]>
Source§impl WasmDescribeVector for CreateOrderKind
impl WasmDescribeVector for CreateOrderKind
impl Copy for CreateOrderKind
Auto Trait Implementations§
impl Freeze for CreateOrderKind
impl RefUnwindSafe for CreateOrderKind
impl Send for CreateOrderKind
impl Sync for CreateOrderKind
impl Unpin for CreateOrderKind
impl UnwindSafe for CreateOrderKind
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§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§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more