@routerprotocol/chain-api
Version:
Router Chain API Query client with generated gRPC bindings.
1,513 lines (1,306 loc) • 46.7 kB
JavaScript
// source: routerprotocol/routerchain/voyager/fund_deposit_request.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 routerprotocol_routerchain_multichain_chain_type_pb = require('../../../routerprotocol/routerchain/multichain/chain_type_pb.js');
goog.object.extend(proto, routerprotocol_routerchain_multichain_chain_type_pb);
var cosmos_base_v1beta1_coin_pb = require('../../../cosmos/base/v1beta1/coin_pb.js');
goog.object.extend(proto, cosmos_base_v1beta1_coin_pb);
var gogoproto_gogo_pb = require('../../../gogoproto/gogo_pb.js');
goog.object.extend(proto, gogoproto_gogo_pb);
var routerprotocol_routerchain_voyager_voyager_fund_deposit_status_pb = require('../../../routerprotocol/routerchain/voyager/voyager_fund_deposit_status_pb.js');
goog.object.extend(proto, routerprotocol_routerchain_voyager_voyager_fund_deposit_status_pb);
goog.exportSymbol('proto.routerprotocol.routerchain.voyager.FundDepositRequest', null, global);
goog.exportSymbol('proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash', 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.routerprotocol.routerchain.voyager.FundDepositRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.routerprotocol.routerchain.voyager.FundDepositRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.displayName = 'proto.routerprotocol.routerchain.voyager.FundDepositRequest';
}
/**
* 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.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.displayName = 'proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash';
}
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.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.toObject = function(opt_includeInstance) {
return proto.routerprotocol.routerchain.voyager.FundDepositRequest.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.routerprotocol.routerchain.voyager.FundDepositRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.toObject = function(includeInstance, msg) {
var f, obj = {
srcchainid: jspb.Message.getFieldWithDefault(msg, 1, ""),
srcchaintype: jspb.Message.getFieldWithDefault(msg, 2, 0),
srctxhash: jspb.Message.getFieldWithDefault(msg, 3, ""),
srctimestamp: jspb.Message.getFieldWithDefault(msg, 4, 0),
contract: jspb.Message.getFieldWithDefault(msg, 5, ""),
depositId: jspb.Message.getFieldWithDefault(msg, 6, 0),
blockheight: jspb.Message.getFieldWithDefault(msg, 7, 0),
destchainid: msg.getDestchainid_asB64(),
amount: jspb.Message.getFieldWithDefault(msg, 9, ""),
destamount: jspb.Message.getFieldWithDefault(msg, 10, ""),
srctoken: jspb.Message.getFieldWithDefault(msg, 11, ""),
recipient: msg.getRecipient_asB64(),
depositor: jspb.Message.getFieldWithDefault(msg, 13, ""),
partnerId: jspb.Message.getFieldWithDefault(msg, 14, ""),
message: msg.getMessage_asB64(),
status: jspb.Message.getFieldWithDefault(msg, 16, 0),
depositWithMessage: jspb.Message.getBooleanFieldWithDefault(msg, 17, false),
desttoken: msg.getDesttoken_asB64()
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.routerprotocol.routerchain.voyager.FundDepositRequest;
return proto.routerprotocol.routerchain.voyager.FundDepositRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.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.setSrcchainid(value);
break;
case 2:
var value = /** @type {!proto.routerprotocol.routerchain.multichain.ChainType} */ (reader.readEnum());
msg.setSrcchaintype(value);
break;
case 3:
var value = /** @type {string} */ (reader.readString());
msg.setSrctxhash(value);
break;
case 4:
var value = /** @type {number} */ (reader.readUint64());
msg.setSrctimestamp(value);
break;
case 5:
var value = /** @type {string} */ (reader.readString());
msg.setContract(value);
break;
case 6:
var value = /** @type {number} */ (reader.readUint64());
msg.setDepositId(value);
break;
case 7:
var value = /** @type {number} */ (reader.readUint64());
msg.setBlockheight(value);
break;
case 8:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setDestchainid(value);
break;
case 9:
var value = /** @type {string} */ (reader.readString());
msg.setAmount(value);
break;
case 10:
var value = /** @type {string} */ (reader.readString());
msg.setDestamount(value);
break;
case 11:
var value = /** @type {string} */ (reader.readString());
msg.setSrctoken(value);
break;
case 12:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setRecipient(value);
break;
case 13:
var value = /** @type {string} */ (reader.readString());
msg.setDepositor(value);
break;
case 14:
var value = /** @type {string} */ (reader.readString());
msg.setPartnerId(value);
break;
case 15:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setMessage(value);
break;
case 16:
var value = /** @type {!proto.routerprotocol.routerchain.voyager.VoyagerFundDepositStatus} */ (reader.readEnum());
msg.setStatus(value);
break;
case 17:
var value = /** @type {boolean} */ (reader.readBool());
msg.setDepositWithMessage(value);
break;
case 18:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setDesttoken(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.routerprotocol.routerchain.voyager.FundDepositRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getSrcchainid();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getSrcchaintype();
if (f !== 0.0) {
writer.writeEnum(
2,
f
);
}
f = message.getSrctxhash();
if (f.length > 0) {
writer.writeString(
3,
f
);
}
f = message.getSrctimestamp();
if (f !== 0) {
writer.writeUint64(
4,
f
);
}
f = message.getContract();
if (f.length > 0) {
writer.writeString(
5,
f
);
}
f = message.getDepositId();
if (f !== 0) {
writer.writeUint64(
6,
f
);
}
f = message.getBlockheight();
if (f !== 0) {
writer.writeUint64(
7,
f
);
}
f = message.getDestchainid_asU8();
if (f.length > 0) {
writer.writeBytes(
8,
f
);
}
f = message.getAmount();
if (f.length > 0) {
writer.writeString(
9,
f
);
}
f = message.getDestamount();
if (f.length > 0) {
writer.writeString(
10,
f
);
}
f = message.getSrctoken();
if (f.length > 0) {
writer.writeString(
11,
f
);
}
f = message.getRecipient_asU8();
if (f.length > 0) {
writer.writeBytes(
12,
f
);
}
f = message.getDepositor();
if (f.length > 0) {
writer.writeString(
13,
f
);
}
f = message.getPartnerId();
if (f.length > 0) {
writer.writeString(
14,
f
);
}
f = message.getMessage_asU8();
if (f.length > 0) {
writer.writeBytes(
15,
f
);
}
f = message.getStatus();
if (f !== 0.0) {
writer.writeEnum(
16,
f
);
}
f = message.getDepositWithMessage();
if (f) {
writer.writeBool(
17,
f
);
}
f = message.getDesttoken_asU8();
if (f.length > 0) {
writer.writeBytes(
18,
f
);
}
};
/**
* optional string srcChainId = 1;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getSrcchainid = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setSrcchainid = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional routerprotocol.routerchain.multichain.ChainType srcChainType = 2;
* @return {!proto.routerprotocol.routerchain.multichain.ChainType}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getSrcchaintype = function() {
return /** @type {!proto.routerprotocol.routerchain.multichain.ChainType} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
};
/**
* @param {!proto.routerprotocol.routerchain.multichain.ChainType} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setSrcchaintype = function(value) {
return jspb.Message.setProto3EnumField(this, 2, value);
};
/**
* optional string srcTxHash = 3;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getSrctxhash = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setSrctxhash = function(value) {
return jspb.Message.setProto3StringField(this, 3, value);
};
/**
* optional uint64 srcTimestamp = 4;
* @return {number}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getSrctimestamp = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
};
/**
* @param {number} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setSrctimestamp = function(value) {
return jspb.Message.setProto3IntField(this, 4, value);
};
/**
* optional string contract = 5;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getContract = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setContract = function(value) {
return jspb.Message.setProto3StringField(this, 5, value);
};
/**
* optional uint64 deposit_id = 6;
* @return {number}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDepositId = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
};
/**
* @param {number} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setDepositId = function(value) {
return jspb.Message.setProto3IntField(this, 6, value);
};
/**
* optional uint64 blockHeight = 7;
* @return {number}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getBlockheight = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 7, 0));
};
/**
* @param {number} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setBlockheight = function(value) {
return jspb.Message.setProto3IntField(this, 7, value);
};
/**
* optional bytes destChainId = 8;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDestchainid = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 8, ""));
};
/**
* optional bytes destChainId = 8;
* This is a type-conversion wrapper around `getDestchainid()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDestchainid_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getDestchainid()));
};
/**
* optional bytes destChainId = 8;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getDestchainid()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDestchainid_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getDestchainid()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setDestchainid = function(value) {
return jspb.Message.setProto3BytesField(this, 8, value);
};
/**
* optional string amount = 9;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getAmount = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setAmount = function(value) {
return jspb.Message.setProto3StringField(this, 9, value);
};
/**
* optional string destAmount = 10;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDestamount = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 10, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setDestamount = function(value) {
return jspb.Message.setProto3StringField(this, 10, value);
};
/**
* optional string srcToken = 11;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getSrctoken = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 11, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setSrctoken = function(value) {
return jspb.Message.setProto3StringField(this, 11, value);
};
/**
* optional bytes recipient = 12;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getRecipient = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 12, ""));
};
/**
* optional bytes recipient = 12;
* This is a type-conversion wrapper around `getRecipient()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getRecipient_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getRecipient()));
};
/**
* optional bytes recipient = 12;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getRecipient()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getRecipient_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getRecipient()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setRecipient = function(value) {
return jspb.Message.setProto3BytesField(this, 12, value);
};
/**
* optional string depositor = 13;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDepositor = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 13, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setDepositor = function(value) {
return jspb.Message.setProto3StringField(this, 13, value);
};
/**
* optional string partner_id = 14;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getPartnerId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 14, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setPartnerId = function(value) {
return jspb.Message.setProto3StringField(this, 14, value);
};
/**
* optional bytes message = 15;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getMessage = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 15, ""));
};
/**
* optional bytes message = 15;
* This is a type-conversion wrapper around `getMessage()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getMessage_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getMessage()));
};
/**
* optional bytes message = 15;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getMessage()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getMessage_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getMessage()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setMessage = function(value) {
return jspb.Message.setProto3BytesField(this, 15, value);
};
/**
* optional VoyagerFundDepositStatus status = 16;
* @return {!proto.routerprotocol.routerchain.voyager.VoyagerFundDepositStatus}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getStatus = function() {
return /** @type {!proto.routerprotocol.routerchain.voyager.VoyagerFundDepositStatus} */ (jspb.Message.getFieldWithDefault(this, 16, 0));
};
/**
* @param {!proto.routerprotocol.routerchain.voyager.VoyagerFundDepositStatus} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setStatus = function(value) {
return jspb.Message.setProto3EnumField(this, 16, value);
};
/**
* optional bool deposit_with_message = 17;
* @return {boolean}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDepositWithMessage = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 17, false));
};
/**
* @param {boolean} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setDepositWithMessage = function(value) {
return jspb.Message.setProto3BooleanField(this, 17, value);
};
/**
* optional bytes destToken = 18;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDesttoken = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 18, ""));
};
/**
* optional bytes destToken = 18;
* This is a type-conversion wrapper around `getDesttoken()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDesttoken_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getDesttoken()));
};
/**
* optional bytes destToken = 18;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getDesttoken()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.getDesttoken_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getDesttoken()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequest} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequest.prototype.setDesttoken = function(value) {
return jspb.Message.setProto3BytesField(this, 18, 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.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.toObject = function(opt_includeInstance) {
return proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.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.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.toObject = function(includeInstance, msg) {
var f, obj = {
srcchainid: jspb.Message.getFieldWithDefault(msg, 1, ""),
srcchaintype: jspb.Message.getFieldWithDefault(msg, 2, 0),
srctxhash: jspb.Message.getFieldWithDefault(msg, 3, ""),
srctimestamp: jspb.Message.getFieldWithDefault(msg, 4, 0),
contract: jspb.Message.getFieldWithDefault(msg, 5, ""),
depositId: jspb.Message.getFieldWithDefault(msg, 6, 0),
blockheight: jspb.Message.getFieldWithDefault(msg, 7, 0),
destchainid: msg.getDestchainid_asB64(),
amount: jspb.Message.getFieldWithDefault(msg, 9, ""),
destamount: jspb.Message.getFieldWithDefault(msg, 10, ""),
srctoken: jspb.Message.getFieldWithDefault(msg, 11, ""),
recipient: msg.getRecipient_asB64(),
depositor: jspb.Message.getFieldWithDefault(msg, 13, ""),
message: msg.getMessage_asB64(),
partnerId: jspb.Message.getFieldWithDefault(msg, 15, ""),
depositWithMessage: jspb.Message.getBooleanFieldWithDefault(msg, 16, false),
desttoken: msg.getDesttoken_asB64()
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash;
return proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.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.setSrcchainid(value);
break;
case 2:
var value = /** @type {!proto.routerprotocol.routerchain.multichain.ChainType} */ (reader.readEnum());
msg.setSrcchaintype(value);
break;
case 3:
var value = /** @type {string} */ (reader.readString());
msg.setSrctxhash(value);
break;
case 4:
var value = /** @type {number} */ (reader.readUint64());
msg.setSrctimestamp(value);
break;
case 5:
var value = /** @type {string} */ (reader.readString());
msg.setContract(value);
break;
case 6:
var value = /** @type {number} */ (reader.readUint64());
msg.setDepositId(value);
break;
case 7:
var value = /** @type {number} */ (reader.readUint64());
msg.setBlockheight(value);
break;
case 8:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setDestchainid(value);
break;
case 9:
var value = /** @type {string} */ (reader.readString());
msg.setAmount(value);
break;
case 10:
var value = /** @type {string} */ (reader.readString());
msg.setDestamount(value);
break;
case 11:
var value = /** @type {string} */ (reader.readString());
msg.setSrctoken(value);
break;
case 12:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setRecipient(value);
break;
case 13:
var value = /** @type {string} */ (reader.readString());
msg.setDepositor(value);
break;
case 14:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setMessage(value);
break;
case 15:
var value = /** @type {string} */ (reader.readString());
msg.setPartnerId(value);
break;
case 16:
var value = /** @type {boolean} */ (reader.readBool());
msg.setDepositWithMessage(value);
break;
case 18:
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setDesttoken(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getSrcchainid();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getSrcchaintype();
if (f !== 0.0) {
writer.writeEnum(
2,
f
);
}
f = message.getSrctxhash();
if (f.length > 0) {
writer.writeString(
3,
f
);
}
f = message.getSrctimestamp();
if (f !== 0) {
writer.writeUint64(
4,
f
);
}
f = message.getContract();
if (f.length > 0) {
writer.writeString(
5,
f
);
}
f = message.getDepositId();
if (f !== 0) {
writer.writeUint64(
6,
f
);
}
f = message.getBlockheight();
if (f !== 0) {
writer.writeUint64(
7,
f
);
}
f = message.getDestchainid_asU8();
if (f.length > 0) {
writer.writeBytes(
8,
f
);
}
f = message.getAmount();
if (f.length > 0) {
writer.writeString(
9,
f
);
}
f = message.getDestamount();
if (f.length > 0) {
writer.writeString(
10,
f
);
}
f = message.getSrctoken();
if (f.length > 0) {
writer.writeString(
11,
f
);
}
f = message.getRecipient_asU8();
if (f.length > 0) {
writer.writeBytes(
12,
f
);
}
f = message.getDepositor();
if (f.length > 0) {
writer.writeString(
13,
f
);
}
f = message.getMessage_asU8();
if (f.length > 0) {
writer.writeBytes(
14,
f
);
}
f = message.getPartnerId();
if (f.length > 0) {
writer.writeString(
15,
f
);
}
f = message.getDepositWithMessage();
if (f) {
writer.writeBool(
16,
f
);
}
f = message.getDesttoken_asU8();
if (f.length > 0) {
writer.writeBytes(
18,
f
);
}
};
/**
* optional string srcChainId = 1;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getSrcchainid = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setSrcchainid = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional routerprotocol.routerchain.multichain.ChainType srcChainType = 2;
* @return {!proto.routerprotocol.routerchain.multichain.ChainType}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getSrcchaintype = function() {
return /** @type {!proto.routerprotocol.routerchain.multichain.ChainType} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
};
/**
* @param {!proto.routerprotocol.routerchain.multichain.ChainType} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setSrcchaintype = function(value) {
return jspb.Message.setProto3EnumField(this, 2, value);
};
/**
* optional string srcTxHash = 3;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getSrctxhash = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setSrctxhash = function(value) {
return jspb.Message.setProto3StringField(this, 3, value);
};
/**
* optional uint64 srcTimestamp = 4;
* @return {number}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getSrctimestamp = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
};
/**
* @param {number} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setSrctimestamp = function(value) {
return jspb.Message.setProto3IntField(this, 4, value);
};
/**
* optional string contract = 5;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getContract = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setContract = function(value) {
return jspb.Message.setProto3StringField(this, 5, value);
};
/**
* optional uint64 deposit_id = 6;
* @return {number}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDepositId = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
};
/**
* @param {number} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setDepositId = function(value) {
return jspb.Message.setProto3IntField(this, 6, value);
};
/**
* optional uint64 blockHeight = 7;
* @return {number}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getBlockheight = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 7, 0));
};
/**
* @param {number} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setBlockheight = function(value) {
return jspb.Message.setProto3IntField(this, 7, value);
};
/**
* optional bytes destChainId = 8;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDestchainid = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 8, ""));
};
/**
* optional bytes destChainId = 8;
* This is a type-conversion wrapper around `getDestchainid()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDestchainid_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getDestchainid()));
};
/**
* optional bytes destChainId = 8;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getDestchainid()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDestchainid_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getDestchainid()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setDestchainid = function(value) {
return jspb.Message.setProto3BytesField(this, 8, value);
};
/**
* optional string amount = 9;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getAmount = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setAmount = function(value) {
return jspb.Message.setProto3StringField(this, 9, value);
};
/**
* optional string destAmount = 10;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDestamount = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 10, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setDestamount = function(value) {
return jspb.Message.setProto3StringField(this, 10, value);
};
/**
* optional string srcToken = 11;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getSrctoken = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 11, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setSrctoken = function(value) {
return jspb.Message.setProto3StringField(this, 11, value);
};
/**
* optional bytes recipient = 12;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getRecipient = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 12, ""));
};
/**
* optional bytes recipient = 12;
* This is a type-conversion wrapper around `getRecipient()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getRecipient_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getRecipient()));
};
/**
* optional bytes recipient = 12;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getRecipient()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getRecipient_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getRecipient()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setRecipient = function(value) {
return jspb.Message.setProto3BytesField(this, 12, value);
};
/**
* optional string depositor = 13;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDepositor = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 13, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setDepositor = function(value) {
return jspb.Message.setProto3StringField(this, 13, value);
};
/**
* optional bytes message = 14;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getMessage = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 14, ""));
};
/**
* optional bytes message = 14;
* This is a type-conversion wrapper around `getMessage()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getMessage_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getMessage()));
};
/**
* optional bytes message = 14;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getMessage()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getMessage_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getMessage()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setMessage = function(value) {
return jspb.Message.setProto3BytesField(this, 14, value);
};
/**
* optional string partner_id = 15;
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getPartnerId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 15, ""));
};
/**
* @param {string} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setPartnerId = function(value) {
return jspb.Message.setProto3StringField(this, 15, value);
};
/**
* optional bool deposit_with_message = 16;
* @return {boolean}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDepositWithMessage = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 16, false));
};
/**
* @param {boolean} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setDepositWithMessage = function(value) {
return jspb.Message.setProto3BooleanField(this, 16, value);
};
/**
* optional bytes destToken = 18;
* @return {!(string|Uint8Array)}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDesttoken = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 18, ""));
};
/**
* optional bytes destToken = 18;
* This is a type-conversion wrapper around `getDesttoken()`
* @return {string}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDesttoken_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getDesttoken()));
};
/**
* optional bytes destToken = 18;
* Note that Uint8Array is not supported on all browsers.
* @see http://caniuse.com/Uint8Array
* This is a type-conversion wrapper around `getDesttoken()`
* @return {!Uint8Array}
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.getDesttoken_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getDesttoken()));
};
/**
* @param {!(string|Uint8Array)} value
* @return {!proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash} returns this
*/
proto.routerprotocol.routerchain.voyager.FundDepositRequestClaimHash.prototype.setDesttoken = function(value) {
return jspb.Message.setProto3BytesField(this, 18, value);
};
goog.object.extend(exports, proto.routerprotocol.routerchain.voyager);