IEngine
This interface defines the functions that can be called on the Engine contract. These functions provide various operations related to market orders, limit orders, market prices, and adding new trading pairs.
Functions
mktPrice
mktPrice
Retrieves the market price of the specified trading pair.
Parameters
Returns
getOrderbook
getOrderbook
Retrieves the address of the order book corresponding to the specified bookId
.
Parameters
Returns
marketBuy
marketBuy
Executes a market buy order for the specified trading pair and amount.
Parameters
marketSell
marketSell
Executes a market sell order for the specified trading pair and amount.
Parameters
limitBuy
limitBuy
Places a limit buy order for the specified trading pair, amount, and price.
Parameters
limitSell
limitSell
Places a limit sell order for the specified trading pair, amount, and price.
Parameters
addPair
addPair
Adds a new trading pair to the engine and returns the address of the corresponding order book.
Parameters
Returns
Last updated