aave-protocol-v2/types/IExchangeAdapter.d.ts
2020-08-24 10:48:55 +02:00

172 lines
4.8 KiB
TypeScript

/* Generated by ts-generator ver. 0.0.8 */
/* tslint:disable */
import {ethers, EventFilter, Signer, BigNumber, BigNumberish, PopulatedTransaction} from 'ethers';
import {Contract, ContractTransaction, Overrides, CallOverrides} from '@ethersproject/contracts';
import {BytesLike} from '@ethersproject/bytes';
import {Listener, Provider} from '@ethersproject/providers';
import {FunctionFragment, EventFragment, Result} from '@ethersproject/abi';
interface IExchangeAdapterInterface extends ethers.utils.Interface {
functions: {
'approveExchange(address[])': FunctionFragment;
'exchange(address,address,uint256,uint256)': FunctionFragment;
};
encodeFunctionData(functionFragment: 'approveExchange', values: [string[]]): string;
encodeFunctionData(
functionFragment: 'exchange',
values: [string, string, BigNumberish, BigNumberish]
): string;
decodeFunctionResult(functionFragment: 'approveExchange', data: BytesLike): Result;
decodeFunctionResult(functionFragment: 'exchange', data: BytesLike): Result;
events: {
'Exchange(address,address,address,uint256,uint256)': EventFragment;
};
getEvent(nameOrSignatureOrTopic: 'Exchange'): EventFragment;
}
export class IExchangeAdapter extends Contract {
connect(signerOrProvider: Signer | Provider | string): this;
attach(addressOrName: string): this;
deployed(): Promise<this>;
on(event: EventFilter | string, listener: Listener): this;
once(event: EventFilter | string, listener: Listener): this;
addListener(eventName: EventFilter | string, listener: Listener): this;
removeAllListeners(eventName: EventFilter | string): this;
removeListener(eventName: any, listener: Listener): this;
interface: IExchangeAdapterInterface;
functions: {
approveExchange(_tokens: string[], overrides?: Overrides): Promise<ContractTransaction>;
'approveExchange(address[])'(
_tokens: string[],
overrides?: Overrides
): Promise<ContractTransaction>;
exchange(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<ContractTransaction>;
'exchange(address,address,uint256,uint256)'(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<ContractTransaction>;
};
approveExchange(_tokens: string[], overrides?: Overrides): Promise<ContractTransaction>;
'approveExchange(address[])'(
_tokens: string[],
overrides?: Overrides
): Promise<ContractTransaction>;
exchange(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<ContractTransaction>;
'exchange(address,address,uint256,uint256)'(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<ContractTransaction>;
callStatic: {
approveExchange(_tokens: string[], overrides?: CallOverrides): Promise<void>;
'approveExchange(address[])'(_tokens: string[], overrides?: CallOverrides): Promise<void>;
exchange(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: CallOverrides
): Promise<BigNumber>;
'exchange(address,address,uint256,uint256)'(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: CallOverrides
): Promise<BigNumber>;
};
filters: {
Exchange(
from: string | null,
to: string | null,
platform: string | null,
fromAmount: null,
toAmount: null
): EventFilter;
};
estimateGas: {
approveExchange(_tokens: string[], overrides?: Overrides): Promise<BigNumber>;
'approveExchange(address[])'(_tokens: string[], overrides?: Overrides): Promise<BigNumber>;
exchange(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<BigNumber>;
'exchange(address,address,uint256,uint256)'(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<BigNumber>;
};
populateTransaction: {
approveExchange(_tokens: string[], overrides?: Overrides): Promise<PopulatedTransaction>;
'approveExchange(address[])'(
_tokens: string[],
overrides?: Overrides
): Promise<PopulatedTransaction>;
exchange(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<PopulatedTransaction>;
'exchange(address,address,uint256,uint256)'(
_from: string,
_to: string,
_amount: BigNumberish,
_maxSlippage: BigNumberish,
overrides?: Overrides
): Promise<PopulatedTransaction>;
};
}