pub struct OrderBuilder<'a, S: Eip712Signer> { /* private fields */ }Implementations§
Source§impl<'a, S: Eip712Signer> OrderBuilder<'a, S>
impl<'a, S: Eip712Signer> OrderBuilder<'a, S>
pub fn new( signer: &'a S, chain_id: i64, signature_type: Option<SignatureType>, funder_address: Option<String>, ) -> Self
pub fn with_config(signer: &'a S, chain_id: i64, cfg: &BuilderConfig) -> Self
pub async fn build_order( &self, exchange_address: &str, user_order: &UserOrder, options_tick: &str, ) -> Result<SignedOrder, ClobError>
Sourcepub async fn build_order_with_salt(
&self,
exchange_address: &str,
user_order: &UserOrder,
options_tick: &str,
forced_salt: &str,
) -> Result<SignedOrder, ClobError>
pub async fn build_order_with_salt( &self, exchange_address: &str, user_order: &UserOrder, options_tick: &str, forced_salt: &str, ) -> Result<SignedOrder, ClobError>
构建限价单(强制指定 salt,用于跨语言/跨路径签名完全一致的验证)
pub async fn build_market_order( &self, exchange_address: &str, user_market_order: &UserMarketOrder, options_tick: &str, ) -> Result<SignedOrder, ClobError>
Auto Trait Implementations§
impl<'a, S> Freeze for OrderBuilder<'a, S>
impl<'a, S> RefUnwindSafe for OrderBuilder<'a, S>where
S: RefUnwindSafe,
impl<'a, S> Send for OrderBuilder<'a, S>
impl<'a, S> Sync for OrderBuilder<'a, S>
impl<'a, S> Unpin for OrderBuilder<'a, S>
impl<'a, S> UnwindSafe for OrderBuilder<'a, S>where
S: RefUnwindSafe,
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> 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