pub struct Modify { /* private fields */ }Expand description
modify: {type, oid, order, a?}, one order. a (always place) is written last and only
when set, and set whenever the new order is a trigger: the venue refuses a trigger without it
and an action hashed with a: false. A batchModify entry never carries it; the batch does.
Implementations§
Source§impl Modify
impl Modify
Sourcepub const fn new(target: OrderRef, order: Order) -> Modify
pub const fn new(target: OrderRef, order: Order) -> Modify
Replaces target with order; always places when order is a trigger.
Sourcepub const fn always_place(self) -> Modify
pub const fn always_place(self) -> Modify
Places the new order even where the old one is gone.
Sourcepub const fn is_always_place(&self) -> bool
pub const fn is_always_place(&self) -> bool
Whether a is set: the new order goes on even where the old one is gone.
Trait Implementations§
impl Copy for Modify
impl Eq for Modify
Source§impl From<Modify> for TradeAction
impl From<Modify> for TradeAction
Source§fn from(action: Modify) -> TradeAction
fn from(action: Modify) -> TradeAction
Converts to this type from the input type.
Source§impl L1Action for Modify
impl L1Action for Modify
Source§fn action(&self) -> Map
fn action(&self) -> Map
The action’s keys and values in wire order, which is the hashed order.
Source§fn msgpack(&self) -> Vec<u8> ⓘ
fn msgpack(&self) -> Vec<u8> ⓘ
The action as msgpack bytes, the first part of the connection id’s hash.
Source§fn typed(
&self,
nonce: u64,
vault: Option<Address>,
network: Network,
) -> TypedStruct<'static>
fn typed( &self, nonce: u64, vault: Option<Address>, network: Network, ) -> TypedStruct<'static>
The phantom agent struct the key signs for this action.
Source§fn digest(
&self,
nonce: u64,
vault: Option<Address>,
network: Network,
) -> [u8; 32]
fn digest( &self, nonce: u64, vault: Option<Address>, network: Network, ) -> [u8; 32]
What the key signs for this action: the phantom agent’s digest under
Domain::EXCHANGE.impl StructuralPartialEq for Modify
Auto Trait Implementations§
impl Forget for Modify
impl Freeze for Modify
impl Move for Modify
impl RefUnwindSafe for Modify
impl Send for Modify
impl Sync for Modify
impl Unpin for Modify
impl UnsafeUnpin for Modify
impl UnwindSafe for Modify
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.