import { utils, BytesLike, BaseContract, Signer, Overrides, ContractTransaction, CallOverrides, BigNumber, PopulatedTransaction } from 'ethers';
import { FunctionFragment, Result } from '@ethersproject/abi';
import { Provider, Listener } from '@ethersproject/providers';
import { TypedEvent, TypedEventFilter, TypedListener, OnEvent } from './common.js';

interface MulticallInterface extends utils.Interface {
    contractName: string | "Multicall";
    functions: {
        "multicall(bytes[])": FunctionFragment;
    };
    encodeFunctionData(functionFragment: "multicall", values: [BytesLike[]]): string;
    decodeFunctionResult(functionFragment: "multicall", data: BytesLike): Result;
    events: {};
}
interface Multicall extends BaseContract {
    contractName: string | "Multicall";
    connect(signerOrProvider: Signer | Provider | string): this;
    attach(addressOrName: string): this;
    deployed(): Promise<this>;
    interface: MulticallInterface;
    queryFilter<TEvent extends TypedEvent>(event: TypedEventFilter<TEvent>, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TEvent>>;
    listeners<TEvent extends TypedEvent>(eventFilter?: TypedEventFilter<TEvent>): Array<TypedListener<TEvent>>;
    listeners(eventName?: string): Array<Listener>;
    removeAllListeners<TEvent extends TypedEvent>(eventFilter: TypedEventFilter<TEvent>): this;
    removeAllListeners(eventName?: string): this;
    off: OnEvent<this>;
    on: OnEvent<this>;
    once: OnEvent<this>;
    removeListener: OnEvent<this>;
    functions: {
        multicall(data: BytesLike[], overrides?: Overrides & {
            from?: string | Promise<string>;
        }): Promise<ContractTransaction>;
    };
    multicall(data: BytesLike[], overrides?: Overrides & {
        from?: string | Promise<string>;
    }): Promise<ContractTransaction>;
    callStatic: {
        multicall(data: BytesLike[], overrides?: CallOverrides): Promise<string[]>;
    };
    filters: {};
    estimateGas: {
        multicall(data: BytesLike[], overrides?: Overrides & {
            from?: string | Promise<string>;
        }): Promise<BigNumber>;
    };
    populateTransaction: {
        multicall(data: BytesLike[], overrides?: Overrides & {
            from?: string | Promise<string>;
        }): Promise<PopulatedTransaction>;
    };
}

export { Multicall, MulticallInterface };
