Struct nash_protocol::protocol::State[][src]

pub struct State {
    pub signer: Option<Signer>,
    pub asset_nonces: Option<HashMap<String, Vec<u32>>>,
    pub markets: Option<HashMap<String, Market>>,
    pub assets: Option<Vec<Asset>>,
    pub remaining_orders: AtomicU64,
    pub affiliate_code: Option<String>,
    pub assets_nonces_refresh: bool,
    pub dont_sign_states: bool,
    pub place_order_semaphore: Arc<Semaphore>,
    pub sign_all_states_semaphore: Arc<Semaphore>,
    pub k1_fill_pool_semaphore: Arc<Semaphore>,
    pub r1_fill_pool_semaphore: Arc<Semaphore>,
}
Expand description

Client state shared across the protocol.

Fields

signer: Option<Signer>asset_nonces: Option<HashMap<String, Vec<u32>>>markets: Option<HashMap<String, Market>>assets: Option<Vec<Asset>>remaining_orders: AtomicU64affiliate_code: Option<String>assets_nonces_refresh: booldont_sign_states: boolplace_order_semaphore: Arc<Semaphore>sign_all_states_semaphore: Arc<Semaphore>k1_fill_pool_semaphore: Arc<Semaphore>r1_fill_pool_semaphore: Arc<Semaphore>

Implementations

Check if pools need a refill

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Should always be Self

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more