Struct kucoin_rs::kucoin::trade::OrderOptionals [−][src]
pub struct OrderOptionals<'a> { pub remark: Option<&'a str>, pub stop: Option<&'a str>, pub stop_price: Option<&'a str>, pub stp: Option<&'a str>, pub trade_type: Option<&'a str>, pub time_in_force: Option<&'a str>, pub cancel_after: Option<i64>, pub post_only: Option<bool>, pub hidden: Option<bool>, pub iceberg: Option<bool>, pub visible_size: Option<&'a str>, }
OrderOptionals contains a builder pattern that can be used to more easily take advantage of optional inputs.
Example:
use kucoin_rs::kucoin::trade::OrderOptionals; let options = OrderOptionals::new() .remark("Example of OrderOptionals builder pattern") .stp("CO") .hidden(true) .build();
See the Kucoin documentation for full list of options relative to market and limit orders.
Fields
remark: Option<&'a str>
stop: Option<&'a str>
stop_price: Option<&'a str>
stp: Option<&'a str>
trade_type: Option<&'a str>
time_in_force: Option<&'a str>
cancel_after: Option<i64>
post_only: Option<bool>
iceberg: Option<bool>
visible_size: Option<&'a str>
Implementations
impl<'a> OrderOptionals<'a>
[src]
impl<'a> OrderOptionals<'a>
[src]Generates new empty OrderOptionals struct ready for building.
pub fn new() -> Self
[src]
pub fn remark(&mut self, r: &'a str) -> &mut Self
[src]
pub fn stop(&mut self, s: &'a str) -> &mut Self
[src]
pub fn stop_price(&mut self, s: &'a str) -> &mut Self
[src]
pub fn stp(&mut self, s: &'a str) -> &mut Self
[src]
pub fn time_in_force(&mut self, t: &'a str) -> &mut Self
[src]
pub fn trade_type(&mut self, t: &'a str) -> &mut Self
[src]
pub fn cancel_after(&mut self, c: i64) -> &mut Self
[src]
pub fn post_only(&mut self, p: bool) -> &mut Self
[src]
pub fn hidden(&mut self, h: bool) -> &mut Self
[src]
pub fn iceberg(&mut self, i: bool) -> &mut Self
[src]
pub fn visible_size(&mut self, v: &'a str) -> &mut Self
[src]
pub fn build(&self) -> Self
[src]
Builds an OrderOptional Type from chained optional funtions to be used with posting orders. Only contains optional inputs the post order functions require specific required inputs. See those functions’ documentation for details.
Trait Implementations
impl<'a> Clone for OrderOptionals<'a>
[src]
impl<'a> Clone for OrderOptionals<'a>
[src]fn clone(&self) -> OrderOptionals<'a>
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<'a> Default for OrderOptionals<'a>
[src]
impl<'a> Default for OrderOptionals<'a>
[src]fn default() -> OrderOptionals<'a>
[src]
impl<'a> PartialEq<OrderOptionals<'a>> for OrderOptionals<'a>
[src]
impl<'a> PartialEq<OrderOptionals<'a>> for OrderOptionals<'a>
[src]fn eq(&self, other: &OrderOptionals<'a>) -> bool
[src]
fn ne(&self, other: &OrderOptionals<'a>) -> bool
[src]
impl<'a> StructuralPartialEq for OrderOptionals<'a>
[src]
impl<'a> StructuralPartialEq for OrderOptionals<'a>
[src]Auto Trait Implementations
impl<'a> RefUnwindSafe for OrderOptionals<'a>
impl<'a> RefUnwindSafe for OrderOptionals<'a>
impl<'a> Send for OrderOptionals<'a>
impl<'a> Send for OrderOptionals<'a>
impl<'a> Sync for OrderOptionals<'a>
impl<'a> Sync for OrderOptionals<'a>
impl<'a> Unpin for OrderOptionals<'a>
impl<'a> Unpin for OrderOptionals<'a>
impl<'a> UnwindSafe for OrderOptionals<'a>
impl<'a> UnwindSafe for OrderOptionals<'a>
Blanket Implementations
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,