pub struct BinanceNewOrderParamsBuilder { /* private fields */ }Expand description
Builder for BinanceNewOrderParams.
Implementations§
Source§impl BinanceNewOrderParamsBuilder
impl BinanceNewOrderParamsBuilder
Sourcepub fn symbol<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn symbol<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Trading symbol (required).
Sourcepub fn side<VALUE: Into<BinanceSide>>(&mut self, value: VALUE) -> &mut Self
pub fn side<VALUE: Into<BinanceSide>>(&mut self, value: VALUE) -> &mut Self
Order side (required).
Sourcepub fn order_type<VALUE: Into<BinanceFuturesOrderType>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn order_type<VALUE: Into<BinanceFuturesOrderType>>( &mut self, value: VALUE, ) -> &mut Self
Order type (required).
Sourcepub fn position_side<VALUE: Into<BinancePositionSide>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn position_side<VALUE: Into<BinancePositionSide>>( &mut self, value: VALUE, ) -> &mut Self
Position side (required for hedge mode).
Sourcepub fn time_in_force<VALUE: Into<BinanceTimeInForce>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn time_in_force<VALUE: Into<BinanceTimeInForce>>( &mut self, value: VALUE, ) -> &mut Self
Time in force.
Sourcepub fn reduce_only<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn reduce_only<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Reduce only flag.
Sourcepub fn new_client_order_id<VALUE: Into<String>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn new_client_order_id<VALUE: Into<String>>( &mut self, value: VALUE, ) -> &mut Self
Client order ID.
Sourcepub fn stop_price<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn stop_price<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Stop price.
Sourcepub fn close_position<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn close_position<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Close position flag.
Sourcepub fn activation_price<VALUE: Into<String>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn activation_price<VALUE: Into<String>>( &mut self, value: VALUE, ) -> &mut Self
Activation price for trailing stop.
Sourcepub fn callback_rate<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn callback_rate<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Callback rate for trailing stop.
Sourcepub fn working_type<VALUE: Into<BinanceWorkingType>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn working_type<VALUE: Into<BinanceWorkingType>>( &mut self, value: VALUE, ) -> &mut Self
Working type (MARK_PRICE or CONTRACT_PRICE).
Sourcepub fn price_protect<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn price_protect<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Price protect flag.
Sourcepub fn new_order_resp_type<VALUE: Into<String>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn new_order_resp_type<VALUE: Into<String>>( &mut self, value: VALUE, ) -> &mut Self
Response type (ACK, RESULT, FULL).
Sourcepub fn good_till_date<VALUE: Into<i64>>(&mut self, value: VALUE) -> &mut Self
pub fn good_till_date<VALUE: Into<i64>>(&mut self, value: VALUE) -> &mut Self
Good till date (for GTD orders).
Sourcepub fn recv_window<VALUE: Into<u64>>(&mut self, value: VALUE) -> &mut Self
pub fn recv_window<VALUE: Into<u64>>(&mut self, value: VALUE) -> &mut Self
Recv window override (ms).
Sourcepub fn price_match<VALUE: Into<BinancePriceMatch>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn price_match<VALUE: Into<BinancePriceMatch>>( &mut self, value: VALUE, ) -> &mut Self
Price match mode for algorithmic price matching.
Sourcepub fn self_trade_prevention_mode<VALUE: Into<BinanceSelfTradePreventionMode>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn self_trade_prevention_mode<VALUE: Into<BinanceSelfTradePreventionMode>>( &mut self, value: VALUE, ) -> &mut Self
Self-trade prevention mode.
Sourcepub fn build(
&self,
) -> Result<BinanceNewOrderParams, BinanceNewOrderParamsBuilderError>
pub fn build( &self, ) -> Result<BinanceNewOrderParams, BinanceNewOrderParamsBuilderError>
Trait Implementations§
Source§impl Clone for BinanceNewOrderParamsBuilder
impl Clone for BinanceNewOrderParamsBuilder
Source§fn clone(&self) -> BinanceNewOrderParamsBuilder
fn clone(&self) -> BinanceNewOrderParamsBuilder
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 moreAuto Trait Implementations§
impl Freeze for BinanceNewOrderParamsBuilder
impl RefUnwindSafe for BinanceNewOrderParamsBuilder
impl Send for BinanceNewOrderParamsBuilder
impl Sync for BinanceNewOrderParamsBuilder
impl Unpin for BinanceNewOrderParamsBuilder
impl UnsafeUnpin for BinanceNewOrderParamsBuilder
impl UnwindSafe for BinanceNewOrderParamsBuilder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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