Enum agnostic_orderbook::instruction::AgnosticOrderbookInstruction[][src]

pub enum AgnosticOrderbookInstruction {
    CreateMarket(Params),
    NewOrder(Params),
    ConsumeEvents(Params),
    CancelOrder(Params),
    CloseMarket,
}
Expand description

Describes all possible instructions and their required accounts

Variants

CreateMarket(Params)

Create and initialize a new orderbook market

Required accounts

indexwritablesignerdescription
0The market account
1A zeroed out event queue account
2A zeroed out bids account
3A zeroed out asks account
NewOrder(Params)

Execute a new order on the orderbook.

Depending on the provided parameters, the program will attempt to match the order with existing entries in the orderbook, and then optionally post the remaining order.

Required accounts

indexwritablesignerdescription
0The market account
1The event queue account
2The bids account
3The asks account
4The caller authority
ConsumeEvents(Params)

Pop a series of events off the event queue.

Required accounts

indexwritablesignerdescription
0The market account
1The event queue account
3The caller authority
4The reward target account
5The MSRM token account
6The MSRM token account owner
CancelOrder(Params)

Cancel an existing order in the orderbook.

Required accounts

indexwritablesignerdescription
0The market account
1The event queue account
2The bids account
3The asks account
4The caller authority
CloseMarket

Close and existing market.

Required accounts

indexwritablesignerdescription
0The market account
1The event queue account
2The bids account
3The asks account
4The caller authority
5The lamports target account

Trait Implementations

Deserializes this instance from a given slice of bytes. Updates the buffer to point at the remaining bytes. Read more

Deserialize this instance from a slice of bytes.

Serialize this instance into a vector of bytes.

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.

Performs the conversion.

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.