/* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ import { AbiItem, Callback, CeloTxObject, Contract, EventLog, } from "@celo/connect"; import { EventEmitter } from "events"; import Web3 from "web3"; import { ContractEvent, EventOptions } from "./types"; export interface IBRegistry extends Contract { clone(): IBRegistry; methods: { getPairInfo( pool: string, fromToken: string, destToken: string ): CeloTxObject<{ weight1: string; weight2: string; swapFee: string; 0: string; 1: string; 2: string; }>; getPoolsWithLimit( fromToken: string, destToken: string, offset: number | string, limit: number | string ): CeloTxObject; getBestPools(fromToken: string, destToken: string): CeloTxObject; getBestPoolsWithLimit( fromToken: string, destToken: string, limit: number | string ): CeloTxObject; addPoolPair( pool: string, token1: string, token2: string ): CeloTxObject; addPools( pools: string[], token1: string, token2: string ): CeloTxObject; sortPools( tokens: string[], lengthLimit: number | string ): CeloTxObject; sortPoolsWithPurge( tokens: string[], lengthLimit: number | string ): CeloTxObject; }; events: { IndicesUpdated: ContractEvent<{ token1: string; token2: string; oldIndices: string; newIndices: string; 0: string; 1: string; 2: string; 3: string; }>; PoolTokenPairAdded: ContractEvent<{ pool: string; token1: string; token2: string; 0: string; 1: string; 2: string; }>; allEvents: ( options?: EventOptions, cb?: Callback ) => EventEmitter; }; } export const ABI: AbiItem[] = [ { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "token1", type: "address", }, { indexed: true, internalType: "address", name: "token2", type: "address", }, { indexed: false, internalType: "bytes32", name: "oldIndices", type: "bytes32", }, { indexed: false, internalType: "bytes32", name: "newIndices", type: "bytes32", }, ], name: "IndicesUpdated", type: "event", }, { anonymous: false, inputs: [ { indexed: true, internalType: "address", name: "pool", type: "address" }, { indexed: true, internalType: "address", name: "token1", type: "address", }, { indexed: true, internalType: "address", name: "token2", type: "address", }, ], name: "PoolTokenPairAdded", type: "event", }, { inputs: [ { internalType: "address", name: "pool", type: "address" }, { internalType: "address", name: "fromToken", type: "address" }, { internalType: "address", name: "destToken", type: "address" }, ], name: "getPairInfo", outputs: [ { internalType: "uint256", name: "weight1", type: "uint256" }, { internalType: "uint256", name: "weight2", type: "uint256" }, { internalType: "uint256", name: "swapFee", type: "uint256" }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "fromToken", type: "address" }, { internalType: "address", name: "destToken", type: "address" }, { internalType: "uint256", name: "offset", type: "uint256" }, { internalType: "uint256", name: "limit", type: "uint256" }, ], name: "getPoolsWithLimit", outputs: [{ internalType: "address[]", name: "result", type: "address[]" }], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "fromToken", type: "address" }, { internalType: "address", name: "destToken", type: "address" }, ], name: "getBestPools", outputs: [{ internalType: "address[]", name: "pools", type: "address[]" }], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "fromToken", type: "address" }, { internalType: "address", name: "destToken", type: "address" }, { internalType: "uint256", name: "limit", type: "uint256" }, ], name: "getBestPoolsWithLimit", outputs: [{ internalType: "address[]", name: "pools", type: "address[]" }], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "pool", type: "address" }, { internalType: "address", name: "token1", type: "address" }, { internalType: "address", name: "token2", type: "address" }, ], name: "addPoolPair", outputs: [{ internalType: "uint256", name: "listed", type: "uint256" }], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address[]", name: "pools", type: "address[]" }, { internalType: "address", name: "token1", type: "address" }, { internalType: "address", name: "token2", type: "address" }, ], name: "addPools", outputs: [{ internalType: "uint256[]", name: "listed", type: "uint256[]" }], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address[]", name: "tokens", type: "address[]" }, { internalType: "uint256", name: "lengthLimit", type: "uint256" }, ], name: "sortPools", outputs: [], stateMutability: "nonpayable", type: "function", }, { inputs: [ { internalType: "address[]", name: "tokens", type: "address[]" }, { internalType: "uint256", name: "lengthLimit", type: "uint256" }, ], name: "sortPoolsWithPurge", outputs: [], stateMutability: "nonpayable", type: "function", }, ]; export function newIBRegistry(web3: Web3, address: string): IBRegistry { return new web3.eth.Contract(ABI, address) as any; }