Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/interfaces/IStablecoinDEX.sol
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ interface IStablecoinDEX {
error BelowMinimumOrderSize(uint128 amount);
error InvalidBaseToken();
error OrderNotStale();
error IndexAlreadySet();

event OrderCancelled(uint128 indexed orderId);
event OrderFilled(
Expand Down Expand Up @@ -110,6 +111,10 @@ interface IStablecoinDEX {
view
returns (address base, address quote, int16 bestBidTick, int16 bestAskTick);

function bookIndexForKey(bytes32 bookKey) external view returns (bool set, uint32 index);

function bookKeyForIndex(uint32 index) external view returns (bytes32 bookKey);

function cancel(uint128 orderId) external;

function cancelStaleOrder(uint128 orderId) external;
Expand All @@ -133,6 +138,8 @@ interface IStablecoinDEX {

function priceToTick(uint32 price) external pure returns (int16 tick);

function setBookIndex(uint32 index) external;

function quoteSwapExactAmountIn(address tokenIn, address tokenOut, uint128 amountIn)
external
view
Expand Down
Loading