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
0✅❌The market account
1✅❌A zeroed out event queue account
2✅❌A zeroed out bids account
3✅❌A 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
0✅❌The market account
1✅❌The event queue account
2✅❌The bids account
3✅❌The asks account
4❌✅The caller authority
ConsumeEvents(Params)

Pop a series of events off the event queue.

Required accounts

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

Cancel an existing order in the orderbook.

Required accounts

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

Close and existing market.

Required accounts

indexwritablesignerdescription
0✅❌The market account
1✅❌The event queue account
2✅❌The bids account
3✅❌The asks account
4❌✅The caller authority
5✅❌The 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.