UNPKG

@orionprotocol/contracts

Version:
370 lines (369 loc) 18.4 kB
import type { BaseContract, BigNumberish, BytesLike, FunctionFragment, Result, Interface, EventFragment, AddressLike, ContractRunner, ContractMethod, Listener } from "ethers"; import type { TypedContractEvent, TypedDeferredTopicFilter, TypedEventLog, TypedLogDescription, TypedListener, TypedContractMethod } from "./common"; export interface LumiaInterface extends Interface { getFunction(nameOrSignature: "DOMAIN_SEPARATOR" | "allowance" | "approve" | "balanceOf" | "burn" | "burnFrom" | "decimals" | "decreaseAllowance" | "eip712Domain" | "increaseAllowance" | "mint" | "minters" | "name" | "nonces" | "owner" | "permit" | "renounceOwnership" | "symbol" | "toggleMinter" | "totalSupply" | "transfer" | "transferFrom" | "transferOwnership"): FunctionFragment; getEvent(nameOrSignatureOrTopic: "Approval" | "EIP712DomainChanged" | "Mint" | "OwnershipTransferred" | "ToggleMinter" | "Transfer"): EventFragment; encodeFunctionData(functionFragment: "DOMAIN_SEPARATOR", values?: undefined): string; encodeFunctionData(functionFragment: "allowance", values: [AddressLike, AddressLike]): string; encodeFunctionData(functionFragment: "approve", values: [AddressLike, BigNumberish]): string; encodeFunctionData(functionFragment: "balanceOf", values: [AddressLike]): string; encodeFunctionData(functionFragment: "burn", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "burnFrom", values: [AddressLike, BigNumberish]): string; encodeFunctionData(functionFragment: "decimals", values?: undefined): string; encodeFunctionData(functionFragment: "decreaseAllowance", values: [AddressLike, BigNumberish]): string; encodeFunctionData(functionFragment: "eip712Domain", values?: undefined): string; encodeFunctionData(functionFragment: "increaseAllowance", values: [AddressLike, BigNumberish]): string; encodeFunctionData(functionFragment: "mint", values: [AddressLike, BigNumberish]): string; encodeFunctionData(functionFragment: "minters", values: [AddressLike]): string; encodeFunctionData(functionFragment: "name", values?: undefined): string; encodeFunctionData(functionFragment: "nonces", values: [AddressLike]): string; encodeFunctionData(functionFragment: "owner", values?: undefined): string; encodeFunctionData(functionFragment: "permit", values: [ AddressLike, AddressLike, BigNumberish, BigNumberish, BigNumberish, BytesLike, BytesLike ]): string; encodeFunctionData(functionFragment: "renounceOwnership", values?: undefined): string; encodeFunctionData(functionFragment: "symbol", values?: undefined): string; encodeFunctionData(functionFragment: "toggleMinter", values: [AddressLike]): string; encodeFunctionData(functionFragment: "totalSupply", values?: undefined): string; encodeFunctionData(functionFragment: "transfer", values: [AddressLike, BigNumberish]): string; encodeFunctionData(functionFragment: "transferFrom", values: [AddressLike, AddressLike, BigNumberish]): string; encodeFunctionData(functionFragment: "transferOwnership", values: [AddressLike]): string; decodeFunctionResult(functionFragment: "DOMAIN_SEPARATOR", data: BytesLike): Result; decodeFunctionResult(functionFragment: "allowance", data: BytesLike): Result; decodeFunctionResult(functionFragment: "approve", data: BytesLike): Result; decodeFunctionResult(functionFragment: "balanceOf", data: BytesLike): Result; decodeFunctionResult(functionFragment: "burn", data: BytesLike): Result; decodeFunctionResult(functionFragment: "burnFrom", data: BytesLike): Result; decodeFunctionResult(functionFragment: "decimals", data: BytesLike): Result; decodeFunctionResult(functionFragment: "decreaseAllowance", data: BytesLike): Result; decodeFunctionResult(functionFragment: "eip712Domain", data: BytesLike): Result; decodeFunctionResult(functionFragment: "increaseAllowance", data: BytesLike): Result; decodeFunctionResult(functionFragment: "mint", data: BytesLike): Result; decodeFunctionResult(functionFragment: "minters", data: BytesLike): Result; decodeFunctionResult(functionFragment: "name", data: BytesLike): Result; decodeFunctionResult(functionFragment: "nonces", data: BytesLike): Result; decodeFunctionResult(functionFragment: "owner", data: BytesLike): Result; decodeFunctionResult(functionFragment: "permit", data: BytesLike): Result; decodeFunctionResult(functionFragment: "renounceOwnership", data: BytesLike): Result; decodeFunctionResult(functionFragment: "symbol", data: BytesLike): Result; decodeFunctionResult(functionFragment: "toggleMinter", data: BytesLike): Result; decodeFunctionResult(functionFragment: "totalSupply", data: BytesLike): Result; decodeFunctionResult(functionFragment: "transfer", data: BytesLike): Result; decodeFunctionResult(functionFragment: "transferFrom", data: BytesLike): Result; decodeFunctionResult(functionFragment: "transferOwnership", data: BytesLike): Result; } export declare namespace ApprovalEvent { type InputTuple = [ owner: AddressLike, spender: AddressLike, value: BigNumberish ]; type OutputTuple = [owner: string, spender: string, value: bigint]; interface OutputObject { owner: string; spender: string; value: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace EIP712DomainChangedEvent { type InputTuple = []; type OutputTuple = []; interface OutputObject { } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace MintEvent { type InputTuple = [to: AddressLike, amount: BigNumberish]; type OutputTuple = [to: string, amount: bigint]; interface OutputObject { to: string; amount: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace OwnershipTransferredEvent { type InputTuple = [previousOwner: AddressLike, newOwner: AddressLike]; type OutputTuple = [previousOwner: string, newOwner: string]; interface OutputObject { previousOwner: string; newOwner: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace ToggleMinterEvent { type InputTuple = [account: AddressLike, isMinter: boolean]; type OutputTuple = [account: string, isMinter: boolean]; interface OutputObject { account: string; isMinter: boolean; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace TransferEvent { type InputTuple = [ from: AddressLike, to: AddressLike, value: BigNumberish ]; type OutputTuple = [from: string, to: string, value: bigint]; interface OutputObject { from: string; to: string; value: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export interface Lumia extends BaseContract { connect(runner?: ContractRunner | null): Lumia; waitForDeployment(): Promise<this>; interface: LumiaInterface; 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>; DOMAIN_SEPARATOR: TypedContractMethod<[], [string], "view">; allowance: TypedContractMethod<[ owner: AddressLike, spender: AddressLike ], [ bigint ], "view">; approve: TypedContractMethod<[ spender: AddressLike, amount: BigNumberish ], [ boolean ], "nonpayable">; balanceOf: TypedContractMethod<[account: AddressLike], [bigint], "view">; burn: TypedContractMethod<[amount: BigNumberish], [void], "nonpayable">; burnFrom: TypedContractMethod<[ account: AddressLike, amount: BigNumberish ], [ void ], "nonpayable">; decimals: TypedContractMethod<[], [bigint], "view">; decreaseAllowance: TypedContractMethod<[ spender: AddressLike, subtractedValue: BigNumberish ], [ boolean ], "nonpayable">; eip712Domain: TypedContractMethod<[ ], [ [ string, string, string, bigint, string, string, bigint[] ] & { fields: string; name: string; version: string; chainId: bigint; verifyingContract: string; salt: string; extensions: bigint[]; } ], "view">; increaseAllowance: TypedContractMethod<[ spender: AddressLike, addedValue: BigNumberish ], [ boolean ], "nonpayable">; mint: TypedContractMethod<[ to: AddressLike, amount: BigNumberish ], [ void ], "nonpayable">; minters: TypedContractMethod<[arg0: AddressLike], [boolean], "view">; name: TypedContractMethod<[], [string], "view">; nonces: TypedContractMethod<[owner: AddressLike], [bigint], "view">; owner: TypedContractMethod<[], [string], "view">; permit: TypedContractMethod<[ owner: AddressLike, spender: AddressLike, value: BigNumberish, deadline: BigNumberish, v: BigNumberish, r: BytesLike, s: BytesLike ], [ void ], "nonpayable">; renounceOwnership: TypedContractMethod<[], [void], "nonpayable">; symbol: TypedContractMethod<[], [string], "view">; toggleMinter: TypedContractMethod<[ minter: AddressLike ], [ void ], "nonpayable">; totalSupply: TypedContractMethod<[], [bigint], "view">; transfer: TypedContractMethod<[ to: AddressLike, amount: BigNumberish ], [ boolean ], "nonpayable">; transferFrom: TypedContractMethod<[ from: AddressLike, to: AddressLike, amount: BigNumberish ], [ boolean ], "nonpayable">; transferOwnership: TypedContractMethod<[ newOwner: AddressLike ], [ void ], "nonpayable">; getFunction<T extends ContractMethod = ContractMethod>(key: string | FunctionFragment): T; getFunction(nameOrSignature: "DOMAIN_SEPARATOR"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "allowance"): TypedContractMethod<[ owner: AddressLike, spender: AddressLike ], [ bigint ], "view">; getFunction(nameOrSignature: "approve"): TypedContractMethod<[ spender: AddressLike, amount: BigNumberish ], [ boolean ], "nonpayable">; getFunction(nameOrSignature: "balanceOf"): TypedContractMethod<[account: AddressLike], [bigint], "view">; getFunction(nameOrSignature: "burn"): TypedContractMethod<[amount: BigNumberish], [void], "nonpayable">; getFunction(nameOrSignature: "burnFrom"): TypedContractMethod<[ account: AddressLike, amount: BigNumberish ], [ void ], "nonpayable">; getFunction(nameOrSignature: "decimals"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "decreaseAllowance"): TypedContractMethod<[ spender: AddressLike, subtractedValue: BigNumberish ], [ boolean ], "nonpayable">; getFunction(nameOrSignature: "eip712Domain"): TypedContractMethod<[ ], [ [ string, string, string, bigint, string, string, bigint[] ] & { fields: string; name: string; version: string; chainId: bigint; verifyingContract: string; salt: string; extensions: bigint[]; } ], "view">; getFunction(nameOrSignature: "increaseAllowance"): TypedContractMethod<[ spender: AddressLike, addedValue: BigNumberish ], [ boolean ], "nonpayable">; getFunction(nameOrSignature: "mint"): TypedContractMethod<[ to: AddressLike, amount: BigNumberish ], [ void ], "nonpayable">; getFunction(nameOrSignature: "minters"): TypedContractMethod<[arg0: AddressLike], [boolean], "view">; getFunction(nameOrSignature: "name"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "nonces"): TypedContractMethod<[owner: AddressLike], [bigint], "view">; getFunction(nameOrSignature: "owner"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "permit"): TypedContractMethod<[ owner: AddressLike, spender: AddressLike, value: BigNumberish, deadline: BigNumberish, v: BigNumberish, r: BytesLike, s: BytesLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "renounceOwnership"): TypedContractMethod<[], [void], "nonpayable">; getFunction(nameOrSignature: "symbol"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "toggleMinter"): TypedContractMethod<[minter: AddressLike], [void], "nonpayable">; getFunction(nameOrSignature: "totalSupply"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "transfer"): TypedContractMethod<[ to: AddressLike, amount: BigNumberish ], [ boolean ], "nonpayable">; getFunction(nameOrSignature: "transferFrom"): TypedContractMethod<[ from: AddressLike, to: AddressLike, amount: BigNumberish ], [ boolean ], "nonpayable">; getFunction(nameOrSignature: "transferOwnership"): TypedContractMethod<[newOwner: AddressLike], [void], "nonpayable">; getEvent(key: "Approval"): TypedContractEvent<ApprovalEvent.InputTuple, ApprovalEvent.OutputTuple, ApprovalEvent.OutputObject>; getEvent(key: "EIP712DomainChanged"): TypedContractEvent<EIP712DomainChangedEvent.InputTuple, EIP712DomainChangedEvent.OutputTuple, EIP712DomainChangedEvent.OutputObject>; getEvent(key: "Mint"): TypedContractEvent<MintEvent.InputTuple, MintEvent.OutputTuple, MintEvent.OutputObject>; getEvent(key: "OwnershipTransferred"): TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>; getEvent(key: "ToggleMinter"): TypedContractEvent<ToggleMinterEvent.InputTuple, ToggleMinterEvent.OutputTuple, ToggleMinterEvent.OutputObject>; getEvent(key: "Transfer"): TypedContractEvent<TransferEvent.InputTuple, TransferEvent.OutputTuple, TransferEvent.OutputObject>; filters: { "Approval(address,address,uint256)": TypedContractEvent<ApprovalEvent.InputTuple, ApprovalEvent.OutputTuple, ApprovalEvent.OutputObject>; Approval: TypedContractEvent<ApprovalEvent.InputTuple, ApprovalEvent.OutputTuple, ApprovalEvent.OutputObject>; "EIP712DomainChanged()": TypedContractEvent<EIP712DomainChangedEvent.InputTuple, EIP712DomainChangedEvent.OutputTuple, EIP712DomainChangedEvent.OutputObject>; EIP712DomainChanged: TypedContractEvent<EIP712DomainChangedEvent.InputTuple, EIP712DomainChangedEvent.OutputTuple, EIP712DomainChangedEvent.OutputObject>; "Mint(address,uint256)": TypedContractEvent<MintEvent.InputTuple, MintEvent.OutputTuple, MintEvent.OutputObject>; Mint: TypedContractEvent<MintEvent.InputTuple, MintEvent.OutputTuple, MintEvent.OutputObject>; "OwnershipTransferred(address,address)": TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>; OwnershipTransferred: TypedContractEvent<OwnershipTransferredEvent.InputTuple, OwnershipTransferredEvent.OutputTuple, OwnershipTransferredEvent.OutputObject>; "ToggleMinter(address,bool)": TypedContractEvent<ToggleMinterEvent.InputTuple, ToggleMinterEvent.OutputTuple, ToggleMinterEvent.OutputObject>; ToggleMinter: TypedContractEvent<ToggleMinterEvent.InputTuple, ToggleMinterEvent.OutputTuple, ToggleMinterEvent.OutputObject>; "Transfer(address,address,uint256)": TypedContractEvent<TransferEvent.InputTuple, TransferEvent.OutputTuple, TransferEvent.OutputObject>; Transfer: TypedContractEvent<TransferEvent.InputTuple, TransferEvent.OutputTuple, TransferEvent.OutputObject>; }; }