minterjs-tx
Version:
A simple module for creating, manipulating and signing Minter transactions
238 lines (236 loc) • 5.11 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = void 0;
var _defineProperties2 = _interopRequireDefault(require("../define-properties.js"));
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
var TxDataVoteCommission = /*#__PURE__*/_createClass(function TxDataVoteCommission(data, options) {
_classCallCheck(this, TxDataVoteCommission);
// Define Properties
var fields = [{
name: 'publicKey',
length: 32
}, {
name: 'height',
length: 32,
allowLess: true
}, {
name: 'coin',
length: 4,
allowLess: true
}, {
name: 'payloadByte',
length: 32,
allowLess: true
}, {
name: 'send',
length: 32,
allowLess: true
}, {
name: 'buyBancor',
length: 32,
allowLess: true
}, {
name: 'sellBancor',
length: 32,
allowLess: true
}, {
name: 'sellAllBancor',
length: 32,
allowLess: true
}, {
name: 'buyPoolBase',
length: 32,
allowLess: true
}, {
name: 'buyPoolDelta',
length: 32,
allowLess: true
}, {
name: 'sellPoolBase',
length: 32,
allowLess: true
}, {
name: 'sellPoolDelta',
length: 32,
allowLess: true
}, {
name: 'sellAllPoolBase',
length: 32,
allowLess: true
}, {
name: 'sellAllPoolDelta',
length: 32,
allowLess: true
}, {
name: 'createTicker3',
length: 32,
allowLess: true
}, {
name: 'createTicker4',
length: 32,
allowLess: true
}, {
name: 'createTicker5',
length: 32,
allowLess: true
}, {
name: 'createTicker6',
length: 32,
allowLess: true
}, {
name: 'createTicker7to10',
length: 32,
allowLess: true
}, {
name: 'createCoin',
length: 32,
allowLess: true
}, {
name: 'createToken',
length: 32,
allowLess: true
}, {
name: 'recreateCoin',
length: 32,
allowLess: true
}, {
name: 'recreateToken',
length: 32,
allowLess: true
}, {
name: 'declareCandidacy',
length: 32,
allowLess: true
}, {
name: 'delegate',
length: 32,
allowLess: true
}, {
name: 'unbond',
length: 32,
allowLess: true
}, {
name: 'redeemCheck',
length: 32,
allowLess: true
}, {
name: 'setCandidateOn',
length: 32,
allowLess: true
}, {
name: 'setCandidateOff',
length: 32,
allowLess: true
}, {
name: 'createMultisig',
length: 32,
allowLess: true
}, {
name: 'multisendBase',
length: 32,
allowLess: true
}, {
name: 'multisendDelta',
length: 32,
allowLess: true
}, {
name: 'editCandidate',
length: 32,
allowLess: true
}, {
name: 'setHaltBlock',
length: 32,
allowLess: true
}, {
name: 'editTickerOwner',
length: 32,
allowLess: true
}, {
name: 'editMultisig',
length: 32,
allowLess: true
},
/*
{
name: 'priceVote',
length: 32,
allowLess: true,
},
*/
{
name: 'editCandidatePublicKey',
length: 32,
allowLess: true
}, {
name: 'createSwapPool',
length: 32,
allowLess: true
}, {
name: 'addLiquidity',
length: 32,
allowLess: true
}, {
name: 'removeLiquidity',
length: 32,
allowLess: true
}, {
name: 'editCandidateCommission',
length: 32,
allowLess: true
}, {
name: 'mintToken',
length: 32,
allowLess: true
}, {
name: 'burnToken',
length: 32,
allowLess: true
}, {
name: 'voteCommission',
length: 32,
allowLess: true
}, {
name: 'voteUpdate',
length: 32,
allowLess: true
}, {
name: 'failedTx',
length: 32,
allowLess: true
}, {
name: 'addLimitOrder',
length: 32,
allowLess: true
}, {
name: 'removeLimitOrder',
length: 32,
allowLess: true
}, {
name: 'moveStake',
length: 32,
allowLess: true
}, {
name: 'lockStake',
length: 32,
allowLess: true
}, {
name: 'lock',
length: 32,
allowLess: true
}];
/**
* Returns the rlp encoding of the transaction
* @method serialize
* @return {Buffer}
* @memberof Transaction
* @name serialize
*/
// attached serialize
(0, _defineProperties2["default"])(this, fields, data, options);
});
exports["default"] = TxDataVoteCommission;