vasku-tip3
Version:
TIP-3 Broxus contract
263 lines (262 loc) • 9.51 kB
JavaScript
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.TokenRootUpgradeable = void 0;
const vasku_1 = require("vasku");
const TokenRootUpgradeableContent_1 = __importDefault(require("./TokenRootUpgradeableContent"));
class TokenRootUpgradeable extends vasku_1.Contract {
_call;
_run;
_payload;
constructor(config = {}, options = {}) {
if (config.address === undefined)
super({
abi: TokenRootUpgradeableContent_1.default.abi,
initial: config.initial ?? {},
keys: config.keys,
tvc: TokenRootUpgradeableContent_1.default.tvc
}, options);
else
super({
address: config.address,
abi: TokenRootUpgradeableContent_1.default.abi
}, options);
this._call = new TokenRootUpgradeableCalls(this);
this._run = new TokenRootUpgradeableRuns(this);
this._payload = new TokenRootUpgradeablePayload(this);
}
async deploy(value, input, useGiver = true, timeout = 60000) {
return await this._deploy(value, input, useGiver, timeout);
}
get call() {
return this._call;
}
get run() {
return this._run;
}
get payload() {
return this._payload;
}
}
exports.TokenRootUpgradeable = TokenRootUpgradeable;
class TokenRootUpgradeableCalls {
contract;
constructor(contract) {
this.contract = contract;
}
async supportsInterface(input, keys) {
return await this.contract.callMethod('supportsInterface', input, keys);
}
async walletVersion(input, keys) {
return await this.contract.callMethod('walletVersion', input, keys);
}
async platformCode(input, keys) {
return await this.contract.callMethod('platformCode', input, keys);
}
async requestUpgradeWallet(input, keys) {
return await this.contract.callMethod('requestUpgradeWallet', input, keys);
}
async setWalletCode(input, keys) {
return await this.contract.callMethod('setWalletCode', input, keys);
}
async upgrade(input, keys) {
return await this.contract.callMethod('upgrade', input, keys);
}
async disableMint(input, keys) {
return await this.contract.callMethod('disableMint', input, keys);
}
async mintDisabled(input, keys) {
return await this.contract.callMethod('mintDisabled', input, keys);
}
async burnTokens(input, keys) {
return await this.contract.callMethod('burnTokens', input, keys);
}
async disableBurnByRoot(input, keys) {
return await this.contract.callMethod('disableBurnByRoot', input, keys);
}
async burnByRootDisabled(input, keys) {
return await this.contract.callMethod('burnByRootDisabled', input, keys);
}
async burnPaused(input, keys) {
return await this.contract.callMethod('burnPaused', input, keys);
}
async setBurnPaused(input, keys) {
return await this.contract.callMethod('setBurnPaused', input, keys);
}
async transferOwnership(input, keys) {
return await this.contract.callMethod('transferOwnership', input, keys);
}
async name(input, keys) {
return await this.contract.callMethod('name', input, keys);
}
async symbol(input, keys) {
return await this.contract.callMethod('symbol', input, keys);
}
async decimals(input, keys) {
return await this.contract.callMethod('decimals', input, keys);
}
async totalSupply(input, keys) {
return await this.contract.callMethod('totalSupply', input, keys);
}
async walletCode(input, keys) {
return await this.contract.callMethod('walletCode', input, keys);
}
async rootOwner(input, keys) {
return await this.contract.callMethod('rootOwner', input, keys);
}
async walletOf(input, keys) {
return await this.contract.callMethod('walletOf', input, keys);
}
async deployWallet(input, keys) {
return await this.contract.callMethod('deployWallet', input, keys);
}
async mint(input, keys) {
return await this.contract.callMethod('mint', input, keys);
}
async acceptBurn(input, keys) {
return await this.contract.callMethod('acceptBurn', input, keys);
}
async sendSurplusGas(input, keys) {
return await this.contract.callMethod('sendSurplusGas', input, keys);
}
}
class TokenRootUpgradeableRuns {
contract;
constructor(contract) {
this.contract = contract;
}
async supportsInterface(input) {
return (await this.contract.runMethod('supportsInterface', input)).value;
}
async walletVersion(input) {
return (await this.contract.runMethod('walletVersion', input)).value;
}
async platformCode(input) {
return (await this.contract.runMethod('platformCode', input)).value;
}
async disableMint(input) {
return (await this.contract.runMethod('disableMint', input)).value;
}
async mintDisabled(input) {
return (await this.contract.runMethod('mintDisabled', input)).value;
}
async disableBurnByRoot(input) {
return (await this.contract.runMethod('disableBurnByRoot', input)).value;
}
async burnByRootDisabled(input) {
return (await this.contract.runMethod('burnByRootDisabled', input)).value;
}
async burnPaused(input) {
return (await this.contract.runMethod('burnPaused', input)).value;
}
async setBurnPaused(input) {
return (await this.contract.runMethod('setBurnPaused', input)).value;
}
async name(input) {
return (await this.contract.runMethod('name', input)).value;
}
async symbol(input) {
return (await this.contract.runMethod('symbol', input)).value;
}
async decimals(input) {
return (await this.contract.runMethod('decimals', input)).value;
}
async totalSupply(input) {
return (await this.contract.runMethod('totalSupply', input)).value;
}
async walletCode(input) {
return (await this.contract.runMethod('walletCode', input)).value;
}
async rootOwner(input) {
return (await this.contract.runMethod('rootOwner', input)).value;
}
async walletOf(input) {
return (await this.contract.runMethod('walletOf', input)).value;
}
async deployWallet(input) {
return (await this.contract.runMethod('deployWallet', input)).value;
}
}
class TokenRootUpgradeablePayload {
contract;
constructor(contract) {
this.contract = contract;
}
async supportsInterface(input) {
return await this.contract.createPayload('supportsInterface', input);
}
async walletVersion(input) {
return await this.contract.createPayload('walletVersion', input);
}
async platformCode(input) {
return await this.contract.createPayload('platformCode', input);
}
async requestUpgradeWallet(input) {
return await this.contract.createPayload('requestUpgradeWallet', input);
}
async setWalletCode(input) {
return await this.contract.createPayload('setWalletCode', input);
}
async upgrade(input) {
return await this.contract.createPayload('upgrade', input);
}
async disableMint(input) {
return await this.contract.createPayload('disableMint', input);
}
async mintDisabled(input) {
return await this.contract.createPayload('mintDisabled', input);
}
async burnTokens(input) {
return await this.contract.createPayload('burnTokens', input);
}
async disableBurnByRoot(input) {
return await this.contract.createPayload('disableBurnByRoot', input);
}
async burnByRootDisabled(input) {
return await this.contract.createPayload('burnByRootDisabled', input);
}
async burnPaused(input) {
return await this.contract.createPayload('burnPaused', input);
}
async setBurnPaused(input) {
return await this.contract.createPayload('setBurnPaused', input);
}
async transferOwnership(input) {
return await this.contract.createPayload('transferOwnership', input);
}
async name(input) {
return await this.contract.createPayload('name', input);
}
async symbol(input) {
return await this.contract.createPayload('symbol', input);
}
async decimals(input) {
return await this.contract.createPayload('decimals', input);
}
async totalSupply(input) {
return await this.contract.createPayload('totalSupply', input);
}
async walletCode(input) {
return await this.contract.createPayload('walletCode', input);
}
async rootOwner(input) {
return await this.contract.createPayload('rootOwner', input);
}
async walletOf(input) {
return await this.contract.createPayload('walletOf', input);
}
async deployWallet(input) {
return await this.contract.createPayload('deployWallet', input);
}
async mint(input) {
return await this.contract.createPayload('mint', input);
}
async acceptBurn(input) {
return await this.contract.createPayload('acceptBurn', input);
}
async sendSurplusGas(input) {
return await this.contract.createPayload('sendSurplusGas', input);
}
}