UNPKG

@routerprotocol/chain-api

Version:

Router Chain API Query client with generated gRPC bindings.

1,409 lines (1,255 loc) 119 kB
// source: ibc/core/client/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')(); 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 ibc_core_client_v1_client_pb = require('../../../../ibc/core/client/v1/client_pb.js'); goog.object.extend(proto, ibc_core_client_v1_client_pb); var google_protobuf_any_pb = require('google-protobuf/google/protobuf/any_pb.js'); goog.object.extend(proto, google_protobuf_any_pb); var google_api_annotations_pb = require('../../../../google/api/annotations_pb.js'); goog.object.extend(proto, google_api_annotations_pb); var gogoproto_gogo_pb = require('../../../../gogoproto/gogo_pb.js'); goog.object.extend(proto, gogoproto_gogo_pb); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientParamsRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientParamsResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientStateRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientStateResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientStatesRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientStatesResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientStatusRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryClientStatusResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryConsensusStateHeightsRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryConsensusStateHeightsResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryConsensusStateRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryConsensusStateResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryConsensusStatesRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryConsensusStatesResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryUpgradedClientStateRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryUpgradedClientStateResponse', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryUpgradedConsensusStateRequest', null, global); goog.exportSymbol('proto.ibc.core.client.v1.QueryUpgradedConsensusStateResponse', 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.ibc.core.client.v1.QueryClientStateRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientStateRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientStateRequest.displayName = 'proto.ibc.core.client.v1.QueryClientStateRequest'; } /** * 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.ibc.core.client.v1.QueryClientStateResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientStateResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientStateResponse.displayName = 'proto.ibc.core.client.v1.QueryClientStateResponse'; } /** * 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.ibc.core.client.v1.QueryClientStatesRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientStatesRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientStatesRequest.displayName = 'proto.ibc.core.client.v1.QueryClientStatesRequest'; } /** * 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.ibc.core.client.v1.QueryClientStatesResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.ibc.core.client.v1.QueryClientStatesResponse.repeatedFields_, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientStatesResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientStatesResponse.displayName = 'proto.ibc.core.client.v1.QueryClientStatesResponse'; } /** * 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.ibc.core.client.v1.QueryConsensusStateRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryConsensusStateRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryConsensusStateRequest.displayName = 'proto.ibc.core.client.v1.QueryConsensusStateRequest'; } /** * 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.ibc.core.client.v1.QueryConsensusStateResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryConsensusStateResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryConsensusStateResponse.displayName = 'proto.ibc.core.client.v1.QueryConsensusStateResponse'; } /** * 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.ibc.core.client.v1.QueryConsensusStatesRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryConsensusStatesRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryConsensusStatesRequest.displayName = 'proto.ibc.core.client.v1.QueryConsensusStatesRequest'; } /** * 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.ibc.core.client.v1.QueryConsensusStatesResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.ibc.core.client.v1.QueryConsensusStatesResponse.repeatedFields_, null); }; goog.inherits(proto.ibc.core.client.v1.QueryConsensusStatesResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryConsensusStatesResponse.displayName = 'proto.ibc.core.client.v1.QueryConsensusStatesResponse'; } /** * 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.ibc.core.client.v1.QueryConsensusStateHeightsRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryConsensusStateHeightsRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryConsensusStateHeightsRequest.displayName = 'proto.ibc.core.client.v1.QueryConsensusStateHeightsRequest'; } /** * 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.ibc.core.client.v1.QueryConsensusStateHeightsResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.ibc.core.client.v1.QueryConsensusStateHeightsResponse.repeatedFields_, null); }; goog.inherits(proto.ibc.core.client.v1.QueryConsensusStateHeightsResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryConsensusStateHeightsResponse.displayName = 'proto.ibc.core.client.v1.QueryConsensusStateHeightsResponse'; } /** * 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.ibc.core.client.v1.QueryClientStatusRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientStatusRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientStatusRequest.displayName = 'proto.ibc.core.client.v1.QueryClientStatusRequest'; } /** * 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.ibc.core.client.v1.QueryClientStatusResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientStatusResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientStatusResponse.displayName = 'proto.ibc.core.client.v1.QueryClientStatusResponse'; } /** * 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.ibc.core.client.v1.QueryClientParamsRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientParamsRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientParamsRequest.displayName = 'proto.ibc.core.client.v1.QueryClientParamsRequest'; } /** * 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.ibc.core.client.v1.QueryClientParamsResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryClientParamsResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryClientParamsResponse.displayName = 'proto.ibc.core.client.v1.QueryClientParamsResponse'; } /** * 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.ibc.core.client.v1.QueryUpgradedClientStateRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryUpgradedClientStateRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryUpgradedClientStateRequest.displayName = 'proto.ibc.core.client.v1.QueryUpgradedClientStateRequest'; } /** * 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.ibc.core.client.v1.QueryUpgradedClientStateResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryUpgradedClientStateResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryUpgradedClientStateResponse.displayName = 'proto.ibc.core.client.v1.QueryUpgradedClientStateResponse'; } /** * 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.ibc.core.client.v1.QueryUpgradedConsensusStateRequest = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryUpgradedConsensusStateRequest, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryUpgradedConsensusStateRequest.displayName = 'proto.ibc.core.client.v1.QueryUpgradedConsensusStateRequest'; } /** * 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.ibc.core.client.v1.QueryUpgradedConsensusStateResponse = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.ibc.core.client.v1.QueryUpgradedConsensusStateResponse, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.ibc.core.client.v1.QueryUpgradedConsensusStateResponse.displayName = 'proto.ibc.core.client.v1.QueryUpgradedConsensusStateResponse'; } 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.ibc.core.client.v1.QueryClientStateRequest.prototype.toObject = function(opt_includeInstance) { return proto.ibc.core.client.v1.QueryClientStateRequest.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.ibc.core.client.v1.QueryClientStateRequest} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStateRequest.toObject = function(includeInstance, msg) { var f, obj = { clientId: 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.ibc.core.client.v1.QueryClientStateRequest} */ proto.ibc.core.client.v1.QueryClientStateRequest.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.ibc.core.client.v1.QueryClientStateRequest; return proto.ibc.core.client.v1.QueryClientStateRequest.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.ibc.core.client.v1.QueryClientStateRequest} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.ibc.core.client.v1.QueryClientStateRequest} */ proto.ibc.core.client.v1.QueryClientStateRequest.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.setClientId(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.ibc.core.client.v1.QueryClientStateRequest.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.ibc.core.client.v1.QueryClientStateRequest.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.ibc.core.client.v1.QueryClientStateRequest} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStateRequest.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getClientId(); if (f.length > 0) { writer.writeString( 1, f ); } }; /** * optional string client_id = 1; * @return {string} */ proto.ibc.core.client.v1.QueryClientStateRequest.prototype.getClientId = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.ibc.core.client.v1.QueryClientStateRequest} returns this */ proto.ibc.core.client.v1.QueryClientStateRequest.prototype.setClientId = function(value) { return jspb.Message.setProto3StringField(this, 1, value); }; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.toObject = function(opt_includeInstance) { return proto.ibc.core.client.v1.QueryClientStateResponse.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.ibc.core.client.v1.QueryClientStateResponse} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStateResponse.toObject = function(includeInstance, msg) { var f, obj = { clientState: (f = msg.getClientState()) && google_protobuf_any_pb.Any.toObject(includeInstance, f), proof: msg.getProof_asB64(), proofHeight: (f = msg.getProofHeight()) && ibc_core_client_v1_client_pb.Height.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.ibc.core.client.v1.QueryClientStateResponse} */ proto.ibc.core.client.v1.QueryClientStateResponse.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.ibc.core.client.v1.QueryClientStateResponse; return proto.ibc.core.client.v1.QueryClientStateResponse.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.ibc.core.client.v1.QueryClientStateResponse} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.ibc.core.client.v1.QueryClientStateResponse} */ proto.ibc.core.client.v1.QueryClientStateResponse.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = new google_protobuf_any_pb.Any; reader.readMessage(value,google_protobuf_any_pb.Any.deserializeBinaryFromReader); msg.setClientState(value); break; case 2: var value = /** @type {!Uint8Array} */ (reader.readBytes()); msg.setProof(value); break; case 3: var value = new ibc_core_client_v1_client_pb.Height; reader.readMessage(value,ibc_core_client_v1_client_pb.Height.deserializeBinaryFromReader); msg.setProofHeight(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.ibc.core.client.v1.QueryClientStateResponse.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.ibc.core.client.v1.QueryClientStateResponse} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStateResponse.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getClientState(); if (f != null) { writer.writeMessage( 1, f, google_protobuf_any_pb.Any.serializeBinaryToWriter ); } f = message.getProof_asU8(); if (f.length > 0) { writer.writeBytes( 2, f ); } f = message.getProofHeight(); if (f != null) { writer.writeMessage( 3, f, ibc_core_client_v1_client_pb.Height.serializeBinaryToWriter ); } }; /** * optional google.protobuf.Any client_state = 1; * @return {?proto.google.protobuf.Any} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.getClientState = function() { return /** @type{?proto.google.protobuf.Any} */ ( jspb.Message.getWrapperField(this, google_protobuf_any_pb.Any, 1)); }; /** * @param {?proto.google.protobuf.Any|undefined} value * @return {!proto.ibc.core.client.v1.QueryClientStateResponse} returns this */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.setClientState = function(value) { return jspb.Message.setWrapperField(this, 1, value); }; /** * Clears the message field making it undefined. * @return {!proto.ibc.core.client.v1.QueryClientStateResponse} returns this */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.clearClientState = function() { return this.setClientState(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.hasClientState = function() { return jspb.Message.getField(this, 1) != null; }; /** * optional bytes proof = 2; * @return {!(string|Uint8Array)} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.getProof = function() { return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, "")); }; /** * optional bytes proof = 2; * This is a type-conversion wrapper around `getProof()` * @return {string} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.getProof_asB64 = function() { return /** @type {string} */ (jspb.Message.bytesAsB64( this.getProof())); }; /** * optional bytes proof = 2; * Note that Uint8Array is not supported on all browsers. * @see http://caniuse.com/Uint8Array * This is a type-conversion wrapper around `getProof()` * @return {!Uint8Array} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.getProof_asU8 = function() { return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8( this.getProof())); }; /** * @param {!(string|Uint8Array)} value * @return {!proto.ibc.core.client.v1.QueryClientStateResponse} returns this */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.setProof = function(value) { return jspb.Message.setProto3BytesField(this, 2, value); }; /** * optional Height proof_height = 3; * @return {?proto.ibc.core.client.v1.Height} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.getProofHeight = function() { return /** @type{?proto.ibc.core.client.v1.Height} */ ( jspb.Message.getWrapperField(this, ibc_core_client_v1_client_pb.Height, 3)); }; /** * @param {?proto.ibc.core.client.v1.Height|undefined} value * @return {!proto.ibc.core.client.v1.QueryClientStateResponse} returns this */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.setProofHeight = function(value) { return jspb.Message.setWrapperField(this, 3, value); }; /** * Clears the message field making it undefined. * @return {!proto.ibc.core.client.v1.QueryClientStateResponse} returns this */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.clearProofHeight = function() { return this.setProofHeight(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.ibc.core.client.v1.QueryClientStateResponse.prototype.hasProofHeight = 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.ibc.core.client.v1.QueryClientStatesRequest.prototype.toObject = function(opt_includeInstance) { return proto.ibc.core.client.v1.QueryClientStatesRequest.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.ibc.core.client.v1.QueryClientStatesRequest} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStatesRequest.toObject = function(includeInstance, msg) { var f, obj = { 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.ibc.core.client.v1.QueryClientStatesRequest} */ proto.ibc.core.client.v1.QueryClientStatesRequest.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.ibc.core.client.v1.QueryClientStatesRequest; return proto.ibc.core.client.v1.QueryClientStatesRequest.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.ibc.core.client.v1.QueryClientStatesRequest} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.ibc.core.client.v1.QueryClientStatesRequest} */ proto.ibc.core.client.v1.QueryClientStatesRequest.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: 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.ibc.core.client.v1.QueryClientStatesRequest.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.ibc.core.client.v1.QueryClientStatesRequest.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.ibc.core.client.v1.QueryClientStatesRequest} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStatesRequest.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getPagination(); if (f != null) { writer.writeMessage( 1, f, cosmos_base_query_v1beta1_pagination_pb.PageRequest.serializeBinaryToWriter ); } }; /** * optional cosmos.base.query.v1beta1.PageRequest pagination = 1; * @return {?proto.cosmos.base.query.v1beta1.PageRequest} */ proto.ibc.core.client.v1.QueryClientStatesRequest.prototype.getPagination = function() { return /** @type{?proto.cosmos.base.query.v1beta1.PageRequest} */ ( jspb.Message.getWrapperField(this, cosmos_base_query_v1beta1_pagination_pb.PageRequest, 1)); }; /** * @param {?proto.cosmos.base.query.v1beta1.PageRequest|undefined} value * @return {!proto.ibc.core.client.v1.QueryClientStatesRequest} returns this */ proto.ibc.core.client.v1.QueryClientStatesRequest.prototype.setPagination = function(value) { return jspb.Message.setWrapperField(this, 1, value); }; /** * Clears the message field making it undefined. * @return {!proto.ibc.core.client.v1.QueryClientStatesRequest} returns this */ proto.ibc.core.client.v1.QueryClientStatesRequest.prototype.clearPagination = function() { return this.setPagination(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.ibc.core.client.v1.QueryClientStatesRequest.prototype.hasPagination = function() { return jspb.Message.getField(this, 1) != null; }; /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.ibc.core.client.v1.QueryClientStatesResponse.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.ibc.core.client.v1.QueryClientStatesResponse.prototype.toObject = function(opt_includeInstance) { return proto.ibc.core.client.v1.QueryClientStatesResponse.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.ibc.core.client.v1.QueryClientStatesResponse} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStatesResponse.toObject = function(includeInstance, msg) { var f, obj = { clientStatesList: jspb.Message.toObjectList(msg.getClientStatesList(), ibc_core_client_v1_client_pb.IdentifiedClientState.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.ibc.core.client.v1.QueryClientStatesResponse} */ proto.ibc.core.client.v1.QueryClientStatesResponse.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.ibc.core.client.v1.QueryClientStatesResponse; return proto.ibc.core.client.v1.QueryClientStatesResponse.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.ibc.core.client.v1.QueryClientStatesResponse} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.ibc.core.client.v1.QueryClientStatesResponse} */ proto.ibc.core.client.v1.QueryClientStatesResponse.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = new ibc_core_client_v1_client_pb.IdentifiedClientState; reader.readMessage(value,ibc_core_client_v1_client_pb.IdentifiedClientState.deserializeBinaryFromReader); msg.addClientStates(value); break; case 2: 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.ibc.core.client.v1.QueryClientStatesResponse.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.ibc.core.client.v1.QueryClientStatesResponse.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.ibc.core.client.v1.QueryClientStatesResponse} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryClientStatesResponse.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getClientStatesList(); if (f.length > 0) { writer.writeRepeatedMessage( 1, f, ibc_core_client_v1_client_pb.IdentifiedClientState.serializeBinaryToWriter ); } f = message.getPagination(); if (f != null) { writer.writeMessage( 2, f, cosmos_base_query_v1beta1_pagination_pb.PageResponse.serializeBinaryToWriter ); } }; /** * repeated IdentifiedClientState client_states = 1; * @return {!Array<!proto.ibc.core.client.v1.IdentifiedClientState>} */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.getClientStatesList = function() { return /** @type{!Array<!proto.ibc.core.client.v1.IdentifiedClientState>} */ ( jspb.Message.getRepeatedWrapperField(this, ibc_core_client_v1_client_pb.IdentifiedClientState, 1)); }; /** * @param {!Array<!proto.ibc.core.client.v1.IdentifiedClientState>} value * @return {!proto.ibc.core.client.v1.QueryClientStatesResponse} returns this */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.setClientStatesList = function(value) { return jspb.Message.setRepeatedWrapperField(this, 1, value); }; /** * @param {!proto.ibc.core.client.v1.IdentifiedClientState=} opt_value * @param {number=} opt_index * @return {!proto.ibc.core.client.v1.IdentifiedClientState} */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.addClientStates = function(opt_value, opt_index) { return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.ibc.core.client.v1.IdentifiedClientState, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.ibc.core.client.v1.QueryClientStatesResponse} returns this */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.clearClientStatesList = function() { return this.setClientStatesList([]); }; /** * optional cosmos.base.query.v1beta1.PageResponse pagination = 2; * @return {?proto.cosmos.base.query.v1beta1.PageResponse} */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.getPagination = function() { return /** @type{?proto.cosmos.base.query.v1beta1.PageResponse} */ ( jspb.Message.getWrapperField(this, cosmos_base_query_v1beta1_pagination_pb.PageResponse, 2)); }; /** * @param {?proto.cosmos.base.query.v1beta1.PageResponse|undefined} value * @return {!proto.ibc.core.client.v1.QueryClientStatesResponse} returns this */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.setPagination = function(value) { return jspb.Message.setWrapperField(this, 2, value); }; /** * Clears the message field making it undefined. * @return {!proto.ibc.core.client.v1.QueryClientStatesResponse} returns this */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.clearPagination = function() { return this.setPagination(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.ibc.core.client.v1.QueryClientStatesResponse.prototype.hasPagination = function() { return jspb.Message.getField(this, 2) != null; }; if (jspb.Message.GENERATE_TO_OBJECT) { /** * Creates an object representation of this proto. * Field names that are reserved in JavaScript and will be renamed to pb_name. * Optional fields that are not set will be set to undefined. * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default. * For the list of reserved names please see: * net/proto2/compiler/js/internal/generator.cc#kKeyword. * @param {boolean=} opt_includeInstance Deprecated. whether to include the * JSPB instance for transitional soy proto support: * http://goto/soy-param-migration * @return {!Object} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.toObject = function(opt_includeInstance) { return proto.ibc.core.client.v1.QueryConsensusStateRequest.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.ibc.core.client.v1.QueryConsensusStateRequest} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryConsensusStateRequest.toObject = function(includeInstance, msg) { var f, obj = { clientId: jspb.Message.getFieldWithDefault(msg, 1, ""), revisionNumber: jspb.Message.getFieldWithDefault(msg, 2, 0), revisionHeight: jspb.Message.getFieldWithDefault(msg, 3, 0), latestHeight: jspb.Message.getBooleanFieldWithDefault(msg, 4, false) }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.ibc.core.client.v1.QueryConsensusStateRequest} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.ibc.core.client.v1.QueryConsensusStateRequest; return proto.ibc.core.client.v1.QueryConsensusStateRequest.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.ibc.core.client.v1.QueryConsensusStateRequest} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.ibc.core.client.v1.QueryConsensusStateRequest} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.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.setClientId(value); break; case 2: var value = /** @type {number} */ (reader.readUint64()); msg.setRevisionNumber(value); break; case 3: var value = /** @type {number} */ (reader.readUint64()); msg.setRevisionHeight(value); break; case 4: var value = /** @type {boolean} */ (reader.readBool()); msg.setLatestHeight(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.ibc.core.client.v1.QueryConsensusStateRequest.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.ibc.core.client.v1.QueryConsensusStateRequest} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.ibc.core.client.v1.QueryConsensusStateRequest.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getClientId(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getRevisionNumber(); if (f !== 0) { writer.writeUint64( 2, f ); } f = message.getRevisionHeight(); if (f !== 0) { writer.writeUint64( 3, f ); } f = message.getLatestHeight(); if (f) { writer.writeBool( 4, f ); } }; /** * optional string client_id = 1; * @return {string} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.getClientId = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.ibc.core.client.v1.QueryConsensusStateRequest} returns this */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.setClientId = function(value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional uint64 revision_number = 2; * @return {number} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.getRevisionNumber = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0)); }; /** * @param {number} value * @return {!proto.ibc.core.client.v1.QueryConsensusStateRequest} returns this */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.setRevisionNumber = function(value) { return jspb.Message.setProto3IntField(this, 2, value); }; /** * optional uint64 revision_height = 3; * @return {number} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.getRevisionHeight = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); }; /** * @param {number} value * @return {!proto.ibc.core.client.v1.QueryConsensusStateRequest} returns this */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.setRevisionHeight = function(value) { return jspb.Message.setProto3IntField(this, 3, value); }; /** * optional bool latest_height = 4; * @return {boolean} */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.getLatestHeight = function() { return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 4, false)); }; /** * @param {boolean} value * @return {!proto.ibc.core.client.v1.QueryConsensusStateRequest} returns this */ proto.ibc.core.client.v1.QueryConsensusStateRequest.prototype.setLatestHeight = function(value) { return jspb.Message.setProto3BooleanField(this, 4, 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.ibc.core.client.v1.QueryConsensusStateResponse.prototype.toObject = function(opt_includeInstance) { return proto.ibc.core.client.v1.QueryConsensus