UNPKG

@fleupold/dex-contracts

Version:

Contracts for dFusion multi-token batch auction exchange

18 lines (17 loc) 1.56 kB
import BN from "bn.js"; import type { BatchExchangeInstance, TokenOwlInstance, Erc20MintableInstance } from "../types/truffle-typings"; import type { SolutionSubmission } from "../test/resources/examples/model"; export interface ExchangeToken { id: number; address: string; } export declare function getBatchExchange(artifacts: Truffle.Artifacts): Promise<BatchExchangeInstance>; export declare function getOwl(artifacts: Truffle.Artifacts): Promise<TokenOwlInstance>; export declare function setAllowances(users: string[], amount: string | BN, exchange: BatchExchangeInstance, tokens: (TokenOwlInstance | Erc20MintableInstance)[]): Promise<void>; export declare function addTokens(tokenAddresses: string[], account: string, exchange: BatchExchangeInstance, owl: TokenOwlInstance): Promise<ExchangeToken[]>; export declare function deleteOrders(orderIds: number[], accounts: string[], exchange: BatchExchangeInstance): Promise<void>; export declare function submitSolution(name: string, batchId: number, solution: SolutionSubmission, solverAddress: string, exchange: BatchExchangeInstance): Promise<void>; export declare function getBatchId(exchange: BatchExchangeInstance): Promise<number>; export declare function createMintableToken(artifacts: Truffle.Artifacts): Promise<Erc20MintableInstance>; export declare function mintTokens(tokens: Erc20MintableInstance[], users: string[], amount: string, minter: string): Promise<void>; export declare function mintOwl(owl: TokenOwlInstance, users: string[], amount: string, minter: string): Promise<void>;