/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
import type {
  BaseContract,
  BigNumberish,
  BytesLike,
  FunctionFragment,
  Result,
  Interface,
  AddressLike,
  ContractRunner,
  ContractMethod,
  Listener,
} from "ethers";
import type {
  TypedContractEvent,
  TypedDeferredTopicFilter,
  TypedEventLog,
  TypedListener,
  TypedContractMethod,
} from "../../../common";

export declare namespace IDisputeManager {
  export type AttestationStruct = {
    requestCID: BytesLike;
    responseCID: BytesLike;
    subgraphDeploymentID: BytesLike;
    r: BytesLike;
    s: BytesLike;
    v: BigNumberish;
  };

  export type AttestationStructOutput = [
    requestCID: string,
    responseCID: string,
    subgraphDeploymentID: string,
    r: string,
    s: string,
    v: bigint,
  ] & {
    requestCID: string;
    responseCID: string;
    subgraphDeploymentID: string;
    r: string;
    s: string;
    v: bigint;
  };

  export type ReceiptStruct = {
    requestCID: BytesLike;
    responseCID: BytesLike;
    subgraphDeploymentID: BytesLike;
  };

  export type ReceiptStructOutput = [
    requestCID: string,
    responseCID: string,
    subgraphDeploymentID: string,
  ] & { requestCID: string; responseCID: string; subgraphDeploymentID: string };
}

export interface IDisputeManagerInterface extends Interface {
  getFunction(
    nameOrSignature:
      | "acceptDispute"
      | "areConflictingAttestations"
      | "createIndexingDispute"
      | "createQueryDispute"
      | "createQueryDisputeConflict"
      | "drawDispute"
      | "encodeHashReceipt"
      | "getAttestationIndexer"
      | "isDisputeCreated"
      | "rejectDispute"
      | "setArbitrator"
      | "setFishermanRewardPercentage"
      | "setMinimumDeposit"
      | "setSlashingPercentage",
  ): FunctionFragment;

  encodeFunctionData(
    functionFragment: "acceptDispute",
    values: [BytesLike],
  ): string;
  encodeFunctionData(
    functionFragment: "areConflictingAttestations",
    values: [
      IDisputeManager.AttestationStruct,
      IDisputeManager.AttestationStruct,
    ],
  ): string;
  encodeFunctionData(
    functionFragment: "createIndexingDispute",
    values: [AddressLike, BigNumberish],
  ): string;
  encodeFunctionData(
    functionFragment: "createQueryDispute",
    values: [BytesLike, BigNumberish],
  ): string;
  encodeFunctionData(
    functionFragment: "createQueryDisputeConflict",
    values: [BytesLike, BytesLike],
  ): string;
  encodeFunctionData(
    functionFragment: "drawDispute",
    values: [BytesLike],
  ): string;
  encodeFunctionData(
    functionFragment: "encodeHashReceipt",
    values: [IDisputeManager.ReceiptStruct],
  ): string;
  encodeFunctionData(
    functionFragment: "getAttestationIndexer",
    values: [IDisputeManager.AttestationStruct],
  ): string;
  encodeFunctionData(
    functionFragment: "isDisputeCreated",
    values: [BytesLike],
  ): string;
  encodeFunctionData(
    functionFragment: "rejectDispute",
    values: [BytesLike],
  ): string;
  encodeFunctionData(
    functionFragment: "setArbitrator",
    values: [AddressLike],
  ): string;
  encodeFunctionData(
    functionFragment: "setFishermanRewardPercentage",
    values: [BigNumberish],
  ): string;
  encodeFunctionData(
    functionFragment: "setMinimumDeposit",
    values: [BigNumberish],
  ): string;
  encodeFunctionData(
    functionFragment: "setSlashingPercentage",
    values: [BigNumberish, BigNumberish],
  ): string;

  decodeFunctionResult(
    functionFragment: "acceptDispute",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "areConflictingAttestations",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "createIndexingDispute",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "createQueryDispute",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "createQueryDisputeConflict",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "drawDispute",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "encodeHashReceipt",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "getAttestationIndexer",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "isDisputeCreated",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "rejectDispute",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "setArbitrator",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "setFishermanRewardPercentage",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "setMinimumDeposit",
    data: BytesLike,
  ): Result;
  decodeFunctionResult(
    functionFragment: "setSlashingPercentage",
    data: BytesLike,
  ): Result;
}

export interface IDisputeManager extends BaseContract {
  connect(runner?: ContractRunner | null): IDisputeManager;
  waitForDeployment(): Promise<this>;

  interface: IDisputeManagerInterface;

  queryFilter<TCEvent extends TypedContractEvent>(
    event: TCEvent,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined,
  ): Promise<Array<TypedEventLog<TCEvent>>>;
  queryFilter<TCEvent extends TypedContractEvent>(
    filter: TypedDeferredTopicFilter<TCEvent>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined,
  ): Promise<Array<TypedEventLog<TCEvent>>>;

  on<TCEvent extends TypedContractEvent>(
    event: TCEvent,
    listener: TypedListener<TCEvent>,
  ): Promise<this>;
  on<TCEvent extends TypedContractEvent>(
    filter: TypedDeferredTopicFilter<TCEvent>,
    listener: TypedListener<TCEvent>,
  ): Promise<this>;

  once<TCEvent extends TypedContractEvent>(
    event: TCEvent,
    listener: TypedListener<TCEvent>,
  ): Promise<this>;
  once<TCEvent extends TypedContractEvent>(
    filter: TypedDeferredTopicFilter<TCEvent>,
    listener: TypedListener<TCEvent>,
  ): Promise<this>;

  listeners<TCEvent extends TypedContractEvent>(
    event: TCEvent,
  ): Promise<Array<TypedListener<TCEvent>>>;
  listeners(eventName?: string): Promise<Array<Listener>>;
  removeAllListeners<TCEvent extends TypedContractEvent>(
    event?: TCEvent,
  ): Promise<this>;

  acceptDispute: TypedContractMethod<
    [disputeID: BytesLike],
    [void],
    "nonpayable"
  >;

  areConflictingAttestations: TypedContractMethod<
    [
      attestation1: IDisputeManager.AttestationStruct,
      attestation2: IDisputeManager.AttestationStruct,
    ],
    [boolean],
    "view"
  >;

  createIndexingDispute: TypedContractMethod<
    [allocationID: AddressLike, deposit: BigNumberish],
    [string],
    "nonpayable"
  >;

  createQueryDispute: TypedContractMethod<
    [attestationData: BytesLike, deposit: BigNumberish],
    [string],
    "nonpayable"
  >;

  createQueryDisputeConflict: TypedContractMethod<
    [attestationData1: BytesLike, attestationData2: BytesLike],
    [[string, string]],
    "nonpayable"
  >;

  drawDispute: TypedContractMethod<
    [disputeID: BytesLike],
    [void],
    "nonpayable"
  >;

  encodeHashReceipt: TypedContractMethod<
    [receipt: IDisputeManager.ReceiptStruct],
    [string],
    "view"
  >;

  getAttestationIndexer: TypedContractMethod<
    [attestation: IDisputeManager.AttestationStruct],
    [string],
    "view"
  >;

  isDisputeCreated: TypedContractMethod<
    [disputeID: BytesLike],
    [boolean],
    "view"
  >;

  rejectDispute: TypedContractMethod<
    [disputeID: BytesLike],
    [void],
    "nonpayable"
  >;

  setArbitrator: TypedContractMethod<
    [arbitrator: AddressLike],
    [void],
    "nonpayable"
  >;

  setFishermanRewardPercentage: TypedContractMethod<
    [percentage: BigNumberish],
    [void],
    "nonpayable"
  >;

  setMinimumDeposit: TypedContractMethod<
    [minimumDeposit: BigNumberish],
    [void],
    "nonpayable"
  >;

  setSlashingPercentage: TypedContractMethod<
    [qryPercentage: BigNumberish, idxPercentage: BigNumberish],
    [void],
    "nonpayable"
  >;

  getFunction<T extends ContractMethod = ContractMethod>(
    key: string | FunctionFragment,
  ): T;

  getFunction(
    nameOrSignature: "acceptDispute",
  ): TypedContractMethod<[disputeID: BytesLike], [void], "nonpayable">;
  getFunction(
    nameOrSignature: "areConflictingAttestations",
  ): TypedContractMethod<
    [
      attestation1: IDisputeManager.AttestationStruct,
      attestation2: IDisputeManager.AttestationStruct,
    ],
    [boolean],
    "view"
  >;
  getFunction(
    nameOrSignature: "createIndexingDispute",
  ): TypedContractMethod<
    [allocationID: AddressLike, deposit: BigNumberish],
    [string],
    "nonpayable"
  >;
  getFunction(
    nameOrSignature: "createQueryDispute",
  ): TypedContractMethod<
    [attestationData: BytesLike, deposit: BigNumberish],
    [string],
    "nonpayable"
  >;
  getFunction(
    nameOrSignature: "createQueryDisputeConflict",
  ): TypedContractMethod<
    [attestationData1: BytesLike, attestationData2: BytesLike],
    [[string, string]],
    "nonpayable"
  >;
  getFunction(
    nameOrSignature: "drawDispute",
  ): TypedContractMethod<[disputeID: BytesLike], [void], "nonpayable">;
  getFunction(
    nameOrSignature: "encodeHashReceipt",
  ): TypedContractMethod<
    [receipt: IDisputeManager.ReceiptStruct],
    [string],
    "view"
  >;
  getFunction(
    nameOrSignature: "getAttestationIndexer",
  ): TypedContractMethod<
    [attestation: IDisputeManager.AttestationStruct],
    [string],
    "view"
  >;
  getFunction(
    nameOrSignature: "isDisputeCreated",
  ): TypedContractMethod<[disputeID: BytesLike], [boolean], "view">;
  getFunction(
    nameOrSignature: "rejectDispute",
  ): TypedContractMethod<[disputeID: BytesLike], [void], "nonpayable">;
  getFunction(
    nameOrSignature: "setArbitrator",
  ): TypedContractMethod<[arbitrator: AddressLike], [void], "nonpayable">;
  getFunction(
    nameOrSignature: "setFishermanRewardPercentage",
  ): TypedContractMethod<[percentage: BigNumberish], [void], "nonpayable">;
  getFunction(
    nameOrSignature: "setMinimumDeposit",
  ): TypedContractMethod<[minimumDeposit: BigNumberish], [void], "nonpayable">;
  getFunction(
    nameOrSignature: "setSlashingPercentage",
  ): TypedContractMethod<
    [qryPercentage: BigNumberish, idxPercentage: BigNumberish],
    [void],
    "nonpayable"
  >;

  filters: {};
}
