@astonic-io/astonic-bindings-ts
Version:
Astonic type generation and npm package deployment repo
327 lines (326 loc) • 13.5 kB
JavaScript
;
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
return extendStatics(d, b);
};
return function (d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.Emission__factory = void 0;
/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
var ethers_1 = require("ethers");
var _abi = [
{
type: "constructor",
inputs: [
{
name: "disable",
type: "bool",
internalType: "bool",
},
],
stateMutability: "nonpayable",
},
{
type: "function",
name: "A",
inputs: [],
outputs: [
{
name: "",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "view",
},
{
type: "function",
name: "SCALER",
inputs: [],
outputs: [
{
name: "",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "view",
},
{
type: "function",
name: "astonicToken",
inputs: [],
outputs: [
{
name: "",
type: "address",
internalType: "contract AstonicToken",
},
],
stateMutability: "view",
},
{
type: "function",
name: "calculateEmission",
inputs: [],
outputs: [
{
name: "amount",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "view",
},
{
type: "function",
name: "emissionStartTime",
inputs: [],
outputs: [
{
name: "",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "view",
},
{
type: "function",
name: "emissionSupply",
inputs: [],
outputs: [
{
name: "",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "view",
},
{
type: "function",
name: "emissionTarget",
inputs: [],
outputs: [
{
name: "",
type: "address",
internalType: "address",
},
],
stateMutability: "view",
},
{
type: "function",
name: "emitTokens",
inputs: [],
outputs: [
{
name: "amount",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "nonpayable",
},
{
type: "function",
name: "initialize",
inputs: [
{
name: "astonicToken_",
type: "address",
internalType: "address",
},
{
name: "emissionTarget_",
type: "address",
internalType: "address",
},
{
name: "emissionSupply_",
type: "uint256",
internalType: "uint256",
},
],
outputs: [],
stateMutability: "nonpayable",
},
{
type: "function",
name: "owner",
inputs: [],
outputs: [
{
name: "",
type: "address",
internalType: "address",
},
],
stateMutability: "view",
},
{
type: "function",
name: "renounceOwnership",
inputs: [],
outputs: [],
stateMutability: "nonpayable",
},
{
type: "function",
name: "setEmissionTarget",
inputs: [
{
name: "emissionTarget_",
type: "address",
internalType: "address",
},
],
outputs: [],
stateMutability: "nonpayable",
},
{
type: "function",
name: "totalEmittedAmount",
inputs: [],
outputs: [
{
name: "",
type: "uint256",
internalType: "uint256",
},
],
stateMutability: "view",
},
{
type: "function",
name: "transferOwnership",
inputs: [
{
name: "newOwner",
type: "address",
internalType: "address",
},
],
outputs: [],
stateMutability: "nonpayable",
},
{
type: "event",
name: "EmissionTargetSet",
inputs: [
{
name: "newTargetAddress",
type: "address",
indexed: false,
internalType: "address",
},
],
anonymous: false,
},
{
type: "event",
name: "Initialized",
inputs: [
{
name: "version",
type: "uint8",
indexed: false,
internalType: "uint8",
},
],
anonymous: false,
},
{
type: "event",
name: "OwnershipTransferred",
inputs: [
{
name: "previousOwner",
type: "address",
indexed: true,
internalType: "address",
},
{
name: "newOwner",
type: "address",
indexed: true,
internalType: "address",
},
],
anonymous: false,
},
{
type: "event",
name: "TokensEmitted",
inputs: [
{
name: "target",
type: "address",
indexed: true,
internalType: "address",
},
{
name: "amount",
type: "uint256",
indexed: false,
internalType: "uint256",
},
],
anonymous: false,
},
];
var _bytecode = "0x60803461010b57601f6109ad38819003918201601f19168301916001600160401b038311848410176101105780849260209460405283398101031261010b5751801515810361010b5761005c575b60405161088690816101278239f35b60005460ff8160081c166100b65760ff8082161061007b575b5061004d565b60ff90811916176000557f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498602060405160ff8152a138610075565b60405162461bcd60e51b815260206004820152602760248201527f496e697469616c697a61626c653a20636f6e747261637420697320696e697469604482015266616c697a696e6760c81b6064820152608490fd5b600080fd5b634e487b7160e01b600052604160045260246000fdfe608060408181526004918236101561001657600080fd5b600092833560e01c9182631794bb3c1461048e575081631efbdcd3146104655781633fecb08714610446578163715018a6146103e65781637cfd0f99146103775781638da5cb5b1461034e5781639245902814610325578163aa8754e414610301578163b55e511d146102e2578163c89aee83146101b8578163d73e179214610199578163f003f2c014610176578163f2fde38b146100e0575063f446c1d0146100bf57600080fd5b346100dc57816003193601126100dc5760209051630d8f21fa8152f35b5080fd5b905034610172576020366003190112610172576100fb610616565b916101046107af565b6001600160a01b03831615610120578361011d84610807565b80f35b906020608492519162461bcd60e51b8352820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152fd5b8280fd5b5050346100dc57816003193601126100dc5760209051670de0b6b3a76400008152f35b5050346100dc57816003193601126100dc576020906069549051908152f35b8383346100dc57816003193601126100dc576101d2610674565b91821561029f576101e583606954610631565b60695560018060a01b03806068541690817f2a0663121101e671ccf9b7a37475f4b7dd34994b8711f1bd2cc11fa8f0760d0b60208651888152a26066541690813b1561017257829160448392865195869384926340c10f1960e01b84528b8401528960248401525af1801561029357610263575b6020848451908152f35b67ffffffffffffffff821161028057506020935081528380610259565b634e487b7160e01b815260418552602490fd5b508251903d90823e3d90fd5b815162461bcd60e51b8152602081860152601b60248201527f456d697373696f6e3a206e6f20746f6b656e7320746f20656d697400000000006044820152606490fd5b5050346100dc57816003193601126100dc576020906065549051908152f35b5050346100dc57816003193601126100dc5760209061031e610674565b9051908152f35b5050346100dc57816003193601126100dc5760665490516001600160a01b039091168152602090f35b5050346100dc57816003193601126100dc5760335490516001600160a01b039091168152602090f35b5050346100dc5760203660031901126100dc5760207ff8c91b1c6f821fe1e0f54a700d7971394e31753d44867fa41b80762dd3e2362c916103b6610616565b6103be6107af565b606880546001600160a01b0319166001600160a01b039290921691821790559051908152a180f35b83346104435780600319360112610443576103ff6107af565b603380546001600160a01b0319811690915581906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b80fd5b5050346100dc57816003193601126100dc576020906067549051908152f35b5050346100dc57816003193601126100dc5760685490516001600160a01b039091168152602090f35b90915034610612576060366003190112610612576104aa610616565b6001600160a01b03602435818116939084900361060e5786549060ff8260081c161595868097610601575b80156105ea575b1561059257505060ff198116600117875584610581575b50426065556bffffffffffffffffffffffff60a01b9116816066541617606655606854161760685560443560675561053a60ff845460081c166105358161074f565b61074f565b61054333610807565b61054b575080f35b60207f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989161ff001984541684555160018152a180f35b61ffff1916610101178655386104f3565b62461bcd60e51b8252602090820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608490fd5b50303b1580156104dc5750600160ff8416146104dc565b50600160ff8416106104d5565b8680fd5b8380fd5b600435906001600160a01b038216820361062c57565b600080fd5b9190820180921161063e57565b634e487b7160e01b600052601160045260246000fd5b9190820391821161063e57565b8181029291811591840414171561063e57565b61068060655442610654565b670de0b6b3a764000090808202828104820361063e57630d8f21fa900490631b1e43f46106ad8284610661565b046328ad65ee6106bd8383610661565b04916343cba9e26106de63363c87e86106d68487610661565b049283610661565b049185019283861161063e576106fa6107009261070595610631565b94610631565b610631565b9081811061073d5761073a9261072a6107246107319460675494610654565b83610661565b0490610654565b60695490610654565b90565b50505061073a60675460695490610654565b1561075657565b60405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608490fd5b6033546001600160a01b031633036107c357565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b603380546001600160a01b039283166001600160a01b0319821681179092559091167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a356fea26469706673582212205f2b7cddaf7f48e85fe0ddb047a8acd8b8cea21dc3dc44610f5029caeefbd20464736f6c63430008120033";
var isSuperArgs = function (xs) { return xs.length > 1; };
var Emission__factory = /** @class */ (function (_super) {
__extends(Emission__factory, _super);
function Emission__factory() {
var args = [];
for (var _i = 0; _i < arguments.length; _i++) {
args[_i] = arguments[_i];
}
var _this = this;
if (isSuperArgs(args)) {
_this = _super.apply(this, args) || this;
}
else {
_this = _super.call(this, _abi, _bytecode, args[0]) || this;
}
return _this;
}
Emission__factory.prototype.deploy = function (disable, overrides) {
return _super.prototype.deploy.call(this, disable, overrides || {});
};
Emission__factory.prototype.getDeployTransaction = function (disable, overrides) {
return _super.prototype.getDeployTransaction.call(this, disable, overrides || {});
};
Emission__factory.prototype.attach = function (address) {
return _super.prototype.attach.call(this, address);
};
Emission__factory.prototype.connect = function (signer) {
return _super.prototype.connect.call(this, signer);
};
Emission__factory.createInterface = function () {
return new ethers_1.utils.Interface(_abi);
};
Emission__factory.connect = function (address, signerOrProvider) {
return new ethers_1.Contract(address, _abi, signerOrProvider);
};
Emission__factory.bytecode = _bytecode;
Emission__factory.abi = _abi;
return Emission__factory;
}(ethers_1.ContractFactory));
exports.Emission__factory = Emission__factory;