UNPKG

@phiresky/eth-scan

Version:

An efficient Ether and token balance scanner

221 lines (214 loc) 11 kB
/* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ import {Signer} from "ethers"; import {Provider, TransactionRequest} from "@ethersproject/providers"; import {Contract, ContractFactory, Overrides} from "@ethersproject/contracts"; import type {BalanceScanner} from "../BalanceScanner"; export class BalanceScanner__factory extends ContractFactory { constructor(signer?: Signer) { super(_abi, _bytecode, signer); } deploy(overrides?: Overrides): Promise<BalanceScanner> { return super.deploy(overrides || {}) as Promise<BalanceScanner>; } getDeployTransaction(overrides?: Overrides): TransactionRequest { return super.getDeployTransaction(overrides || {}); } attach(address: string): BalanceScanner { return super.attach(address) as BalanceScanner; } connect(signer: Signer): BalanceScanner__factory { return super.connect(signer) as BalanceScanner__factory; } static connect( address: string, signerOrProvider: Signer | Provider ): BalanceScanner { return new Contract(address, _abi, signerOrProvider) as BalanceScanner; } } const _abi = [ { inputs: [ { internalType: "address[]", name: "contracts", type: "address[]", }, { internalType: "bytes[]", name: "data", type: "bytes[]", }, { internalType: "uint256", name: "gas", type: "uint256", }, ], name: "call", outputs: [ { components: [ { internalType: "bool", name: "success", type: "bool", }, { internalType: "bytes", name: "data", type: "bytes", }, ], internalType: "struct BalanceScanner.Result[]", name: "results", type: "tuple[]", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address[]", name: "contracts", type: "address[]", }, { internalType: "bytes[]", name: "data", type: "bytes[]", }, ], name: "call", outputs: [ { components: [ { internalType: "bool", name: "success", type: "bool", }, { internalType: "bytes", name: "data", type: "bytes", }, ], internalType: "struct BalanceScanner.Result[]", name: "results", type: "tuple[]", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address[]", name: "addresses", type: "address[]", }, ], name: "etherBalances", outputs: [ { components: [ { internalType: "bool", name: "success", type: "bool", }, { internalType: "bytes", name: "data", type: "bytes", }, ], internalType: "struct BalanceScanner.Result[]", name: "results", type: "tuple[]", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address[]", name: "addresses", type: "address[]", }, { internalType: "address", name: "token", type: "address", }, ], name: "tokenBalances", outputs: [ { components: [ { internalType: "bool", name: "success", type: "bool", }, { internalType: "bytes", name: "data", type: "bytes", }, ], internalType: "struct BalanceScanner.Result[]", name: "results", type: "tuple[]", }, ], stateMutability: "view", type: "function", }, { inputs: [ { internalType: "address", name: "owner", type: "address", }, { internalType: "address[]", name: "contracts", type: "address[]", }, ], name: "tokensBalance", outputs: [ { components: [ { internalType: "bool", name: "success", type: "bool", }, { internalType: "bytes", name: "data", type: "bytes", }, ], internalType: "struct BalanceScanner.Result[]", name: "results", type: "tuple[]", }, ], stateMutability: "view", type: "function", }, ]; const _bytecode = "0x608060405234801561001057600080fd5b50610c29806100206000396000f3fe608060405234801561001057600080fd5b50600436106100675760003560e01c8063aad3309111610050578063aad33091146100a8578063dbdbb51b146100bb578063e5da1b68146100ce57610067565b8063367383741461006c578063458b3a7c14610095575b600080fd5b61007f61007a3660046109de565b6100e1565b60405161008c9190610a6b565b60405180910390f35b61007f6100a3366004610975565b6102b9565b61007f6100b6366004610923565b6102d1565b61007f6100c93660046108e3565b610456565b61007f6100dc366004610892565b61059c565b6060848314610150576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4c656e677468206d75737420626520657175616c000000000000000000000000604482015260640160405180910390fd5b8467ffffffffffffffff81111561017757634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156101bd57816020015b6040805180820190915260008152606060208201528152602001906001900390816101955790505b50905060005b858110156102af576102718787838181106101ee57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906102039190610878565b86868481811061022357634e487b7160e01b600052603260045260246000fd5b90506020028101906102359190610b1b565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250889250610721915050565b82828151811061029157634e487b7160e01b600052603260045260246000fd5b602002602001018190525080806102a790610bae565b9150506101c3565b5095945050505050565b60606102c8858585855a6100e1565b95945050505050565b60608267ffffffffffffffff8111156102fa57634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561034057816020015b6040805180820190915260008152606060208201528152602001906001900390816103185790505b50905060005b8381101561044e57600085858381811061037057634e487b7160e01b600052603260045260246000fd5b90506020020160208101906103859190610878565b60405173ffffffffffffffffffffffffffffffffffffffff909116602482015260440160408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f70a0823100000000000000000000000000000000000000000000000000000000179052905061040f8482614e20610721565b83838151811061042f57634e487b7160e01b600052603260045260246000fd5b602002602001018190525050808061044690610bae565b915050610346565b509392505050565b60608167ffffffffffffffff81111561047f57634e487b7160e01b600052604160045260246000fd5b6040519080825280602002602001820160405280156104c557816020015b60408051808201909152600081526060602082015281526020019060019003908161049d5790505b50905060005b8281101561059557604051806040016040528060011515815260200185858481811061050757634e487b7160e01b600052603260045260246000fd5b905060200201602081019061051c9190610878565b73ffffffffffffffffffffffffffffffffffffffff163160405160200161054591815260200190565b60405160208183030381529060405281525082828151811061057757634e487b7160e01b600052603260045260246000fd5b6020026020010181905250808061058d90610bae565b9150506104cb565b5092915050565b60608167ffffffffffffffff8111156105c557634e487b7160e01b600052604160045260246000fd5b60405190808252806020026020018201604052801561060b57816020015b6040805180820190915260008152606060208201528152602001906001900390816105e35790505b5060405173ffffffffffffffffffffffffffffffffffffffff8616602482015290915060009060440160408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f70a0823100000000000000000000000000000000000000000000000000000000179052905060005b83811015610718576106da8585838181106106bc57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906106d19190610878565b83614e20610721565b8382815181106106fa57634e487b7160e01b600052603260045260246000fd5b6020026020010181905250808061071090610bae565b915050610691565b50509392505050565b604080518082019091526000815260606020820152833b80156107d3576000808673ffffffffffffffffffffffffffffffffffffffff1685876040516107679190610a4f565b6000604051808303818686fa925050503d80600081146107a3576040519150601f19603f3d011682016040523d82523d6000602084013e6107a8565b606091505b509150915081156107d057604080518082019091529115158252602082015291506107fe9050565b50505b6040518060400160405280600015158152602001604051806020016040528060008152508152509150505b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461082957600080fd5b919050565b60008083601f84011261083f578182fd5b50813567ffffffffffffffff811115610856578182fd5b6020830191508360208260051b850101111561087157600080fd5b9250929050565b600060208284031215610889578081fd5b6107fe82610805565b6000806000604084860312156108a6578182fd5b6108af84610805565b9250602084013567ffffffffffffffff8111156108ca578283fd5b6108d68682870161082e565b9497909650939450505050565b600080602083850312156108f5578182fd5b823567ffffffffffffffff81111561090b578283fd5b6109178582860161082e565b90969095509350505050565b600080600060408486031215610937578283fd5b833567ffffffffffffffff81111561094d578384fd5b6109598682870161082e565b909450925061096c905060208501610805565b90509250925092565b6000806000806040858703121561098a578081fd5b843567ffffffffffffffff808211156109a1578283fd5b6109ad8883890161082e565b909650945060208701359150808211156109c5578283fd5b506109d28782880161082e565b95989497509550505050565b6000806000806000606086880312156109f5578081fd5b853567ffffffffffffffff80821115610a0c578283fd5b610a1889838a0161082e565b90975095506020880135915080821115610a30578283fd5b50610a3d8882890161082e565b96999598509660400135949350505050565b60008251610a61818460208701610b7e565b9190910192915050565b60006020808301818452808551808352604092508286019150828160051b870101848801865b83811015610b0d578883037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc0018552815180511515845287015187840187905280518785018190526060610aea82828801858d01610b7e565b96890196601f91909101601f191694909401909301925090860190600101610a91565b509098975050505050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610b4f578283fd5b83018035915067ffffffffffffffff821115610b69578283fd5b60200191503681900382131561087157600080fd5b60005b83811015610b99578181015183820152602001610b81565b83811115610ba8576000848401525b50505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415610bec57634e487b7160e01b81526011600452602481fd5b506001019056fea2646970667358221220e8c924774ae9547fb6c3f81b9817f53df0b070dd9e37e05ce52f4cfa1712f0f164736f6c63430008030033";