ufomarketplace-sdk-new
Version:
SDK to interact with set ufo marketplace contracts
140 lines (132 loc) • 7.9 kB
text/typescript
/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
import {
Signer,
utils,
Contract,
ContractFactory,
PayableOverrides,
BytesLike,
} from "ethers";
import type { Provider, TransactionRequest } from "@ethersproject/providers";
import type { BeaconProxy, BeaconProxyInterface } from "../BeaconProxy";
const _abi = [
{
type: "constructor",
inputs: [
{
name: "beacon",
type: "address",
internalType: "address",
},
{
name: "data",
type: "bytes",
internalType: "bytes",
},
],
stateMutability: "payable",
},
{
type: "fallback",
stateMutability: "payable",
},
{
type: "receive",
stateMutability: "payable",
},
{
type: "event",
name: "AdminChanged",
inputs: [
{
name: "previousAdmin",
type: "address",
indexed: false,
internalType: "address",
},
{
name: "newAdmin",
type: "address",
indexed: false,
internalType: "address",
},
],
anonymous: false,
},
{
type: "event",
name: "BeaconUpgraded",
inputs: [
{
name: "beacon",
type: "address",
indexed: true,
internalType: "address",
},
],
anonymous: false,
},
{
type: "event",
name: "Upgraded",
inputs: [
{
name: "implementation",
type: "address",
indexed: true,
internalType: "address",
},
],
anonymous: false,
},
] as const;
const _bytecode =
"0x608060405260405161091238038061091283398101604081905261002291610457565b61002e82826000610035565b50506105a8565b61003e8361010f565b6040516001600160a01b038416907f1cf3b03a6cf19fa2baba4df148e9dcabedea7f8a5c07840e207e5c089be95d3e90600090a260008251118061007f5750805b1561010a57610108836001600160a01b0316635c60da1b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156100c057600080fd5b505afa1580156100d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906100f8919061043c565b836102c160201b6100291760201c565b505b505050565b610122816102ed60201b6100551760201c565b6101815760405162461bcd60e51b815260206004820152602560248201527f455243313936373a206e657720626561636f6e206973206e6f74206120636f6e6044820152641d1c9858dd60da1b60648201526084015b60405180910390fd5b610204816001600160a01b0316635c60da1b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156101bd57600080fd5b505afa1580156101d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101f5919061043c565b6102ed60201b6100551760201c565b6102695760405162461bcd60e51b815260206004820152603060248201527f455243313936373a20626561636f6e20696d706c656d656e746174696f6e206960448201526f1cc81b9bdd08184818dbdb9d1c9858dd60821b6064820152608401610178565b806102a07fa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d5060001b6102fc60201b6100641760201c565b80546001600160a01b0319166001600160a01b039290921691909117905550565b60606102e683836040518060600160405280602781526020016108eb602791396102ff565b9392505050565b6001600160a01b03163b151590565b90565b6060600080856001600160a01b03168560405161031c9190610517565b600060405180830381855af49150503d8060008114610357576040519150601f19603f3d011682016040523d82523d6000602084013e61035c565b606091505b50909250905061036e86838387610378565b9695505050505050565b606083156103e45782516103dd576001600160a01b0385163b6103dd5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610178565b50816103ee565b6103ee83836103f6565b949350505050565b8151156104065781518083602001fd5b8060405162461bcd60e51b81526004016101789190610533565b80516001600160a01b038116811461043757600080fd5b919050565b60006020828403121561044e57600080fd5b6102e682610420565b6000806040838503121561046a57600080fd5b61047383610420565b60208401519092506001600160401b038082111561049057600080fd5b818501915085601f8301126104a457600080fd5b8151818111156104b6576104b6610592565b604051601f8201601f19908116603f011681019083821181831017156104de576104de610592565b816040528281528860208487010111156104f757600080fd5b610508836020830160208801610566565b80955050505050509250929050565b60008251610529818460208701610566565b9190910192915050565b6020815260008251806020840152610552816040850160208701610566565b601f01601f19169190910160400192915050565b60005b83811015610581578181015183820152602001610569565b838111156101085750506000910152565b634e487b7160e01b600052604160045260246000fd5b610334806105b76000396000f3fe60806040523661001357610011610017565b005b6100115b610027610022610067565b61010f565b565b606061004e838360405180606001604052806027815260200161030160279139610133565b9392505050565b6001600160a01b03163b151590565b90565b600061009a7fa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50546001600160a01b031690565b6001600160a01b0316635c60da1b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156100d257600080fd5b505afa1580156100e6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061010a9190610258565b905090565b3660008037600080366000845af43d6000803e80801561012e573d6000f35b3d6000fd5b6060600080856001600160a01b0316856040516101509190610281565b600060405180830381855af49150503d806000811461018b576040519150601f19603f3d011682016040523d82523d6000602084013e610190565b606091505b50915091506101a1868383876101ab565b9695505050505050565b6060831561021c578251610215576001600160a01b0385163b6102155760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064015b60405180910390fd5b5081610226565b610226838361022e565b949350505050565b81511561023e5781518083602001fd5b8060405162461bcd60e51b815260040161020c919061029d565b60006020828403121561026a57600080fd5b81516001600160a01b038116811461004e57600080fd5b600082516102938184602087016102d0565b9190910192915050565b60208152600082518060208401526102bc8160408501602087016102d0565b601f01601f19169190910160400192915050565b60005b838110156102eb5781810151838201526020016102d3565b838111156102fa576000848401525b5050505056fe416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564a164736f6c6343000807000a416464726573733a206c6f772d6c6576656c2064656c65676174652063616c6c206661696c6564";
type BeaconProxyConstructorParams =
| [signer?: Signer]
| ConstructorParameters<typeof ContractFactory>;
const isSuperArgs = (
xs: BeaconProxyConstructorParams
): xs is ConstructorParameters<typeof ContractFactory> => xs.length > 1;
export class BeaconProxy__factory extends ContractFactory {
constructor(...args: BeaconProxyConstructorParams) {
if (isSuperArgs(args)) {
super(...args);
} else {
super(_abi, _bytecode, args[0]);
}
}
override deploy(
beacon: string,
data: BytesLike,
overrides?: PayableOverrides & { from?: string }
): Promise<BeaconProxy> {
return super.deploy(beacon, data, overrides || {}) as Promise<BeaconProxy>;
}
override getDeployTransaction(
beacon: string,
data: BytesLike,
overrides?: PayableOverrides & { from?: string }
): TransactionRequest {
return super.getDeployTransaction(beacon, data, overrides || {});
}
override attach(address: string): BeaconProxy {
return super.attach(address) as BeaconProxy;
}
override connect(signer: Signer): BeaconProxy__factory {
return super.connect(signer) as BeaconProxy__factory;
}
static readonly bytecode = _bytecode;
static readonly abi = _abi;
static createInterface(): BeaconProxyInterface {
return new utils.Interface(_abi) as BeaconProxyInterface;
}
static connect(
address: string,
signerOrProvider: Signer | Provider
): BeaconProxy {
return new Contract(address, _abi, signerOrProvider) as BeaconProxy;
}
}