mirror of
https://github.com/chirpstack/chirpstack.git
synced 2024-12-19 05:07:54 +00:00
3837 lines
105 KiB
JavaScript
Vendored
3837 lines
105 KiB
JavaScript
Vendored
// source: integration/integration.proto
|
|
/**
|
|
* @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 common_common_pb = require('../common/common_pb.js');
|
|
goog.object.extend(proto, common_common_pb);
|
|
var gw_gw_pb = require('../gw/gw_pb.js');
|
|
goog.object.extend(proto, gw_gw_pb);
|
|
var google_protobuf_timestamp_pb = require('google-protobuf/google/protobuf/timestamp_pb.js');
|
|
goog.object.extend(proto, google_protobuf_timestamp_pb);
|
|
goog.exportSymbol('proto.integration.AckEvent', null, global);
|
|
goog.exportSymbol('proto.integration.ErrorEvent', null, global);
|
|
goog.exportSymbol('proto.integration.ErrorType', null, global);
|
|
goog.exportSymbol('proto.integration.IntegrationEvent', null, global);
|
|
goog.exportSymbol('proto.integration.JoinEvent', null, global);
|
|
goog.exportSymbol('proto.integration.LocationEvent', null, global);
|
|
goog.exportSymbol('proto.integration.StatusEvent', null, global);
|
|
goog.exportSymbol('proto.integration.TxAckEvent', null, global);
|
|
goog.exportSymbol('proto.integration.UplinkEvent', 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.integration.UplinkEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, proto.integration.UplinkEvent.repeatedFields_, null);
|
|
};
|
|
goog.inherits(proto.integration.UplinkEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.UplinkEvent.displayName = 'proto.integration.UplinkEvent';
|
|
}
|
|
/**
|
|
* 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.integration.JoinEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, proto.integration.JoinEvent.repeatedFields_, null);
|
|
};
|
|
goog.inherits(proto.integration.JoinEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.JoinEvent.displayName = 'proto.integration.JoinEvent';
|
|
}
|
|
/**
|
|
* 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.integration.AckEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
};
|
|
goog.inherits(proto.integration.AckEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.AckEvent.displayName = 'proto.integration.AckEvent';
|
|
}
|
|
/**
|
|
* 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.integration.TxAckEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
};
|
|
goog.inherits(proto.integration.TxAckEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.TxAckEvent.displayName = 'proto.integration.TxAckEvent';
|
|
}
|
|
/**
|
|
* 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.integration.ErrorEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
};
|
|
goog.inherits(proto.integration.ErrorEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.ErrorEvent.displayName = 'proto.integration.ErrorEvent';
|
|
}
|
|
/**
|
|
* 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.integration.StatusEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
};
|
|
goog.inherits(proto.integration.StatusEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.StatusEvent.displayName = 'proto.integration.StatusEvent';
|
|
}
|
|
/**
|
|
* 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.integration.LocationEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, proto.integration.LocationEvent.repeatedFields_, null);
|
|
};
|
|
goog.inherits(proto.integration.LocationEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.LocationEvent.displayName = 'proto.integration.LocationEvent';
|
|
}
|
|
/**
|
|
* 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.integration.IntegrationEvent = function(opt_data) {
|
|
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
|
};
|
|
goog.inherits(proto.integration.IntegrationEvent, jspb.Message);
|
|
if (goog.DEBUG && !COMPILED) {
|
|
/**
|
|
* @public
|
|
* @override
|
|
*/
|
|
proto.integration.IntegrationEvent.displayName = 'proto.integration.IntegrationEvent';
|
|
}
|
|
|
|
/**
|
|
* List of repeated fields within this message type.
|
|
* @private {!Array<number>}
|
|
* @const
|
|
*/
|
|
proto.integration.UplinkEvent.repeatedFields_ = [5];
|
|
|
|
|
|
|
|
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.integration.UplinkEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.UplinkEvent.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.integration.UplinkEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.UplinkEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
rxInfoList: jspb.Message.toObjectList(msg.getRxInfoList(),
|
|
gw_gw_pb.UplinkRXInfo.toObject, includeInstance),
|
|
txInfo: (f = msg.getTxInfo()) && gw_gw_pb.UplinkTXInfo.toObject(includeInstance, f),
|
|
adr: jspb.Message.getBooleanFieldWithDefault(msg, 7, false),
|
|
dr: jspb.Message.getFieldWithDefault(msg, 8, 0),
|
|
fCnt: jspb.Message.getFieldWithDefault(msg, 9, 0),
|
|
fPort: jspb.Message.getFieldWithDefault(msg, 10, 0),
|
|
data: jspb.Message.getFieldWithDefault(msg, 11, ""),
|
|
objectJson: jspb.Message.getFieldWithDefault(msg, 12, ""),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
confirmedUplink: jspb.Message.getBooleanFieldWithDefault(msg, 14, false),
|
|
devAddr: jspb.Message.getFieldWithDefault(msg, 15, ""),
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
|
|
deviceProfileId: jspb.Message.getFieldWithDefault(msg, 17, ""),
|
|
deviceProfileName: jspb.Message.getFieldWithDefault(msg, 18, "")
|
|
};
|
|
|
|
if (includeInstance) {
|
|
obj.$jspbMessageInstance = msg;
|
|
}
|
|
return obj;
|
|
};
|
|
}
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format).
|
|
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
|
* @return {!proto.integration.UplinkEvent}
|
|
*/
|
|
proto.integration.UplinkEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.UplinkEvent;
|
|
return proto.integration.UplinkEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.UplinkEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.UplinkEvent}
|
|
*/
|
|
proto.integration.UplinkEvent.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.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = new gw_gw_pb.UplinkRXInfo;
|
|
reader.readMessage(value,gw_gw_pb.UplinkRXInfo.deserializeBinaryFromReader);
|
|
msg.addRxInfo(value);
|
|
break;
|
|
case 6:
|
|
var value = new gw_gw_pb.UplinkTXInfo;
|
|
reader.readMessage(value,gw_gw_pb.UplinkTXInfo.deserializeBinaryFromReader);
|
|
msg.setTxInfo(value);
|
|
break;
|
|
case 7:
|
|
var value = /** @type {boolean} */ (reader.readBool());
|
|
msg.setAdr(value);
|
|
break;
|
|
case 8:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setDr(value);
|
|
break;
|
|
case 9:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setFCnt(value);
|
|
break;
|
|
case 10:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setFPort(value);
|
|
break;
|
|
case 11:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setData(value);
|
|
break;
|
|
case 12:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setObjectJson(value);
|
|
break;
|
|
case 13:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 14:
|
|
var value = /** @type {boolean} */ (reader.readBool());
|
|
msg.setConfirmedUplink(value);
|
|
break;
|
|
case 15:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevAddr(value);
|
|
break;
|
|
case 16:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
case 17:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceProfileId(value);
|
|
break;
|
|
case 18:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceProfileName(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.UplinkEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.UplinkEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.UplinkEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getRxInfoList();
|
|
if (f.length > 0) {
|
|
writer.writeRepeatedMessage(
|
|
5,
|
|
f,
|
|
gw_gw_pb.UplinkRXInfo.serializeBinaryToWriter
|
|
);
|
|
}
|
|
f = message.getTxInfo();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
6,
|
|
f,
|
|
gw_gw_pb.UplinkTXInfo.serializeBinaryToWriter
|
|
);
|
|
}
|
|
f = message.getAdr();
|
|
if (f) {
|
|
writer.writeBool(
|
|
7,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDr();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
8,
|
|
f
|
|
);
|
|
}
|
|
f = message.getFCnt();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
9,
|
|
f
|
|
);
|
|
}
|
|
f = message.getFPort();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
10,
|
|
f
|
|
);
|
|
}
|
|
f = message.getData();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
11,
|
|
f
|
|
);
|
|
}
|
|
f = message.getObjectJson();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
12,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(13, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getConfirmedUplink();
|
|
if (f) {
|
|
writer.writeBool(
|
|
14,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevAddr();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
15,
|
|
f
|
|
);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
16,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
f = message.getDeviceProfileId();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
17,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceProfileName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
18,
|
|
f
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_id = 1;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getApplicationId = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* repeated gw.UplinkRXInfo rx_info = 5;
|
|
* @return {!Array<!proto.gw.UplinkRXInfo>}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getRxInfoList = function() {
|
|
return /** @type{!Array<!proto.gw.UplinkRXInfo>} */ (
|
|
jspb.Message.getRepeatedWrapperField(this, gw_gw_pb.UplinkRXInfo, 5));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {!Array<!proto.gw.UplinkRXInfo>} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setRxInfoList = function(value) {
|
|
return jspb.Message.setRepeatedWrapperField(this, 5, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {!proto.gw.UplinkRXInfo=} opt_value
|
|
* @param {number=} opt_index
|
|
* @return {!proto.gw.UplinkRXInfo}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.addRxInfo = function(opt_value, opt_index) {
|
|
return jspb.Message.addToRepeatedWrapperField(this, 5, opt_value, proto.gw.UplinkRXInfo, opt_index);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the list making it empty but non-null.
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.clearRxInfoList = function() {
|
|
return this.setRxInfoList([]);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional gw.UplinkTXInfo tx_info = 6;
|
|
* @return {?proto.gw.UplinkTXInfo}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getTxInfo = function() {
|
|
return /** @type{?proto.gw.UplinkTXInfo} */ (
|
|
jspb.Message.getWrapperField(this, gw_gw_pb.UplinkTXInfo, 6));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.gw.UplinkTXInfo|undefined} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setTxInfo = function(value) {
|
|
return jspb.Message.setWrapperField(this, 6, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.clearTxInfo = function() {
|
|
return this.setTxInfo(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.hasTxInfo = function() {
|
|
return jspb.Message.getField(this, 6) != null;
|
|
};
|
|
|
|
|
|
/**
|
|
* optional bool adr = 7;
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getAdr = function() {
|
|
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 7, false));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {boolean} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setAdr = function(value) {
|
|
return jspb.Message.setProto3BooleanField(this, 7, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 dr = 8;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getDr = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 8, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setDr = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 8, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 f_cnt = 9;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getFCnt = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 9, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setFCnt = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 9, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 f_port = 10;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getFPort = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 10, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setFPort = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 10, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string data = 11;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getData = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 11, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setData = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 11, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string object_json = 12;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getObjectJson = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 12, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setObjectJson = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 12, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 13;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 13, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* optional bool confirmed_uplink = 14;
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getConfirmedUplink = function() {
|
|
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 14, false));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {boolean} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setConfirmedUplink = function(value) {
|
|
return jspb.Message.setProto3BooleanField(this, 14, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_addr = 15;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getDevAddr = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 15, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setDevAddr = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 15, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 16;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 16));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 16, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 16) != null;
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_profile_id = 17;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getDeviceProfileId = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 17, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setDeviceProfileId = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 17, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_profile_name = 18;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.getDeviceProfileName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 18, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.UplinkEvent} returns this
|
|
*/
|
|
proto.integration.UplinkEvent.prototype.setDeviceProfileName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 18, value);
|
|
};
|
|
|
|
|
|
|
|
/**
|
|
* List of repeated fields within this message type.
|
|
* @private {!Array<number>}
|
|
* @const
|
|
*/
|
|
proto.integration.JoinEvent.repeatedFields_ = [6];
|
|
|
|
|
|
|
|
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.integration.JoinEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.JoinEvent.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.integration.JoinEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.JoinEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
devAddr: jspb.Message.getFieldWithDefault(msg, 5, ""),
|
|
rxInfoList: jspb.Message.toObjectList(msg.getRxInfoList(),
|
|
gw_gw_pb.UplinkRXInfo.toObject, includeInstance),
|
|
txInfo: (f = msg.getTxInfo()) && gw_gw_pb.UplinkTXInfo.toObject(includeInstance, f),
|
|
dr: jspb.Message.getFieldWithDefault(msg, 8, 0),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.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.integration.JoinEvent}
|
|
*/
|
|
proto.integration.JoinEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.JoinEvent;
|
|
return proto.integration.JoinEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.JoinEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.JoinEvent}
|
|
*/
|
|
proto.integration.JoinEvent.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.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevAddr(value);
|
|
break;
|
|
case 6:
|
|
var value = new gw_gw_pb.UplinkRXInfo;
|
|
reader.readMessage(value,gw_gw_pb.UplinkRXInfo.deserializeBinaryFromReader);
|
|
msg.addRxInfo(value);
|
|
break;
|
|
case 7:
|
|
var value = new gw_gw_pb.UplinkTXInfo;
|
|
reader.readMessage(value,gw_gw_pb.UplinkTXInfo.deserializeBinaryFromReader);
|
|
msg.setTxInfo(value);
|
|
break;
|
|
case 8:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setDr(value);
|
|
break;
|
|
case 9:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 10:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.JoinEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.JoinEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.JoinEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevAddr();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
5,
|
|
f
|
|
);
|
|
}
|
|
f = message.getRxInfoList();
|
|
if (f.length > 0) {
|
|
writer.writeRepeatedMessage(
|
|
6,
|
|
f,
|
|
gw_gw_pb.UplinkRXInfo.serializeBinaryToWriter
|
|
);
|
|
}
|
|
f = message.getTxInfo();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
7,
|
|
f,
|
|
gw_gw_pb.UplinkTXInfo.serializeBinaryToWriter
|
|
);
|
|
}
|
|
f = message.getDr();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
8,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(9, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
10,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_id = 1;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getApplicationId = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_addr = 5;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getDevAddr = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setDevAddr = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 5, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* repeated gw.UplinkRXInfo rx_info = 6;
|
|
* @return {!Array<!proto.gw.UplinkRXInfo>}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getRxInfoList = function() {
|
|
return /** @type{!Array<!proto.gw.UplinkRXInfo>} */ (
|
|
jspb.Message.getRepeatedWrapperField(this, gw_gw_pb.UplinkRXInfo, 6));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {!Array<!proto.gw.UplinkRXInfo>} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setRxInfoList = function(value) {
|
|
return jspb.Message.setRepeatedWrapperField(this, 6, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {!proto.gw.UplinkRXInfo=} opt_value
|
|
* @param {number=} opt_index
|
|
* @return {!proto.gw.UplinkRXInfo}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.addRxInfo = function(opt_value, opt_index) {
|
|
return jspb.Message.addToRepeatedWrapperField(this, 6, opt_value, proto.gw.UplinkRXInfo, opt_index);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the list making it empty but non-null.
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.clearRxInfoList = function() {
|
|
return this.setRxInfoList([]);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional gw.UplinkTXInfo tx_info = 7;
|
|
* @return {?proto.gw.UplinkTXInfo}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getTxInfo = function() {
|
|
return /** @type{?proto.gw.UplinkTXInfo} */ (
|
|
jspb.Message.getWrapperField(this, gw_gw_pb.UplinkTXInfo, 7));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.gw.UplinkTXInfo|undefined} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setTxInfo = function(value) {
|
|
return jspb.Message.setWrapperField(this, 7, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.clearTxInfo = function() {
|
|
return this.setTxInfo(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.hasTxInfo = function() {
|
|
return jspb.Message.getField(this, 7) != null;
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 dr = 8;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getDr = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 8, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setDr = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 8, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 9;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 9, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 10;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 10));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 10, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.JoinEvent} returns this
|
|
*/
|
|
proto.integration.JoinEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.JoinEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 10) != 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.integration.AckEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.AckEvent.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.integration.AckEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.AckEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
acknowledged: jspb.Message.getBooleanFieldWithDefault(msg, 5, false),
|
|
fCnt: jspb.Message.getFieldWithDefault(msg, 6, 0),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.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.integration.AckEvent}
|
|
*/
|
|
proto.integration.AckEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.AckEvent;
|
|
return proto.integration.AckEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.AckEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.AckEvent}
|
|
*/
|
|
proto.integration.AckEvent.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.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = /** @type {boolean} */ (reader.readBool());
|
|
msg.setAcknowledged(value);
|
|
break;
|
|
case 6:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setFCnt(value);
|
|
break;
|
|
case 7:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 8:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.AckEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.AckEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.AckEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.AckEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getAcknowledged();
|
|
if (f) {
|
|
writer.writeBool(
|
|
5,
|
|
f
|
|
);
|
|
}
|
|
f = message.getFCnt();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
6,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(7, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
8,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_id = 1;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getApplicationId = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional bool acknowledged = 5;
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getAcknowledged = function() {
|
|
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 5, false));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {boolean} value
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.setAcknowledged = function(value) {
|
|
return jspb.Message.setProto3BooleanField(this, 5, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 f_cnt = 6;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getFCnt = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.setFCnt = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 6, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 7;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 7, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 8;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.AckEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 8));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 8, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.AckEvent} returns this
|
|
*/
|
|
proto.integration.AckEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.AckEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 8) != 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.integration.TxAckEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.TxAckEvent.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.integration.TxAckEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.TxAckEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, 0),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
fCnt: jspb.Message.getFieldWithDefault(msg, 5, 0),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
gatewayId: jspb.Message.getFieldWithDefault(msg, 7, ""),
|
|
txInfo: (f = msg.getTxInfo()) && gw_gw_pb.DownlinkTXInfo.toObject(includeInstance, f),
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.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.integration.TxAckEvent}
|
|
*/
|
|
proto.integration.TxAckEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.TxAckEvent;
|
|
return proto.integration.TxAckEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.TxAckEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.TxAckEvent}
|
|
*/
|
|
proto.integration.TxAckEvent.deserializeBinaryFromReader = function(msg, reader) {
|
|
while (reader.nextField()) {
|
|
if (reader.isEndGroup()) {
|
|
break;
|
|
}
|
|
var field = reader.getFieldNumber();
|
|
switch (field) {
|
|
case 1:
|
|
var value = /** @type {number} */ (reader.readUint64());
|
|
msg.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setFCnt(value);
|
|
break;
|
|
case 6:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 7:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setGatewayId(value);
|
|
break;
|
|
case 8:
|
|
var value = new gw_gw_pb.DownlinkTXInfo;
|
|
reader.readMessage(value,gw_gw_pb.DownlinkTXInfo.deserializeBinaryFromReader);
|
|
msg.setTxInfo(value);
|
|
break;
|
|
case 9:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.TxAckEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.TxAckEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.TxAckEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f !== 0) {
|
|
writer.writeUint64(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getFCnt();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
5,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(6, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getGatewayId();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
7,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTxInfo();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
8,
|
|
f,
|
|
gw_gw_pb.DownlinkTXInfo.serializeBinaryToWriter
|
|
);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
9,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint64 application_id = 1;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getApplicationId = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 f_cnt = 5;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getFCnt = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setFCnt = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 5, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 6;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 6, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* optional string gateway_id = 7;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getGatewayId = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setGatewayId = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 7, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional gw.DownlinkTXInfo tx_info = 8;
|
|
* @return {?proto.gw.DownlinkTXInfo}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getTxInfo = function() {
|
|
return /** @type{?proto.gw.DownlinkTXInfo} */ (
|
|
jspb.Message.getWrapperField(this, gw_gw_pb.DownlinkTXInfo, 8));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.gw.DownlinkTXInfo|undefined} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setTxInfo = function(value) {
|
|
return jspb.Message.setWrapperField(this, 8, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.clearTxInfo = function() {
|
|
return this.setTxInfo(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.hasTxInfo = function() {
|
|
return jspb.Message.getField(this, 8) != null;
|
|
};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 9;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 9));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 9, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.TxAckEvent} returns this
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.TxAckEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 9) != 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.integration.ErrorEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.ErrorEvent.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.integration.ErrorEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.ErrorEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, 0),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
type: jspb.Message.getFieldWithDefault(msg, 5, 0),
|
|
error: jspb.Message.getFieldWithDefault(msg, 6, ""),
|
|
fCnt: jspb.Message.getFieldWithDefault(msg, 7, 0),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.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.integration.ErrorEvent}
|
|
*/
|
|
proto.integration.ErrorEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.ErrorEvent;
|
|
return proto.integration.ErrorEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.ErrorEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.ErrorEvent}
|
|
*/
|
|
proto.integration.ErrorEvent.deserializeBinaryFromReader = function(msg, reader) {
|
|
while (reader.nextField()) {
|
|
if (reader.isEndGroup()) {
|
|
break;
|
|
}
|
|
var field = reader.getFieldNumber();
|
|
switch (field) {
|
|
case 1:
|
|
var value = /** @type {number} */ (reader.readUint64());
|
|
msg.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = /** @type {!proto.integration.ErrorType} */ (reader.readEnum());
|
|
msg.setType(value);
|
|
break;
|
|
case 6:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setError(value);
|
|
break;
|
|
case 7:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setFCnt(value);
|
|
break;
|
|
case 8:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 9:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.ErrorEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.ErrorEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.ErrorEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f !== 0) {
|
|
writer.writeUint64(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getType();
|
|
if (f !== 0.0) {
|
|
writer.writeEnum(
|
|
5,
|
|
f
|
|
);
|
|
}
|
|
f = message.getError();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
6,
|
|
f
|
|
);
|
|
}
|
|
f = message.getFCnt();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
7,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(8, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
9,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint64 application_id = 1;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getApplicationId = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional ErrorType type = 5;
|
|
* @return {!proto.integration.ErrorType}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getType = function() {
|
|
return /** @type {!proto.integration.ErrorType} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {!proto.integration.ErrorType} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setType = function(value) {
|
|
return jspb.Message.setProto3EnumField(this, 5, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string error = 6;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getError = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setError = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 6, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 f_cnt = 7;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getFCnt = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 7, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setFCnt = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 7, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 8;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 8, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 9;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 9));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 9, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.ErrorEvent} returns this
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.ErrorEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 9) != 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.integration.StatusEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.StatusEvent.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.integration.StatusEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.StatusEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, 0),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
margin: jspb.Message.getFieldWithDefault(msg, 5, 0),
|
|
externalPowerSource: jspb.Message.getBooleanFieldWithDefault(msg, 6, false),
|
|
batteryLevelUnavailable: jspb.Message.getBooleanFieldWithDefault(msg, 7, false),
|
|
batteryLevel: jspb.Message.getFloatingPointFieldWithDefault(msg, 8, 0.0),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.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.integration.StatusEvent}
|
|
*/
|
|
proto.integration.StatusEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.StatusEvent;
|
|
return proto.integration.StatusEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.StatusEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.StatusEvent}
|
|
*/
|
|
proto.integration.StatusEvent.deserializeBinaryFromReader = function(msg, reader) {
|
|
while (reader.nextField()) {
|
|
if (reader.isEndGroup()) {
|
|
break;
|
|
}
|
|
var field = reader.getFieldNumber();
|
|
switch (field) {
|
|
case 1:
|
|
var value = /** @type {number} */ (reader.readUint64());
|
|
msg.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = /** @type {number} */ (reader.readInt32());
|
|
msg.setMargin(value);
|
|
break;
|
|
case 6:
|
|
var value = /** @type {boolean} */ (reader.readBool());
|
|
msg.setExternalPowerSource(value);
|
|
break;
|
|
case 7:
|
|
var value = /** @type {boolean} */ (reader.readBool());
|
|
msg.setBatteryLevelUnavailable(value);
|
|
break;
|
|
case 8:
|
|
var value = /** @type {number} */ (reader.readFloat());
|
|
msg.setBatteryLevel(value);
|
|
break;
|
|
case 9:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 10:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.StatusEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.StatusEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.StatusEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f !== 0) {
|
|
writer.writeUint64(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getMargin();
|
|
if (f !== 0) {
|
|
writer.writeInt32(
|
|
5,
|
|
f
|
|
);
|
|
}
|
|
f = message.getExternalPowerSource();
|
|
if (f) {
|
|
writer.writeBool(
|
|
6,
|
|
f
|
|
);
|
|
}
|
|
f = message.getBatteryLevelUnavailable();
|
|
if (f) {
|
|
writer.writeBool(
|
|
7,
|
|
f
|
|
);
|
|
}
|
|
f = message.getBatteryLevel();
|
|
if (f !== 0.0) {
|
|
writer.writeFloat(
|
|
8,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(9, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
10,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint64 application_id = 1;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getApplicationId = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional int32 margin = 5;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getMargin = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setMargin = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 5, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional bool external_power_source = 6;
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getExternalPowerSource = function() {
|
|
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 6, false));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {boolean} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setExternalPowerSource = function(value) {
|
|
return jspb.Message.setProto3BooleanField(this, 6, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional bool battery_level_unavailable = 7;
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getBatteryLevelUnavailable = function() {
|
|
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 7, false));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {boolean} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setBatteryLevelUnavailable = function(value) {
|
|
return jspb.Message.setProto3BooleanField(this, 7, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional float battery_level = 8;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getBatteryLevel = function() {
|
|
return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 8, 0.0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setBatteryLevel = function(value) {
|
|
return jspb.Message.setProto3FloatField(this, 8, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 9;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 9, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 10;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 10));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 10, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.StatusEvent} returns this
|
|
*/
|
|
proto.integration.StatusEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.StatusEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 10) != null;
|
|
};
|
|
|
|
|
|
|
|
/**
|
|
* List of repeated fields within this message type.
|
|
* @private {!Array<number>}
|
|
* @const
|
|
*/
|
|
proto.integration.LocationEvent.repeatedFields_ = [7];
|
|
|
|
|
|
|
|
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.integration.LocationEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.LocationEvent.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.integration.LocationEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.LocationEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, 0),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
location: (f = msg.getLocation()) && common_common_pb.Location.toObject(includeInstance, f),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
uplinkIdsList: (f = jspb.Message.getRepeatedField(msg, 7)) == null ? undefined : f,
|
|
fCnt: jspb.Message.getFieldWithDefault(msg, 8, 0),
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.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.integration.LocationEvent}
|
|
*/
|
|
proto.integration.LocationEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.LocationEvent;
|
|
return proto.integration.LocationEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.LocationEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.LocationEvent}
|
|
*/
|
|
proto.integration.LocationEvent.deserializeBinaryFromReader = function(msg, reader) {
|
|
while (reader.nextField()) {
|
|
if (reader.isEndGroup()) {
|
|
break;
|
|
}
|
|
var field = reader.getFieldNumber();
|
|
switch (field) {
|
|
case 1:
|
|
var value = /** @type {number} */ (reader.readUint64());
|
|
msg.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = new common_common_pb.Location;
|
|
reader.readMessage(value,common_common_pb.Location.deserializeBinaryFromReader);
|
|
msg.setLocation(value);
|
|
break;
|
|
case 6:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 7:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.addUplinkIds(value);
|
|
break;
|
|
case 8:
|
|
var value = /** @type {number} */ (reader.readUint32());
|
|
msg.setFCnt(value);
|
|
break;
|
|
case 9:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.LocationEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.LocationEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.LocationEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f !== 0) {
|
|
writer.writeUint64(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getLocation();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
5,
|
|
f,
|
|
common_common_pb.Location.serializeBinaryToWriter
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(6, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getUplinkIdsList();
|
|
if (f.length > 0) {
|
|
writer.writeRepeatedString(
|
|
7,
|
|
f
|
|
);
|
|
}
|
|
f = message.getFCnt();
|
|
if (f !== 0) {
|
|
writer.writeUint32(
|
|
8,
|
|
f
|
|
);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
9,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint64 application_id = 1;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getApplicationId = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional common.Location location = 5;
|
|
* @return {?proto.common.Location}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getLocation = function() {
|
|
return /** @type{?proto.common.Location} */ (
|
|
jspb.Message.getWrapperField(this, common_common_pb.Location, 5));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.common.Location|undefined} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setLocation = function(value) {
|
|
return jspb.Message.setWrapperField(this, 5, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.clearLocation = function() {
|
|
return this.setLocation(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.hasLocation = function() {
|
|
return jspb.Message.getField(this, 5) != null;
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 6;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 6, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* repeated string uplink_ids = 7;
|
|
* @return {!Array<string>}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getUplinkIdsList = function() {
|
|
return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 7));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {!Array<string>} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setUplinkIdsList = function(value) {
|
|
return jspb.Message.setField(this, 7, value || []);
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @param {number=} opt_index
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.addUplinkIds = function(value, opt_index) {
|
|
return jspb.Message.addToRepeatedField(this, 7, value, opt_index);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the list making it empty but non-null.
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.clearUplinkIdsList = function() {
|
|
return this.setUplinkIdsList([]);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint32 f_cnt = 8;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getFCnt = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 8, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setFCnt = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 8, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 9;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 9));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 9, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.LocationEvent} returns this
|
|
*/
|
|
proto.integration.LocationEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.LocationEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 9) != 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.integration.IntegrationEvent.prototype.toObject = function(opt_includeInstance) {
|
|
return proto.integration.IntegrationEvent.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.integration.IntegrationEvent} msg The msg instance to transform.
|
|
* @return {!Object}
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.IntegrationEvent.toObject = function(includeInstance, msg) {
|
|
var f, obj = {
|
|
applicationId: jspb.Message.getFieldWithDefault(msg, 1, 0),
|
|
applicationName: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
|
deviceName: jspb.Message.getFieldWithDefault(msg, 3, ""),
|
|
devEui: jspb.Message.getFieldWithDefault(msg, 4, ""),
|
|
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
|
|
integrationName: jspb.Message.getFieldWithDefault(msg, 6, ""),
|
|
eventType: jspb.Message.getFieldWithDefault(msg, 7, ""),
|
|
objectJson: jspb.Message.getFieldWithDefault(msg, 8, ""),
|
|
publishedAt: (f = msg.getPublishedAt()) && google_protobuf_timestamp_pb.Timestamp.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.integration.IntegrationEvent}
|
|
*/
|
|
proto.integration.IntegrationEvent.deserializeBinary = function(bytes) {
|
|
var reader = new jspb.BinaryReader(bytes);
|
|
var msg = new proto.integration.IntegrationEvent;
|
|
return proto.integration.IntegrationEvent.deserializeBinaryFromReader(msg, reader);
|
|
};
|
|
|
|
|
|
/**
|
|
* Deserializes binary data (in protobuf wire format) from the
|
|
* given reader into the given message object.
|
|
* @param {!proto.integration.IntegrationEvent} msg The message object to deserialize into.
|
|
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
|
* @return {!proto.integration.IntegrationEvent}
|
|
*/
|
|
proto.integration.IntegrationEvent.deserializeBinaryFromReader = function(msg, reader) {
|
|
while (reader.nextField()) {
|
|
if (reader.isEndGroup()) {
|
|
break;
|
|
}
|
|
var field = reader.getFieldNumber();
|
|
switch (field) {
|
|
case 1:
|
|
var value = /** @type {number} */ (reader.readUint64());
|
|
msg.setApplicationId(value);
|
|
break;
|
|
case 2:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setApplicationName(value);
|
|
break;
|
|
case 3:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDeviceName(value);
|
|
break;
|
|
case 4:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setDevEui(value);
|
|
break;
|
|
case 5:
|
|
var value = msg.getTagsMap();
|
|
reader.readMessage(value, function(message, reader) {
|
|
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readString, null, "", "");
|
|
});
|
|
break;
|
|
case 6:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setIntegrationName(value);
|
|
break;
|
|
case 7:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setEventType(value);
|
|
break;
|
|
case 8:
|
|
var value = /** @type {string} */ (reader.readString());
|
|
msg.setObjectJson(value);
|
|
break;
|
|
case 9:
|
|
var value = new google_protobuf_timestamp_pb.Timestamp;
|
|
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
|
|
msg.setPublishedAt(value);
|
|
break;
|
|
default:
|
|
reader.skipField();
|
|
break;
|
|
}
|
|
}
|
|
return msg;
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the message to binary data (in protobuf wire format).
|
|
* @return {!Uint8Array}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.serializeBinary = function() {
|
|
var writer = new jspb.BinaryWriter();
|
|
proto.integration.IntegrationEvent.serializeBinaryToWriter(this, writer);
|
|
return writer.getResultBuffer();
|
|
};
|
|
|
|
|
|
/**
|
|
* Serializes the given message to binary data (in protobuf wire
|
|
* format), writing to the given BinaryWriter.
|
|
* @param {!proto.integration.IntegrationEvent} message
|
|
* @param {!jspb.BinaryWriter} writer
|
|
* @suppress {unusedLocalVariables} f is only used for nested messages
|
|
*/
|
|
proto.integration.IntegrationEvent.serializeBinaryToWriter = function(message, writer) {
|
|
var f = undefined;
|
|
f = message.getApplicationId();
|
|
if (f !== 0) {
|
|
writer.writeUint64(
|
|
1,
|
|
f
|
|
);
|
|
}
|
|
f = message.getApplicationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
2,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDeviceName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
3,
|
|
f
|
|
);
|
|
}
|
|
f = message.getDevEui();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
4,
|
|
f
|
|
);
|
|
}
|
|
f = message.getTagsMap(true);
|
|
if (f && f.getLength() > 0) {
|
|
f.serializeBinary(5, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
|
|
}
|
|
f = message.getIntegrationName();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
6,
|
|
f
|
|
);
|
|
}
|
|
f = message.getEventType();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
7,
|
|
f
|
|
);
|
|
}
|
|
f = message.getObjectJson();
|
|
if (f.length > 0) {
|
|
writer.writeString(
|
|
8,
|
|
f
|
|
);
|
|
}
|
|
f = message.getPublishedAt();
|
|
if (f != null) {
|
|
writer.writeMessage(
|
|
9,
|
|
f,
|
|
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
|
|
);
|
|
}
|
|
};
|
|
|
|
|
|
/**
|
|
* optional uint64 application_id = 1;
|
|
* @return {number}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getApplicationId = function() {
|
|
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {number} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setApplicationId = function(value) {
|
|
return jspb.Message.setProto3IntField(this, 1, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string application_name = 2;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getApplicationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setApplicationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 2, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string device_name = 3;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getDeviceName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setDeviceName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 3, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string dev_eui = 4;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getDevEui = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setDevEui = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 4, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* map<string, string> tags = 5;
|
|
* @param {boolean=} opt_noLazyCreate Do not create the map if
|
|
* empty, instead returning `undefined`
|
|
* @return {!jspb.Map<string,string>}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getTagsMap = function(opt_noLazyCreate) {
|
|
return /** @type {!jspb.Map<string,string>} */ (
|
|
jspb.Message.getMapField(this, 5, opt_noLazyCreate,
|
|
null));
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears values from the map. The map will be non-null.
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.clearTagsMap = function() {
|
|
this.getTagsMap().clear();
|
|
return this;};
|
|
|
|
|
|
/**
|
|
* optional string integration_name = 6;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getIntegrationName = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setIntegrationName = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 6, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string event_type = 7;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getEventType = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setEventType = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 7, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional string object_json = 8;
|
|
* @return {string}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getObjectJson = function() {
|
|
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 8, ""));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {string} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setObjectJson = function(value) {
|
|
return jspb.Message.setProto3StringField(this, 8, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* optional google.protobuf.Timestamp published_at = 9;
|
|
* @return {?proto.google.protobuf.Timestamp}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.getPublishedAt = function() {
|
|
return /** @type{?proto.google.protobuf.Timestamp} */ (
|
|
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 9));
|
|
};
|
|
|
|
|
|
/**
|
|
* @param {?proto.google.protobuf.Timestamp|undefined} value
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.setPublishedAt = function(value) {
|
|
return jspb.Message.setWrapperField(this, 9, value);
|
|
};
|
|
|
|
|
|
/**
|
|
* Clears the message field making it undefined.
|
|
* @return {!proto.integration.IntegrationEvent} returns this
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.clearPublishedAt = function() {
|
|
return this.setPublishedAt(undefined);
|
|
};
|
|
|
|
|
|
/**
|
|
* Returns whether this field is set.
|
|
* @return {boolean}
|
|
*/
|
|
proto.integration.IntegrationEvent.prototype.hasPublishedAt = function() {
|
|
return jspb.Message.getField(this, 9) != null;
|
|
};
|
|
|
|
|
|
/**
|
|
* @enum {number}
|
|
*/
|
|
proto.integration.ErrorType = {
|
|
UNKNOWN: 0,
|
|
DOWNLINK_PAYLOAD_SIZE: 1,
|
|
DOWNLINK_FCNT: 2,
|
|
UPLINK_CODEC: 3,
|
|
DOWNLINK_CODEC: 4,
|
|
OTAA: 5,
|
|
UPLINK_FCNT_RESET: 6,
|
|
UPLINK_MIC: 7,
|
|
UPLINK_FCNT_RETRANSMISSION: 8,
|
|
DOWNLINK_GATEWAY: 9
|
|
};
|
|
|
|
goog.object.extend(exports, proto.integration);
|