Implement adding gws to multicast-group + Class-C scheduling config.

This makes it possible to add gateways to a multicast-group, which in
case configured will always be used for transmitting the multicast
downlinks.

This also moves the multicast class-c scheduling to the multicast-group
configuration. Options are delay between multiple gateways, or GPS time
synchronized transmission.
This commit is contained in:
Orne Brocaar
2023-02-09 15:11:06 +00:00
parent 8d34bb0d0c
commit f657c3e971
96 changed files with 3337 additions and 604 deletions

View File

@ -243,6 +243,9 @@ export class ListGatewaysRequest extends jspb.Message {
getTenantId(): string;
setTenantId(value: string): ListGatewaysRequest;
getMulticastGroupId(): string;
setMulticastGroupId(value: string): ListGatewaysRequest;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): ListGatewaysRequest.AsObject;
static toObject(includeInstance: boolean, msg: ListGatewaysRequest): ListGatewaysRequest.AsObject;
@ -257,6 +260,7 @@ export namespace ListGatewaysRequest {
offset: number,
search: string,
tenantId: string,
multicastGroupId: string,
}
}

View File

@ -2062,7 +2062,8 @@ proto.api.ListGatewaysRequest.toObject = function(includeInstance, msg) {
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, "")
tenantId: jspb.Message.getFieldWithDefault(msg, 4, ""),
multicastGroupId: jspb.Message.getFieldWithDefault(msg, 5, "")
};
if (includeInstance) {
@ -2115,6 +2116,10 @@ proto.api.ListGatewaysRequest.deserializeBinaryFromReader = function(msg, reader
var value = /** @type {string} */ (reader.readString());
msg.setTenantId(value);
break;
case 5:
var value = /** @type {string} */ (reader.readString());
msg.setMulticastGroupId(value);
break;
default:
reader.skipField();
break;
@ -2172,6 +2177,13 @@ proto.api.ListGatewaysRequest.serializeBinaryToWriter = function(message, writer
f
);
}
f = message.getMulticastGroupId();
if (f.length > 0) {
writer.writeString(
5,
f
);
}
};
@ -2247,6 +2259,24 @@ proto.api.ListGatewaysRequest.prototype.setTenantId = function(value) {
};
/**
* optional string multicast_group_id = 5;
* @return {string}
*/
proto.api.ListGatewaysRequest.prototype.getMulticastGroupId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
};
/**
* @param {string} value
* @return {!proto.api.ListGatewaysRequest} returns this
*/
proto.api.ListGatewaysRequest.prototype.setMulticastGroupId = function(value) {
return jspb.Message.setProto3StringField(this, 5, value);
};
/**
* List of repeated fields within this message type.

View File

@ -58,6 +58,20 @@ export class MulticastGroupServiceClient {
response: google_protobuf_empty_pb.Empty) => void
): grpcWeb.ClientReadableStream<google_protobuf_empty_pb.Empty>;
addGateway(
request: api_multicast_group_pb.AddGatewayToMulticastGroupRequest,
metadata: grpcWeb.Metadata | undefined,
callback: (err: grpcWeb.RpcError,
response: google_protobuf_empty_pb.Empty) => void
): grpcWeb.ClientReadableStream<google_protobuf_empty_pb.Empty>;
removeGateway(
request: api_multicast_group_pb.RemoveGatewayFromMulticastGroupRequest,
metadata: grpcWeb.Metadata | undefined,
callback: (err: grpcWeb.RpcError,
response: google_protobuf_empty_pb.Empty) => void
): grpcWeb.ClientReadableStream<google_protobuf_empty_pb.Empty>;
enqueue(
request: api_multicast_group_pb.EnqueueMulticastGroupQueueItemRequest,
metadata: grpcWeb.Metadata | undefined,
@ -121,6 +135,16 @@ export class MulticastGroupServicePromiseClient {
metadata?: grpcWeb.Metadata
): Promise<google_protobuf_empty_pb.Empty>;
addGateway(
request: api_multicast_group_pb.AddGatewayToMulticastGroupRequest,
metadata?: grpcWeb.Metadata
): Promise<google_protobuf_empty_pb.Empty>;
removeGateway(
request: api_multicast_group_pb.RemoveGatewayFromMulticastGroupRequest,
metadata?: grpcWeb.Metadata
): Promise<google_protobuf_empty_pb.Empty>;
enqueue(
request: api_multicast_group_pb.EnqueueMulticastGroupQueueItemRequest,
metadata?: grpcWeb.Metadata

View File

@ -509,6 +509,128 @@ proto.api.MulticastGroupServicePromiseClient.prototype.removeDevice =
};
/**
* @const
* @type {!grpc.web.MethodDescriptor<
* !proto.api.AddGatewayToMulticastGroupRequest,
* !proto.google.protobuf.Empty>}
*/
const methodDescriptor_MulticastGroupService_AddGateway = new grpc.web.MethodDescriptor(
'/api.MulticastGroupService/AddGateway',
grpc.web.MethodType.UNARY,
proto.api.AddGatewayToMulticastGroupRequest,
google_protobuf_empty_pb.Empty,
/**
* @param {!proto.api.AddGatewayToMulticastGroupRequest} request
* @return {!Uint8Array}
*/
function(request) {
return request.serializeBinary();
},
google_protobuf_empty_pb.Empty.deserializeBinary
);
/**
* @param {!proto.api.AddGatewayToMulticastGroupRequest} request The
* request proto
* @param {?Object<string, string>} metadata User defined
* call metadata
* @param {function(?grpc.web.RpcError, ?proto.google.protobuf.Empty)}
* callback The callback function(error, response)
* @return {!grpc.web.ClientReadableStream<!proto.google.protobuf.Empty>|undefined}
* The XHR Node Readable Stream
*/
proto.api.MulticastGroupServiceClient.prototype.addGateway =
function(request, metadata, callback) {
return this.client_.rpcCall(this.hostname_ +
'/api.MulticastGroupService/AddGateway',
request,
metadata || {},
methodDescriptor_MulticastGroupService_AddGateway,
callback);
};
/**
* @param {!proto.api.AddGatewayToMulticastGroupRequest} request The
* request proto
* @param {?Object<string, string>=} metadata User defined
* call metadata
* @return {!Promise<!proto.google.protobuf.Empty>}
* Promise that resolves to the response
*/
proto.api.MulticastGroupServicePromiseClient.prototype.addGateway =
function(request, metadata) {
return this.client_.unaryCall(this.hostname_ +
'/api.MulticastGroupService/AddGateway',
request,
metadata || {},
methodDescriptor_MulticastGroupService_AddGateway);
};
/**
* @const
* @type {!grpc.web.MethodDescriptor<
* !proto.api.RemoveGatewayFromMulticastGroupRequest,
* !proto.google.protobuf.Empty>}
*/
const methodDescriptor_MulticastGroupService_RemoveGateway = new grpc.web.MethodDescriptor(
'/api.MulticastGroupService/RemoveGateway',
grpc.web.MethodType.UNARY,
proto.api.RemoveGatewayFromMulticastGroupRequest,
google_protobuf_empty_pb.Empty,
/**
* @param {!proto.api.RemoveGatewayFromMulticastGroupRequest} request
* @return {!Uint8Array}
*/
function(request) {
return request.serializeBinary();
},
google_protobuf_empty_pb.Empty.deserializeBinary
);
/**
* @param {!proto.api.RemoveGatewayFromMulticastGroupRequest} request The
* request proto
* @param {?Object<string, string>} metadata User defined
* call metadata
* @param {function(?grpc.web.RpcError, ?proto.google.protobuf.Empty)}
* callback The callback function(error, response)
* @return {!grpc.web.ClientReadableStream<!proto.google.protobuf.Empty>|undefined}
* The XHR Node Readable Stream
*/
proto.api.MulticastGroupServiceClient.prototype.removeGateway =
function(request, metadata, callback) {
return this.client_.rpcCall(this.hostname_ +
'/api.MulticastGroupService/RemoveGateway',
request,
metadata || {},
methodDescriptor_MulticastGroupService_RemoveGateway,
callback);
};
/**
* @param {!proto.api.RemoveGatewayFromMulticastGroupRequest} request The
* request proto
* @param {?Object<string, string>=} metadata User defined
* call metadata
* @return {!Promise<!proto.google.protobuf.Empty>}
* Promise that resolves to the response
*/
proto.api.MulticastGroupServicePromiseClient.prototype.removeGateway =
function(request, metadata) {
return this.client_.unaryCall(this.hostname_ +
'/api.MulticastGroupService/RemoveGateway',
request,
metadata || {},
methodDescriptor_MulticastGroupService_RemoveGateway);
};
/**
* @const
* @type {!grpc.web.MethodDescriptor<

View File

@ -43,6 +43,9 @@ export class MulticastGroup extends jspb.Message {
getClassBPingSlotPeriod(): number;
setClassBPingSlotPeriod(value: number): MulticastGroup;
getClassCSchedulingType(): MulticastGroupSchedulingType;
setClassCSchedulingType(value: MulticastGroupSchedulingType): MulticastGroup;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): MulticastGroup.AsObject;
static toObject(includeInstance: boolean, msg: MulticastGroup): MulticastGroup.AsObject;
@ -65,6 +68,7 @@ export namespace MulticastGroup {
dr: number,
frequency: number,
classBPingSlotPeriod: number,
classCSchedulingType: MulticastGroupSchedulingType,
}
}
@ -334,6 +338,50 @@ export namespace RemoveDeviceFromMulticastGroupRequest {
}
}
export class AddGatewayToMulticastGroupRequest extends jspb.Message {
getMulticastGroupId(): string;
setMulticastGroupId(value: string): AddGatewayToMulticastGroupRequest;
getGatewayId(): string;
setGatewayId(value: string): AddGatewayToMulticastGroupRequest;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): AddGatewayToMulticastGroupRequest.AsObject;
static toObject(includeInstance: boolean, msg: AddGatewayToMulticastGroupRequest): AddGatewayToMulticastGroupRequest.AsObject;
static serializeBinaryToWriter(message: AddGatewayToMulticastGroupRequest, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): AddGatewayToMulticastGroupRequest;
static deserializeBinaryFromReader(message: AddGatewayToMulticastGroupRequest, reader: jspb.BinaryReader): AddGatewayToMulticastGroupRequest;
}
export namespace AddGatewayToMulticastGroupRequest {
export type AsObject = {
multicastGroupId: string,
gatewayId: string,
}
}
export class RemoveGatewayFromMulticastGroupRequest extends jspb.Message {
getMulticastGroupId(): string;
setMulticastGroupId(value: string): RemoveGatewayFromMulticastGroupRequest;
getGatewayId(): string;
setGatewayId(value: string): RemoveGatewayFromMulticastGroupRequest;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): RemoveGatewayFromMulticastGroupRequest.AsObject;
static toObject(includeInstance: boolean, msg: RemoveGatewayFromMulticastGroupRequest): RemoveGatewayFromMulticastGroupRequest.AsObject;
static serializeBinaryToWriter(message: RemoveGatewayFromMulticastGroupRequest, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): RemoveGatewayFromMulticastGroupRequest;
static deserializeBinaryFromReader(message: RemoveGatewayFromMulticastGroupRequest, reader: jspb.BinaryReader): RemoveGatewayFromMulticastGroupRequest;
}
export namespace RemoveGatewayFromMulticastGroupRequest {
export type AsObject = {
multicastGroupId: string,
gatewayId: string,
}
}
export class MulticastGroupQueueItem extends jspb.Message {
getMulticastGroupId(): string;
setMulticastGroupId(value: string): MulticastGroupQueueItem;
@ -464,3 +512,7 @@ export enum MulticastGroupType {
CLASS_C = 0,
CLASS_B = 1,
}
export enum MulticastGroupSchedulingType {
DELAY = 0,
GPS_TIME = 1,
}

View File

@ -21,6 +21,7 @@ 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.AddDeviceToMulticastGroupRequest', null, global);
goog.exportSymbol('proto.api.AddGatewayToMulticastGroupRequest', null, global);
goog.exportSymbol('proto.api.CreateMulticastGroupRequest', null, global);
goog.exportSymbol('proto.api.CreateMulticastGroupResponse', null, global);
goog.exportSymbol('proto.api.DeleteMulticastGroupRequest', null, global);
@ -36,8 +37,10 @@ goog.exportSymbol('proto.api.ListMulticastGroupsResponse', null, global);
goog.exportSymbol('proto.api.MulticastGroup', null, global);
goog.exportSymbol('proto.api.MulticastGroupListItem', null, global);
goog.exportSymbol('proto.api.MulticastGroupQueueItem', null, global);
goog.exportSymbol('proto.api.MulticastGroupSchedulingType', null, global);
goog.exportSymbol('proto.api.MulticastGroupType', null, global);
goog.exportSymbol('proto.api.RemoveDeviceFromMulticastGroupRequest', null, global);
goog.exportSymbol('proto.api.RemoveGatewayFromMulticastGroupRequest', null, global);
goog.exportSymbol('proto.api.UpdateMulticastGroupRequest', null, global);
/**
* Generated by JsPbCodeGenerator.
@ -291,6 +294,48 @@ if (goog.DEBUG && !COMPILED) {
*/
proto.api.RemoveDeviceFromMulticastGroupRequest.displayName = 'proto.api.RemoveDeviceFromMulticastGroupRequest';
}
/**
* 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.AddGatewayToMulticastGroupRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.AddGatewayToMulticastGroupRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.AddGatewayToMulticastGroupRequest.displayName = 'proto.api.AddGatewayToMulticastGroupRequest';
}
/**
* 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.RemoveGatewayFromMulticastGroupRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.api.RemoveGatewayFromMulticastGroupRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.displayName = 'proto.api.RemoveGatewayFromMulticastGroupRequest';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
@ -460,7 +505,8 @@ proto.api.MulticastGroup.toObject = function(includeInstance, msg) {
groupType: jspb.Message.getFieldWithDefault(msg, 9, 0),
dr: jspb.Message.getFieldWithDefault(msg, 10, 0),
frequency: jspb.Message.getFieldWithDefault(msg, 11, 0),
classBPingSlotPeriod: jspb.Message.getFieldWithDefault(msg, 12, 0)
classBPingSlotPeriod: jspb.Message.getFieldWithDefault(msg, 12, 0),
classCSchedulingType: jspb.Message.getFieldWithDefault(msg, 13, 0)
};
if (includeInstance) {
@ -545,6 +591,10 @@ proto.api.MulticastGroup.deserializeBinaryFromReader = function(msg, reader) {
var value = /** @type {number} */ (reader.readUint32());
msg.setClassBPingSlotPeriod(value);
break;
case 13:
var value = /** @type {!proto.api.MulticastGroupSchedulingType} */ (reader.readEnum());
msg.setClassCSchedulingType(value);
break;
default:
reader.skipField();
break;
@ -658,6 +708,13 @@ proto.api.MulticastGroup.serializeBinaryToWriter = function(message, writer) {
f
);
}
f = message.getClassCSchedulingType();
if (f !== 0.0) {
writer.writeEnum(
13,
f
);
}
};
@ -877,6 +934,24 @@ proto.api.MulticastGroup.prototype.setClassBPingSlotPeriod = function(value) {
};
/**
* optional MulticastGroupSchedulingType class_c_scheduling_type = 13;
* @return {!proto.api.MulticastGroupSchedulingType}
*/
proto.api.MulticastGroup.prototype.getClassCSchedulingType = function() {
return /** @type {!proto.api.MulticastGroupSchedulingType} */ (jspb.Message.getFieldWithDefault(this, 13, 0));
};
/**
* @param {!proto.api.MulticastGroupSchedulingType} value
* @return {!proto.api.MulticastGroup} returns this
*/
proto.api.MulticastGroup.prototype.setClassCSchedulingType = function(value) {
return jspb.Message.setProto3EnumField(this, 13, value);
};
@ -2877,6 +2952,326 @@ proto.api.RemoveDeviceFromMulticastGroupRequest.prototype.setDevEui = function(v
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.AddGatewayToMulticastGroupRequest.prototype.toObject = function(opt_includeInstance) {
return proto.api.AddGatewayToMulticastGroupRequest.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.AddGatewayToMulticastGroupRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.AddGatewayToMulticastGroupRequest.toObject = function(includeInstance, msg) {
var f, obj = {
multicastGroupId: jspb.Message.getFieldWithDefault(msg, 1, ""),
gatewayId: 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.AddGatewayToMulticastGroupRequest}
*/
proto.api.AddGatewayToMulticastGroupRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.AddGatewayToMulticastGroupRequest;
return proto.api.AddGatewayToMulticastGroupRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.AddGatewayToMulticastGroupRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.AddGatewayToMulticastGroupRequest}
*/
proto.api.AddGatewayToMulticastGroupRequest.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.setMulticastGroupId(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setGatewayId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.AddGatewayToMulticastGroupRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.AddGatewayToMulticastGroupRequest.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.AddGatewayToMulticastGroupRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.AddGatewayToMulticastGroupRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getMulticastGroupId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getGatewayId();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string multicast_group_id = 1;
* @return {string}
*/
proto.api.AddGatewayToMulticastGroupRequest.prototype.getMulticastGroupId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.AddGatewayToMulticastGroupRequest} returns this
*/
proto.api.AddGatewayToMulticastGroupRequest.prototype.setMulticastGroupId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string gateway_id = 2;
* @return {string}
*/
proto.api.AddGatewayToMulticastGroupRequest.prototype.getGatewayId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.api.AddGatewayToMulticastGroupRequest} returns this
*/
proto.api.AddGatewayToMulticastGroupRequest.prototype.setGatewayId = function(value) {
return jspb.Message.setProto3StringField(this, 2, 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.RemoveGatewayFromMulticastGroupRequest.prototype.toObject = function(opt_includeInstance) {
return proto.api.RemoveGatewayFromMulticastGroupRequest.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.RemoveGatewayFromMulticastGroupRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.toObject = function(includeInstance, msg) {
var f, obj = {
multicastGroupId: jspb.Message.getFieldWithDefault(msg, 1, ""),
gatewayId: 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.RemoveGatewayFromMulticastGroupRequest}
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.api.RemoveGatewayFromMulticastGroupRequest;
return proto.api.RemoveGatewayFromMulticastGroupRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.api.RemoveGatewayFromMulticastGroupRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.api.RemoveGatewayFromMulticastGroupRequest}
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.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.setMulticastGroupId(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setGatewayId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.api.RemoveGatewayFromMulticastGroupRequest.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.RemoveGatewayFromMulticastGroupRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getMulticastGroupId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getGatewayId();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string multicast_group_id = 1;
* @return {string}
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.prototype.getMulticastGroupId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.api.RemoveGatewayFromMulticastGroupRequest} returns this
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.prototype.setMulticastGroupId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string gateway_id = 2;
* @return {string}
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.prototype.getGatewayId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.api.RemoveGatewayFromMulticastGroupRequest} returns this
*/
proto.api.RemoveGatewayFromMulticastGroupRequest.prototype.setGatewayId = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
@ -3827,4 +4222,12 @@ proto.api.MulticastGroupType = {
CLASS_B: 1
};
/**
* @enum {number}
*/
proto.api.MulticastGroupSchedulingType = {
DELAY: 0,
GPS_TIME: 1
};
goog.object.extend(exports, proto.api);