import type { BaseContract, BigNumber, BigNumberish, BytesLike, CallOverrides, ContractTransaction, Overrides, PopulatedTransaction, Signer, utils } from "ethers";
import type { FunctionFragment, Result } from "@ethersproject/abi";
import type { Listener, Provider } from "@ethersproject/providers";
import type { TypedEventFilter, TypedEvent, TypedListener, OnEvent, PromiseOrValue } from "../../../../../common";
export type MessageStruct = {
    value: PromiseOrValue<BigNumberish>;
    sender: PromiseOrValue<string>;
    client: PromiseOrValue<string>;
    chainId: PromiseOrValue<BigNumberish>;
};
export type MessageStructOutput = [BigNumber, string, string, number] & {
    value: BigNumber;
    sender: string;
    client: string;
    chainId: number;
};
export interface IPostOfficeInterface extends utils.Interface {
    functions: {
        "readMessage(uint8)": FunctionFragment;
        "readMessageSumReduce(uint8)": FunctionFragment;
        "sendMessage(address,(uint256,address,address,uint16),uint16,uint8)": FunctionFragment;
        "writeMessage(address,(uint256,address,address,uint16),uint8)": FunctionFragment;
    };
    getFunction(nameOrSignatureOrTopic: "readMessage" | "readMessageSumReduce" | "sendMessage" | "writeMessage"): FunctionFragment;
    encodeFunctionData(functionFragment: "readMessage", values: [PromiseOrValue<BigNumberish>]): string;
    encodeFunctionData(functionFragment: "readMessageSumReduce", values: [PromiseOrValue<BigNumberish>]): string;
    encodeFunctionData(functionFragment: "sendMessage", values: [
        PromiseOrValue<string>,
        MessageStruct,
        PromiseOrValue<BigNumberish>,
        PromiseOrValue<BigNumberish>
    ]): string;
    encodeFunctionData(functionFragment: "writeMessage", values: [
        PromiseOrValue<string>,
        MessageStruct,
        PromiseOrValue<BigNumberish>
    ]): string;
    decodeFunctionResult(functionFragment: "readMessage", data: BytesLike): Result;
    decodeFunctionResult(functionFragment: "readMessageSumReduce", data: BytesLike): Result;
    decodeFunctionResult(functionFragment: "sendMessage", data: BytesLike): Result;
    decodeFunctionResult(functionFragment: "writeMessage", data: BytesLike): Result;
    events: {};
}
export interface IPostOffice extends BaseContract {
    connect(signerOrProvider: Signer | Provider | string): this;
    attach(addressOrName: string): this;
    deployed(): Promise<this>;
    interface: IPostOfficeInterface;
    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: {
        readMessage(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<ContractTransaction>;
        readMessageSumReduce(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<ContractTransaction>;
        sendMessage(receiverAddr: PromiseOrValue<string>, message: MessageStruct, receiverChainId: PromiseOrValue<BigNumberish>, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<ContractTransaction>;
        writeMessage(receiver: PromiseOrValue<string>, message: MessageStruct, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<ContractTransaction>;
    };
    readMessage(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
        from?: PromiseOrValue<string>;
    }): Promise<ContractTransaction>;
    readMessageSumReduce(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
        from?: PromiseOrValue<string>;
    }): Promise<ContractTransaction>;
    sendMessage(receiverAddr: PromiseOrValue<string>, message: MessageStruct, receiverChainId: PromiseOrValue<BigNumberish>, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
        from?: PromiseOrValue<string>;
    }): Promise<ContractTransaction>;
    writeMessage(receiver: PromiseOrValue<string>, message: MessageStruct, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
        from?: PromiseOrValue<string>;
    }): Promise<ContractTransaction>;
    callStatic: {
        readMessage(msgType: PromiseOrValue<BigNumberish>, overrides?: CallOverrides): Promise<MessageStructOutput[]>;
        readMessageSumReduce(msgType: PromiseOrValue<BigNumberish>, overrides?: CallOverrides): Promise<[BigNumber, BigNumber] & {
            acc: BigNumber;
            count: BigNumber;
        }>;
        sendMessage(receiverAddr: PromiseOrValue<string>, message: MessageStruct, receiverChainId: PromiseOrValue<BigNumberish>, msgType: PromiseOrValue<BigNumberish>, overrides?: CallOverrides): Promise<void>;
        writeMessage(receiver: PromiseOrValue<string>, message: MessageStruct, msgType: PromiseOrValue<BigNumberish>, overrides?: CallOverrides): Promise<void>;
    };
    filters: {};
    estimateGas: {
        readMessage(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<BigNumber>;
        readMessageSumReduce(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<BigNumber>;
        sendMessage(receiverAddr: PromiseOrValue<string>, message: MessageStruct, receiverChainId: PromiseOrValue<BigNumberish>, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<BigNumber>;
        writeMessage(receiver: PromiseOrValue<string>, message: MessageStruct, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<BigNumber>;
    };
    populateTransaction: {
        readMessage(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<PopulatedTransaction>;
        readMessageSumReduce(msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<PopulatedTransaction>;
        sendMessage(receiverAddr: PromiseOrValue<string>, message: MessageStruct, receiverChainId: PromiseOrValue<BigNumberish>, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<PopulatedTransaction>;
        writeMessage(receiver: PromiseOrValue<string>, message: MessageStruct, msgType: PromiseOrValue<BigNumberish>, overrides?: Overrides & {
            from?: PromiseOrValue<string>;
        }): Promise<PopulatedTransaction>;
    };
}
