UNPKG

@provenanceio/wallet-utils

Version:

Typescript Utilities for Provenance Blockchain Wallet

1,490 lines (1,227 loc) 87.7 kB
"use strict"; // source: provenance/attribute/v1/query.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 cosmos_base_query_v1beta1_pagination_pb = require('../../../cosmos/base/query/v1beta1/pagination_pb.js'); goog.object.extend(proto, cosmos_base_query_v1beta1_pagination_pb); var gogoproto_gogo_pb = require('../../../gogoproto/gogo_pb.js'); goog.object.extend(proto, gogoproto_gogo_pb); var google_api_annotations_pb = require('../../../google/api/annotations_pb.js'); goog.object.extend(proto, google_api_annotations_pb); var provenance_attribute_v1_attribute_pb = require('../../../provenance/attribute/v1/attribute_pb.js'); goog.object.extend(proto, provenance_attribute_v1_attribute_pb); goog.exportSymbol('proto.provenance.attribute.v1.QueryAccountDataRequest', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryAccountDataResponse', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryAttributeAccountsRequest', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryAttributeAccountsResponse', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryAttributeRequest', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryAttributeResponse', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryAttributesRequest', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryAttributesResponse', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryParamsRequest', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryParamsResponse', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryScanRequest', null, global); goog.exportSymbol('proto.provenance.attribute.v1.QueryScanResponse', 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.provenance.attribute.v1.QueryParamsRequest = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryParamsRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryParamsRequest.displayName = 'proto.provenance.attribute.v1.QueryParamsRequest'; } /** * 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.provenance.attribute.v1.QueryParamsResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryParamsResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryParamsResponse.displayName = 'proto.provenance.attribute.v1.QueryParamsResponse'; } /** * 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.provenance.attribute.v1.QueryAttributeRequest = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAttributeRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAttributeRequest.displayName = 'proto.provenance.attribute.v1.QueryAttributeRequest'; } /** * 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.provenance.attribute.v1.QueryAttributeResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.provenance.attribute.v1.QueryAttributeResponse.repeatedFields_, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAttributeResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAttributeResponse.displayName = 'proto.provenance.attribute.v1.QueryAttributeResponse'; } /** * 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.provenance.attribute.v1.QueryAttributesRequest = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAttributesRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAttributesRequest.displayName = 'proto.provenance.attribute.v1.QueryAttributesRequest'; } /** * 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.provenance.attribute.v1.QueryAttributesResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.provenance.attribute.v1.QueryAttributesResponse.repeatedFields_, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAttributesResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAttributesResponse.displayName = 'proto.provenance.attribute.v1.QueryAttributesResponse'; } /** * 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.provenance.attribute.v1.QueryScanRequest = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryScanRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryScanRequest.displayName = 'proto.provenance.attribute.v1.QueryScanRequest'; } /** * 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.provenance.attribute.v1.QueryScanResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.provenance.attribute.v1.QueryScanResponse.repeatedFields_, null); }; goog.inherits(proto.provenance.attribute.v1.QueryScanResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryScanResponse.displayName = 'proto.provenance.attribute.v1.QueryScanResponse'; } /** * 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.provenance.attribute.v1.QueryAttributeAccountsRequest = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAttributeAccountsRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAttributeAccountsRequest.displayName = 'proto.provenance.attribute.v1.QueryAttributeAccountsRequest'; } /** * 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.provenance.attribute.v1.QueryAttributeAccountsResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.provenance.attribute.v1.QueryAttributeAccountsResponse.repeatedFields_, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAttributeAccountsResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAttributeAccountsResponse.displayName = 'proto.provenance.attribute.v1.QueryAttributeAccountsResponse'; } /** * 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.provenance.attribute.v1.QueryAccountDataRequest = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAccountDataRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAccountDataRequest.displayName = 'proto.provenance.attribute.v1.QueryAccountDataRequest'; } /** * 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.provenance.attribute.v1.QueryAccountDataResponse = function (opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.provenance.attribute.v1.QueryAccountDataResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.provenance.attribute.v1.QueryAccountDataResponse.displayName = 'proto.provenance.attribute.v1.QueryAccountDataResponse'; } 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.provenance.attribute.v1.QueryParamsRequest.prototype.toObject = function (opt_includeInstance) { return proto.provenance.attribute.v1.QueryParamsRequest.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.provenance.attribute.v1.QueryParamsRequest} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryParamsRequest.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.provenance.attribute.v1.QueryParamsRequest} */ proto.provenance.attribute.v1.QueryParamsRequest.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.provenance.attribute.v1.QueryParamsRequest(); return proto.provenance.attribute.v1.QueryParamsRequest.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.provenance.attribute.v1.QueryParamsRequest} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.provenance.attribute.v1.QueryParamsRequest} */ proto.provenance.attribute.v1.QueryParamsRequest.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.provenance.attribute.v1.QueryParamsRequest.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.provenance.attribute.v1.QueryParamsRequest.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.provenance.attribute.v1.QueryParamsRequest} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryParamsRequest.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.provenance.attribute.v1.QueryParamsResponse.prototype.toObject = function (opt_includeInstance) { return proto.provenance.attribute.v1.QueryParamsResponse.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.provenance.attribute.v1.QueryParamsResponse} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryParamsResponse.toObject = function (includeInstance, msg) { var f, obj = { params: (f = msg.getParams()) && provenance_attribute_v1_attribute_pb.Params.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.provenance.attribute.v1.QueryParamsResponse} */ proto.provenance.attribute.v1.QueryParamsResponse.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.provenance.attribute.v1.QueryParamsResponse(); return proto.provenance.attribute.v1.QueryParamsResponse.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.provenance.attribute.v1.QueryParamsResponse} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.provenance.attribute.v1.QueryParamsResponse} */ proto.provenance.attribute.v1.QueryParamsResponse.deserializeBinaryFromReader = function (msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = new provenance_attribute_v1_attribute_pb.Params(); reader.readMessage(value, provenance_attribute_v1_attribute_pb.Params.deserializeBinaryFromReader); msg.setParams(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.provenance.attribute.v1.QueryParamsResponse.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.provenance.attribute.v1.QueryParamsResponse.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.provenance.attribute.v1.QueryParamsResponse} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryParamsResponse.serializeBinaryToWriter = function (message, writer) { var f = undefined; f = message.getParams(); if (f != null) { writer.writeMessage(1, f, provenance_attribute_v1_attribute_pb.Params.serializeBinaryToWriter); } }; /** * optional Params params = 1; * @return {?proto.provenance.attribute.v1.Params} */ proto.provenance.attribute.v1.QueryParamsResponse.prototype.getParams = function () { return ( /** @type{?proto.provenance.attribute.v1.Params} */ jspb.Message.getWrapperField(this, provenance_attribute_v1_attribute_pb.Params, 1) ); }; /** * @param {?proto.provenance.attribute.v1.Params|undefined} value * @return {!proto.provenance.attribute.v1.QueryParamsResponse} returns this */ proto.provenance.attribute.v1.QueryParamsResponse.prototype.setParams = function (value) { return jspb.Message.setWrapperField(this, 1, value); }; /** * Clears the message field making it undefined. * @return {!proto.provenance.attribute.v1.QueryParamsResponse} returns this */ proto.provenance.attribute.v1.QueryParamsResponse.prototype.clearParams = function () { return this.setParams(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.provenance.attribute.v1.QueryParamsResponse.prototype.hasParams = function () { return jspb.Message.getField(this, 1) != 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.provenance.attribute.v1.QueryAttributeRequest.prototype.toObject = function (opt_includeInstance) { return proto.provenance.attribute.v1.QueryAttributeRequest.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.provenance.attribute.v1.QueryAttributeRequest} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributeRequest.toObject = function (includeInstance, msg) { var f, obj = { account: jspb.Message.getFieldWithDefault(msg, 1, ""), name: jspb.Message.getFieldWithDefault(msg, 2, ""), pagination: (f = msg.getPagination()) && cosmos_base_query_v1beta1_pagination_pb.PageRequest.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.provenance.attribute.v1.QueryAttributeRequest} */ proto.provenance.attribute.v1.QueryAttributeRequest.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.provenance.attribute.v1.QueryAttributeRequest(); return proto.provenance.attribute.v1.QueryAttributeRequest.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.provenance.attribute.v1.QueryAttributeRequest} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.provenance.attribute.v1.QueryAttributeRequest} */ proto.provenance.attribute.v1.QueryAttributeRequest.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.setAccount(value); break; case 2: var value = /** @type {string} */ reader.readString(); msg.setName(value); break; case 3: var value = new cosmos_base_query_v1beta1_pagination_pb.PageRequest(); reader.readMessage(value, cosmos_base_query_v1beta1_pagination_pb.PageRequest.deserializeBinaryFromReader); msg.setPagination(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.provenance.attribute.v1.QueryAttributeRequest.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.provenance.attribute.v1.QueryAttributeRequest} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributeRequest.serializeBinaryToWriter = function (message, writer) { var f = undefined; f = message.getAccount(); if (f.length > 0) { writer.writeString(1, f); } f = message.getName(); if (f.length > 0) { writer.writeString(2, f); } f = message.getPagination(); if (f != null) { writer.writeMessage(3, f, cosmos_base_query_v1beta1_pagination_pb.PageRequest.serializeBinaryToWriter); } }; /** * optional string account = 1; * @return {string} */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.getAccount = function () { return ( /** @type {string} */ jspb.Message.getFieldWithDefault(this, 1, "") ); }; /** * @param {string} value * @return {!proto.provenance.attribute.v1.QueryAttributeRequest} returns this */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.setAccount = function (value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional string name = 2; * @return {string} */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.getName = function () { return ( /** @type {string} */ jspb.Message.getFieldWithDefault(this, 2, "") ); }; /** * @param {string} value * @return {!proto.provenance.attribute.v1.QueryAttributeRequest} returns this */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.setName = function (value) { return jspb.Message.setProto3StringField(this, 2, value); }; /** * optional cosmos.base.query.v1beta1.PageRequest pagination = 3; * @return {?proto.cosmos.base.query.v1beta1.PageRequest} */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.getPagination = function () { return ( /** @type{?proto.cosmos.base.query.v1beta1.PageRequest} */ jspb.Message.getWrapperField(this, cosmos_base_query_v1beta1_pagination_pb.PageRequest, 3) ); }; /** * @param {?proto.cosmos.base.query.v1beta1.PageRequest|undefined} value * @return {!proto.provenance.attribute.v1.QueryAttributeRequest} returns this */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.setPagination = function (value) { return jspb.Message.setWrapperField(this, 3, value); }; /** * Clears the message field making it undefined. * @return {!proto.provenance.attribute.v1.QueryAttributeRequest} returns this */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.clearPagination = function () { return this.setPagination(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.provenance.attribute.v1.QueryAttributeRequest.prototype.hasPagination = function () { return jspb.Message.getField(this, 3) != null; }; /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.provenance.attribute.v1.QueryAttributeResponse.repeatedFields_ = [2]; 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.provenance.attribute.v1.QueryAttributeResponse.prototype.toObject = function (opt_includeInstance) { return proto.provenance.attribute.v1.QueryAttributeResponse.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.provenance.attribute.v1.QueryAttributeResponse} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributeResponse.toObject = function (includeInstance, msg) { var f, obj = { account: jspb.Message.getFieldWithDefault(msg, 1, ""), attributesList: jspb.Message.toObjectList(msg.getAttributesList(), provenance_attribute_v1_attribute_pb.Attribute.toObject, includeInstance), pagination: (f = msg.getPagination()) && cosmos_base_query_v1beta1_pagination_pb.PageResponse.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.provenance.attribute.v1.QueryAttributeResponse} */ proto.provenance.attribute.v1.QueryAttributeResponse.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.provenance.attribute.v1.QueryAttributeResponse(); return proto.provenance.attribute.v1.QueryAttributeResponse.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.provenance.attribute.v1.QueryAttributeResponse} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.provenance.attribute.v1.QueryAttributeResponse} */ proto.provenance.attribute.v1.QueryAttributeResponse.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.setAccount(value); break; case 2: var value = new provenance_attribute_v1_attribute_pb.Attribute(); reader.readMessage(value, provenance_attribute_v1_attribute_pb.Attribute.deserializeBinaryFromReader); msg.addAttributes(value); break; case 3: var value = new cosmos_base_query_v1beta1_pagination_pb.PageResponse(); reader.readMessage(value, cosmos_base_query_v1beta1_pagination_pb.PageResponse.deserializeBinaryFromReader); msg.setPagination(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.provenance.attribute.v1.QueryAttributeResponse.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.provenance.attribute.v1.QueryAttributeResponse} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributeResponse.serializeBinaryToWriter = function (message, writer) { var f = undefined; f = message.getAccount(); if (f.length > 0) { writer.writeString(1, f); } f = message.getAttributesList(); if (f.length > 0) { writer.writeRepeatedMessage(2, f, provenance_attribute_v1_attribute_pb.Attribute.serializeBinaryToWriter); } f = message.getPagination(); if (f != null) { writer.writeMessage(3, f, cosmos_base_query_v1beta1_pagination_pb.PageResponse.serializeBinaryToWriter); } }; /** * optional string account = 1; * @return {string} */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.getAccount = function () { return ( /** @type {string} */ jspb.Message.getFieldWithDefault(this, 1, "") ); }; /** * @param {string} value * @return {!proto.provenance.attribute.v1.QueryAttributeResponse} returns this */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.setAccount = function (value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * repeated Attribute attributes = 2; * @return {!Array<!proto.provenance.attribute.v1.Attribute>} */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.getAttributesList = function () { return ( /** @type{!Array<!proto.provenance.attribute.v1.Attribute>} */ jspb.Message.getRepeatedWrapperField(this, provenance_attribute_v1_attribute_pb.Attribute, 2) ); }; /** * @param {!Array<!proto.provenance.attribute.v1.Attribute>} value * @return {!proto.provenance.attribute.v1.QueryAttributeResponse} returns this */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.setAttributesList = function (value) { return jspb.Message.setRepeatedWrapperField(this, 2, value); }; /** * @param {!proto.provenance.attribute.v1.Attribute=} opt_value * @param {number=} opt_index * @return {!proto.provenance.attribute.v1.Attribute} */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.addAttributes = function (opt_value, opt_index) { return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.provenance.attribute.v1.Attribute, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.provenance.attribute.v1.QueryAttributeResponse} returns this */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.clearAttributesList = function () { return this.setAttributesList([]); }; /** * optional cosmos.base.query.v1beta1.PageResponse pagination = 3; * @return {?proto.cosmos.base.query.v1beta1.PageResponse} */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.getPagination = function () { return ( /** @type{?proto.cosmos.base.query.v1beta1.PageResponse} */ jspb.Message.getWrapperField(this, cosmos_base_query_v1beta1_pagination_pb.PageResponse, 3) ); }; /** * @param {?proto.cosmos.base.query.v1beta1.PageResponse|undefined} value * @return {!proto.provenance.attribute.v1.QueryAttributeResponse} returns this */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.setPagination = function (value) { return jspb.Message.setWrapperField(this, 3, value); }; /** * Clears the message field making it undefined. * @return {!proto.provenance.attribute.v1.QueryAttributeResponse} returns this */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.clearPagination = function () { return this.setPagination(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.provenance.attribute.v1.QueryAttributeResponse.prototype.hasPagination = function () { return jspb.Message.getField(this, 3) != 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.provenance.attribute.v1.QueryAttributesRequest.prototype.toObject = function (opt_includeInstance) { return proto.provenance.attribute.v1.QueryAttributesRequest.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.provenance.attribute.v1.QueryAttributesRequest} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributesRequest.toObject = function (includeInstance, msg) { var f, obj = { account: jspb.Message.getFieldWithDefault(msg, 1, ""), pagination: (f = msg.getPagination()) && cosmos_base_query_v1beta1_pagination_pb.PageRequest.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.provenance.attribute.v1.QueryAttributesRequest} */ proto.provenance.attribute.v1.QueryAttributesRequest.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.provenance.attribute.v1.QueryAttributesRequest(); return proto.provenance.attribute.v1.QueryAttributesRequest.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.provenance.attribute.v1.QueryAttributesRequest} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.provenance.attribute.v1.QueryAttributesRequest} */ proto.provenance.attribute.v1.QueryAttributesRequest.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.setAccount(value); break; case 2: var value = new cosmos_base_query_v1beta1_pagination_pb.PageRequest(); reader.readMessage(value, cosmos_base_query_v1beta1_pagination_pb.PageRequest.deserializeBinaryFromReader); msg.setPagination(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.provenance.attribute.v1.QueryAttributesRequest.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.provenance.attribute.v1.QueryAttributesRequest.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.provenance.attribute.v1.QueryAttributesRequest} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributesRequest.serializeBinaryToWriter = function (message, writer) { var f = undefined; f = message.getAccount(); if (f.length > 0) { writer.writeString(1, f); } f = message.getPagination(); if (f != null) { writer.writeMessage(2, f, cosmos_base_query_v1beta1_pagination_pb.PageRequest.serializeBinaryToWriter); } }; /** * optional string account = 1; * @return {string} */ proto.provenance.attribute.v1.QueryAttributesRequest.prototype.getAccount = function () { return ( /** @type {string} */ jspb.Message.getFieldWithDefault(this, 1, "") ); }; /** * @param {string} value * @return {!proto.provenance.attribute.v1.QueryAttributesRequest} returns this */ proto.provenance.attribute.v1.QueryAttributesRequest.prototype.setAccount = function (value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional cosmos.base.query.v1beta1.PageRequest pagination = 2; * @return {?proto.cosmos.base.query.v1beta1.PageRequest} */ proto.provenance.attribute.v1.QueryAttributesRequest.prototype.getPagination = function () { return ( /** @type{?proto.cosmos.base.query.v1beta1.PageRequest} */ jspb.Message.getWrapperField(this, cosmos_base_query_v1beta1_pagination_pb.PageRequest, 2) ); }; /** * @param {?proto.cosmos.base.query.v1beta1.PageRequest|undefined} value * @return {!proto.provenance.attribute.v1.QueryAttributesRequest} returns this */ proto.provenance.attribute.v1.QueryAttributesRequest.prototype.setPagination = function (value) { return jspb.Message.setWrapperField(this, 2, value); }; /** * Clears the message field making it undefined. * @return {!proto.provenance.attribute.v1.QueryAttributesRequest} returns this */ proto.provenance.attribute.v1.QueryAttributesRequest.prototype.clearPagination = function () { return this.setPagination(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.provenance.attribute.v1.QueryAttributesRequest.prototype.hasPagination = function () { return jspb.Message.getField(this, 2) != null; }; /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.provenance.attribute.v1.QueryAttributesResponse.repeatedFields_ = [2]; 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.provenance.attribute.v1.QueryAttributesResponse.prototype.toObject = function (opt_includeInstance) { return proto.provenance.attribute.v1.QueryAttributesResponse.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.provenance.attribute.v1.QueryAttributesResponse} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributesResponse.toObject = function (includeInstance, msg) { var f, obj = { account: jspb.Message.getFieldWithDefault(msg, 1, ""), attributesList: jspb.Message.toObjectList(msg.getAttributesList(), provenance_attribute_v1_attribute_pb.Attribute.toObject, includeInstance), pagination: (f = msg.getPagination()) && cosmos_base_query_v1beta1_pagination_pb.PageResponse.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.provenance.attribute.v1.QueryAttributesResponse} */ proto.provenance.attribute.v1.QueryAttributesResponse.deserializeBinary = function (bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.provenance.attribute.v1.QueryAttributesResponse(); return proto.provenance.attribute.v1.QueryAttributesResponse.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.provenance.attribute.v1.QueryAttributesResponse} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.provenance.attribute.v1.QueryAttributesResponse} */ proto.provenance.attribute.v1.QueryAttributesResponse.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.setAccount(value); break; case 2: var value = new provenance_attribute_v1_attribute_pb.Attribute(); reader.readMessage(value, provenance_attribute_v1_attribute_pb.Attribute.deserializeBinaryFromReader); msg.addAttributes(value); break; case 3: var value = new cosmos_base_query_v1beta1_pagination_pb.PageResponse(); reader.readMessage(value, cosmos_base_query_v1beta1_pagination_pb.PageResponse.deserializeBinaryFromReader); msg.setPagination(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.serializeBinary = function () { var writer = new jspb.BinaryWriter(); proto.provenance.attribute.v1.QueryAttributesResponse.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.provenance.attribute.v1.QueryAttributesResponse} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.provenance.attribute.v1.QueryAttributesResponse.serializeBinaryToWriter = function (message, writer) { var f = undefined; f = message.getAccount(); if (f.length > 0) { writer.writeString(1, f); } f = message.getAttributesList(); if (f.length > 0) { writer.writeRepeatedMessage(2, f, provenance_attribute_v1_attribute_pb.Attribute.serializeBinaryToWriter); } f = message.getPagination(); if (f != null) { writer.writeMessage(3, f, cosmos_base_query_v1beta1_pagination_pb.PageResponse.serializeBinaryToWriter); } }; /** * optional string account = 1; * @return {string} */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.getAccount = function () { return ( /** @type {string} */ jspb.Message.getFieldWithDefault(this, 1, "") ); }; /** * @param {string} value * @return {!proto.provenance.attribute.v1.QueryAttributesResponse} returns this */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.setAccount = function (value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * repeated Attribute attributes = 2; * @return {!Array<!proto.provenance.attribute.v1.Attribute>} */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.getAttributesList = function () { return ( /** @type{!Array<!proto.provenance.attribute.v1.Attribute>} */ jspb.Message.getRepeatedWrapperField(this, provenance_attribute_v1_attribute_pb.Attribute, 2) ); }; /** * @param {!Array<!proto.provenance.attribute.v1.Attribute>} value * @return {!proto.provenance.attribute.v1.QueryAttributesResponse} returns this */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.setAttributesList = function (value) { return jspb.Message.setRepeatedWrapperField(this, 2, value); }; /** * @param {!proto.provenance.attribute.v1.Attribute=} opt_value * @param {number=} opt_index * @return {!proto.provenance.attribute.v1.Attribute} */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.addAttributes = function (opt_value, opt_index) { return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.provenance.attribute.v1.Attribute, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.provenance.attribute.v1.QueryAttributesResponse} returns this */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.clearAttributesList = function () { return this.setAttributesList([]); }; /** * optional cosmos.base.query.v1beta1.PageResponse pagination = 3; * @return {?proto.cosmos.base.query.v1beta1.PageResponse} */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.getPagination = function () { return ( /** @type{?proto.cosmos.base.query.v1beta1.PageResponse} */ jspb.Message.getWrapperField(this, cosmos_base_query_v1beta1_pagination_pb.PageResponse, 3) ); }; /** * @param {?proto.cosmos.base.query.v1beta1.PageResponse|undefined} value * @return {!proto.provenance.attribute.v1.QueryAttributesResponse} returns this */ proto.provenance.attribute.v1.QueryAttributesResponse.prototype.setPagination = function (value) { return jspb.Message.setWrapperField(this, 3, value); }; /*