Struct serum_dex::state::MarketState[][src]

#[repr(packed)]
pub struct MarketState {
Show fields pub account_flags: u64, pub own_address: [u64; 4], pub vault_signer_nonce: u64, pub coin_mint: [u64; 4], pub pc_mint: [u64; 4], pub coin_vault: [u64; 4], pub coin_deposits_total: u64, pub coin_fees_accrued: u64, pub pc_vault: [u64; 4], pub pc_deposits_total: u64, pub pc_fees_accrued: u64, pub pc_dust_threshold: u64, pub req_q: [u64; 4], pub event_q: [u64; 4], pub bids: [u64; 4], pub asks: [u64; 4], pub coin_lot_size: u64, pub pc_lot_size: u64, pub fee_rate_bps: u64, pub referrer_rebates_accrued: u64,
}

Fields

account_flags: u64own_address: [u64; 4]vault_signer_nonce: u64coin_mint: [u64; 4]pc_mint: [u64; 4]coin_vault: [u64; 4]coin_deposits_total: u64coin_fees_accrued: u64pc_vault: [u64; 4]pc_deposits_total: u64pc_fees_accrued: u64pc_dust_threshold: u64req_q: [u64; 4]event_q: [u64; 4]bids: [u64; 4]asks: [u64; 4]coin_lot_size: u64pc_lot_size: u64fee_rate_bps: u64referrer_rebates_accrued: u64

Implementations

impl MarketState[src]

pub fn load<'a>(
    market_account: &'a AccountInfo<'_>,
    program_id: &Pubkey
) -> DexResult<RefMut<'a, Self>>
[src]

pub fn check_flags(&self) -> DexResult[src]

pub fn load_orders_mut<'a>(
    &self,
    orders_account: &'a AccountInfo<'_>,
    owner_account: Option<&AccountInfo<'_>>,
    program_id: &Pubkey,
    rent: Option<Rent>
) -> DexResult<RefMut<'a, OpenOrders>>
[src]

Trait Implementations

impl Clone for MarketState[src]

fn clone(&self) -> MarketState[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for MarketState[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Zeroable for MarketState[src]

fn zeroed() -> Self[src]

impl Copy for MarketState[src]

impl Pod for MarketState[src]

impl TriviallyTransmutable for MarketState[src]

Auto Trait Implementations

Blanket Implementations

impl<T> AbiExample for T

pub default fn example() -> T

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

pub fn to_owned(&self) -> T[src]

Creates owned data from borrowed data, usually by cloning. Read more

pub fn clone_into(&self, target: &mut T)[src]

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

pub fn vzip(self) -> V