12345import type BN from "bn.js";6import type { ContractOptions } from "web3-eth-contract";7import type { EventLog } from "web3-core";8import type { EventEmitter } from "events";9import type {10 Callback,11 PayableTransactionObject,12 NonPayableTransactionObject,13 BlockType,14 ContractEventLog,15 BaseContract,16} from "./types";1718export interface EventOptions {19 filter?: object;20 fromBlock?: BlockType;21 topics?: string[];22}2324export type AllChildrenRejected = ContractEventLog<{25 tokenId: string;26 0: string;27}>;28export type Approval = ContractEventLog<{29 owner: string;30 approved: string;31 tokenId: string;32 0: string;33 1: string;34 2: string;35}>;36export type ApprovalForAll = ContractEventLog<{37 owner: string;38 operator: string;39 approved: boolean;40 0: string;41 1: string;42 2: boolean;43}>;44export type ChildAccepted = ContractEventLog<{45 tokenId: string;46 childIndex: string;47 childAddress: string;48 childId: string;49 0: string;50 1: string;51 2: string;52 3: string;53}>;54export type ChildProposed = ContractEventLog<{55 tokenId: string;56 childIndex: string;57 childAddress: string;58 childId: string;59 0: string;60 1: string;61 2: string;62 3: string;63}>;64export type ChildTransferred = ContractEventLog<{65 tokenId: string;66 childIndex: string;67 childAddress: string;68 childId: string;69 fromPending: boolean;70 toZero: boolean;71 0: string;72 1: string;73 2: string;74 3: string;75 4: boolean;76 5: boolean;77}>;78export type NestTransfer = ContractEventLog<{79 from: string;80 to: string;81 fromTokenId: string;82 toTokenId: string;83 tokenId: string;84 0: string;85 1: string;86 2: string;87 3: string;88 4: string;89}>;90export type Transfer = ContractEventLog<{91 from: string;92 to: string;93 tokenId: string;94 0: string;95 1: string;96 2: string;97}>;9899export interface RMRKNestableMintable extends BaseContract {100 constructor(101 jsonInterface: any[],102 address?: string,103 options?: ContractOptions104 ): RMRKNestableMintable;105 clone(): RMRKNestableMintable;106 methods: {107 RMRK_INTERFACE(): NonPayableTransactionObject<string>;108109 VERSION(): NonPayableTransactionObject<string>;110111 acceptChild(112 parentId: number | string | BN,113 childIndex: number | string | BN,114 childAddress: string,115 childId: number | string | BN116 ): NonPayableTransactionObject<void>;117118 addChild(119 parentId: number | string | BN,120 childId: number | string | BN,121 data: string | number[]122 ): NonPayableTransactionObject<void>;123124 approve(125 to: string,126 tokenId: number | string | BN127 ): NonPayableTransactionObject<void>;128129 balanceOf(owner: string): NonPayableTransactionObject<string>;130131 "burn(uint256)"(132 tokenId: number | string | BN133 ): NonPayableTransactionObject<void>;134135 "burn(uint256,uint256)"(136 tokenId: number | string | BN,137 maxChildrenBurns: number | string | BN138 ): NonPayableTransactionObject<string>;139140 childOf(141 parentId: number | string | BN,142 index: number | string | BN143 ): NonPayableTransactionObject<[string, string]>;144145 childrenOf(146 parentId: number | string | BN147 ): NonPayableTransactionObject<[string, string][]>;148149 directOwnerOf(tokenId: number | string | BN): NonPayableTransactionObject<{150 0: string;151 1: string;152 2: boolean;153 }>;154155 getApproved(156 tokenId: number | string | BN157 ): NonPayableTransactionObject<string>;158159 isApprovedForAll(160 owner: string,161 operator: string162 ): NonPayableTransactionObject<boolean>;163164 mint(165 to: string,166 tokenId: number | string | BN167 ): NonPayableTransactionObject<void>;168169 name(): NonPayableTransactionObject<string>;170171 nestMint(172 to: string,173 tokenId: number | string | BN,174 destinationId: number | string | BN175 ): NonPayableTransactionObject<void>;176177 nestTransfer(178 to: string,179 tokenId: number | string | BN,180 destinationId: number | string | BN181 ): NonPayableTransactionObject<void>;182183 nestTransferFrom(184 from: string,185 to: string,186 tokenId: number | string | BN,187 destinationId: number | string | BN,188 data: string | number[]189 ): NonPayableTransactionObject<void>;190191 onERC721Received(192 _operator: string,193 _from: string,194 _tokenId: number | string | BN,195 _data: string | number[]196 ): NonPayableTransactionObject<string>;197198 ownerOf(tokenId: number | string | BN): NonPayableTransactionObject<string>;199200 pendingChildOf(201 parentId: number | string | BN,202 index: number | string | BN203 ): NonPayableTransactionObject<[string, string]>;204205 pendingChildrenOf(206 parentId: number | string | BN207 ): NonPayableTransactionObject<[string, string][]>;208209 rejectAllChildren(210 tokenId: number | string | BN,211 maxRejections: number | string | BN212 ): NonPayableTransactionObject<void>;213214 safeMint(to: string): NonPayableTransactionObject<void>;215216 "safeTransferFrom(address,address,uint256)"(217 from: string,218 to: string,219 tokenId: number | string | BN220 ): NonPayableTransactionObject<void>;221222 "safeTransferFrom(address,address,uint256,bytes)"(223 from: string,224 to: string,225 tokenId: number | string | BN,226 data: string | number[]227 ): NonPayableTransactionObject<void>;228229 setApprovalForAll(230 operator: string,231 approved: boolean232 ): NonPayableTransactionObject<void>;233234 supportsInterface(235 interfaceId: string | number[]236 ): NonPayableTransactionObject<boolean>;237238 symbol(): NonPayableTransactionObject<string>;239240 transfer(241 to: string,242 tokenId: number | string | BN243 ): NonPayableTransactionObject<void>;244245 transferChild(246 tokenId: number | string | BN,247 to: string,248 destinationId: number | string | BN,249 childIndex: number | string | BN,250 childAddress: string,251 childId: number | string | BN,252 isPending: boolean,253 data: string | number[]254 ): NonPayableTransactionObject<void>;255256 transferFrom(257 from: string,258 to: string,259 tokenId: number | string | BN260 ): NonPayableTransactionObject<void>;261 };262 events: {263 AllChildrenRejected(cb?: Callback<AllChildrenRejected>): EventEmitter;264 AllChildrenRejected(265 options?: EventOptions,266 cb?: Callback<AllChildrenRejected>267 ): EventEmitter;268269 Approval(cb?: Callback<Approval>): EventEmitter;270 Approval(options?: EventOptions, cb?: Callback<Approval>): EventEmitter;271272 ApprovalForAll(cb?: Callback<ApprovalForAll>): EventEmitter;273 ApprovalForAll(274 options?: EventOptions,275 cb?: Callback<ApprovalForAll>276 ): EventEmitter;277278 ChildAccepted(cb?: Callback<ChildAccepted>): EventEmitter;279 ChildAccepted(280 options?: EventOptions,281 cb?: Callback<ChildAccepted>282 ): EventEmitter;283284 ChildProposed(cb?: Callback<ChildProposed>): EventEmitter;285 ChildProposed(286 options?: EventOptions,287 cb?: Callback<ChildProposed>288 ): EventEmitter;289290 ChildTransferred(cb?: Callback<ChildTransferred>): EventEmitter;291 ChildTransferred(292 options?: EventOptions,293 cb?: Callback<ChildTransferred>294 ): EventEmitter;295296 NestTransfer(cb?: Callback<NestTransfer>): EventEmitter;297 NestTransfer(298 options?: EventOptions,299 cb?: Callback<NestTransfer>300 ): EventEmitter;301302 Transfer(cb?: Callback<Transfer>): EventEmitter;303 Transfer(options?: EventOptions, cb?: Callback<Transfer>): EventEmitter;304305 allEvents(options?: EventOptions, cb?: Callback<EventLog>): EventEmitter;306 };307308 once(event: "AllChildrenRejected", cb: Callback<AllChildrenRejected>): void;309 once(310 event: "AllChildrenRejected",311 options: EventOptions,312 cb: Callback<AllChildrenRejected>313 ): void;314315 once(event: "Approval", cb: Callback<Approval>): void;316 once(event: "Approval", options: EventOptions, cb: Callback<Approval>): void;317318 once(event: "ApprovalForAll", cb: Callback<ApprovalForAll>): void;319 once(320 event: "ApprovalForAll",321 options: EventOptions,322 cb: Callback<ApprovalForAll>323 ): void;324325 once(event: "ChildAccepted", cb: Callback<ChildAccepted>): void;326 once(327 event: "ChildAccepted",328 options: EventOptions,329 cb: Callback<ChildAccepted>330 ): void;331332 once(event: "ChildProposed", cb: Callback<ChildProposed>): void;333 once(334 event: "ChildProposed",335 options: EventOptions,336 cb: Callback<ChildProposed>337 ): void;338339 once(event: "ChildTransferred", cb: Callback<ChildTransferred>): void;340 once(341 event: "ChildTransferred",342 options: EventOptions,343 cb: Callback<ChildTransferred>344 ): void;345346 once(event: "NestTransfer", cb: Callback<NestTransfer>): void;347 once(348 event: "NestTransfer",349 options: EventOptions,350 cb: Callback<NestTransfer>351 ): void;352353 once(event: "Transfer", cb: Callback<Transfer>): void;354 once(event: "Transfer", options: EventOptions, cb: Callback<Transfer>): void;355}