UNPKG

@provenanceio/wallet-utils

Version:

Typescript Utilities for Provenance Blockchain Wallet

666 lines (550 loc) 21.9 kB
"use strict"; // source: cosmos/upgrade/v1beta1/tx.proto /** * @fileoverview * @enhanceable * @suppress {missingRequire} reports error on implicit type usages. * @suppress {messageConventions} JS Compiler reports an error if a variable or * field starts with 'MSG_' and isn't a translatable message. * @public */ // GENERATED CODE -- DO NOT EDIT! /* eslint-disable */ // @ts-nocheck var jspb = require('google-protobuf'); var goog = jspb; var global = function () { return this || window || global || self || Function('return this')(); }.call(null); var gogoproto_gogo_pb = require('../../../gogoproto/gogo_pb.js'); goog.object.extend(proto, gogoproto_gogo_pb); var cosmos_proto_cosmos_pb = require('../../../cosmos_proto/cosmos_pb.js'); goog.object.extend(proto, cosmos_proto_cosmos_pb); var cosmos_upgrade_v1beta1_upgrade_pb = require('../../../cosmos/upgrade/v1beta1/upgrade_pb.js'); goog.object.extend(proto, cosmos_upgrade_v1beta1_upgrade_pb); var cosmos_msg_v1_msg_pb = require('../../../cosmos/msg/v1/msg_pb.js'); goog.object.extend(proto, cosmos_msg_v1_msg_pb); goog.exportSymbol('proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade', null, global); goog.exportSymbol('proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse', null, global); goog.exportSymbol('proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade', null, global); goog.exportSymbol('proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse', null, global); /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.displayName = 'proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade'; } /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.displayName = 'proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse'; } /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.displayName = 'proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade'; } /** * Generated by JsPbCodeGenerator. * @param {Array=} opt_data Optional initial data array, typically from a * server response, or constructed directly in Javascript. The array is used * in place and becomes part of the constructed object. It is not cloned. * If no data is provided, the constructed object will be empty, but still * valid. * @extends {jspb.Message} * @constructor */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.displayName = 'proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse'; } if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.toObject = function (opt_includeInstance) { return proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.toObject = function (includeInstance, msg) { var f, obj = { authority: jspb.Message.getFieldWithDefault(msg, 1, ""), plan: (f = msg.getPlan()) && cosmos_upgrade_v1beta1_upgrade_pb.Plan.toObject(includeInstance, f) }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade(); return proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.deserializeBinaryFromReader = function (msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {string} */ reader.readString(); msg.setAuthority(value); break; case 2: var value = new cosmos_upgrade_v1beta1_upgrade_pb.Plan(); reader.readMessage(value, cosmos_upgrade_v1beta1_upgrade_pb.Plan.deserializeBinaryFromReader); msg.setPlan(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.serializeBinaryToWriter = function (message, writer) { var f = undefined; f = message.getAuthority(); if (f.length > 0) { writer.writeString(1, f); } f = message.getPlan(); if (f != null) { writer.writeMessage(2, f, cosmos_upgrade_v1beta1_upgrade_pb.Plan.serializeBinaryToWriter); } }; /** * optional string authority = 1; * @return {string} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.getAuthority = function () { return ( /** @type {string} */ jspb.Message.getFieldWithDefault(this, 1, "") ); }; /** * @param {string} value * @return {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} returns this */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.setAuthority = function (value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional Plan plan = 2; * @return {?proto.cosmos.upgrade.v1beta1.Plan} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.getPlan = function () { return ( /** @type{?proto.cosmos.upgrade.v1beta1.Plan} */ jspb.Message.getWrapperField(this, cosmos_upgrade_v1beta1_upgrade_pb.Plan, 2) ); }; /** * @param {?proto.cosmos.upgrade.v1beta1.Plan|undefined} value * @return {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} returns this */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.setPlan = function (value) { return jspb.Message.setWrapperField(this, 2, value); }; /** * Clears the message field making it undefined. * @return {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade} returns this */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.clearPlan = function () { return this.setPlan(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgrade.prototype.hasPlan = function () { return jspb.Message.getField(this, 2) != null; }; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.prototype.toObject = function (opt_includeInstance) { return proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.toObject = function (includeInstance, msg) { var f, obj = {}; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse(); return proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.deserializeBinaryFromReader = function (msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgSoftwareUpgradeResponse.serializeBinaryToWriter = function (message, writer) { var f = undefined; }; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.prototype.toObject = function (opt_includeInstance) { return proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.toObject = function (includeInstance, msg) { var f, obj = { authority: jspb.Message.getFieldWithDefault(msg, 1, "") }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade(); return proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.deserializeBinaryFromReader = function (msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {string} */ reader.readString(); msg.setAuthority(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.serializeBinaryToWriter = function (message, writer) { var f = undefined; f = message.getAuthority(); if (f.length > 0) { writer.writeString(1, f); } }; /** * optional string authority = 1; * @return {string} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.prototype.getAuthority = function () { return ( /** @type {string} */ jspb.Message.getFieldWithDefault(this, 1, "") ); }; /** * @param {string} value * @return {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade} returns this */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgrade.prototype.setAuthority = function (value) { return jspb.Message.setProto3StringField(this, 1, value); }; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.prototype.toObject = function (opt_includeInstance) { return proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.toObject(opt_includeInstance, this); }; /** * Static version of the {@see toObject} method. * @param {boolean|undefined} includeInstance Deprecated. Whether to include * the JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @param {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.toObject = function (includeInstance, msg) { var f, obj = {}; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse(); return proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.deserializeBinaryFromReader = function (msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.cosmos.upgrade.v1beta1.MsgCancelUpgradeResponse.serializeBinaryToWriter = function (message, writer) { var f = undefined; }; goog.object.extend(exports, proto.cosmos.upgrade.v1beta1);