mezon-sdk 2.7.75 → 2.7.76

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -158,6 +158,7 @@ function createBaseEnvelope() {
158
158
  ptt_leaved_event: undefined,
159
159
  sd_topic_event: undefined,
160
160
  follow_event: undefined,
161
+ channel_app_event: undefined,
161
162
  };
162
163
  }
163
164
  export const Envelope = {
@@ -375,6 +376,9 @@ export const Envelope = {
375
376
  if (message.follow_event !== undefined) {
376
377
  FollowEvent.encode(message.follow_event, writer.uint32(570).fork()).ldelim();
377
378
  }
379
+ if (message.channel_app_event !== undefined) {
380
+ ChannelAppEvent.encode(message.channel_app_event, writer.uint32(578).fork()).ldelim();
381
+ }
378
382
  return writer;
379
383
  },
380
384
  decode(input, length) {
@@ -810,6 +814,12 @@ export const Envelope = {
810
814
  }
811
815
  message.follow_event = FollowEvent.decode(reader, reader.uint32());
812
816
  continue;
817
+ case 72:
818
+ if (tag !== 578) {
819
+ break;
820
+ }
821
+ message.channel_app_event = ChannelAppEvent.decode(reader, reader.uint32());
822
+ continue;
813
823
  }
814
824
  if ((tag & 7) === 4 || tag === 0) {
815
825
  break;
@@ -979,6 +989,9 @@ export const Envelope = {
979
989
  ptt_leaved_event: isSet(object.ptt_leaved_event) ? PTTLeavedEvent.fromJSON(object.ptt_leaved_event) : undefined,
980
990
  sd_topic_event: isSet(object.sd_topic_event) ? SdTopicEvent.fromJSON(object.sd_topic_event) : undefined,
981
991
  follow_event: isSet(object.follow_event) ? FollowEvent.fromJSON(object.follow_event) : undefined,
992
+ channel_app_event: isSet(object.channel_app_event)
993
+ ? ChannelAppEvent.fromJSON(object.channel_app_event)
994
+ : undefined,
982
995
  };
983
996
  },
984
997
  toJSON(message) {
@@ -1196,6 +1209,9 @@ export const Envelope = {
1196
1209
  if (message.follow_event !== undefined) {
1197
1210
  obj.follow_event = FollowEvent.toJSON(message.follow_event);
1198
1211
  }
1212
+ if (message.channel_app_event !== undefined) {
1213
+ obj.channel_app_event = ChannelAppEvent.toJSON(message.channel_app_event);
1214
+ }
1199
1215
  return obj;
1200
1216
  },
1201
1217
  create(base) {
@@ -1430,6 +1446,9 @@ export const Envelope = {
1430
1446
  message.follow_event = (object.follow_event !== undefined && object.follow_event !== null)
1431
1447
  ? FollowEvent.fromPartial(object.follow_event)
1432
1448
  : undefined;
1449
+ message.channel_app_event = (object.channel_app_event !== undefined && object.channel_app_event !== null)
1450
+ ? ChannelAppEvent.fromPartial(object.channel_app_event)
1451
+ : undefined;
1433
1452
  return message;
1434
1453
  },
1435
1454
  };
@@ -9357,6 +9376,114 @@ export const SdTopicEvent = {
9357
9376
  return message;
9358
9377
  },
9359
9378
  };
9379
+ function createBaseChannelAppEvent() {
9380
+ return { user_id: "", username: "", clan_id: "", channel_id: "", action: 0 };
9381
+ }
9382
+ export const ChannelAppEvent = {
9383
+ encode(message, writer = _m0.Writer.create()) {
9384
+ if (message.user_id !== "") {
9385
+ writer.uint32(10).string(message.user_id);
9386
+ }
9387
+ if (message.username !== "") {
9388
+ writer.uint32(18).string(message.username);
9389
+ }
9390
+ if (message.clan_id !== "") {
9391
+ writer.uint32(26).string(message.clan_id);
9392
+ }
9393
+ if (message.channel_id !== "") {
9394
+ writer.uint32(34).string(message.channel_id);
9395
+ }
9396
+ if (message.action !== 0) {
9397
+ writer.uint32(40).int32(message.action);
9398
+ }
9399
+ return writer;
9400
+ },
9401
+ decode(input, length) {
9402
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
9403
+ let end = length === undefined ? reader.len : reader.pos + length;
9404
+ const message = createBaseChannelAppEvent();
9405
+ while (reader.pos < end) {
9406
+ const tag = reader.uint32();
9407
+ switch (tag >>> 3) {
9408
+ case 1:
9409
+ if (tag !== 10) {
9410
+ break;
9411
+ }
9412
+ message.user_id = reader.string();
9413
+ continue;
9414
+ case 2:
9415
+ if (tag !== 18) {
9416
+ break;
9417
+ }
9418
+ message.username = reader.string();
9419
+ continue;
9420
+ case 3:
9421
+ if (tag !== 26) {
9422
+ break;
9423
+ }
9424
+ message.clan_id = reader.string();
9425
+ continue;
9426
+ case 4:
9427
+ if (tag !== 34) {
9428
+ break;
9429
+ }
9430
+ message.channel_id = reader.string();
9431
+ continue;
9432
+ case 5:
9433
+ if (tag !== 40) {
9434
+ break;
9435
+ }
9436
+ message.action = reader.int32();
9437
+ continue;
9438
+ }
9439
+ if ((tag & 7) === 4 || tag === 0) {
9440
+ break;
9441
+ }
9442
+ reader.skipType(tag & 7);
9443
+ }
9444
+ return message;
9445
+ },
9446
+ fromJSON(object) {
9447
+ return {
9448
+ user_id: isSet(object.user_id) ? globalThis.String(object.user_id) : "",
9449
+ username: isSet(object.username) ? globalThis.String(object.username) : "",
9450
+ clan_id: isSet(object.clan_id) ? globalThis.String(object.clan_id) : "",
9451
+ channel_id: isSet(object.channel_id) ? globalThis.String(object.channel_id) : "",
9452
+ action: isSet(object.action) ? globalThis.Number(object.action) : 0,
9453
+ };
9454
+ },
9455
+ toJSON(message) {
9456
+ const obj = {};
9457
+ if (message.user_id !== "") {
9458
+ obj.user_id = message.user_id;
9459
+ }
9460
+ if (message.username !== "") {
9461
+ obj.username = message.username;
9462
+ }
9463
+ if (message.clan_id !== "") {
9464
+ obj.clan_id = message.clan_id;
9465
+ }
9466
+ if (message.channel_id !== "") {
9467
+ obj.channel_id = message.channel_id;
9468
+ }
9469
+ if (message.action !== 0) {
9470
+ obj.action = Math.round(message.action);
9471
+ }
9472
+ return obj;
9473
+ },
9474
+ create(base) {
9475
+ return ChannelAppEvent.fromPartial(base ?? {});
9476
+ },
9477
+ fromPartial(object) {
9478
+ const message = createBaseChannelAppEvent();
9479
+ message.user_id = object.user_id ?? "";
9480
+ message.username = object.username ?? "";
9481
+ message.clan_id = object.clan_id ?? "";
9482
+ message.channel_id = object.channel_id ?? "";
9483
+ message.action = object.action ?? 0;
9484
+ return message;
9485
+ },
9486
+ };
9360
9487
  function toTimestamp(date) {
9361
9488
  const seconds = Math.trunc(date.getTime() / 1_000);
9362
9489
  const nanos = (date.getTime() % 1_000) * 1_000_000;