Flex
Flex exchange system
|
Class for iterating queue and processing deals. More...
#include <dealer.hpp>
Classes | |
struct | deal_result |
Result of make_deal. More... | |
struct | process_result |
Result of process() call. More... | |
Public Member Functions | |
dealer (price_t price, address pair, Tip3Config major_tip3cfg, Tip3Config minor_tip3cfg, EversConfig ev_cfg, orders_queue sells, orders_queue buys, uint128 min_amount, unsigned deals_limit, unsigned msgs_limit, IFlexNotifyPtr notify_addr, address major_reserve_wallet, address minor_reserve_wallet) | |
process_result | process (unsigned sell_idx, unsigned buy_idx) |
Process order queues and make deals. | |
deal_result | make_deal (OrderInfoXchg sell, OrderInfoXchg buy) |
Make tip3/tip exchange deal. | |
Public Attributes | |
price_t | price_ |
Price (rational value) | |
address | pair_ |
Address of XchgPair contract. | |
Tip3Config | major_tip3cfg_ |
Major tip3 configuration. | |
Tip3Config | minor_tip3cfg_ |
Minor tip3 configuration. | |
EversConfig | ev_cfg_ |
Processing costs configuration (evers) | |
orders_queue | sells_ |
Sell orders queue. | |
orders_queue | buys_ |
Buy orders queue. | |
uint128 | min_amount_ |
Minimum amount of major tokens for a deal or an order. | |
unsigned | deals_limit_ |
Deals limit. | |
unsigned | msgs_limit_ |
Messages limit. | |
uint128 | deal_costs_ |
Deal costs in evers. | |
address | tip3root_major_ |
Address of RootTokenContract for major tip3 token. | |
address | tip3root_minor_ |
Address of RootTokenContract for minor tip3 token. | |
IFlexNotifyPtr | notify_addr_ |
Notification address for AMM. | |
address | major_reserve_wallet_ |
Major reserve wallet. | |
address | minor_reserve_wallet_ |
Minor reserve wallet. | |
Class for iterating queue and processing deals.
struct tvm::xchg::dealer::deal_result |
Result of make_deal.
struct tvm::xchg::dealer::process_result |
Result of process() call.
Class Members | ||
---|---|---|
orders_queue | buys | Buy orders queue. |
opt< OrderRet > | ret | Return value for the called function. |
orders_queue | sells | Sell orders queue. |
|
inline |
price | Price (rational value) |
pair | Address of XchgPair contract |
major_tip3cfg | Major tip3 configuration |
minor_tip3cfg | Minor tip3 configuration |
ev_cfg | Processing costs configuration (evers) |
sells | Sell orders queue |
buys | Buy orders queue |
min_amount | Minimum amount of major tokens for a deal or an order |
deals_limit | Deals limit |
msgs_limit | Messages limit |
notify_addr | Notification address for AMM |
major_reserve_wallet | Major reserve wallet |
minor_reserve_wallet | Minor reserve wallet |