@sangaman/xud
Version:
Exchange Union Daemon
1,577 lines (1,364 loc) • 190 kB
JavaScript
/**
* @fileoverview
* @enhanceable
* @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!
var jspb = require('google-protobuf');
var goog = jspb;
var global = Function('return this')();
var annotations_pb = require('./annotations_pb.js');
goog.exportSymbol('proto.xudrpc.CancelOrderRequest', null, global);
goog.exportSymbol('proto.xudrpc.CancelOrderResponse', null, global);
goog.exportSymbol('proto.xudrpc.ConnectRequest', null, global);
goog.exportSymbol('proto.xudrpc.ConnectResponse', null, global);
goog.exportSymbol('proto.xudrpc.DisconnectRequest', null, global);
goog.exportSymbol('proto.xudrpc.DisconnectResponse', null, global);
goog.exportSymbol('proto.xudrpc.ExecuteSwapRequest', null, global);
goog.exportSymbol('proto.xudrpc.ExecuteSwapResponse', null, global);
goog.exportSymbol('proto.xudrpc.GetInfoRequest', null, global);
goog.exportSymbol('proto.xudrpc.GetInfoResponse', null, global);
goog.exportSymbol('proto.xudrpc.GetOrdersRequest', null, global);
goog.exportSymbol('proto.xudrpc.GetOrdersResponse', null, global);
goog.exportSymbol('proto.xudrpc.GetPairsRequest', null, global);
goog.exportSymbol('proto.xudrpc.GetPairsResponse', null, global);
goog.exportSymbol('proto.xudrpc.ListPeersRequest', null, global);
goog.exportSymbol('proto.xudrpc.ListPeersResponse', null, global);
goog.exportSymbol('proto.xudrpc.LndChannels', null, global);
goog.exportSymbol('proto.xudrpc.LndInfo', null, global);
goog.exportSymbol('proto.xudrpc.Order', null, global);
goog.exportSymbol('proto.xudrpc.OrderMatch', null, global);
goog.exportSymbol('proto.xudrpc.Orders', null, global);
goog.exportSymbol('proto.xudrpc.OrdersCount', null, global);
goog.exportSymbol('proto.xudrpc.Pair', null, global);
goog.exportSymbol('proto.xudrpc.Peer', null, global);
goog.exportSymbol('proto.xudrpc.PlaceOrderRequest', null, global);
goog.exportSymbol('proto.xudrpc.PlaceOrderResponse', null, global);
goog.exportSymbol('proto.xudrpc.RaidenInfo', null, global);
goog.exportSymbol('proto.xudrpc.ShutdownRequest', null, global);
goog.exportSymbol('proto.xudrpc.ShutdownResponse', null, global);
goog.exportSymbol('proto.xudrpc.SubscribePeerOrdersRequest', null, global);
goog.exportSymbol('proto.xudrpc.SubscribePeerOrdersResponse', null, global);
goog.exportSymbol('proto.xudrpc.SubscribeSwapsRequest', null, global);
goog.exportSymbol('proto.xudrpc.SubscribeSwapsResponse', null, global);
goog.exportSymbol('proto.xudrpc.SwapPayload', 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.xudrpc.CancelOrderRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.CancelOrderRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.CancelOrderRequest.displayName = 'proto.xudrpc.CancelOrderRequest';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.CancelOrderRequest.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.CancelOrderRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.CancelOrderRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.CancelOrderRequest.toObject = function(includeInstance, msg) {
var f, obj = {
orderId: jspb.Message.getFieldWithDefault(msg, 1, ""),
pairId: jspb.Message.getFieldWithDefault(msg, 2, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.xudrpc.CancelOrderRequest}
*/
proto.xudrpc.CancelOrderRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.CancelOrderRequest;
return proto.xudrpc.CancelOrderRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.CancelOrderRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.CancelOrderRequest}
*/
proto.xudrpc.CancelOrderRequest.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.setOrderId(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setPairId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.CancelOrderRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.CancelOrderRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.CancelOrderRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.CancelOrderRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getOrderId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getPairId();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string order_id = 1;
* @return {string}
*/
proto.xudrpc.CancelOrderRequest.prototype.getOrderId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.xudrpc.CancelOrderRequest.prototype.setOrderId = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* optional string pair_id = 2;
* @return {string}
*/
proto.xudrpc.CancelOrderRequest.prototype.getPairId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/** @param {string} value */
proto.xudrpc.CancelOrderRequest.prototype.setPairId = function(value) {
jspb.Message.setField(this, 2, value);
};
/**
* 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.xudrpc.CancelOrderResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.CancelOrderResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.CancelOrderResponse.displayName = 'proto.xudrpc.CancelOrderResponse';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.CancelOrderResponse.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.CancelOrderResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.CancelOrderResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.CancelOrderResponse.toObject = function(includeInstance, msg) {
var f, obj = {
canceled: jspb.Message.getFieldWithDefault(msg, 1, 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.xudrpc.CancelOrderResponse}
*/
proto.xudrpc.CancelOrderResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.CancelOrderResponse;
return proto.xudrpc.CancelOrderResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.CancelOrderResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.CancelOrderResponse}
*/
proto.xudrpc.CancelOrderResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {boolean} */ (reader.readBool());
msg.setCanceled(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.CancelOrderResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.CancelOrderResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.CancelOrderResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.CancelOrderResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getCanceled();
if (f) {
writer.writeBool(
1,
f
);
}
};
/**
* optional bool canceled = 1;
* Note that Boolean fields may be set to 0/1 when serialized from a Java server.
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.xudrpc.CancelOrderResponse.prototype.getCanceled = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 1, false));
};
/** @param {boolean} value */
proto.xudrpc.CancelOrderResponse.prototype.setCanceled = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* 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.xudrpc.ConnectRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.ConnectRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.ConnectRequest.displayName = 'proto.xudrpc.ConnectRequest';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.ConnectRequest.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.ConnectRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.ConnectRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ConnectRequest.toObject = function(includeInstance, msg) {
var f, obj = {
host: jspb.Message.getFieldWithDefault(msg, 1, ""),
port: jspb.Message.getFieldWithDefault(msg, 2, 0),
nodePubKey: jspb.Message.getFieldWithDefault(msg, 3, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.xudrpc.ConnectRequest}
*/
proto.xudrpc.ConnectRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.ConnectRequest;
return proto.xudrpc.ConnectRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.ConnectRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.ConnectRequest}
*/
proto.xudrpc.ConnectRequest.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.setHost(value);
break;
case 2:
var value = /** @type {number} */ (reader.readUint32());
msg.setPort(value);
break;
case 3:
var value = /** @type {string} */ (reader.readString());
msg.setNodePubKey(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.ConnectRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.ConnectRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.ConnectRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ConnectRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getHost();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getPort();
if (f !== 0) {
writer.writeUint32(
2,
f
);
}
f = message.getNodePubKey();
if (f.length > 0) {
writer.writeString(
3,
f
);
}
};
/**
* optional string host = 1;
* @return {string}
*/
proto.xudrpc.ConnectRequest.prototype.getHost = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.xudrpc.ConnectRequest.prototype.setHost = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* optional uint32 port = 2;
* @return {number}
*/
proto.xudrpc.ConnectRequest.prototype.getPort = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
};
/** @param {number} value */
proto.xudrpc.ConnectRequest.prototype.setPort = function(value) {
jspb.Message.setField(this, 2, value);
};
/**
* optional string node_pub_key = 3;
* @return {string}
*/
proto.xudrpc.ConnectRequest.prototype.getNodePubKey = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
};
/** @param {string} value */
proto.xudrpc.ConnectRequest.prototype.setNodePubKey = function(value) {
jspb.Message.setField(this, 3, value);
};
/**
* 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.xudrpc.ConnectResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.ConnectResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.ConnectResponse.displayName = 'proto.xudrpc.ConnectResponse';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.ConnectResponse.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.ConnectResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.ConnectResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ConnectResponse.toObject = function(includeInstance, msg) {
var f, obj = {
result: 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.xudrpc.ConnectResponse}
*/
proto.xudrpc.ConnectResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.ConnectResponse;
return proto.xudrpc.ConnectResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.ConnectResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.ConnectResponse}
*/
proto.xudrpc.ConnectResponse.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.setResult(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.ConnectResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.ConnectResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.ConnectResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ConnectResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getResult();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string result = 1;
* @return {string}
*/
proto.xudrpc.ConnectResponse.prototype.getResult = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.xudrpc.ConnectResponse.prototype.setResult = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* 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.xudrpc.DisconnectRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.DisconnectRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.DisconnectRequest.displayName = 'proto.xudrpc.DisconnectRequest';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.DisconnectRequest.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.DisconnectRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.DisconnectRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.DisconnectRequest.toObject = function(includeInstance, msg) {
var f, obj = {
nodePubKey: 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.xudrpc.DisconnectRequest}
*/
proto.xudrpc.DisconnectRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.DisconnectRequest;
return proto.xudrpc.DisconnectRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.DisconnectRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.DisconnectRequest}
*/
proto.xudrpc.DisconnectRequest.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.setNodePubKey(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.DisconnectRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.DisconnectRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.DisconnectRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.DisconnectRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getNodePubKey();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string node_pub_key = 1;
* @return {string}
*/
proto.xudrpc.DisconnectRequest.prototype.getNodePubKey = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.xudrpc.DisconnectRequest.prototype.setNodePubKey = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* 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.xudrpc.DisconnectResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.DisconnectResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.DisconnectResponse.displayName = 'proto.xudrpc.DisconnectResponse';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.DisconnectResponse.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.DisconnectResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.DisconnectResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.DisconnectResponse.toObject = function(includeInstance, msg) {
var f, obj = {
result: 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.xudrpc.DisconnectResponse}
*/
proto.xudrpc.DisconnectResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.DisconnectResponse;
return proto.xudrpc.DisconnectResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.DisconnectResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.DisconnectResponse}
*/
proto.xudrpc.DisconnectResponse.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.setResult(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.DisconnectResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.DisconnectResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.DisconnectResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.DisconnectResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getResult();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string result = 1;
* @return {string}
*/
proto.xudrpc.DisconnectResponse.prototype.getResult = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.xudrpc.DisconnectResponse.prototype.setResult = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* 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.xudrpc.ExecuteSwapRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.ExecuteSwapRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.ExecuteSwapRequest.displayName = 'proto.xudrpc.ExecuteSwapRequest';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.ExecuteSwapRequest.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.ExecuteSwapRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.ExecuteSwapRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ExecuteSwapRequest.toObject = function(includeInstance, msg) {
var f, obj = {
targetAddress: jspb.Message.getFieldWithDefault(msg, 1, ""),
payload: (f = msg.getPayload()) && proto.xudrpc.SwapPayload.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.xudrpc.ExecuteSwapRequest}
*/
proto.xudrpc.ExecuteSwapRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.ExecuteSwapRequest;
return proto.xudrpc.ExecuteSwapRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.ExecuteSwapRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.ExecuteSwapRequest}
*/
proto.xudrpc.ExecuteSwapRequest.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.setTargetAddress(value);
break;
case 2:
var value = new proto.xudrpc.SwapPayload;
reader.readMessage(value,proto.xudrpc.SwapPayload.deserializeBinaryFromReader);
msg.setPayload(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.ExecuteSwapRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.ExecuteSwapRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.ExecuteSwapRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ExecuteSwapRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getTargetAddress();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getPayload();
if (f != null) {
writer.writeMessage(
2,
f,
proto.xudrpc.SwapPayload.serializeBinaryToWriter
);
}
};
/**
* optional string target_address = 1;
* @return {string}
*/
proto.xudrpc.ExecuteSwapRequest.prototype.getTargetAddress = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.xudrpc.ExecuteSwapRequest.prototype.setTargetAddress = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* optional SwapPayload payload = 2;
* @return {?proto.xudrpc.SwapPayload}
*/
proto.xudrpc.ExecuteSwapRequest.prototype.getPayload = function() {
return /** @type{?proto.xudrpc.SwapPayload} */ (
jspb.Message.getWrapperField(this, proto.xudrpc.SwapPayload, 2));
};
/** @param {?proto.xudrpc.SwapPayload|undefined} value */
proto.xudrpc.ExecuteSwapRequest.prototype.setPayload = function(value) {
jspb.Message.setWrapperField(this, 2, value);
};
proto.xudrpc.ExecuteSwapRequest.prototype.clearPayload = function() {
this.setPayload(undefined);
};
/**
* Returns whether this field is set.
* @return {!boolean}
*/
proto.xudrpc.ExecuteSwapRequest.prototype.hasPayload = function() {
return jspb.Message.getField(this, 2) != null;
};
/**
* 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.xudrpc.ExecuteSwapResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.ExecuteSwapResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.ExecuteSwapResponse.displayName = 'proto.xudrpc.ExecuteSwapResponse';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.ExecuteSwapResponse.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.ExecuteSwapResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.ExecuteSwapResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ExecuteSwapResponse.toObject = function(includeInstance, msg) {
var f, obj = {
result: 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.xudrpc.ExecuteSwapResponse}
*/
proto.xudrpc.ExecuteSwapResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.ExecuteSwapResponse;
return proto.xudrpc.ExecuteSwapResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.ExecuteSwapResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.ExecuteSwapResponse}
*/
proto.xudrpc.ExecuteSwapResponse.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.setResult(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.ExecuteSwapResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.ExecuteSwapResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.ExecuteSwapResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.ExecuteSwapResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getResult();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string result = 1;
* @return {string}
*/
proto.xudrpc.ExecuteSwapResponse.prototype.getResult = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.xudrpc.ExecuteSwapResponse.prototype.setResult = function(value) {
jspb.Message.setField(this, 1, value);
};
/**
* 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.xudrpc.GetInfoRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.GetInfoRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.GetInfoRequest.displayName = 'proto.xudrpc.GetInfoRequest';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.GetInfoRequest.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.GetInfoRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.GetInfoRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.GetInfoRequest.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.xudrpc.GetInfoRequest}
*/
proto.xudrpc.GetInfoRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.GetInfoRequest;
return proto.xudrpc.GetInfoRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.GetInfoRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.GetInfoRequest}
*/
proto.xudrpc.GetInfoRequest.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.xudrpc.GetInfoRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.GetInfoRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.GetInfoRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.GetInfoRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
};
/**
* 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.xudrpc.GetInfoResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.xudrpc.GetInfoResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.xudrpc.GetInfoResponse.displayName = 'proto.xudrpc.GetInfoResponse';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto suitable for use in Soy templates.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
* @param {boolean=} opt_includeInstance Whether to include the JSPB instance
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.xudrpc.GetInfoResponse.prototype.toObject = function(opt_includeInstance) {
return proto.xudrpc.GetInfoResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.xudrpc.GetInfoResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.GetInfoResponse.toObject = function(includeInstance, msg) {
var f, obj = {
numPeers: jspb.Message.getFieldWithDefault(msg, 1, 0),
numPairs: jspb.Message.getFieldWithDefault(msg, 2, 0),
version: jspb.Message.getFieldWithDefault(msg, 3, ""),
orders: (f = msg.getOrders()) && proto.xudrpc.OrdersCount.toObject(includeInstance, f),
lndbtc: (f = msg.getLndbtc()) && proto.xudrpc.LndInfo.toObject(includeInstance, f),
lndltc: (f = msg.getLndltc()) && proto.xudrpc.LndInfo.toObject(includeInstance, f),
raiden: (f = msg.getRaiden()) && proto.xudrpc.RaidenInfo.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.xudrpc.GetInfoResponse}
*/
proto.xudrpc.GetInfoResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.xudrpc.GetInfoResponse;
return proto.xudrpc.GetInfoResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.xudrpc.GetInfoResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.xudrpc.GetInfoResponse}
*/
proto.xudrpc.GetInfoResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {number} */ (reader.readInt32());
msg.setNumPeers(value);
break;
case 2:
var value = /** @type {number} */ (reader.readInt32());
msg.setNumPairs(value);
break;
case 3:
var value = /** @type {string} */ (reader.readString());
msg.setVersion(value);
break;
case 4:
var value = new proto.xudrpc.OrdersCount;
reader.readMessage(value,proto.xudrpc.OrdersCount.deserializeBinaryFromReader);
msg.setOrders(value);
break;
case 5:
var value = new proto.xudrpc.LndInfo;
reader.readMessage(value,proto.xudrpc.LndInfo.deserializeBinaryFromReader);
msg.setLndbtc(value);
break;
case 6:
var value = new proto.xudrpc.LndInfo;
reader.readMessage(value,proto.xudrpc.LndInfo.deserializeBinaryFromReader);
msg.setLndltc(value);
break;
case 7:
var value = new proto.xudrpc.RaidenInfo;
reader.readMessage(value,proto.xudrpc.RaidenInfo.deserializeBinaryFromReader);
msg.setRaiden(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.xudrpc.GetInfoResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.xudrpc.GetInfoResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.xudrpc.GetInfoResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.xudrpc.GetInfoResponse.s