@routerprotocol/chain-api
Version:
Router Chain API Query client with generated gRPC bindings.
1,366 lines (1,197 loc) • 73.3 kB
JavaScript
// source: cosmos/distribution/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')();
var gogoproto_gogo_pb = require('../../../gogoproto/gogo_pb.js');
goog.object.extend(proto, gogoproto_gogo_pb);
var cosmos_base_v1beta1_coin_pb = require('../../../cosmos/base/v1beta1/coin_pb.js');
goog.object.extend(proto, cosmos_base_v1beta1_coin_pb);
var cosmos_proto_cosmos_pb = require('../../../cosmos_proto/cosmos_pb.js');
goog.object.extend(proto, cosmos_proto_cosmos_pb);
var cosmos_msg_v1_msg_pb = require('../../../cosmos/msg/v1/msg_pb.js');
goog.object.extend(proto, cosmos_msg_v1_msg_pb);
var amino_amino_pb = require('../../../amino/amino_pb.js');
goog.object.extend(proto, amino_amino_pb);
var cosmos_distribution_v1beta1_distribution_pb = require('../../../cosmos/distribution/v1beta1/distribution_pb.js');
goog.object.extend(proto, cosmos_distribution_v1beta1_distribution_pb);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpend', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpendResponse', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgFundCommunityPool', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgFundCommunityPoolResponse', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgUpdateParams', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgUpdateParamsResponse', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission', null, global);
goog.exportSymbol('proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse', 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.distribution.v1beta1.MsgSetWithdrawAddress = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.displayName = 'proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress';
}
/**
* 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.distribution.v1beta1.MsgSetWithdrawAddressResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.displayName = 'proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse';
}
/**
* 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.distribution.v1beta1.MsgWithdrawDelegatorReward = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.displayName = 'proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward';
}
/**
* 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.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.repeatedFields_, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.displayName = 'proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse';
}
/**
* 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.distribution.v1beta1.MsgWithdrawValidatorCommission = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.displayName = 'proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission';
}
/**
* 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.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.repeatedFields_, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.displayName = 'proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse';
}
/**
* 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.distribution.v1beta1.MsgFundCommunityPool = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.repeatedFields_, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgFundCommunityPool, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.displayName = 'proto.cosmos.distribution.v1beta1.MsgFundCommunityPool';
}
/**
* 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.distribution.v1beta1.MsgFundCommunityPoolResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgFundCommunityPoolResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPoolResponse.displayName = 'proto.cosmos.distribution.v1beta1.MsgFundCommunityPoolResponse';
}
/**
* 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.distribution.v1beta1.MsgUpdateParams = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgUpdateParams, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgUpdateParams.displayName = 'proto.cosmos.distribution.v1beta1.MsgUpdateParams';
}
/**
* 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.distribution.v1beta1.MsgUpdateParamsResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgUpdateParamsResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgUpdateParamsResponse.displayName = 'proto.cosmos.distribution.v1beta1.MsgUpdateParamsResponse';
}
/**
* 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.distribution.v1beta1.MsgCommunityPoolSpend = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpend.repeatedFields_, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpend, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpend.displayName = 'proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpend';
}
/**
* 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.distribution.v1beta1.MsgCommunityPoolSpendResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpendResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpendResponse.displayName = 'proto.cosmos.distribution.v1beta1.MsgCommunityPoolSpendResponse';
}
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.distribution.v1beta1.MsgSetWithdrawAddress.prototype.toObject = function(opt_includeInstance) {
return proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.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.distribution.v1beta1.MsgSetWithdrawAddress} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.toObject = function(includeInstance, msg) {
var f, obj = {
delegatorAddress: jspb.Message.getFieldWithDefault(msg, 1, ""),
withdrawAddress: jspb.Message.getFieldWithDefault(msg, 2, "")
};
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.distribution.v1beta1.MsgSetWithdrawAddress}
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress;
return proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress}
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.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.setDelegatorAddress(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setWithdrawAddress(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.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.distribution.v1beta1.MsgSetWithdrawAddress} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getDelegatorAddress();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getWithdrawAddress();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string delegator_address = 1;
* @return {string}
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.prototype.getDelegatorAddress = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress} returns this
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.prototype.setDelegatorAddress = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string withdraw_address = 2;
* @return {string}
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.prototype.getWithdrawAddress = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress} returns this
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddress.prototype.setWithdrawAddress = function(value) {
return jspb.Message.setProto3StringField(this, 2, 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.distribution.v1beta1.MsgSetWithdrawAddressResponse.prototype.toObject = function(opt_includeInstance) {
return proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.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.distribution.v1beta1.MsgSetWithdrawAddressResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.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.distribution.v1beta1.MsgSetWithdrawAddressResponse}
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse;
return proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse}
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.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.distribution.v1beta1.MsgSetWithdrawAddressResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.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.distribution.v1beta1.MsgSetWithdrawAddressResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgSetWithdrawAddressResponse.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.distribution.v1beta1.MsgWithdrawDelegatorReward.prototype.toObject = function(opt_includeInstance) {
return proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.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.distribution.v1beta1.MsgWithdrawDelegatorReward} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.toObject = function(includeInstance, msg) {
var f, obj = {
delegatorAddress: jspb.Message.getFieldWithDefault(msg, 1, ""),
validatorAddress: jspb.Message.getFieldWithDefault(msg, 2, "")
};
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.distribution.v1beta1.MsgWithdrawDelegatorReward}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward;
return proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.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.setDelegatorAddress(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setValidatorAddress(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.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.distribution.v1beta1.MsgWithdrawDelegatorReward} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getDelegatorAddress();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getValidatorAddress();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string delegator_address = 1;
* @return {string}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.prototype.getDelegatorAddress = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward} returns this
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.prototype.setDelegatorAddress = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string validator_address = 2;
* @return {string}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.prototype.getValidatorAddress = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward} returns this
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorReward.prototype.setValidatorAddress = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
/**
* List of repeated fields within this message type.
* @private {!Array<number>}
* @const
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.repeatedFields_ = [1];
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.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.prototype.toObject = function(opt_includeInstance) {
return proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.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.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.toObject = function(includeInstance, msg) {
var f, obj = {
amountList: jspb.Message.toObjectList(msg.getAmountList(),
cosmos_base_v1beta1_coin_pb.Coin.toObject, includeInstance)
};
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.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse;
return proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new cosmos_base_v1beta1_coin_pb.Coin;
reader.readMessage(value,cosmos_base_v1beta1_coin_pb.Coin.deserializeBinaryFromReader);
msg.addAmount(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.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.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getAmountList();
if (f.length > 0) {
writer.writeRepeatedMessage(
1,
f,
cosmos_base_v1beta1_coin_pb.Coin.serializeBinaryToWriter
);
}
};
/**
* repeated cosmos.base.v1beta1.Coin amount = 1;
* @return {!Array<!proto.cosmos.base.v1beta1.Coin>}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.prototype.getAmountList = function() {
return /** @type{!Array<!proto.cosmos.base.v1beta1.Coin>} */ (
jspb.Message.getRepeatedWrapperField(this, cosmos_base_v1beta1_coin_pb.Coin, 1));
};
/**
* @param {!Array<!proto.cosmos.base.v1beta1.Coin>} value
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse} returns this
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.prototype.setAmountList = function(value) {
return jspb.Message.setRepeatedWrapperField(this, 1, value);
};
/**
* @param {!proto.cosmos.base.v1beta1.Coin=} opt_value
* @param {number=} opt_index
* @return {!proto.cosmos.base.v1beta1.Coin}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.prototype.addAmount = function(opt_value, opt_index) {
return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.cosmos.base.v1beta1.Coin, opt_index);
};
/**
* Clears the list making it empty but non-null.
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse} returns this
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawDelegatorRewardResponse.prototype.clearAmountList = function() {
return this.setAmountList([]);
};
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.distribution.v1beta1.MsgWithdrawValidatorCommission.prototype.toObject = function(opt_includeInstance) {
return proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.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.distribution.v1beta1.MsgWithdrawValidatorCommission} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.toObject = function(includeInstance, msg) {
var f, obj = {
validatorAddress: 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.distribution.v1beta1.MsgWithdrawValidatorCommission}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission;
return proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.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.setValidatorAddress(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.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.distribution.v1beta1.MsgWithdrawValidatorCommission} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getValidatorAddress();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string validator_address = 1;
* @return {string}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.prototype.getValidatorAddress = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission} returns this
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommission.prototype.setValidatorAddress = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* List of repeated fields within this message type.
* @private {!Array<number>}
* @const
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.repeatedFields_ = [1];
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.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.prototype.toObject = function(opt_includeInstance) {
return proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.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.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.toObject = function(includeInstance, msg) {
var f, obj = {
amountList: jspb.Message.toObjectList(msg.getAmountList(),
cosmos_base_v1beta1_coin_pb.Coin.toObject, includeInstance)
};
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.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse;
return proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new cosmos_base_v1beta1_coin_pb.Coin;
reader.readMessage(value,cosmos_base_v1beta1_coin_pb.Coin.deserializeBinaryFromReader);
msg.addAmount(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.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.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getAmountList();
if (f.length > 0) {
writer.writeRepeatedMessage(
1,
f,
cosmos_base_v1beta1_coin_pb.Coin.serializeBinaryToWriter
);
}
};
/**
* repeated cosmos.base.v1beta1.Coin amount = 1;
* @return {!Array<!proto.cosmos.base.v1beta1.Coin>}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.prototype.getAmountList = function() {
return /** @type{!Array<!proto.cosmos.base.v1beta1.Coin>} */ (
jspb.Message.getRepeatedWrapperField(this, cosmos_base_v1beta1_coin_pb.Coin, 1));
};
/**
* @param {!Array<!proto.cosmos.base.v1beta1.Coin>} value
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse} returns this
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.prototype.setAmountList = function(value) {
return jspb.Message.setRepeatedWrapperField(this, 1, value);
};
/**
* @param {!proto.cosmos.base.v1beta1.Coin=} opt_value
* @param {number=} opt_index
* @return {!proto.cosmos.base.v1beta1.Coin}
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.prototype.addAmount = function(opt_value, opt_index) {
return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.cosmos.base.v1beta1.Coin, opt_index);
};
/**
* Clears the list making it empty but non-null.
* @return {!proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse} returns this
*/
proto.cosmos.distribution.v1beta1.MsgWithdrawValidatorCommissionResponse.prototype.clearAmountList = function() {
return this.setAmountList([]);
};
/**
* List of repeated fields within this message type.
* @private {!Array<number>}
* @const
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.repeatedFields_ = [1];
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.distribution.v1beta1.MsgFundCommunityPool.prototype.toObject = function(opt_includeInstance) {
return proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.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.distribution.v1beta1.MsgFundCommunityPool} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.toObject = function(includeInstance, msg) {
var f, obj = {
amountList: jspb.Message.toObjectList(msg.getAmountList(),
cosmos_base_v1beta1_coin_pb.Coin.toObject, includeInstance),
depositor: jspb.Message.getFieldWithDefault(msg, 2, "")
};
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.distribution.v1beta1.MsgFundCommunityPool}
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.cosmos.distribution.v1beta1.MsgFundCommunityPool;
return proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.cosmos.distribution.v1beta1.MsgFundCommunityPool} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.cosmos.distribution.v1beta1.MsgFundCommunityPool}
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new cosmos_base_v1beta1_coin_pb.Coin;
reader.readMessage(value,cosmos_base_v1beta1_coin_pb.Coin.deserializeBinaryFromReader);
msg.addAmount(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setDepositor(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.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.distribution.v1beta1.MsgFundCommunityPool} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getAmountList();
if (f.length > 0) {
writer.writeRepeatedMessage(
1,
f,
cosmos_base_v1beta1_coin_pb.Coin.serializeBinaryToWriter
);
}
f = message.getDepositor();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* repeated cosmos.base.v1beta1.Coin amount = 1;
* @return {!Array<!proto.cosmos.base.v1beta1.Coin>}
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.prototype.getAmountList = function() {
return /** @type{!Array<!proto.cosmos.base.v1beta1.Coin>} */ (
jspb.Message.getRepeatedWrapperField(this, cosmos_base_v1beta1_coin_pb.Coin, 1));
};
/**
* @param {!Array<!proto.cosmos.base.v1beta1.Coin>} value
* @return {!proto.cosmos.distribution.v1beta1.MsgFundCommunityPool} returns this
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.prototype.setAmountList = function(value) {
return jspb.Message.setRepeatedWrapperField(this, 1, value);
};
/**
* @param {!proto.cosmos.base.v1beta1.Coin=} opt_value
* @param {number=} opt_index
* @return {!proto.cosmos.base.v1beta1.Coin}
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.prototype.addAmount = function(opt_value, opt_index) {
return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.cosmos.base.v1beta1.Coin, opt_index);
};
/**
* Clears the list making it empty but non-null.
* @return {!proto.cosmos.distribution.v1beta1.MsgFundCommunityPool} returns this
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.prototype.clearAmountList = function() {
return this.setAmountList([]);
};
/**
* optional string depositor = 2;
* @return {string}
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.prototype.getDepositor = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.cosmos.distribution.v1beta1.MsgFundCommunityPool} returns this
*/
proto.cosmos.distribution.v1beta1.MsgFundCommunityPool.prototype.setDepositor = function(value) {
return jspb.Message.setProto3StringField(this, 2, 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. wheth