OrderId
OrderId
OrderIdLibrary
encode
function encode(BookId bookId, Tick tick, uint40 index) internal pure returns (OrderId id)
Encode the order id.
Parameters
Name | Type | Description |
---|---|---|
bookId | BookId | The book id. |
tick | Tick | The tick. |
index | uint40 | The index. |
Return Values
Name | Type | Description |
---|---|---|
id | OrderId | The order id. |
decode
function decode(OrderId id) internal pure returns (BookId bookId, Tick tick, uint40 index)
getBookId
function getBookId(OrderId id) internal pure returns (BookId bookId)
getTick
function getTick(OrderId id) internal pure returns (Tick tick)
getIndex
function getIndex(OrderId id) internal pure returns (uint40 index)