@wireapp/protocol-messaging 1.49.0 → 1.51.0
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.
- package/package.json +1 -1
- package/proto/messages.proto +15 -0
- package/web/messages.d.ts +33 -1
- package/web/messages.js +305 -3
package/package.json
CHANGED
package/proto/messages.proto
CHANGED
|
@@ -47,6 +47,17 @@ message GenericMessage {
|
|
|
47
47
|
ButtonActionConfirmation buttonActionConfirmation = 22;
|
|
48
48
|
DataTransfer dataTransfer = 23; // client-side synchronization across devices of the same user
|
|
49
49
|
InCallEmoji inCallEmoji = 24;
|
|
50
|
+
// UnknownStrategy unknownStrategy = 25; -- Defined outside the oneof
|
|
51
|
+
// Next field should be 26 ↓
|
|
52
|
+
InCallHandRaise inCallHandRaise = 26;
|
|
53
|
+
}
|
|
54
|
+
optional UnknownStrategy unknownStrategy = 25 [default = IGNORE];
|
|
55
|
+
|
|
56
|
+
// See internal RFC: "2024-07-18 RFC Improve future-proofing for new OTR message types"
|
|
57
|
+
enum UnknownStrategy {
|
|
58
|
+
IGNORE = 0; // Ignore the message completely. Trash. Bye
|
|
59
|
+
DISCARD_AND_WARN = 1; // Warn the user, but discard the message, as it won't be helpful in the future.
|
|
60
|
+
WARN_USER_ALLOW_RETRY = 2; // Warn the user. Client has freedom to store it and retry in the future.
|
|
50
61
|
}
|
|
51
62
|
}
|
|
52
63
|
|
|
@@ -336,6 +347,10 @@ message InCallEmoji {
|
|
|
336
347
|
map<string, int32> emojis = 1;
|
|
337
348
|
}
|
|
338
349
|
|
|
350
|
+
message InCallHandRaise {
|
|
351
|
+
required bool is_hand_up = 1; // true if the hand is raised, false if lowered
|
|
352
|
+
}
|
|
353
|
+
|
|
339
354
|
message Calling {
|
|
340
355
|
required string content = 1;
|
|
341
356
|
optional QualifiedConversationId qualified_conversation_id = 2;
|
package/web/messages.d.ts
CHANGED
|
@@ -24,6 +24,8 @@ export interface IGenericMessage {
|
|
|
24
24
|
buttonActionConfirmation?: (IButtonActionConfirmation|null);
|
|
25
25
|
dataTransfer?: (IDataTransfer|null);
|
|
26
26
|
inCallEmoji?: (IInCallEmoji|null);
|
|
27
|
+
inCallHandRaise?: (IInCallHandRaise|null);
|
|
28
|
+
unknownStrategy?: (GenericMessage.UnknownStrategy|null);
|
|
27
29
|
}
|
|
28
30
|
|
|
29
31
|
export class GenericMessage implements IGenericMessage {
|
|
@@ -51,7 +53,9 @@ export class GenericMessage implements IGenericMessage {
|
|
|
51
53
|
public buttonActionConfirmation?: (IButtonActionConfirmation|null);
|
|
52
54
|
public dataTransfer?: (IDataTransfer|null);
|
|
53
55
|
public inCallEmoji?: (IInCallEmoji|null);
|
|
54
|
-
public
|
|
56
|
+
public inCallHandRaise?: (IInCallHandRaise|null);
|
|
57
|
+
public unknownStrategy: GenericMessage.UnknownStrategy;
|
|
58
|
+
public content?: ("text"|"image"|"knock"|"lastRead"|"cleared"|"external"|"clientAction"|"calling"|"asset"|"hidden"|"location"|"deleted"|"edited"|"confirmation"|"reaction"|"ephemeral"|"availability"|"composite"|"buttonAction"|"buttonActionConfirmation"|"dataTransfer"|"inCallEmoji"|"inCallHandRaise");
|
|
55
59
|
public static create(properties?: IGenericMessage): GenericMessage;
|
|
56
60
|
public static encode(message: IGenericMessage, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
57
61
|
public static encodeDelimited(message: IGenericMessage, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
@@ -64,6 +68,15 @@ export class GenericMessage implements IGenericMessage {
|
|
|
64
68
|
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
65
69
|
}
|
|
66
70
|
|
|
71
|
+
export namespace GenericMessage {
|
|
72
|
+
|
|
73
|
+
enum UnknownStrategy {
|
|
74
|
+
IGNORE = 0,
|
|
75
|
+
DISCARD_AND_WARN = 1,
|
|
76
|
+
WARN_USER_ALLOW_RETRY = 2
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
67
80
|
export interface IQualifiedUserId {
|
|
68
81
|
id: string;
|
|
69
82
|
domain: string;
|
|
@@ -926,6 +939,25 @@ export class InCallEmoji implements IInCallEmoji {
|
|
|
926
939
|
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
927
940
|
}
|
|
928
941
|
|
|
942
|
+
export interface IInCallHandRaise {
|
|
943
|
+
isHandUp: boolean;
|
|
944
|
+
}
|
|
945
|
+
|
|
946
|
+
export class InCallHandRaise implements IInCallHandRaise {
|
|
947
|
+
constructor(properties?: IInCallHandRaise);
|
|
948
|
+
public isHandUp: boolean;
|
|
949
|
+
public static create(properties?: IInCallHandRaise): InCallHandRaise;
|
|
950
|
+
public static encode(message: IInCallHandRaise, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
951
|
+
public static encodeDelimited(message: IInCallHandRaise, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
952
|
+
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): InCallHandRaise;
|
|
953
|
+
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): InCallHandRaise;
|
|
954
|
+
public static verify(message: { [k: string]: any }): (string|null);
|
|
955
|
+
public static fromObject(object: { [k: string]: any }): InCallHandRaise;
|
|
956
|
+
public static toObject(message: InCallHandRaise, options?: $protobuf.IConversionOptions): { [k: string]: any };
|
|
957
|
+
public toJSON(): { [k: string]: any };
|
|
958
|
+
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
959
|
+
}
|
|
960
|
+
|
|
929
961
|
export interface ICalling {
|
|
930
962
|
content: string;
|
|
931
963
|
qualifiedConversationId?: (IQualifiedConversationId|null);
|
package/web/messages.js
CHANGED
|
@@ -38,6 +38,8 @@ $root.GenericMessage = (function() {
|
|
|
38
38
|
* @property {IButtonActionConfirmation|null} [buttonActionConfirmation] GenericMessage buttonActionConfirmation
|
|
39
39
|
* @property {IDataTransfer|null} [dataTransfer] GenericMessage dataTransfer
|
|
40
40
|
* @property {IInCallEmoji|null} [inCallEmoji] GenericMessage inCallEmoji
|
|
41
|
+
* @property {IInCallHandRaise|null} [inCallHandRaise] GenericMessage inCallHandRaise
|
|
42
|
+
* @property {GenericMessage.UnknownStrategy|null} [unknownStrategy] GenericMessage unknownStrategy
|
|
41
43
|
*/
|
|
42
44
|
|
|
43
45
|
/**
|
|
@@ -239,17 +241,33 @@ $root.GenericMessage = (function() {
|
|
|
239
241
|
*/
|
|
240
242
|
GenericMessage.prototype.inCallEmoji = null;
|
|
241
243
|
|
|
244
|
+
/**
|
|
245
|
+
* GenericMessage inCallHandRaise.
|
|
246
|
+
* @member {IInCallHandRaise|null|undefined} inCallHandRaise
|
|
247
|
+
* @memberof GenericMessage
|
|
248
|
+
* @instance
|
|
249
|
+
*/
|
|
250
|
+
GenericMessage.prototype.inCallHandRaise = null;
|
|
251
|
+
|
|
252
|
+
/**
|
|
253
|
+
* GenericMessage unknownStrategy.
|
|
254
|
+
* @member {GenericMessage.UnknownStrategy} unknownStrategy
|
|
255
|
+
* @memberof GenericMessage
|
|
256
|
+
* @instance
|
|
257
|
+
*/
|
|
258
|
+
GenericMessage.prototype.unknownStrategy = 0;
|
|
259
|
+
|
|
242
260
|
// OneOf field names bound to virtual getters and setters
|
|
243
261
|
var $oneOfFields;
|
|
244
262
|
|
|
245
263
|
/**
|
|
246
264
|
* GenericMessage content.
|
|
247
|
-
* @member {"text"|"image"|"knock"|"lastRead"|"cleared"|"external"|"clientAction"|"calling"|"asset"|"hidden"|"location"|"deleted"|"edited"|"confirmation"|"reaction"|"ephemeral"|"availability"|"composite"|"buttonAction"|"buttonActionConfirmation"|"dataTransfer"|"inCallEmoji"|undefined} content
|
|
265
|
+
* @member {"text"|"image"|"knock"|"lastRead"|"cleared"|"external"|"clientAction"|"calling"|"asset"|"hidden"|"location"|"deleted"|"edited"|"confirmation"|"reaction"|"ephemeral"|"availability"|"composite"|"buttonAction"|"buttonActionConfirmation"|"dataTransfer"|"inCallEmoji"|"inCallHandRaise"|undefined} content
|
|
248
266
|
* @memberof GenericMessage
|
|
249
267
|
* @instance
|
|
250
268
|
*/
|
|
251
269
|
Object.defineProperty(GenericMessage.prototype, "content", {
|
|
252
|
-
get: $util.oneOfGetter($oneOfFields = ["text", "image", "knock", "lastRead", "cleared", "external", "clientAction", "calling", "asset", "hidden", "location", "deleted", "edited", "confirmation", "reaction", "ephemeral", "availability", "composite", "buttonAction", "buttonActionConfirmation", "dataTransfer", "inCallEmoji"]),
|
|
270
|
+
get: $util.oneOfGetter($oneOfFields = ["text", "image", "knock", "lastRead", "cleared", "external", "clientAction", "calling", "asset", "hidden", "location", "deleted", "edited", "confirmation", "reaction", "ephemeral", "availability", "composite", "buttonAction", "buttonActionConfirmation", "dataTransfer", "inCallEmoji", "inCallHandRaise"]),
|
|
253
271
|
set: $util.oneOfSetter($oneOfFields)
|
|
254
272
|
});
|
|
255
273
|
|
|
@@ -322,6 +340,10 @@ $root.GenericMessage = (function() {
|
|
|
322
340
|
$root.DataTransfer.encode(message.dataTransfer, writer.uint32(/* id 23, wireType 2 =*/186).fork()).ldelim();
|
|
323
341
|
if (message.inCallEmoji != null && Object.hasOwnProperty.call(message, "inCallEmoji"))
|
|
324
342
|
$root.InCallEmoji.encode(message.inCallEmoji, writer.uint32(/* id 24, wireType 2 =*/194).fork()).ldelim();
|
|
343
|
+
if (message.unknownStrategy != null && Object.hasOwnProperty.call(message, "unknownStrategy"))
|
|
344
|
+
writer.uint32(/* id 25, wireType 0 =*/200).int32(message.unknownStrategy);
|
|
345
|
+
if (message.inCallHandRaise != null && Object.hasOwnProperty.call(message, "inCallHandRaise"))
|
|
346
|
+
$root.InCallHandRaise.encode(message.inCallHandRaise, writer.uint32(/* id 26, wireType 2 =*/210).fork()).ldelim();
|
|
325
347
|
return writer;
|
|
326
348
|
};
|
|
327
349
|
|
|
@@ -448,6 +470,14 @@ $root.GenericMessage = (function() {
|
|
|
448
470
|
message.inCallEmoji = $root.InCallEmoji.decode(reader, reader.uint32());
|
|
449
471
|
break;
|
|
450
472
|
}
|
|
473
|
+
case 26: {
|
|
474
|
+
message.inCallHandRaise = $root.InCallHandRaise.decode(reader, reader.uint32());
|
|
475
|
+
break;
|
|
476
|
+
}
|
|
477
|
+
case 25: {
|
|
478
|
+
message.unknownStrategy = reader.int32();
|
|
479
|
+
break;
|
|
480
|
+
}
|
|
451
481
|
default:
|
|
452
482
|
reader.skipType(tag & 7);
|
|
453
483
|
break;
|
|
@@ -707,6 +737,25 @@ $root.GenericMessage = (function() {
|
|
|
707
737
|
return "inCallEmoji." + error;
|
|
708
738
|
}
|
|
709
739
|
}
|
|
740
|
+
if (message.inCallHandRaise != null && message.hasOwnProperty("inCallHandRaise")) {
|
|
741
|
+
if (properties.content === 1)
|
|
742
|
+
return "content: multiple values";
|
|
743
|
+
properties.content = 1;
|
|
744
|
+
{
|
|
745
|
+
var error = $root.InCallHandRaise.verify(message.inCallHandRaise);
|
|
746
|
+
if (error)
|
|
747
|
+
return "inCallHandRaise." + error;
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
if (message.unknownStrategy != null && message.hasOwnProperty("unknownStrategy"))
|
|
751
|
+
switch (message.unknownStrategy) {
|
|
752
|
+
default:
|
|
753
|
+
return "unknownStrategy: enum value expected";
|
|
754
|
+
case 0:
|
|
755
|
+
case 1:
|
|
756
|
+
case 2:
|
|
757
|
+
break;
|
|
758
|
+
}
|
|
710
759
|
return null;
|
|
711
760
|
};
|
|
712
761
|
|
|
@@ -841,6 +890,31 @@ $root.GenericMessage = (function() {
|
|
|
841
890
|
throw TypeError(".GenericMessage.inCallEmoji: object expected");
|
|
842
891
|
message.inCallEmoji = $root.InCallEmoji.fromObject(object.inCallEmoji);
|
|
843
892
|
}
|
|
893
|
+
if (object.inCallHandRaise != null) {
|
|
894
|
+
if (typeof object.inCallHandRaise !== "object")
|
|
895
|
+
throw TypeError(".GenericMessage.inCallHandRaise: object expected");
|
|
896
|
+
message.inCallHandRaise = $root.InCallHandRaise.fromObject(object.inCallHandRaise);
|
|
897
|
+
}
|
|
898
|
+
switch (object.unknownStrategy) {
|
|
899
|
+
default:
|
|
900
|
+
if (typeof object.unknownStrategy === "number") {
|
|
901
|
+
message.unknownStrategy = object.unknownStrategy;
|
|
902
|
+
break;
|
|
903
|
+
}
|
|
904
|
+
break;
|
|
905
|
+
case "IGNORE":
|
|
906
|
+
case 0:
|
|
907
|
+
message.unknownStrategy = 0;
|
|
908
|
+
break;
|
|
909
|
+
case "DISCARD_AND_WARN":
|
|
910
|
+
case 1:
|
|
911
|
+
message.unknownStrategy = 1;
|
|
912
|
+
break;
|
|
913
|
+
case "WARN_USER_ALLOW_RETRY":
|
|
914
|
+
case 2:
|
|
915
|
+
message.unknownStrategy = 2;
|
|
916
|
+
break;
|
|
917
|
+
}
|
|
844
918
|
return message;
|
|
845
919
|
};
|
|
846
920
|
|
|
@@ -857,8 +931,10 @@ $root.GenericMessage = (function() {
|
|
|
857
931
|
if (!options)
|
|
858
932
|
options = {};
|
|
859
933
|
var object = {};
|
|
860
|
-
if (options.defaults)
|
|
934
|
+
if (options.defaults) {
|
|
861
935
|
object.messageId = "";
|
|
936
|
+
object.unknownStrategy = options.enums === String ? "IGNORE" : 0;
|
|
937
|
+
}
|
|
862
938
|
if (message.messageId != null && message.hasOwnProperty("messageId"))
|
|
863
939
|
object.messageId = message.messageId;
|
|
864
940
|
if (message.text != null && message.hasOwnProperty("text")) {
|
|
@@ -971,6 +1047,13 @@ $root.GenericMessage = (function() {
|
|
|
971
1047
|
if (options.oneofs)
|
|
972
1048
|
object.content = "inCallEmoji";
|
|
973
1049
|
}
|
|
1050
|
+
if (message.unknownStrategy != null && message.hasOwnProperty("unknownStrategy"))
|
|
1051
|
+
object.unknownStrategy = options.enums === String ? $root.GenericMessage.UnknownStrategy[message.unknownStrategy] === undefined ? message.unknownStrategy : $root.GenericMessage.UnknownStrategy[message.unknownStrategy] : message.unknownStrategy;
|
|
1052
|
+
if (message.inCallHandRaise != null && message.hasOwnProperty("inCallHandRaise")) {
|
|
1053
|
+
object.inCallHandRaise = $root.InCallHandRaise.toObject(message.inCallHandRaise, options);
|
|
1054
|
+
if (options.oneofs)
|
|
1055
|
+
object.content = "inCallHandRaise";
|
|
1056
|
+
}
|
|
974
1057
|
return object;
|
|
975
1058
|
};
|
|
976
1059
|
|
|
@@ -1000,6 +1083,22 @@ $root.GenericMessage = (function() {
|
|
|
1000
1083
|
return typeUrlPrefix + "/GenericMessage";
|
|
1001
1084
|
};
|
|
1002
1085
|
|
|
1086
|
+
/**
|
|
1087
|
+
* UnknownStrategy enum.
|
|
1088
|
+
* @name GenericMessage.UnknownStrategy
|
|
1089
|
+
* @enum {number}
|
|
1090
|
+
* @property {number} IGNORE=0 IGNORE value
|
|
1091
|
+
* @property {number} DISCARD_AND_WARN=1 DISCARD_AND_WARN value
|
|
1092
|
+
* @property {number} WARN_USER_ALLOW_RETRY=2 WARN_USER_ALLOW_RETRY value
|
|
1093
|
+
*/
|
|
1094
|
+
GenericMessage.UnknownStrategy = (function() {
|
|
1095
|
+
var valuesById = {}, values = Object.create(valuesById);
|
|
1096
|
+
values[valuesById[0] = "IGNORE"] = 0;
|
|
1097
|
+
values[valuesById[1] = "DISCARD_AND_WARN"] = 1;
|
|
1098
|
+
values[valuesById[2] = "WARN_USER_ALLOW_RETRY"] = 2;
|
|
1099
|
+
return values;
|
|
1100
|
+
})();
|
|
1101
|
+
|
|
1003
1102
|
return GenericMessage;
|
|
1004
1103
|
})();
|
|
1005
1104
|
|
|
@@ -10947,6 +11046,209 @@ $root.InCallEmoji = (function() {
|
|
|
10947
11046
|
return InCallEmoji;
|
|
10948
11047
|
})();
|
|
10949
11048
|
|
|
11049
|
+
$root.InCallHandRaise = (function() {
|
|
11050
|
+
|
|
11051
|
+
/**
|
|
11052
|
+
* Properties of an InCallHandRaise.
|
|
11053
|
+
* @exports IInCallHandRaise
|
|
11054
|
+
* @interface IInCallHandRaise
|
|
11055
|
+
* @property {boolean} isHandUp InCallHandRaise isHandUp
|
|
11056
|
+
*/
|
|
11057
|
+
|
|
11058
|
+
/**
|
|
11059
|
+
* Constructs a new InCallHandRaise.
|
|
11060
|
+
* @exports InCallHandRaise
|
|
11061
|
+
* @classdesc Represents an InCallHandRaise.
|
|
11062
|
+
* @implements IInCallHandRaise
|
|
11063
|
+
* @constructor
|
|
11064
|
+
* @param {IInCallHandRaise=} [properties] Properties to set
|
|
11065
|
+
*/
|
|
11066
|
+
function InCallHandRaise(properties) {
|
|
11067
|
+
if (properties)
|
|
11068
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
11069
|
+
if (properties[keys[i]] != null)
|
|
11070
|
+
this[keys[i]] = properties[keys[i]];
|
|
11071
|
+
}
|
|
11072
|
+
|
|
11073
|
+
/**
|
|
11074
|
+
* InCallHandRaise isHandUp.
|
|
11075
|
+
* @member {boolean} isHandUp
|
|
11076
|
+
* @memberof InCallHandRaise
|
|
11077
|
+
* @instance
|
|
11078
|
+
*/
|
|
11079
|
+
InCallHandRaise.prototype.isHandUp = false;
|
|
11080
|
+
|
|
11081
|
+
/**
|
|
11082
|
+
* Creates a new InCallHandRaise instance using the specified properties.
|
|
11083
|
+
* @function create
|
|
11084
|
+
* @memberof InCallHandRaise
|
|
11085
|
+
* @static
|
|
11086
|
+
* @param {IInCallHandRaise=} [properties] Properties to set
|
|
11087
|
+
* @returns {InCallHandRaise} InCallHandRaise instance
|
|
11088
|
+
*/
|
|
11089
|
+
InCallHandRaise.create = function create(properties) {
|
|
11090
|
+
return new InCallHandRaise(properties);
|
|
11091
|
+
};
|
|
11092
|
+
|
|
11093
|
+
/**
|
|
11094
|
+
* Encodes the specified InCallHandRaise message. Does not implicitly {@link InCallHandRaise.verify|verify} messages.
|
|
11095
|
+
* @function encode
|
|
11096
|
+
* @memberof InCallHandRaise
|
|
11097
|
+
* @static
|
|
11098
|
+
* @param {IInCallHandRaise} message InCallHandRaise message or plain object to encode
|
|
11099
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
11100
|
+
* @returns {$protobuf.Writer} Writer
|
|
11101
|
+
*/
|
|
11102
|
+
InCallHandRaise.encode = function encode(message, writer) {
|
|
11103
|
+
if (!writer)
|
|
11104
|
+
writer = $Writer.create();
|
|
11105
|
+
writer.uint32(/* id 1, wireType 0 =*/8).bool(message.isHandUp);
|
|
11106
|
+
return writer;
|
|
11107
|
+
};
|
|
11108
|
+
|
|
11109
|
+
/**
|
|
11110
|
+
* Encodes the specified InCallHandRaise message, length delimited. Does not implicitly {@link InCallHandRaise.verify|verify} messages.
|
|
11111
|
+
* @function encodeDelimited
|
|
11112
|
+
* @memberof InCallHandRaise
|
|
11113
|
+
* @static
|
|
11114
|
+
* @param {IInCallHandRaise} message InCallHandRaise message or plain object to encode
|
|
11115
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
11116
|
+
* @returns {$protobuf.Writer} Writer
|
|
11117
|
+
*/
|
|
11118
|
+
InCallHandRaise.encodeDelimited = function encodeDelimited(message, writer) {
|
|
11119
|
+
return this.encode(message, writer).ldelim();
|
|
11120
|
+
};
|
|
11121
|
+
|
|
11122
|
+
/**
|
|
11123
|
+
* Decodes an InCallHandRaise message from the specified reader or buffer.
|
|
11124
|
+
* @function decode
|
|
11125
|
+
* @memberof InCallHandRaise
|
|
11126
|
+
* @static
|
|
11127
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
11128
|
+
* @param {number} [length] Message length if known beforehand
|
|
11129
|
+
* @returns {InCallHandRaise} InCallHandRaise
|
|
11130
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
11131
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
11132
|
+
*/
|
|
11133
|
+
InCallHandRaise.decode = function decode(reader, length) {
|
|
11134
|
+
if (!(reader instanceof $Reader))
|
|
11135
|
+
reader = $Reader.create(reader);
|
|
11136
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.InCallHandRaise();
|
|
11137
|
+
while (reader.pos < end) {
|
|
11138
|
+
var tag = reader.uint32();
|
|
11139
|
+
switch (tag >>> 3) {
|
|
11140
|
+
case 1: {
|
|
11141
|
+
message.isHandUp = reader.bool();
|
|
11142
|
+
break;
|
|
11143
|
+
}
|
|
11144
|
+
default:
|
|
11145
|
+
reader.skipType(tag & 7);
|
|
11146
|
+
break;
|
|
11147
|
+
}
|
|
11148
|
+
}
|
|
11149
|
+
if (!message.hasOwnProperty("isHandUp"))
|
|
11150
|
+
throw $util.ProtocolError("missing required 'isHandUp'", { instance: message });
|
|
11151
|
+
return message;
|
|
11152
|
+
};
|
|
11153
|
+
|
|
11154
|
+
/**
|
|
11155
|
+
* Decodes an InCallHandRaise message from the specified reader or buffer, length delimited.
|
|
11156
|
+
* @function decodeDelimited
|
|
11157
|
+
* @memberof InCallHandRaise
|
|
11158
|
+
* @static
|
|
11159
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
11160
|
+
* @returns {InCallHandRaise} InCallHandRaise
|
|
11161
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
11162
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
11163
|
+
*/
|
|
11164
|
+
InCallHandRaise.decodeDelimited = function decodeDelimited(reader) {
|
|
11165
|
+
if (!(reader instanceof $Reader))
|
|
11166
|
+
reader = new $Reader(reader);
|
|
11167
|
+
return this.decode(reader, reader.uint32());
|
|
11168
|
+
};
|
|
11169
|
+
|
|
11170
|
+
/**
|
|
11171
|
+
* Verifies an InCallHandRaise message.
|
|
11172
|
+
* @function verify
|
|
11173
|
+
* @memberof InCallHandRaise
|
|
11174
|
+
* @static
|
|
11175
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
11176
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
11177
|
+
*/
|
|
11178
|
+
InCallHandRaise.verify = function verify(message) {
|
|
11179
|
+
if (typeof message !== "object" || message === null)
|
|
11180
|
+
return "object expected";
|
|
11181
|
+
if (typeof message.isHandUp !== "boolean")
|
|
11182
|
+
return "isHandUp: boolean expected";
|
|
11183
|
+
return null;
|
|
11184
|
+
};
|
|
11185
|
+
|
|
11186
|
+
/**
|
|
11187
|
+
* Creates an InCallHandRaise message from a plain object. Also converts values to their respective internal types.
|
|
11188
|
+
* @function fromObject
|
|
11189
|
+
* @memberof InCallHandRaise
|
|
11190
|
+
* @static
|
|
11191
|
+
* @param {Object.<string,*>} object Plain object
|
|
11192
|
+
* @returns {InCallHandRaise} InCallHandRaise
|
|
11193
|
+
*/
|
|
11194
|
+
InCallHandRaise.fromObject = function fromObject(object) {
|
|
11195
|
+
if (object instanceof $root.InCallHandRaise)
|
|
11196
|
+
return object;
|
|
11197
|
+
var message = new $root.InCallHandRaise();
|
|
11198
|
+
if (object.isHandUp != null)
|
|
11199
|
+
message.isHandUp = Boolean(object.isHandUp);
|
|
11200
|
+
return message;
|
|
11201
|
+
};
|
|
11202
|
+
|
|
11203
|
+
/**
|
|
11204
|
+
* Creates a plain object from an InCallHandRaise message. Also converts values to other types if specified.
|
|
11205
|
+
* @function toObject
|
|
11206
|
+
* @memberof InCallHandRaise
|
|
11207
|
+
* @static
|
|
11208
|
+
* @param {InCallHandRaise} message InCallHandRaise
|
|
11209
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
11210
|
+
* @returns {Object.<string,*>} Plain object
|
|
11211
|
+
*/
|
|
11212
|
+
InCallHandRaise.toObject = function toObject(message, options) {
|
|
11213
|
+
if (!options)
|
|
11214
|
+
options = {};
|
|
11215
|
+
var object = {};
|
|
11216
|
+
if (options.defaults)
|
|
11217
|
+
object.isHandUp = false;
|
|
11218
|
+
if (message.isHandUp != null && message.hasOwnProperty("isHandUp"))
|
|
11219
|
+
object.isHandUp = message.isHandUp;
|
|
11220
|
+
return object;
|
|
11221
|
+
};
|
|
11222
|
+
|
|
11223
|
+
/**
|
|
11224
|
+
* Converts this InCallHandRaise to JSON.
|
|
11225
|
+
* @function toJSON
|
|
11226
|
+
* @memberof InCallHandRaise
|
|
11227
|
+
* @instance
|
|
11228
|
+
* @returns {Object.<string,*>} JSON object
|
|
11229
|
+
*/
|
|
11230
|
+
InCallHandRaise.prototype.toJSON = function toJSON() {
|
|
11231
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
11232
|
+
};
|
|
11233
|
+
|
|
11234
|
+
/**
|
|
11235
|
+
* Gets the default type url for InCallHandRaise
|
|
11236
|
+
* @function getTypeUrl
|
|
11237
|
+
* @memberof InCallHandRaise
|
|
11238
|
+
* @static
|
|
11239
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
11240
|
+
* @returns {string} The default type url
|
|
11241
|
+
*/
|
|
11242
|
+
InCallHandRaise.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
11243
|
+
if (typeUrlPrefix === undefined) {
|
|
11244
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
11245
|
+
}
|
|
11246
|
+
return typeUrlPrefix + "/InCallHandRaise";
|
|
11247
|
+
};
|
|
11248
|
+
|
|
11249
|
+
return InCallHandRaise;
|
|
11250
|
+
})();
|
|
11251
|
+
|
|
10950
11252
|
$root.Calling = (function() {
|
|
10951
11253
|
|
|
10952
11254
|
/**
|