import { Address, AddressMap } from '../../../../../node_modules/@btc-vision/transaction/build/index.js'; import { CallResult } from '../../../../contracts/CallResult.js'; import { OPNetEvent } from '../../../../contracts/OPNetEvent.js'; import { IOP_NETContract } from './IOP_NETContract.js'; export type TransferredEvent = { readonly operator: Address; readonly from: Address; readonly to: Address; readonly amount: bigint; }; export type ApprovedEvent = { readonly owner: Address; readonly spender: Address; readonly amount: bigint; }; export type BurnedEvent = { readonly from: Address; readonly amount: bigint; }; export type MintedEvent = { readonly to: Address; readonly amount: bigint; }; export type Name = CallResult<{ name: string; }, [ ]>; export type SymbolOf = CallResult<{ symbol: string; }, [ ]>; export type TokenIcon = CallResult<{ icon: string; }, [ ]>; export type Decimals = CallResult<{ decimals: number; }, [ ]>; export type TotalSupply = CallResult<{ totalSupply: bigint; }, [ ]>; export type MaxSupply = CallResult<{ maximumSupply: bigint; }, [ ]>; export type DomainSeparator = CallResult<{ domainSeparator: Uint8Array; }, [ ]>; export type BalanceOf = CallResult<{ balance: bigint; }, [ ]>; export type NonceOf = CallResult<{ nonce: bigint; }, [ ]>; export type Allowance = CallResult<{ remaining: bigint; }, [ ]>; export type Transfer = CallResult<{}, [OPNetEvent]>; export type TransferFrom = CallResult<{}, [OPNetEvent]>; export type SafeTransfer = CallResult<{}, [OPNetEvent]>; export type SafeTransferFrom = CallResult<{}, [OPNetEvent]>; export type IncreaseAllowance = CallResult<{}, [OPNetEvent]>; export type DecreaseAllowance = CallResult<{}, [OPNetEvent]>; export type IncreaseAllowanceBySignature = CallResult<{}, [OPNetEvent]>; export type DecreaseAllowanceBySignature = CallResult<{}, [OPNetEvent]>; export type Burn = CallResult<{}, [OPNetEvent]>; export type Mint = CallResult<{}, OPNetEvent[]>; export type Airdrop = CallResult<{}, OPNetEvent[]>; export type TokenMetadata = CallResult<{ name: string; symbol: string; icon: string; decimals: number; totalSupply: bigint; domainSeparator: Uint8Array; }, [ ]>; export interface IOP20Contract extends IOP_NETContract { name(): Promise; symbol(): Promise; icon(): Promise; decimals(): Promise; totalSupply(): Promise; maximumSupply(): Promise; domainSeparator(): Promise; balanceOf(owner: Address): Promise; nonceOf(owner: Address): Promise; allowance(owner: Address, spender: Address): Promise; transfer(to: Address, amount: bigint): Promise; transferFrom(from: Address, to: Address, amount: bigint): Promise; safeTransfer(to: Address, amount: bigint, data: Uint8Array): Promise; safeTransferFrom(from: Address, to: Address, amount: bigint, data: Uint8Array): Promise; increaseAllowance(spender: Address, amount: bigint): Promise; decreaseAllowance(spender: Address, amount: bigint): Promise; increaseAllowanceBySignature(owner: Uint8Array, ownerTweakedPublicKey: Uint8Array, spender: Address, amount: bigint, deadline: bigint, signature: Uint8Array): Promise; decreaseAllowanceBySignature(owner: Uint8Array, ownerTweakedPublicKey: Uint8Array, spender: Address, amount: bigint, deadline: bigint, signature: Uint8Array): Promise; burn(amount: bigint): Promise; metadata(): Promise; mint(address: Address, amount: bigint): Promise; airdrop(addressAndAmount: AddressMap): Promise; }