chirpstack/api/grpc-web/api/device_profile_pb.js
Orne Brocaar 36ec11d175 Annotate gRPC methods for REST interface gen.
The option(google.api.http) annotations can be used by for example
https://github.com/grpc-ecosystem/grpc-gateway to generate a gRPC to
REST proxy.
2022-07-13 12:18:46 +01:00

3558 lines
102 KiB
JavaScript
Vendored

// source: api/device_profile.proto
/**
* @fileoverview
* @enhanceable
* @suppress {missingRequire} reports error on implicit type usages.
* @suppress {messageConventions} JS Compiler reports an error if a variable or
* field starts with 'MSG_' and isn't a translatable message.
* @public
*/
// GENERATED CODE -- DO NOT EDIT!
/* eslint-disable */
// @ts-nocheck
var jspb = require('google-protobuf');
var goog = jspb;
var global = Function('return this')();
var google_api_annotations_pb = require('../google/api/annotations_pb.js');
goog.object.extend(proto, google_api_annotations_pb);
var google_protobuf_timestamp_pb = require('google-protobuf/google/protobuf/timestamp_pb.js');
goog.object.extend(proto, google_protobuf_timestamp_pb);
var google_protobuf_empty_pb = require('google-protobuf/google/protobuf/empty_pb.js');
goog.object.extend(proto, google_protobuf_empty_pb);
var common_common_pb = require('../common/common_pb.js');
goog.object.extend(proto, common_common_pb);
goog.exportSymbol('proto.api.AdrAlgorithmListItem', null, global);
goog.exportSymbol('proto.api.CodecRuntime', null, global);
goog.exportSymbol('proto.api.CreateDeviceProfileRequest', null, global);
goog.exportSymbol('proto.api.CreateDeviceProfileResponse', null, global);
goog.exportSymbol('proto.api.DeleteDeviceProfileRequest', null, global);
goog.exportSymbol('proto.api.DeviceProfile', null, global);
goog.exportSymbol('proto.api.DeviceProfileListItem', null, global);
goog.exportSymbol('proto.api.GetDeviceProfileRequest', null, global);
goog.exportSymbol('proto.api.GetDeviceProfileResponse', null, global);
goog.exportSymbol('proto.api.ListDeviceProfileAdrAlgorithmsResponse', null, global);
goog.exportSymbol('proto.api.ListDeviceProfilesRequest', null, global);
goog.exportSymbol('proto.api.ListDeviceProfilesResponse', null, global);
goog.exportSymbol('proto.api.Measurement', null, global);
goog.exportSymbol('proto.api.MeasurementKind', null, global);
goog.exportSymbol('proto.api.UpdateDeviceProfileRequest', 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.api.DeviceProfile = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.DeviceProfile, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.DeviceProfile.displayName = 'proto.api.DeviceProfile';
}
/**
* 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.api.Measurement = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.Measurement, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.Measurement.displayName = 'proto.api.Measurement';
}
/**
* 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.api.DeviceProfileListItem = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.DeviceProfileListItem, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.DeviceProfileListItem.displayName = 'proto.api.DeviceProfileListItem';
}
/**
* 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.api.CreateDeviceProfileRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.CreateDeviceProfileRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.CreateDeviceProfileRequest.displayName = 'proto.api.CreateDeviceProfileRequest';
}
/**
* 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.api.CreateDeviceProfileResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.CreateDeviceProfileResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.CreateDeviceProfileResponse.displayName = 'proto.api.CreateDeviceProfileResponse';
}
/**
* 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.api.GetDeviceProfileRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.GetDeviceProfileRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.GetDeviceProfileRequest.displayName = 'proto.api.GetDeviceProfileRequest';
}
/**
* 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.api.GetDeviceProfileResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.GetDeviceProfileResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.GetDeviceProfileResponse.displayName = 'proto.api.GetDeviceProfileResponse';
}
/**
* 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.api.UpdateDeviceProfileRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.UpdateDeviceProfileRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.UpdateDeviceProfileRequest.displayName = 'proto.api.UpdateDeviceProfileRequest';
}
/**
* 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.api.DeleteDeviceProfileRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.DeleteDeviceProfileRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.DeleteDeviceProfileRequest.displayName = 'proto.api.DeleteDeviceProfileRequest';
}
/**
* 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.api.ListDeviceProfilesRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.ListDeviceProfilesRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.ListDeviceProfilesRequest.displayName = 'proto.api.ListDeviceProfilesRequest';
}
/**
* 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.api.ListDeviceProfilesResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.api.ListDeviceProfilesResponse.repeatedFields_, null);
};
goog.inherits(proto.api.ListDeviceProfilesResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.ListDeviceProfilesResponse.displayName = 'proto.api.ListDeviceProfilesResponse';
}
/**
* 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.api.ListDeviceProfileAdrAlgorithmsResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.api.ListDeviceProfileAdrAlgorithmsResponse.repeatedFields_, null);
};
goog.inherits(proto.api.ListDeviceProfileAdrAlgorithmsResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.displayName = 'proto.api.ListDeviceProfileAdrAlgorithmsResponse';
}
/**
* 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.api.AdrAlgorithmListItem = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.AdrAlgorithmListItem, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.AdrAlgorithmListItem.displayName = 'proto.api.AdrAlgorithmListItem';
}
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.api.DeviceProfile.prototype.toObject = function(opt_includeInstance) {
return proto.api.DeviceProfile.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.api.DeviceProfile} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.DeviceProfile.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, ""),
tenantId: jspb.Message.getFieldWithDefault(msg, 2, ""),
name: jspb.Message.getFieldWithDefault(msg, 3, ""),
description: jspb.Message.getFieldWithDefault(msg, 26, ""),
region: jspb.Message.getFieldWithDefault(msg, 4, 0),
macVersion: jspb.Message.getFieldWithDefault(msg, 5, 0),
regParamsRevision: jspb.Message.getFieldWithDefault(msg, 6, 0),
adrAlgorithmId: jspb.Message.getFieldWithDefault(msg, 7, ""),
payloadCodecRuntime: jspb.Message.getFieldWithDefault(msg, 8, 0),
payloadCodecScript: jspb.Message.getFieldWithDefault(msg, 9, ""),
flushQueueOnActivate: jspb.Message.getBooleanFieldWithDefault(msg, 10, false),
uplinkInterval: jspb.Message.getFieldWithDefault(msg, 11, 0),
deviceStatusReqInterval: jspb.Message.getFieldWithDefault(msg, 12, 0),
supportsOtaa: jspb.Message.getBooleanFieldWithDefault(msg, 13, false),
supportsClassB: jspb.Message.getBooleanFieldWithDefault(msg, 14, false),
supportsClassC: jspb.Message.getBooleanFieldWithDefault(msg, 15, false),
classBTimeout: jspb.Message.getFieldWithDefault(msg, 16, 0),
classBPingSlotPeriod: jspb.Message.getFieldWithDefault(msg, 17, 0),
classBPingSlotDr: jspb.Message.getFieldWithDefault(msg, 18, 0),
classBPingSlotFreq: jspb.Message.getFieldWithDefault(msg, 19, 0),
classCTimeout: jspb.Message.getFieldWithDefault(msg, 20, 0),
abpRx1Delay: jspb.Message.getFieldWithDefault(msg, 21, 0),
abpRx1DrOffset: jspb.Message.getFieldWithDefault(msg, 22, 0),
abpRx2Dr: jspb.Message.getFieldWithDefault(msg, 23, 0),
abpRx2Freq: jspb.Message.getFieldWithDefault(msg, 24, 0),
tagsMap: (f = msg.getTagsMap()) ? f.toObject(includeInstance, undefined) : [],
measurementsMap: (f = msg.getMeasurementsMap()) ? f.toObject(includeInstance, proto.api.Measurement.toObject) : []
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.DeviceProfile}
*/
proto.api.DeviceProfile.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.DeviceProfile;
return proto.api.DeviceProfile.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.DeviceProfile} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.DeviceProfile}
*/
proto.api.DeviceProfile.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.setId(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setTenantId(value);
break;
case 3:
var value = /** @type {string} */ (reader.readString());
msg.setName(value);
break;
case 26:
var value = /** @type {string} */ (reader.readString());
msg.setDescription(value);
break;
case 4:
var value = /** @type {!proto.common.Region} */ (reader.readEnum());
msg.setRegion(value);
break;
case 5:
var value = /** @type {!proto.common.MacVersion} */ (reader.readEnum());
msg.setMacVersion(value);
break;
case 6:
var value = /** @type {!proto.common.RegParamsRevision} */ (reader.readEnum());
msg.setRegParamsRevision(value);
break;
case 7:
var value = /** @type {string} */ (reader.readString());
msg.setAdrAlgorithmId(value);
break;
case 8:
var value = /** @type {!proto.api.CodecRuntime} */ (reader.readEnum());
msg.setPayloadCodecRuntime(value);
break;
case 9:
var value = /** @type {string} */ (reader.readString());
msg.setPayloadCodecScript(value);
break;
case 10:
var value = /** @type {boolean} */ (reader.readBool());
msg.setFlushQueueOnActivate(value);
break;
case 11:
var value = /** @type {number} */ (reader.readUint32());
msg.setUplinkInterval(value);
break;
case 12:
var value = /** @type {number} */ (reader.readUint32());
msg.setDeviceStatusReqInterval(value);
break;
case 13:
var value = /** @type {boolean} */ (reader.readBool());
msg.setSupportsOtaa(value);
break;
case 14:
var value = /** @type {boolean} */ (reader.readBool());
msg.setSupportsClassB(value);
break;
case 15:
var value = /** @type {boolean} */ (reader.readBool());
msg.setSupportsClassC(value);
break;
case 16:
var value = /** @type {number} */ (reader.readUint32());
msg.setClassBTimeout(value);
break;
case 17:
var value = /** @type {number} */ (reader.readUint32());
msg.setClassBPingSlotPeriod(value);
break;
case 18:
var value = /** @type {number} */ (reader.readUint32());
msg.setClassBPingSlotDr(value);
break;
case 19:
var value = /** @type {number} */ (reader.readUint32());
msg.setClassBPingSlotFreq(value);
break;
case 20:
var value = /** @type {number} */ (reader.readUint32());
msg.setClassCTimeout(value);
break;
case 21:
var value = /** @type {number} */ (reader.readUint32());
msg.setAbpRx1Delay(value);
break;
case 22:
var value = /** @type {number} */ (reader.readUint32());
msg.setAbpRx1DrOffset(value);
break;
case 23:
var value = /** @type {number} */ (reader.readUint32());
msg.setAbpRx2Dr(value);
break;
case 24:
var value = /** @type {number} */ (reader.readUint32());
msg.setAbpRx2Freq(value);
break;
case 25:
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 27:
var value = msg.getMeasurementsMap();
reader.readMessage(value, function(message, reader) {
jspb.Map.deserializeBinary(message, reader, jspb.BinaryReader.prototype.readString, jspb.BinaryReader.prototype.readMessage, proto.api.Measurement.deserializeBinaryFromReader, "", new proto.api.Measurement());
});
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.DeviceProfile.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.DeviceProfile.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.DeviceProfile} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.DeviceProfile.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getTenantId();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
f = message.getName();
if (f.length > 0) {
writer.writeString(
3,
f
);
}
f = message.getDescription();
if (f.length > 0) {
writer.writeString(
26,
f
);
}
f = message.getRegion();
if (f !== 0.0) {
writer.writeEnum(
4,
f
);
}
f = message.getMacVersion();
if (f !== 0.0) {
writer.writeEnum(
5,
f
);
}
f = message.getRegParamsRevision();
if (f !== 0.0) {
writer.writeEnum(
6,
f
);
}
f = message.getAdrAlgorithmId();
if (f.length > 0) {
writer.writeString(
7,
f
);
}
f = message.getPayloadCodecRuntime();
if (f !== 0.0) {
writer.writeEnum(
8,
f
);
}
f = message.getPayloadCodecScript();
if (f.length > 0) {
writer.writeString(
9,
f
);
}
f = message.getFlushQueueOnActivate();
if (f) {
writer.writeBool(
10,
f
);
}
f = message.getUplinkInterval();
if (f !== 0) {
writer.writeUint32(
11,
f
);
}
f = message.getDeviceStatusReqInterval();
if (f !== 0) {
writer.writeUint32(
12,
f
);
}
f = message.getSupportsOtaa();
if (f) {
writer.writeBool(
13,
f
);
}
f = message.getSupportsClassB();
if (f) {
writer.writeBool(
14,
f
);
}
f = message.getSupportsClassC();
if (f) {
writer.writeBool(
15,
f
);
}
f = message.getClassBTimeout();
if (f !== 0) {
writer.writeUint32(
16,
f
);
}
f = message.getClassBPingSlotPeriod();
if (f !== 0) {
writer.writeUint32(
17,
f
);
}
f = message.getClassBPingSlotDr();
if (f !== 0) {
writer.writeUint32(
18,
f
);
}
f = message.getClassBPingSlotFreq();
if (f !== 0) {
writer.writeUint32(
19,
f
);
}
f = message.getClassCTimeout();
if (f !== 0) {
writer.writeUint32(
20,
f
);
}
f = message.getAbpRx1Delay();
if (f !== 0) {
writer.writeUint32(
21,
f
);
}
f = message.getAbpRx1DrOffset();
if (f !== 0) {
writer.writeUint32(
22,
f
);
}
f = message.getAbpRx2Dr();
if (f !== 0) {
writer.writeUint32(
23,
f
);
}
f = message.getAbpRx2Freq();
if (f !== 0) {
writer.writeUint32(
24,
f
);
}
f = message.getTagsMap(true);
if (f && f.getLength() > 0) {
f.serializeBinary(25, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeString);
}
f = message.getMeasurementsMap(true);
if (f && f.getLength() > 0) {
f.serializeBinary(27, writer, jspb.BinaryWriter.prototype.writeString, jspb.BinaryWriter.prototype.writeMessage, proto.api.Measurement.serializeBinaryToWriter);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.api.DeviceProfile.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string tenant_id = 2;
* @return {string}
*/
proto.api.DeviceProfile.prototype.getTenantId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setTenantId = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
/**
* optional string name = 3;
* @return {string}
*/
proto.api.DeviceProfile.prototype.getName = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setName = function(value) {
return jspb.Message.setProto3StringField(this, 3, value);
};
/**
* optional string description = 26;
* @return {string}
*/
proto.api.DeviceProfile.prototype.getDescription = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 26, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setDescription = function(value) {
return jspb.Message.setProto3StringField(this, 26, value);
};
/**
* optional common.Region region = 4;
* @return {!proto.common.Region}
*/
proto.api.DeviceProfile.prototype.getRegion = function() {
return /** @type {!proto.common.Region} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
};
/**
* @param {!proto.common.Region} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setRegion = function(value) {
return jspb.Message.setProto3EnumField(this, 4, value);
};
/**
* optional common.MacVersion mac_version = 5;
* @return {!proto.common.MacVersion}
*/
proto.api.DeviceProfile.prototype.getMacVersion = function() {
return /** @type {!proto.common.MacVersion} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
};
/**
* @param {!proto.common.MacVersion} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setMacVersion = function(value) {
return jspb.Message.setProto3EnumField(this, 5, value);
};
/**
* optional common.RegParamsRevision reg_params_revision = 6;
* @return {!proto.common.RegParamsRevision}
*/
proto.api.DeviceProfile.prototype.getRegParamsRevision = function() {
return /** @type {!proto.common.RegParamsRevision} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
};
/**
* @param {!proto.common.RegParamsRevision} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setRegParamsRevision = function(value) {
return jspb.Message.setProto3EnumField(this, 6, value);
};
/**
* optional string adr_algorithm_id = 7;
* @return {string}
*/
proto.api.DeviceProfile.prototype.getAdrAlgorithmId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setAdrAlgorithmId = function(value) {
return jspb.Message.setProto3StringField(this, 7, value);
};
/**
* optional CodecRuntime payload_codec_runtime = 8;
* @return {!proto.api.CodecRuntime}
*/
proto.api.DeviceProfile.prototype.getPayloadCodecRuntime = function() {
return /** @type {!proto.api.CodecRuntime} */ (jspb.Message.getFieldWithDefault(this, 8, 0));
};
/**
* @param {!proto.api.CodecRuntime} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setPayloadCodecRuntime = function(value) {
return jspb.Message.setProto3EnumField(this, 8, value);
};
/**
* optional string payload_codec_script = 9;
* @return {string}
*/
proto.api.DeviceProfile.prototype.getPayloadCodecScript = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setPayloadCodecScript = function(value) {
return jspb.Message.setProto3StringField(this, 9, value);
};
/**
* optional bool flush_queue_on_activate = 10;
* @return {boolean}
*/
proto.api.DeviceProfile.prototype.getFlushQueueOnActivate = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 10, false));
};
/**
* @param {boolean} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setFlushQueueOnActivate = function(value) {
return jspb.Message.setProto3BooleanField(this, 10, value);
};
/**
* optional uint32 uplink_interval = 11;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getUplinkInterval = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 11, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setUplinkInterval = function(value) {
return jspb.Message.setProto3IntField(this, 11, value);
};
/**
* optional uint32 device_status_req_interval = 12;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getDeviceStatusReqInterval = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 12, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setDeviceStatusReqInterval = function(value) {
return jspb.Message.setProto3IntField(this, 12, value);
};
/**
* optional bool supports_otaa = 13;
* @return {boolean}
*/
proto.api.DeviceProfile.prototype.getSupportsOtaa = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 13, false));
};
/**
* @param {boolean} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setSupportsOtaa = function(value) {
return jspb.Message.setProto3BooleanField(this, 13, value);
};
/**
* optional bool supports_class_b = 14;
* @return {boolean}
*/
proto.api.DeviceProfile.prototype.getSupportsClassB = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 14, false));
};
/**
* @param {boolean} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setSupportsClassB = function(value) {
return jspb.Message.setProto3BooleanField(this, 14, value);
};
/**
* optional bool supports_class_c = 15;
* @return {boolean}
*/
proto.api.DeviceProfile.prototype.getSupportsClassC = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 15, false));
};
/**
* @param {boolean} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setSupportsClassC = function(value) {
return jspb.Message.setProto3BooleanField(this, 15, value);
};
/**
* optional uint32 class_b_timeout = 16;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getClassBTimeout = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 16, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setClassBTimeout = function(value) {
return jspb.Message.setProto3IntField(this, 16, value);
};
/**
* optional uint32 class_b_ping_slot_period = 17;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getClassBPingSlotPeriod = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 17, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setClassBPingSlotPeriod = function(value) {
return jspb.Message.setProto3IntField(this, 17, value);
};
/**
* optional uint32 class_b_ping_slot_dr = 18;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getClassBPingSlotDr = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 18, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setClassBPingSlotDr = function(value) {
return jspb.Message.setProto3IntField(this, 18, value);
};
/**
* optional uint32 class_b_ping_slot_freq = 19;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getClassBPingSlotFreq = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 19, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setClassBPingSlotFreq = function(value) {
return jspb.Message.setProto3IntField(this, 19, value);
};
/**
* optional uint32 class_c_timeout = 20;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getClassCTimeout = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 20, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setClassCTimeout = function(value) {
return jspb.Message.setProto3IntField(this, 20, value);
};
/**
* optional uint32 abp_rx1_delay = 21;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getAbpRx1Delay = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 21, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setAbpRx1Delay = function(value) {
return jspb.Message.setProto3IntField(this, 21, value);
};
/**
* optional uint32 abp_rx1_dr_offset = 22;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getAbpRx1DrOffset = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 22, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setAbpRx1DrOffset = function(value) {
return jspb.Message.setProto3IntField(this, 22, value);
};
/**
* optional uint32 abp_rx2_dr = 23;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getAbpRx2Dr = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 23, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setAbpRx2Dr = function(value) {
return jspb.Message.setProto3IntField(this, 23, value);
};
/**
* optional uint32 abp_rx2_freq = 24;
* @return {number}
*/
proto.api.DeviceProfile.prototype.getAbpRx2Freq = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 24, 0));
};
/**
* @param {number} value
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.setAbpRx2Freq = function(value) {
return jspb.Message.setProto3IntField(this, 24, value);
};
/**
* map<string, string> tags = 25;
* @param {boolean=} opt_noLazyCreate Do not create the map if
* empty, instead returning `undefined`
* @return {!jspb.Map<string,string>}
*/
proto.api.DeviceProfile.prototype.getTagsMap = function(opt_noLazyCreate) {
return /** @type {!jspb.Map<string,string>} */ (
jspb.Message.getMapField(this, 25, opt_noLazyCreate,
null));
};
/**
* Clears values from the map. The map will be non-null.
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.clearTagsMap = function() {
this.getTagsMap().clear();
return this;};
/**
* map<string, Measurement> measurements = 27;
* @param {boolean=} opt_noLazyCreate Do not create the map if
* empty, instead returning `undefined`
* @return {!jspb.Map<string,!proto.api.Measurement>}
*/
proto.api.DeviceProfile.prototype.getMeasurementsMap = function(opt_noLazyCreate) {
return /** @type {!jspb.Map<string,!proto.api.Measurement>} */ (
jspb.Message.getMapField(this, 27, opt_noLazyCreate,
proto.api.Measurement));
};
/**
* Clears values from the map. The map will be non-null.
* @return {!proto.api.DeviceProfile} returns this
*/
proto.api.DeviceProfile.prototype.clearMeasurementsMap = function() {
this.getMeasurementsMap().clear();
return this;};
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.api.Measurement.prototype.toObject = function(opt_includeInstance) {
return proto.api.Measurement.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.api.Measurement} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.Measurement.toObject = function(includeInstance, msg) {
var f, obj = {
name: jspb.Message.getFieldWithDefault(msg, 2, ""),
kind: jspb.Message.getFieldWithDefault(msg, 3, 0)
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.Measurement}
*/
proto.api.Measurement.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.Measurement;
return proto.api.Measurement.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.Measurement} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.Measurement}
*/
proto.api.Measurement.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setName(value);
break;
case 3:
var value = /** @type {!proto.api.MeasurementKind} */ (reader.readEnum());
msg.setKind(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.Measurement.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.Measurement.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.Measurement} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.Measurement.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getName();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
f = message.getKind();
if (f !== 0.0) {
writer.writeEnum(
3,
f
);
}
};
/**
* optional string name = 2;
* @return {string}
*/
proto.api.Measurement.prototype.getName = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.api.Measurement} returns this
*/
proto.api.Measurement.prototype.setName = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
/**
* optional MeasurementKind kind = 3;
* @return {!proto.api.MeasurementKind}
*/
proto.api.Measurement.prototype.getKind = function() {
return /** @type {!proto.api.MeasurementKind} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
};
/**
* @param {!proto.api.MeasurementKind} value
* @return {!proto.api.Measurement} returns this
*/
proto.api.Measurement.prototype.setKind = function(value) {
return jspb.Message.setProto3EnumField(this, 3, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.DeviceProfileListItem.prototype.toObject = function(opt_includeInstance) {
return proto.api.DeviceProfileListItem.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.api.DeviceProfileListItem} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.DeviceProfileListItem.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, ""),
createdAt: (f = msg.getCreatedAt()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
updatedAt: (f = msg.getUpdatedAt()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
name: jspb.Message.getFieldWithDefault(msg, 4, ""),
region: jspb.Message.getFieldWithDefault(msg, 5, 0),
macVersion: jspb.Message.getFieldWithDefault(msg, 6, 0),
regParamsRevision: jspb.Message.getFieldWithDefault(msg, 7, 0),
supportsOtaa: jspb.Message.getBooleanFieldWithDefault(msg, 8, false),
supportsClassB: jspb.Message.getBooleanFieldWithDefault(msg, 9, false),
supportsClassC: jspb.Message.getBooleanFieldWithDefault(msg, 10, false)
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.DeviceProfileListItem}
*/
proto.api.DeviceProfileListItem.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.DeviceProfileListItem;
return proto.api.DeviceProfileListItem.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.DeviceProfileListItem} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.DeviceProfileListItem}
*/
proto.api.DeviceProfileListItem.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.setId(value);
break;
case 2:
var value = new google_protobuf_timestamp_pb.Timestamp;
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
msg.setCreatedAt(value);
break;
case 3:
var value = new google_protobuf_timestamp_pb.Timestamp;
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
msg.setUpdatedAt(value);
break;
case 4:
var value = /** @type {string} */ (reader.readString());
msg.setName(value);
break;
case 5:
var value = /** @type {!proto.common.Region} */ (reader.readEnum());
msg.setRegion(value);
break;
case 6:
var value = /** @type {!proto.common.MacVersion} */ (reader.readEnum());
msg.setMacVersion(value);
break;
case 7:
var value = /** @type {!proto.common.RegParamsRevision} */ (reader.readEnum());
msg.setRegParamsRevision(value);
break;
case 8:
var value = /** @type {boolean} */ (reader.readBool());
msg.setSupportsOtaa(value);
break;
case 9:
var value = /** @type {boolean} */ (reader.readBool());
msg.setSupportsClassB(value);
break;
case 10:
var value = /** @type {boolean} */ (reader.readBool());
msg.setSupportsClassC(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.DeviceProfileListItem.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.DeviceProfileListItem.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.DeviceProfileListItem} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.DeviceProfileListItem.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getCreatedAt();
if (f != null) {
writer.writeMessage(
2,
f,
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
);
}
f = message.getUpdatedAt();
if (f != null) {
writer.writeMessage(
3,
f,
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
);
}
f = message.getName();
if (f.length > 0) {
writer.writeString(
4,
f
);
}
f = message.getRegion();
if (f !== 0.0) {
writer.writeEnum(
5,
f
);
}
f = message.getMacVersion();
if (f !== 0.0) {
writer.writeEnum(
6,
f
);
}
f = message.getRegParamsRevision();
if (f !== 0.0) {
writer.writeEnum(
7,
f
);
}
f = message.getSupportsOtaa();
if (f) {
writer.writeBool(
8,
f
);
}
f = message.getSupportsClassB();
if (f) {
writer.writeBool(
9,
f
);
}
f = message.getSupportsClassC();
if (f) {
writer.writeBool(
10,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.api.DeviceProfileListItem.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional google.protobuf.Timestamp created_at = 2;
* @return {?proto.google.protobuf.Timestamp}
*/
proto.api.DeviceProfileListItem.prototype.getCreatedAt = function() {
return /** @type{?proto.google.protobuf.Timestamp} */ (
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 2));
};
/**
* @param {?proto.google.protobuf.Timestamp|undefined} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setCreatedAt = function(value) {
return jspb.Message.setWrapperField(this, 2, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.clearCreatedAt = function() {
return this.setCreatedAt(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.api.DeviceProfileListItem.prototype.hasCreatedAt = function() {
return jspb.Message.getField(this, 2) != null;
};
/**
* optional google.protobuf.Timestamp updated_at = 3;
* @return {?proto.google.protobuf.Timestamp}
*/
proto.api.DeviceProfileListItem.prototype.getUpdatedAt = function() {
return /** @type{?proto.google.protobuf.Timestamp} */ (
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 3));
};
/**
* @param {?proto.google.protobuf.Timestamp|undefined} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setUpdatedAt = function(value) {
return jspb.Message.setWrapperField(this, 3, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.clearUpdatedAt = function() {
return this.setUpdatedAt(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.api.DeviceProfileListItem.prototype.hasUpdatedAt = function() {
return jspb.Message.getField(this, 3) != null;
};
/**
* optional string name = 4;
* @return {string}
*/
proto.api.DeviceProfileListItem.prototype.getName = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setName = function(value) {
return jspb.Message.setProto3StringField(this, 4, value);
};
/**
* optional common.Region region = 5;
* @return {!proto.common.Region}
*/
proto.api.DeviceProfileListItem.prototype.getRegion = function() {
return /** @type {!proto.common.Region} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
};
/**
* @param {!proto.common.Region} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setRegion = function(value) {
return jspb.Message.setProto3EnumField(this, 5, value);
};
/**
* optional common.MacVersion mac_version = 6;
* @return {!proto.common.MacVersion}
*/
proto.api.DeviceProfileListItem.prototype.getMacVersion = function() {
return /** @type {!proto.common.MacVersion} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
};
/**
* @param {!proto.common.MacVersion} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setMacVersion = function(value) {
return jspb.Message.setProto3EnumField(this, 6, value);
};
/**
* optional common.RegParamsRevision reg_params_revision = 7;
* @return {!proto.common.RegParamsRevision}
*/
proto.api.DeviceProfileListItem.prototype.getRegParamsRevision = function() {
return /** @type {!proto.common.RegParamsRevision} */ (jspb.Message.getFieldWithDefault(this, 7, 0));
};
/**
* @param {!proto.common.RegParamsRevision} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setRegParamsRevision = function(value) {
return jspb.Message.setProto3EnumField(this, 7, value);
};
/**
* optional bool supports_otaa = 8;
* @return {boolean}
*/
proto.api.DeviceProfileListItem.prototype.getSupportsOtaa = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 8, false));
};
/**
* @param {boolean} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setSupportsOtaa = function(value) {
return jspb.Message.setProto3BooleanField(this, 8, value);
};
/**
* optional bool supports_class_b = 9;
* @return {boolean}
*/
proto.api.DeviceProfileListItem.prototype.getSupportsClassB = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 9, false));
};
/**
* @param {boolean} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setSupportsClassB = function(value) {
return jspb.Message.setProto3BooleanField(this, 9, value);
};
/**
* optional bool supports_class_c = 10;
* @return {boolean}
*/
proto.api.DeviceProfileListItem.prototype.getSupportsClassC = function() {
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 10, false));
};
/**
* @param {boolean} value
* @return {!proto.api.DeviceProfileListItem} returns this
*/
proto.api.DeviceProfileListItem.prototype.setSupportsClassC = function(value) {
return jspb.Message.setProto3BooleanField(this, 10, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.CreateDeviceProfileRequest.prototype.toObject = function(opt_includeInstance) {
return proto.api.CreateDeviceProfileRequest.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.api.CreateDeviceProfileRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.CreateDeviceProfileRequest.toObject = function(includeInstance, msg) {
var f, obj = {
deviceProfile: (f = msg.getDeviceProfile()) && proto.api.DeviceProfile.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.api.CreateDeviceProfileRequest}
*/
proto.api.CreateDeviceProfileRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.CreateDeviceProfileRequest;
return proto.api.CreateDeviceProfileRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.CreateDeviceProfileRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.CreateDeviceProfileRequest}
*/
proto.api.CreateDeviceProfileRequest.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new proto.api.DeviceProfile;
reader.readMessage(value,proto.api.DeviceProfile.deserializeBinaryFromReader);
msg.setDeviceProfile(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.CreateDeviceProfileRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.CreateDeviceProfileRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.CreateDeviceProfileRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.CreateDeviceProfileRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getDeviceProfile();
if (f != null) {
writer.writeMessage(
1,
f,
proto.api.DeviceProfile.serializeBinaryToWriter
);
}
};
/**
* optional DeviceProfile device_profile = 1;
* @return {?proto.api.DeviceProfile}
*/
proto.api.CreateDeviceProfileRequest.prototype.getDeviceProfile = function() {
return /** @type{?proto.api.DeviceProfile} */ (
jspb.Message.getWrapperField(this, proto.api.DeviceProfile, 1));
};
/**
* @param {?proto.api.DeviceProfile|undefined} value
* @return {!proto.api.CreateDeviceProfileRequest} returns this
*/
proto.api.CreateDeviceProfileRequest.prototype.setDeviceProfile = function(value) {
return jspb.Message.setWrapperField(this, 1, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.api.CreateDeviceProfileRequest} returns this
*/
proto.api.CreateDeviceProfileRequest.prototype.clearDeviceProfile = function() {
return this.setDeviceProfile(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.api.CreateDeviceProfileRequest.prototype.hasDeviceProfile = function() {
return jspb.Message.getField(this, 1) != null;
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.CreateDeviceProfileResponse.prototype.toObject = function(opt_includeInstance) {
return proto.api.CreateDeviceProfileResponse.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.api.CreateDeviceProfileResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.CreateDeviceProfileResponse.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.CreateDeviceProfileResponse}
*/
proto.api.CreateDeviceProfileResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.CreateDeviceProfileResponse;
return proto.api.CreateDeviceProfileResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.CreateDeviceProfileResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.CreateDeviceProfileResponse}
*/
proto.api.CreateDeviceProfileResponse.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.setId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.CreateDeviceProfileResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.CreateDeviceProfileResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.CreateDeviceProfileResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.CreateDeviceProfileResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.api.CreateDeviceProfileResponse.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.CreateDeviceProfileResponse} returns this
*/
proto.api.CreateDeviceProfileResponse.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.GetDeviceProfileRequest.prototype.toObject = function(opt_includeInstance) {
return proto.api.GetDeviceProfileRequest.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.api.GetDeviceProfileRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.GetDeviceProfileRequest.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.GetDeviceProfileRequest}
*/
proto.api.GetDeviceProfileRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.GetDeviceProfileRequest;
return proto.api.GetDeviceProfileRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.GetDeviceProfileRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.GetDeviceProfileRequest}
*/
proto.api.GetDeviceProfileRequest.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.setId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.GetDeviceProfileRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.GetDeviceProfileRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.GetDeviceProfileRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.GetDeviceProfileRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.api.GetDeviceProfileRequest.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.GetDeviceProfileRequest} returns this
*/
proto.api.GetDeviceProfileRequest.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.GetDeviceProfileResponse.prototype.toObject = function(opt_includeInstance) {
return proto.api.GetDeviceProfileResponse.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.api.GetDeviceProfileResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.GetDeviceProfileResponse.toObject = function(includeInstance, msg) {
var f, obj = {
deviceProfile: (f = msg.getDeviceProfile()) && proto.api.DeviceProfile.toObject(includeInstance, f),
createdAt: (f = msg.getCreatedAt()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
updatedAt: (f = msg.getUpdatedAt()) && 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.api.GetDeviceProfileResponse}
*/
proto.api.GetDeviceProfileResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.GetDeviceProfileResponse;
return proto.api.GetDeviceProfileResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.GetDeviceProfileResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.GetDeviceProfileResponse}
*/
proto.api.GetDeviceProfileResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new proto.api.DeviceProfile;
reader.readMessage(value,proto.api.DeviceProfile.deserializeBinaryFromReader);
msg.setDeviceProfile(value);
break;
case 2:
var value = new google_protobuf_timestamp_pb.Timestamp;
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
msg.setCreatedAt(value);
break;
case 3:
var value = new google_protobuf_timestamp_pb.Timestamp;
reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
msg.setUpdatedAt(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.GetDeviceProfileResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.GetDeviceProfileResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.GetDeviceProfileResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.GetDeviceProfileResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getDeviceProfile();
if (f != null) {
writer.writeMessage(
1,
f,
proto.api.DeviceProfile.serializeBinaryToWriter
);
}
f = message.getCreatedAt();
if (f != null) {
writer.writeMessage(
2,
f,
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
);
}
f = message.getUpdatedAt();
if (f != null) {
writer.writeMessage(
3,
f,
google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
);
}
};
/**
* optional DeviceProfile device_profile = 1;
* @return {?proto.api.DeviceProfile}
*/
proto.api.GetDeviceProfileResponse.prototype.getDeviceProfile = function() {
return /** @type{?proto.api.DeviceProfile} */ (
jspb.Message.getWrapperField(this, proto.api.DeviceProfile, 1));
};
/**
* @param {?proto.api.DeviceProfile|undefined} value
* @return {!proto.api.GetDeviceProfileResponse} returns this
*/
proto.api.GetDeviceProfileResponse.prototype.setDeviceProfile = function(value) {
return jspb.Message.setWrapperField(this, 1, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.api.GetDeviceProfileResponse} returns this
*/
proto.api.GetDeviceProfileResponse.prototype.clearDeviceProfile = function() {
return this.setDeviceProfile(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.api.GetDeviceProfileResponse.prototype.hasDeviceProfile = function() {
return jspb.Message.getField(this, 1) != null;
};
/**
* optional google.protobuf.Timestamp created_at = 2;
* @return {?proto.google.protobuf.Timestamp}
*/
proto.api.GetDeviceProfileResponse.prototype.getCreatedAt = function() {
return /** @type{?proto.google.protobuf.Timestamp} */ (
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 2));
};
/**
* @param {?proto.google.protobuf.Timestamp|undefined} value
* @return {!proto.api.GetDeviceProfileResponse} returns this
*/
proto.api.GetDeviceProfileResponse.prototype.setCreatedAt = function(value) {
return jspb.Message.setWrapperField(this, 2, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.api.GetDeviceProfileResponse} returns this
*/
proto.api.GetDeviceProfileResponse.prototype.clearCreatedAt = function() {
return this.setCreatedAt(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.api.GetDeviceProfileResponse.prototype.hasCreatedAt = function() {
return jspb.Message.getField(this, 2) != null;
};
/**
* optional google.protobuf.Timestamp updated_at = 3;
* @return {?proto.google.protobuf.Timestamp}
*/
proto.api.GetDeviceProfileResponse.prototype.getUpdatedAt = function() {
return /** @type{?proto.google.protobuf.Timestamp} */ (
jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 3));
};
/**
* @param {?proto.google.protobuf.Timestamp|undefined} value
* @return {!proto.api.GetDeviceProfileResponse} returns this
*/
proto.api.GetDeviceProfileResponse.prototype.setUpdatedAt = function(value) {
return jspb.Message.setWrapperField(this, 3, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.api.GetDeviceProfileResponse} returns this
*/
proto.api.GetDeviceProfileResponse.prototype.clearUpdatedAt = function() {
return this.setUpdatedAt(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.api.GetDeviceProfileResponse.prototype.hasUpdatedAt = function() {
return jspb.Message.getField(this, 3) != null;
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.UpdateDeviceProfileRequest.prototype.toObject = function(opt_includeInstance) {
return proto.api.UpdateDeviceProfileRequest.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.api.UpdateDeviceProfileRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.UpdateDeviceProfileRequest.toObject = function(includeInstance, msg) {
var f, obj = {
deviceProfile: (f = msg.getDeviceProfile()) && proto.api.DeviceProfile.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.api.UpdateDeviceProfileRequest}
*/
proto.api.UpdateDeviceProfileRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.UpdateDeviceProfileRequest;
return proto.api.UpdateDeviceProfileRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.UpdateDeviceProfileRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.UpdateDeviceProfileRequest}
*/
proto.api.UpdateDeviceProfileRequest.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new proto.api.DeviceProfile;
reader.readMessage(value,proto.api.DeviceProfile.deserializeBinaryFromReader);
msg.setDeviceProfile(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.UpdateDeviceProfileRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.UpdateDeviceProfileRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.UpdateDeviceProfileRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.UpdateDeviceProfileRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getDeviceProfile();
if (f != null) {
writer.writeMessage(
1,
f,
proto.api.DeviceProfile.serializeBinaryToWriter
);
}
};
/**
* optional DeviceProfile device_profile = 1;
* @return {?proto.api.DeviceProfile}
*/
proto.api.UpdateDeviceProfileRequest.prototype.getDeviceProfile = function() {
return /** @type{?proto.api.DeviceProfile} */ (
jspb.Message.getWrapperField(this, proto.api.DeviceProfile, 1));
};
/**
* @param {?proto.api.DeviceProfile|undefined} value
* @return {!proto.api.UpdateDeviceProfileRequest} returns this
*/
proto.api.UpdateDeviceProfileRequest.prototype.setDeviceProfile = function(value) {
return jspb.Message.setWrapperField(this, 1, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.api.UpdateDeviceProfileRequest} returns this
*/
proto.api.UpdateDeviceProfileRequest.prototype.clearDeviceProfile = function() {
return this.setDeviceProfile(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.api.UpdateDeviceProfileRequest.prototype.hasDeviceProfile = function() {
return jspb.Message.getField(this, 1) != null;
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.DeleteDeviceProfileRequest.prototype.toObject = function(opt_includeInstance) {
return proto.api.DeleteDeviceProfileRequest.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.api.DeleteDeviceProfileRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.DeleteDeviceProfileRequest.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.DeleteDeviceProfileRequest}
*/
proto.api.DeleteDeviceProfileRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.DeleteDeviceProfileRequest;
return proto.api.DeleteDeviceProfileRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.DeleteDeviceProfileRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.DeleteDeviceProfileRequest}
*/
proto.api.DeleteDeviceProfileRequest.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.setId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.DeleteDeviceProfileRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.DeleteDeviceProfileRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.DeleteDeviceProfileRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.DeleteDeviceProfileRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.api.DeleteDeviceProfileRequest.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.DeleteDeviceProfileRequest} returns this
*/
proto.api.DeleteDeviceProfileRequest.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.ListDeviceProfilesRequest.prototype.toObject = function(opt_includeInstance) {
return proto.api.ListDeviceProfilesRequest.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.api.ListDeviceProfilesRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.ListDeviceProfilesRequest.toObject = function(includeInstance, msg) {
var f, obj = {
limit: jspb.Message.getFieldWithDefault(msg, 1, 0),
offset: jspb.Message.getFieldWithDefault(msg, 2, 0),
search: jspb.Message.getFieldWithDefault(msg, 3, ""),
tenantId: jspb.Message.getFieldWithDefault(msg, 4, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.ListDeviceProfilesRequest}
*/
proto.api.ListDeviceProfilesRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.ListDeviceProfilesRequest;
return proto.api.ListDeviceProfilesRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.ListDeviceProfilesRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.ListDeviceProfilesRequest}
*/
proto.api.ListDeviceProfilesRequest.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {number} */ (reader.readUint32());
msg.setLimit(value);
break;
case 2:
var value = /** @type {number} */ (reader.readUint32());
msg.setOffset(value);
break;
case 3:
var value = /** @type {string} */ (reader.readString());
msg.setSearch(value);
break;
case 4:
var value = /** @type {string} */ (reader.readString());
msg.setTenantId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.ListDeviceProfilesRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.ListDeviceProfilesRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.ListDeviceProfilesRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.ListDeviceProfilesRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getLimit();
if (f !== 0) {
writer.writeUint32(
1,
f
);
}
f = message.getOffset();
if (f !== 0) {
writer.writeUint32(
2,
f
);
}
f = message.getSearch();
if (f.length > 0) {
writer.writeString(
3,
f
);
}
f = message.getTenantId();
if (f.length > 0) {
writer.writeString(
4,
f
);
}
};
/**
* optional uint32 limit = 1;
* @return {number}
*/
proto.api.ListDeviceProfilesRequest.prototype.getLimit = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
};
/**
* @param {number} value
* @return {!proto.api.ListDeviceProfilesRequest} returns this
*/
proto.api.ListDeviceProfilesRequest.prototype.setLimit = function(value) {
return jspb.Message.setProto3IntField(this, 1, value);
};
/**
* optional uint32 offset = 2;
* @return {number}
*/
proto.api.ListDeviceProfilesRequest.prototype.getOffset = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
};
/**
* @param {number} value
* @return {!proto.api.ListDeviceProfilesRequest} returns this
*/
proto.api.ListDeviceProfilesRequest.prototype.setOffset = function(value) {
return jspb.Message.setProto3IntField(this, 2, value);
};
/**
* optional string search = 3;
* @return {string}
*/
proto.api.ListDeviceProfilesRequest.prototype.getSearch = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
};
/**
* @param {string} value
* @return {!proto.api.ListDeviceProfilesRequest} returns this
*/
proto.api.ListDeviceProfilesRequest.prototype.setSearch = function(value) {
return jspb.Message.setProto3StringField(this, 3, value);
};
/**
* optional string tenant_id = 4;
* @return {string}
*/
proto.api.ListDeviceProfilesRequest.prototype.getTenantId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
};
/**
* @param {string} value
* @return {!proto.api.ListDeviceProfilesRequest} returns this
*/
proto.api.ListDeviceProfilesRequest.prototype.setTenantId = function(value) {
return jspb.Message.setProto3StringField(this, 4, value);
};
/**
* List of repeated fields within this message type.
* @private {!Array<number>}
* @const
*/
proto.api.ListDeviceProfilesResponse.repeatedFields_ = [2];
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.ListDeviceProfilesResponse.prototype.toObject = function(opt_includeInstance) {
return proto.api.ListDeviceProfilesResponse.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.api.ListDeviceProfilesResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.ListDeviceProfilesResponse.toObject = function(includeInstance, msg) {
var f, obj = {
totalCount: jspb.Message.getFieldWithDefault(msg, 1, 0),
resultList: jspb.Message.toObjectList(msg.getResultList(),
proto.api.DeviceProfileListItem.toObject, includeInstance)
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.ListDeviceProfilesResponse}
*/
proto.api.ListDeviceProfilesResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.ListDeviceProfilesResponse;
return proto.api.ListDeviceProfilesResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.ListDeviceProfilesResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.ListDeviceProfilesResponse}
*/
proto.api.ListDeviceProfilesResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {number} */ (reader.readUint32());
msg.setTotalCount(value);
break;
case 2:
var value = new proto.api.DeviceProfileListItem;
reader.readMessage(value,proto.api.DeviceProfileListItem.deserializeBinaryFromReader);
msg.addResult(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.ListDeviceProfilesResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.ListDeviceProfilesResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.ListDeviceProfilesResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.ListDeviceProfilesResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getTotalCount();
if (f !== 0) {
writer.writeUint32(
1,
f
);
}
f = message.getResultList();
if (f.length > 0) {
writer.writeRepeatedMessage(
2,
f,
proto.api.DeviceProfileListItem.serializeBinaryToWriter
);
}
};
/**
* optional uint32 total_count = 1;
* @return {number}
*/
proto.api.ListDeviceProfilesResponse.prototype.getTotalCount = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
};
/**
* @param {number} value
* @return {!proto.api.ListDeviceProfilesResponse} returns this
*/
proto.api.ListDeviceProfilesResponse.prototype.setTotalCount = function(value) {
return jspb.Message.setProto3IntField(this, 1, value);
};
/**
* repeated DeviceProfileListItem result = 2;
* @return {!Array<!proto.api.DeviceProfileListItem>}
*/
proto.api.ListDeviceProfilesResponse.prototype.getResultList = function() {
return /** @type{!Array<!proto.api.DeviceProfileListItem>} */ (
jspb.Message.getRepeatedWrapperField(this, proto.api.DeviceProfileListItem, 2));
};
/**
* @param {!Array<!proto.api.DeviceProfileListItem>} value
* @return {!proto.api.ListDeviceProfilesResponse} returns this
*/
proto.api.ListDeviceProfilesResponse.prototype.setResultList = function(value) {
return jspb.Message.setRepeatedWrapperField(this, 2, value);
};
/**
* @param {!proto.api.DeviceProfileListItem=} opt_value
* @param {number=} opt_index
* @return {!proto.api.DeviceProfileListItem}
*/
proto.api.ListDeviceProfilesResponse.prototype.addResult = function(opt_value, opt_index) {
return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.api.DeviceProfileListItem, opt_index);
};
/**
* Clears the list making it empty but non-null.
* @return {!proto.api.ListDeviceProfilesResponse} returns this
*/
proto.api.ListDeviceProfilesResponse.prototype.clearResultList = function() {
return this.setResultList([]);
};
/**
* List of repeated fields within this message type.
* @private {!Array<number>}
* @const
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.repeatedFields_ = [2];
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.toObject = function(opt_includeInstance) {
return proto.api.ListDeviceProfileAdrAlgorithmsResponse.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.api.ListDeviceProfileAdrAlgorithmsResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.toObject = function(includeInstance, msg) {
var f, obj = {
totalCount: jspb.Message.getFieldWithDefault(msg, 1, 0),
resultList: jspb.Message.toObjectList(msg.getResultList(),
proto.api.AdrAlgorithmListItem.toObject, includeInstance)
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.ListDeviceProfileAdrAlgorithmsResponse}
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.ListDeviceProfileAdrAlgorithmsResponse;
return proto.api.ListDeviceProfileAdrAlgorithmsResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.ListDeviceProfileAdrAlgorithmsResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.ListDeviceProfileAdrAlgorithmsResponse}
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {number} */ (reader.readUint32());
msg.setTotalCount(value);
break;
case 2:
var value = new proto.api.AdrAlgorithmListItem;
reader.readMessage(value,proto.api.AdrAlgorithmListItem.deserializeBinaryFromReader);
msg.addResult(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.ListDeviceProfileAdrAlgorithmsResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.ListDeviceProfileAdrAlgorithmsResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getTotalCount();
if (f !== 0) {
writer.writeUint32(
1,
f
);
}
f = message.getResultList();
if (f.length > 0) {
writer.writeRepeatedMessage(
2,
f,
proto.api.AdrAlgorithmListItem.serializeBinaryToWriter
);
}
};
/**
* optional uint32 total_count = 1;
* @return {number}
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.getTotalCount = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
};
/**
* @param {number} value
* @return {!proto.api.ListDeviceProfileAdrAlgorithmsResponse} returns this
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.setTotalCount = function(value) {
return jspb.Message.setProto3IntField(this, 1, value);
};
/**
* repeated AdrAlgorithmListItem result = 2;
* @return {!Array<!proto.api.AdrAlgorithmListItem>}
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.getResultList = function() {
return /** @type{!Array<!proto.api.AdrAlgorithmListItem>} */ (
jspb.Message.getRepeatedWrapperField(this, proto.api.AdrAlgorithmListItem, 2));
};
/**
* @param {!Array<!proto.api.AdrAlgorithmListItem>} value
* @return {!proto.api.ListDeviceProfileAdrAlgorithmsResponse} returns this
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.setResultList = function(value) {
return jspb.Message.setRepeatedWrapperField(this, 2, value);
};
/**
* @param {!proto.api.AdrAlgorithmListItem=} opt_value
* @param {number=} opt_index
* @return {!proto.api.AdrAlgorithmListItem}
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.addResult = function(opt_value, opt_index) {
return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.api.AdrAlgorithmListItem, opt_index);
};
/**
* Clears the list making it empty but non-null.
* @return {!proto.api.ListDeviceProfileAdrAlgorithmsResponse} returns this
*/
proto.api.ListDeviceProfileAdrAlgorithmsResponse.prototype.clearResultList = function() {
return this.setResultList([]);
};
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.api.AdrAlgorithmListItem.prototype.toObject = function(opt_includeInstance) {
return proto.api.AdrAlgorithmListItem.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.api.AdrAlgorithmListItem} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.AdrAlgorithmListItem.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, ""),
name: jspb.Message.getFieldWithDefault(msg, 2, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.api.AdrAlgorithmListItem}
*/
proto.api.AdrAlgorithmListItem.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.AdrAlgorithmListItem;
return proto.api.AdrAlgorithmListItem.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.AdrAlgorithmListItem} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.AdrAlgorithmListItem}
*/
proto.api.AdrAlgorithmListItem.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.setId(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setName(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.AdrAlgorithmListItem.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.AdrAlgorithmListItem.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.api.AdrAlgorithmListItem} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.AdrAlgorithmListItem.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getName();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.api.AdrAlgorithmListItem.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.AdrAlgorithmListItem} returns this
*/
proto.api.AdrAlgorithmListItem.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string name = 2;
* @return {string}
*/
proto.api.AdrAlgorithmListItem.prototype.getName = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.api.AdrAlgorithmListItem} returns this
*/
proto.api.AdrAlgorithmListItem.prototype.setName = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
/**
* @enum {number}
*/
proto.api.CodecRuntime = {
NONE: 0,
CAYENNE_LPP: 1,
JS: 2
};
/**
* @enum {number}
*/
proto.api.MeasurementKind = {
UNKNOWN: 0,
COUNTER: 1,
ABSOLUTE: 2,
GAUGE: 3,
STRING: 4
};
goog.object.extend(exports, proto.api);