dcodeindra-baileyspro 2.3.9
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/LICENSE +21 -0
- package/README.md +2534 -0
- package/WAProto/Adv/Adv.d.ts +518 -0
- package/WAProto/Adv/Adv.js +1734 -0
- package/WAProto/Adv/Adv.proto +36 -0
- package/WAProto/BotMetadata/BotMetadata.d.ts +5745 -0
- package/WAProto/BotMetadata/BotMetadata.js +16291 -0
- package/WAProto/BotMetadata/BotMetadata.proto +463 -0
- package/WAProto/Cert/Cert.d.ts +497 -0
- package/WAProto/Cert/Cert.js +1503 -0
- package/WAProto/Cert/Cert.proto +28 -0
- package/WAProto/ChatLockSettings/ChatLockSettings.d.ts +391 -0
- package/WAProto/ChatLockSettings/ChatLockSettings.js +1155 -0
- package/WAProto/ChatLockSettings/ChatLockSettings.proto +7 -0
- package/WAProto/CompanionReg/CompanionReg.d.ts +1055 -0
- package/WAProto/CompanionReg/CompanionReg.js +3532 -0
- package/WAProto/CompanionReg/CompanionReg.proto +89 -0
- package/WAProto/DeviceCapabilities/DeviceCapabilities.d.ts +187 -0
- package/WAProto/DeviceCapabilities/DeviceCapabilities.js +520 -0
- package/WAProto/DeviceCapabilities/DeviceCapabilities.proto +14 -0
- package/WAProto/E2E/E2E.d.ts +28417 -0
- package/WAProto/E2E/E2E.js +98438 -0
- package/WAProto/E2E/E2E.proto +2289 -0
- package/WAProto/Ephemeral/Ephemeral.d.ts +95 -0
- package/WAProto/Ephemeral/Ephemeral.js +269 -0
- package/WAProto/Ephemeral/Ephemeral.proto +6 -0
- package/WAProto/HistorySync/HistorySync.d.ts +40728 -0
- package/WAProto/HistorySync/HistorySync.js +142980 -0
- package/WAProto/HistorySync/HistorySync.proto +207 -0
- package/WAProto/LidMigrationSyncPayload/LidMigrationSyncPayload.d.ts +189 -0
- package/WAProto/LidMigrationSyncPayload/LidMigrationSyncPayload.js +585 -0
- package/WAProto/LidMigrationSyncPayload/LidMigrationSyncPayload.proto +11 -0
- package/WAProto/MdStorageChatRowOpaqueData/MdStorageChatRowOpaqueData.d.ts +461 -0
- package/WAProto/MdStorageChatRowOpaqueData/MdStorageChatRowOpaqueData.js +1559 -0
- package/WAProto/MdStorageChatRowOpaqueData/MdStorageChatRowOpaqueData.proto +37 -0
- package/WAProto/MdStorageMsgRowOpaqueData/MdStorageMsgRowOpaqueData.d.ts +29294 -0
- package/WAProto/MdStorageMsgRowOpaqueData/MdStorageMsgRowOpaqueData.js +101732 -0
- package/WAProto/MdStorageMsgRowOpaqueData/MdStorageMsgRowOpaqueData.proto +76 -0
- package/WAProto/MmsRetry/MmsRetry.d.ts +200 -0
- package/WAProto/MmsRetry/MmsRetry.js +586 -0
- package/WAProto/MmsRetry/MmsRetry.proto +17 -0
- package/WAProto/Protocol/Protocol.d.ts +218 -0
- package/WAProto/Protocol/Protocol.js +701 -0
- package/WAProto/Protocol/Protocol.proto +20 -0
- package/WAProto/Reporting/Reporting.d.ts +301 -0
- package/WAProto/Reporting/Reporting.js +989 -0
- package/WAProto/Reporting/Reporting.proto +19 -0
- package/WAProto/ServerSync/ServerSync.d.ts +1050 -0
- package/WAProto/ServerSync/ServerSync.js +3176 -0
- package/WAProto/ServerSync/ServerSync.proto +59 -0
- package/WAProto/SignalLocalStorageProtocol/SignalLocalStorageProtocol.d.ts +1507 -0
- package/WAProto/SignalLocalStorageProtocol/SignalLocalStorageProtocol.js +4756 -0
- package/WAProto/SignalLocalStorageProtocol/SignalLocalStorageProtocol.proto +88 -0
- package/WAProto/SignalWhisperTextProtocol/SignalWhisperTextProtocol.d.ts +617 -0
- package/WAProto/SignalWhisperTextProtocol/SignalWhisperTextProtocol.js +1940 -0
- package/WAProto/SignalWhisperTextProtocol/SignalWhisperTextProtocol.proto +38 -0
- package/WAProto/StatusAttributions/StatusAttributions.d.ts +636 -0
- package/WAProto/StatusAttributions/StatusAttributions.js +2037 -0
- package/WAProto/StatusAttributions/StatusAttributions.proto +61 -0
- package/WAProto/SyncAction/SyncAction.d.ts +7227 -0
- package/WAProto/SyncAction/SyncAction.js +22271 -0
- package/WAProto/SyncAction/SyncAction.proto +423 -0
- package/WAProto/UserPassword/UserPassword.d.ts +298 -0
- package/WAProto/UserPassword/UserPassword.js +898 -0
- package/WAProto/UserPassword/UserPassword.proto +27 -0
- package/WAProto/VnameCert/VnameCert.d.ts +658 -0
- package/WAProto/VnameCert/VnameCert.js +2225 -0
- package/WAProto/VnameCert/VnameCert.proto +60 -0
- package/WAProto/Wa6/Wa6.d.ts +1613 -0
- package/WAProto/Wa6/Wa6.js +6299 -0
- package/WAProto/Wa6/Wa6.proto +229 -0
- package/WAProto/Web/Web.d.ts +31718 -0
- package/WAProto/Web/Web.js +113402 -0
- package/WAProto/Web/Web.proto +545 -0
- package/WAProto/index.d.ts +49 -0
- package/WAProto/index.js +28 -0
- package/WASignalGroup/GroupProtocol.js +1771 -0
- package/WASignalGroup/ciphertext_message.js +10 -0
- package/WASignalGroup/group_cipher.js +103 -0
- package/WASignalGroup/group_session_builder.js +39 -0
- package/WASignalGroup/index.js +5 -0
- package/WASignalGroup/keyhelper.js +17 -0
- package/WASignalGroup/protobufs.js +2 -0
- package/WASignalGroup/queue_job.js +64 -0
- package/WASignalGroup/sender_chain_key.js +38 -0
- package/WASignalGroup/sender_key_distribution_message.js +68 -0
- package/WASignalGroup/sender_key_message.js +79 -0
- package/WASignalGroup/sender_key_name.js +59 -0
- package/WASignalGroup/sender_key_record.js +47 -0
- package/WASignalGroup/sender_key_state.js +110 -0
- package/WASignalGroup/sender_message_key.js +30 -0
- package/check-node-version.js +10 -0
- package/lib/Defaults/baileys-version.json +3 -0
- package/lib/Defaults/index.d.ts +51 -0
- package/lib/Defaults/index.js +108 -0
- package/lib/Defaults/phonenumber-mcc.json +223 -0
- package/lib/Signal/Group/ciphertext-message.d.ts +9 -0
- package/lib/Signal/Group/ciphertext-message.js +19 -0
- package/lib/Signal/Group/group-session-builder.d.ts +17 -0
- package/lib/Signal/Group/group-session-builder.js +72 -0
- package/lib/Signal/Group/group_cipher.d.ts +19 -0
- package/lib/Signal/Group/group_cipher.js +99 -0
- package/lib/Signal/Group/index.d.ts +11 -0
- package/lib/Signal/Group/index.js +61 -0
- package/lib/Signal/Group/keyhelper.d.ts +16 -0
- package/lib/Signal/Group/keyhelper.js +66 -0
- package/lib/Signal/Group/queue-job.d.ts +1 -0
- package/lib/Signal/Group/queue-job.js +64 -0
- package/lib/Signal/Group/sender-chain-key.d.ts +14 -0
- package/lib/Signal/Group/sender-chain-key.js +39 -0
- package/lib/Signal/Group/sender-key-distribution-message.d.ts +17 -0
- package/lib/Signal/Group/sender-key-distribution-message.js +71 -0
- package/lib/Signal/Group/sender-key-message.d.ts +19 -0
- package/lib/Signal/Group/sender-key-message.js +73 -0
- package/lib/Signal/Group/sender-key-name.d.ts +19 -0
- package/lib/Signal/Group/sender-key-name.js +59 -0
- package/lib/Signal/Group/sender-key-record.d.ts +32 -0
- package/lib/Signal/Group/sender-key-record.js +53 -0
- package/lib/Signal/Group/sender-key-record.ts +77 -0
- package/lib/Signal/Group/sender-key-state.d.ts +44 -0
- package/lib/Signal/Group/sender-key-state.js +104 -0
- package/lib/Signal/Group/sender-message-key.d.ts +11 -0
- package/lib/Signal/Group/sender-message-key.js +33 -0
- package/lib/Signal/libsignal.d.ts +3 -0
- package/lib/Signal/libsignal.js +153 -0
- package/lib/Socket/Client/index.d.ts +2 -0
- package/lib/Socket/Client/index.js +18 -0
- package/lib/Socket/Client/types.d.ts +15 -0
- package/lib/Socket/Client/types.js +14 -0
- package/lib/Socket/Client/websocket.d.ts +12 -0
- package/lib/Socket/Client/websocket.js +57 -0
- package/lib/Socket/business.d.ts +181 -0
- package/lib/Socket/business.js +259 -0
- package/lib/Socket/chats.d.ts +95 -0
- package/lib/Socket/chats.js +906 -0
- package/lib/Socket/community.d.ts +131 -0
- package/lib/Socket/community.js +369 -0
- package/lib/Socket/groups.d.ts +122 -0
- package/lib/Socket/groups.js +360 -0
- package/lib/Socket/index.d.ts +183 -0
- package/lib/Socket/index.js +10 -0
- package/lib/Socket/messages-recv.d.ts +170 -0
- package/lib/Socket/messages-recv.js +1074 -0
- package/lib/Socket/messages-send.d.ts +161 -0
- package/lib/Socket/messages-send.js +982 -0
- package/lib/Socket/newsletter.d.ts +140 -0
- package/lib/Socket/newsletter.js +242 -0
- package/lib/Socket/socket.d.ts +43 -0
- package/lib/Socket/socket.js +749 -0
- package/lib/Socket/usync.d.ts +36 -0
- package/lib/Socket/usync.js +71 -0
- package/lib/Store/index.d.ts +4 -0
- package/lib/Store/index.js +20 -0
- package/lib/Store/make-cache-manager-store.d.ts +13 -0
- package/lib/Store/make-cache-manager-store.js +77 -0
- package/lib/Store/make-in-memory-store.d.ts +117 -0
- package/lib/Store/make-in-memory-store.js +420 -0
- package/lib/Store/make-ordered-dictionary.d.ts +12 -0
- package/lib/Store/make-ordered-dictionary.js +83 -0
- package/lib/Store/object-repository.d.ts +10 -0
- package/lib/Store/object-repository.js +28 -0
- package/lib/Types/Auth.d.ts +103 -0
- package/lib/Types/Auth.js +2 -0
- package/lib/Types/Call.d.ts +13 -0
- package/lib/Types/Call.js +2 -0
- package/lib/Types/Chat.d.ts +115 -0
- package/lib/Types/Chat.js +6 -0
- package/lib/Types/Contact.d.ts +35 -0
- package/lib/Types/Contact.js +2 -0
- package/lib/Types/Events.d.ts +208 -0
- package/lib/Types/Events.js +2 -0
- package/lib/Types/GroupMetadata.d.ts +81 -0
- package/lib/Types/GroupMetadata.js +2 -0
- package/lib/Types/Label.d.ts +46 -0
- package/lib/Types/Label.js +28 -0
- package/lib/Types/LabelAssociation.d.ts +29 -0
- package/lib/Types/LabelAssociation.js +10 -0
- package/lib/Types/Message.d.ts +480 -0
- package/lib/Types/Message.js +9 -0
- package/lib/Types/MexUpdates.d.ts +9 -0
- package/lib/Types/MexUpdates.js +18 -0
- package/lib/Types/Newsletter.d.ts +92 -0
- package/lib/Types/Newsletter.js +33 -0
- package/lib/Types/Product.d.ts +78 -0
- package/lib/Types/Product.js +2 -0
- package/lib/Types/Signal.d.ts +57 -0
- package/lib/Types/Signal.js +2 -0
- package/lib/Types/Socket.d.ts +116 -0
- package/lib/Types/Socket.js +2 -0
- package/lib/Types/State.d.ts +27 -0
- package/lib/Types/State.js +2 -0
- package/lib/Types/USync.d.ts +25 -0
- package/lib/Types/USync.js +2 -0
- package/lib/Types/index.d.ts +70 -0
- package/lib/Types/index.js +42 -0
- package/lib/Utils/auth-utils.d.ts +18 -0
- package/lib/Utils/auth-utils.js +198 -0
- package/lib/Utils/baileys-event-stream.d.ts +16 -0
- package/lib/Utils/baileys-event-stream.js +64 -0
- package/lib/Utils/business.d.ts +22 -0
- package/lib/Utils/business.js +243 -0
- package/lib/Utils/chat-utils.d.ts +72 -0
- package/lib/Utils/chat-utils.js +762 -0
- package/lib/Utils/crypto.d.ts +40 -0
- package/lib/Utils/crypto.js +150 -0
- package/lib/Utils/decode-wa-message.d.ts +252 -0
- package/lib/Utils/decode-wa-message.js +232 -0
- package/lib/Utils/event-buffer.d.ts +35 -0
- package/lib/Utils/event-buffer.js +539 -0
- package/lib/Utils/generics.d.ts +96 -0
- package/lib/Utils/generics.js +553 -0
- package/lib/Utils/history.d.ts +29 -0
- package/lib/Utils/history.js +109 -0
- package/lib/Utils/index.d.ts +19 -0
- package/lib/Utils/index.js +35 -0
- package/lib/Utils/link-preview.d.ts +21 -0
- package/lib/Utils/link-preview.js +112 -0
- package/lib/Utils/logger.d.ts +11 -0
- package/lib/Utils/logger.js +7 -0
- package/lib/Utils/lt-hash.d.ts +12 -0
- package/lib/Utils/lt-hash.js +53 -0
- package/lib/Utils/make-mutex.d.ts +7 -0
- package/lib/Utils/make-mutex.js +45 -0
- package/lib/Utils/messages-media.d.ts +104 -0
- package/lib/Utils/messages-media.js +751 -0
- package/lib/Utils/messages.d.ts +80 -0
- package/lib/Utils/messages.js +1741 -0
- package/lib/Utils/noise-handler.d.ts +19 -0
- package/lib/Utils/noise-handler.js +150 -0
- package/lib/Utils/process-message.d.ts +41 -0
- package/lib/Utils/process-message.js +391 -0
- package/lib/Utils/signal.d.ts +33 -0
- package/lib/Utils/signal.js +154 -0
- package/lib/Utils/use-mongo-file-auth-state.d.ts +5 -0
- package/lib/Utils/use-mongo-file-auth-state.js +75 -0
- package/lib/Utils/use-multi-file-auth-state.d.ts +12 -0
- package/lib/Utils/use-multi-file-auth-state.js +123 -0
- package/lib/Utils/use-single-file-auth-state.d.ts +12 -0
- package/lib/Utils/use-single-file-auth-state.js +75 -0
- package/lib/Utils/validate-connection.d.ts +10 -0
- package/lib/Utils/validate-connection.js +174 -0
- package/lib/WABinary/constants.d.ts +27 -0
- package/lib/WABinary/constants.js +45 -0
- package/lib/WABinary/decode.d.ts +6 -0
- package/lib/WABinary/decode.js +255 -0
- package/lib/WABinary/encode.d.ts +2 -0
- package/lib/WABinary/encode.js +243 -0
- package/lib/WABinary/generic-utils.d.ts +16 -0
- package/lib/WABinary/generic-utils.js +125 -0
- package/lib/WABinary/index.d.ts +5 -0
- package/lib/WABinary/index.js +21 -0
- package/lib/WABinary/jid-utils.d.ts +34 -0
- package/lib/WABinary/jid-utils.js +73 -0
- package/lib/WABinary/types.d.ts +18 -0
- package/lib/WABinary/types.js +2 -0
- package/lib/WAM/BinaryInfo.d.ts +16 -0
- package/lib/WAM/BinaryInfo.js +14 -0
- package/lib/WAM/constants.d.ts +39 -0
- package/lib/WAM/constants.js +15362 -0
- package/lib/WAM/encode.d.ts +2 -0
- package/lib/WAM/encode.js +156 -0
- package/lib/WAM/index.d.ts +3 -0
- package/lib/WAM/index.js +19 -0
- package/lib/WAUSync/Protocols/USyncBotProfileProtocol.d.ts +25 -0
- package/lib/WAUSync/Protocols/USyncBotProfileProtocol.js +60 -0
- package/lib/WAUSync/Protocols/USyncContactProtocol.d.ts +9 -0
- package/lib/WAUSync/Protocols/USyncContactProtocol.js +32 -0
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.d.ts +22 -0
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.js +58 -0
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.d.ts +12 -0
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +31 -0
- package/lib/WAUSync/Protocols/USyncLIDProtocol.d.ts +8 -0
- package/lib/WAUSync/Protocols/USyncLIDProtocol.js +26 -0
- package/lib/WAUSync/Protocols/USyncStatusProtocol.d.ts +12 -0
- package/lib/WAUSync/Protocols/USyncStatusProtocol.js +42 -0
- package/lib/WAUSync/Protocols/index.d.ts +6 -0
- package/lib/WAUSync/Protocols/index.js +22 -0
- package/lib/WAUSync/USyncQuery.d.ts +28 -0
- package/lib/WAUSync/USyncQuery.js +88 -0
- package/lib/WAUSync/USyncUser.d.ts +12 -0
- package/lib/WAUSync/USyncUser.js +27 -0
- package/lib/WAUSync/index.d.ts +3 -0
- package/lib/WAUSync/index.js +19 -0
- package/lib/index.d.ts +13 -0
- package/lib/index.js +45 -0
- package/package.json +63 -0
|
@@ -0,0 +1,520 @@
|
|
|
1
|
+
/*eslint-disable block-scoped-var, id-length, no-control-regex, no-magic-numbers, no-prototype-builtins, no-redeclare, no-shadow, no-var, sort-vars*/
|
|
2
|
+
"use strict";
|
|
3
|
+
var $protobuf = require("protobufjs/minimal");
|
|
4
|
+
// Common aliases
|
|
5
|
+
var $Reader = $protobuf.Reader, $Writer = $protobuf.Writer, $util = $protobuf.util;
|
|
6
|
+
// Exported root namespace
|
|
7
|
+
var $root = $protobuf.roots["default"] || ($protobuf.roots["default"] = {});
|
|
8
|
+
$root.DeviceCapabilities = (function() {
|
|
9
|
+
/**
|
|
10
|
+
* Namespace DeviceCapabilities.
|
|
11
|
+
* @exports DeviceCapabilities
|
|
12
|
+
* @namespace
|
|
13
|
+
*/
|
|
14
|
+
var DeviceCapabilities = {};
|
|
15
|
+
DeviceCapabilities.DeviceCapabilities = (function() {
|
|
16
|
+
/**
|
|
17
|
+
* Properties of a DeviceCapabilities.
|
|
18
|
+
* @memberof DeviceCapabilities
|
|
19
|
+
* @interface IDeviceCapabilities
|
|
20
|
+
* @property {DeviceCapabilities.DeviceCapabilities.ChatLockSupportLevel|null} [chatLockSupportLevel] DeviceCapabilities chatLockSupportLevel
|
|
21
|
+
* @property {DeviceCapabilities.DeviceCapabilities.ILIDMigration|null} [lidMigration] DeviceCapabilities lidMigration
|
|
22
|
+
*/
|
|
23
|
+
/**
|
|
24
|
+
* Constructs a new DeviceCapabilities.
|
|
25
|
+
* @memberof DeviceCapabilities
|
|
26
|
+
* @classdesc Represents a DeviceCapabilities.
|
|
27
|
+
* @implements IDeviceCapabilities
|
|
28
|
+
* @constructor
|
|
29
|
+
* @param {DeviceCapabilities.IDeviceCapabilities=} [properties] Properties to set
|
|
30
|
+
*/
|
|
31
|
+
function DeviceCapabilities(properties) {
|
|
32
|
+
if (properties)
|
|
33
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
34
|
+
if (properties[keys[i]] != null)
|
|
35
|
+
this[keys[i]] = properties[keys[i]];
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* DeviceCapabilities chatLockSupportLevel.
|
|
39
|
+
* @member {DeviceCapabilities.DeviceCapabilities.ChatLockSupportLevel|null|undefined} chatLockSupportLevel
|
|
40
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
41
|
+
* @instance
|
|
42
|
+
*/
|
|
43
|
+
DeviceCapabilities.prototype.chatLockSupportLevel = null;
|
|
44
|
+
/**
|
|
45
|
+
* DeviceCapabilities lidMigration.
|
|
46
|
+
* @member {DeviceCapabilities.DeviceCapabilities.ILIDMigration|null|undefined} lidMigration
|
|
47
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
48
|
+
* @instance
|
|
49
|
+
*/
|
|
50
|
+
DeviceCapabilities.prototype.lidMigration = null;
|
|
51
|
+
// OneOf field names bound to virtual getters and setters
|
|
52
|
+
var $oneOfFields;
|
|
53
|
+
/**
|
|
54
|
+
* DeviceCapabilities _chatLockSupportLevel.
|
|
55
|
+
* @member {"chatLockSupportLevel"|undefined} _chatLockSupportLevel
|
|
56
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
57
|
+
* @instance
|
|
58
|
+
*/
|
|
59
|
+
Object.defineProperty(DeviceCapabilities.prototype, "_chatLockSupportLevel", {
|
|
60
|
+
get: $util.oneOfGetter($oneOfFields = ["chatLockSupportLevel"]),
|
|
61
|
+
set: $util.oneOfSetter($oneOfFields)
|
|
62
|
+
});
|
|
63
|
+
/**
|
|
64
|
+
* DeviceCapabilities _lidMigration.
|
|
65
|
+
* @member {"lidMigration"|undefined} _lidMigration
|
|
66
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
67
|
+
* @instance
|
|
68
|
+
*/
|
|
69
|
+
Object.defineProperty(DeviceCapabilities.prototype, "_lidMigration", {
|
|
70
|
+
get: $util.oneOfGetter($oneOfFields = ["lidMigration"]),
|
|
71
|
+
set: $util.oneOfSetter($oneOfFields)
|
|
72
|
+
});
|
|
73
|
+
/**
|
|
74
|
+
* Creates a new DeviceCapabilities instance using the specified properties.
|
|
75
|
+
* @function create
|
|
76
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
77
|
+
* @static
|
|
78
|
+
* @param {DeviceCapabilities.IDeviceCapabilities=} [properties] Properties to set
|
|
79
|
+
* @returns {DeviceCapabilities.DeviceCapabilities} DeviceCapabilities instance
|
|
80
|
+
*/
|
|
81
|
+
DeviceCapabilities.create = function create(properties) {
|
|
82
|
+
return new DeviceCapabilities(properties);
|
|
83
|
+
};
|
|
84
|
+
/**
|
|
85
|
+
* Encodes the specified DeviceCapabilities message. Does not implicitly {@link DeviceCapabilities.DeviceCapabilities.verify|verify} messages.
|
|
86
|
+
* @function encode
|
|
87
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
88
|
+
* @static
|
|
89
|
+
* @param {DeviceCapabilities.IDeviceCapabilities} message DeviceCapabilities message or plain object to encode
|
|
90
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
91
|
+
* @returns {$protobuf.Writer} Writer
|
|
92
|
+
*/
|
|
93
|
+
DeviceCapabilities.encode = function encode(message, writer) {
|
|
94
|
+
if (!writer)
|
|
95
|
+
writer = $Writer.create();
|
|
96
|
+
if (message.chatLockSupportLevel != null && Object.hasOwnProperty.call(message, "chatLockSupportLevel"))
|
|
97
|
+
writer.uint32(/* id 1, wireType 0 =*/8).int32(message.chatLockSupportLevel);
|
|
98
|
+
if (message.lidMigration != null && Object.hasOwnProperty.call(message, "lidMigration"))
|
|
99
|
+
$root.DeviceCapabilities.DeviceCapabilities.LIDMigration.encode(message.lidMigration, writer.uint32(/* id 2, wireType 2 =*/18).fork()).ldelim();
|
|
100
|
+
return writer;
|
|
101
|
+
};
|
|
102
|
+
/**
|
|
103
|
+
* Encodes the specified DeviceCapabilities message, length delimited. Does not implicitly {@link DeviceCapabilities.DeviceCapabilities.verify|verify} messages.
|
|
104
|
+
* @function encodeDelimited
|
|
105
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
106
|
+
* @static
|
|
107
|
+
* @param {DeviceCapabilities.IDeviceCapabilities} message DeviceCapabilities message or plain object to encode
|
|
108
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
109
|
+
* @returns {$protobuf.Writer} Writer
|
|
110
|
+
*/
|
|
111
|
+
DeviceCapabilities.encodeDelimited = function encodeDelimited(message, writer) {
|
|
112
|
+
return this.encode(message, writer).ldelim();
|
|
113
|
+
};
|
|
114
|
+
/**
|
|
115
|
+
* Decodes a DeviceCapabilities message from the specified reader or buffer.
|
|
116
|
+
* @function decode
|
|
117
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
118
|
+
* @static
|
|
119
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
120
|
+
* @param {number} [length] Message length if known beforehand
|
|
121
|
+
* @returns {DeviceCapabilities.DeviceCapabilities} DeviceCapabilities
|
|
122
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
123
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
124
|
+
*/
|
|
125
|
+
DeviceCapabilities.decode = function decode(reader, length, error) {
|
|
126
|
+
if (!(reader instanceof $Reader))
|
|
127
|
+
reader = $Reader.create(reader);
|
|
128
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.DeviceCapabilities.DeviceCapabilities();
|
|
129
|
+
while (reader.pos < end) {
|
|
130
|
+
var tag = reader.uint32();
|
|
131
|
+
if (tag === error)
|
|
132
|
+
break;
|
|
133
|
+
switch (tag >>> 3) {
|
|
134
|
+
case 1: {
|
|
135
|
+
message.chatLockSupportLevel = reader.int32();
|
|
136
|
+
break;
|
|
137
|
+
}
|
|
138
|
+
case 2: {
|
|
139
|
+
message.lidMigration = $root.DeviceCapabilities.DeviceCapabilities.LIDMigration.decode(reader, reader.uint32());
|
|
140
|
+
break;
|
|
141
|
+
}
|
|
142
|
+
default:
|
|
143
|
+
reader.skipType(tag & 7);
|
|
144
|
+
break;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
return message;
|
|
148
|
+
};
|
|
149
|
+
/**
|
|
150
|
+
* Decodes a DeviceCapabilities message from the specified reader or buffer, length delimited.
|
|
151
|
+
* @function decodeDelimited
|
|
152
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
153
|
+
* @static
|
|
154
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
155
|
+
* @returns {DeviceCapabilities.DeviceCapabilities} DeviceCapabilities
|
|
156
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
157
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
158
|
+
*/
|
|
159
|
+
DeviceCapabilities.decodeDelimited = function decodeDelimited(reader) {
|
|
160
|
+
if (!(reader instanceof $Reader))
|
|
161
|
+
reader = new $Reader(reader);
|
|
162
|
+
return this.decode(reader, reader.uint32());
|
|
163
|
+
};
|
|
164
|
+
/**
|
|
165
|
+
* Verifies a DeviceCapabilities message.
|
|
166
|
+
* @function verify
|
|
167
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
168
|
+
* @static
|
|
169
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
170
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
171
|
+
*/
|
|
172
|
+
DeviceCapabilities.verify = function verify(message) {
|
|
173
|
+
if (typeof message !== "object" || message === null)
|
|
174
|
+
return "object expected";
|
|
175
|
+
var properties = {};
|
|
176
|
+
if (message.chatLockSupportLevel != null && message.hasOwnProperty("chatLockSupportLevel")) {
|
|
177
|
+
properties._chatLockSupportLevel = 1;
|
|
178
|
+
switch (message.chatLockSupportLevel) {
|
|
179
|
+
default:
|
|
180
|
+
return "chatLockSupportLevel: enum value expected";
|
|
181
|
+
case 0:
|
|
182
|
+
case 1:
|
|
183
|
+
case 2:
|
|
184
|
+
break;
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
if (message.lidMigration != null && message.hasOwnProperty("lidMigration")) {
|
|
188
|
+
properties._lidMigration = 1;
|
|
189
|
+
{
|
|
190
|
+
var error = $root.DeviceCapabilities.DeviceCapabilities.LIDMigration.verify(message.lidMigration);
|
|
191
|
+
if (error)
|
|
192
|
+
return "lidMigration." + error;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
return null;
|
|
196
|
+
};
|
|
197
|
+
/**
|
|
198
|
+
* Creates a DeviceCapabilities message from a plain object. Also converts values to their respective internal types.
|
|
199
|
+
* @function fromObject
|
|
200
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
201
|
+
* @static
|
|
202
|
+
* @param {Object.<string,*>} object Plain object
|
|
203
|
+
* @returns {DeviceCapabilities.DeviceCapabilities} DeviceCapabilities
|
|
204
|
+
*/
|
|
205
|
+
DeviceCapabilities.fromObject = function fromObject(object) {
|
|
206
|
+
if (object instanceof $root.DeviceCapabilities.DeviceCapabilities)
|
|
207
|
+
return object;
|
|
208
|
+
var message = new $root.DeviceCapabilities.DeviceCapabilities();
|
|
209
|
+
switch (object.chatLockSupportLevel) {
|
|
210
|
+
default:
|
|
211
|
+
if (typeof object.chatLockSupportLevel === "number") {
|
|
212
|
+
message.chatLockSupportLevel = object.chatLockSupportLevel;
|
|
213
|
+
break;
|
|
214
|
+
}
|
|
215
|
+
break;
|
|
216
|
+
case "NONE":
|
|
217
|
+
case 0:
|
|
218
|
+
message.chatLockSupportLevel = 0;
|
|
219
|
+
break;
|
|
220
|
+
case "MINIMAL":
|
|
221
|
+
case 1:
|
|
222
|
+
message.chatLockSupportLevel = 1;
|
|
223
|
+
break;
|
|
224
|
+
case "FULL":
|
|
225
|
+
case 2:
|
|
226
|
+
message.chatLockSupportLevel = 2;
|
|
227
|
+
break;
|
|
228
|
+
}
|
|
229
|
+
if (object.lidMigration != null) {
|
|
230
|
+
if (typeof object.lidMigration !== "object")
|
|
231
|
+
throw TypeError(".DeviceCapabilities.DeviceCapabilities.lidMigration: object expected");
|
|
232
|
+
message.lidMigration = $root.DeviceCapabilities.DeviceCapabilities.LIDMigration.fromObject(object.lidMigration);
|
|
233
|
+
}
|
|
234
|
+
return message;
|
|
235
|
+
};
|
|
236
|
+
/**
|
|
237
|
+
* Creates a plain object from a DeviceCapabilities message. Also converts values to other types if specified.
|
|
238
|
+
* @function toObject
|
|
239
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
240
|
+
* @static
|
|
241
|
+
* @param {DeviceCapabilities.DeviceCapabilities} message DeviceCapabilities
|
|
242
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
243
|
+
* @returns {Object.<string,*>} Plain object
|
|
244
|
+
*/
|
|
245
|
+
DeviceCapabilities.toObject = function toObject(message, options) {
|
|
246
|
+
if (!options)
|
|
247
|
+
options = {};
|
|
248
|
+
var object = {};
|
|
249
|
+
if (message.chatLockSupportLevel != null && message.hasOwnProperty("chatLockSupportLevel")) {
|
|
250
|
+
object.chatLockSupportLevel = options.enums === String ? $root.DeviceCapabilities.DeviceCapabilities.ChatLockSupportLevel[message.chatLockSupportLevel] === undefined ? message.chatLockSupportLevel : $root.DeviceCapabilities.DeviceCapabilities.ChatLockSupportLevel[message.chatLockSupportLevel] : message.chatLockSupportLevel;
|
|
251
|
+
if (options.oneofs)
|
|
252
|
+
object._chatLockSupportLevel = "chatLockSupportLevel";
|
|
253
|
+
}
|
|
254
|
+
if (message.lidMigration != null && message.hasOwnProperty("lidMigration")) {
|
|
255
|
+
object.lidMigration = $root.DeviceCapabilities.DeviceCapabilities.LIDMigration.toObject(message.lidMigration, options);
|
|
256
|
+
if (options.oneofs)
|
|
257
|
+
object._lidMigration = "lidMigration";
|
|
258
|
+
}
|
|
259
|
+
return object;
|
|
260
|
+
};
|
|
261
|
+
/**
|
|
262
|
+
* Converts this DeviceCapabilities to JSON.
|
|
263
|
+
* @function toJSON
|
|
264
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
265
|
+
* @instance
|
|
266
|
+
* @returns {Object.<string,*>} JSON object
|
|
267
|
+
*/
|
|
268
|
+
DeviceCapabilities.prototype.toJSON = function toJSON() {
|
|
269
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
270
|
+
};
|
|
271
|
+
/**
|
|
272
|
+
* Gets the default type url for DeviceCapabilities
|
|
273
|
+
* @function getTypeUrl
|
|
274
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
275
|
+
* @static
|
|
276
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
277
|
+
* @returns {string} The default type url
|
|
278
|
+
*/
|
|
279
|
+
DeviceCapabilities.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
280
|
+
if (typeUrlPrefix === undefined) {
|
|
281
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
282
|
+
}
|
|
283
|
+
return typeUrlPrefix + "/DeviceCapabilities.DeviceCapabilities";
|
|
284
|
+
};
|
|
285
|
+
/**
|
|
286
|
+
* ChatLockSupportLevel enum.
|
|
287
|
+
* @name DeviceCapabilities.DeviceCapabilities.ChatLockSupportLevel
|
|
288
|
+
* @enum {number}
|
|
289
|
+
* @property {number} NONE=0 NONE value
|
|
290
|
+
* @property {number} MINIMAL=1 MINIMAL value
|
|
291
|
+
* @property {number} FULL=2 FULL value
|
|
292
|
+
*/
|
|
293
|
+
DeviceCapabilities.ChatLockSupportLevel = (function() {
|
|
294
|
+
var valuesById = {}, values = Object.create(valuesById);
|
|
295
|
+
values[valuesById[0] = "NONE"] = 0;
|
|
296
|
+
values[valuesById[1] = "MINIMAL"] = 1;
|
|
297
|
+
values[valuesById[2] = "FULL"] = 2;
|
|
298
|
+
return values;
|
|
299
|
+
})();
|
|
300
|
+
DeviceCapabilities.LIDMigration = (function() {
|
|
301
|
+
/**
|
|
302
|
+
* Properties of a LIDMigration.
|
|
303
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
304
|
+
* @interface ILIDMigration
|
|
305
|
+
* @property {number|Long|null} [chatDbMigrationTimestamp] LIDMigration chatDbMigrationTimestamp
|
|
306
|
+
*/
|
|
307
|
+
/**
|
|
308
|
+
* Constructs a new LIDMigration.
|
|
309
|
+
* @memberof DeviceCapabilities.DeviceCapabilities
|
|
310
|
+
* @classdesc Represents a LIDMigration.
|
|
311
|
+
* @implements ILIDMigration
|
|
312
|
+
* @constructor
|
|
313
|
+
* @param {DeviceCapabilities.DeviceCapabilities.ILIDMigration=} [properties] Properties to set
|
|
314
|
+
*/
|
|
315
|
+
function LIDMigration(properties) {
|
|
316
|
+
if (properties)
|
|
317
|
+
for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i)
|
|
318
|
+
if (properties[keys[i]] != null)
|
|
319
|
+
this[keys[i]] = properties[keys[i]];
|
|
320
|
+
}
|
|
321
|
+
/**
|
|
322
|
+
* LIDMigration chatDbMigrationTimestamp.
|
|
323
|
+
* @member {number|Long|null|undefined} chatDbMigrationTimestamp
|
|
324
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
325
|
+
* @instance
|
|
326
|
+
*/
|
|
327
|
+
LIDMigration.prototype.chatDbMigrationTimestamp = null;
|
|
328
|
+
// OneOf field names bound to virtual getters and setters
|
|
329
|
+
var $oneOfFields;
|
|
330
|
+
/**
|
|
331
|
+
* LIDMigration _chatDbMigrationTimestamp.
|
|
332
|
+
* @member {"chatDbMigrationTimestamp"|undefined} _chatDbMigrationTimestamp
|
|
333
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
334
|
+
* @instance
|
|
335
|
+
*/
|
|
336
|
+
Object.defineProperty(LIDMigration.prototype, "_chatDbMigrationTimestamp", {
|
|
337
|
+
get: $util.oneOfGetter($oneOfFields = ["chatDbMigrationTimestamp"]),
|
|
338
|
+
set: $util.oneOfSetter($oneOfFields)
|
|
339
|
+
});
|
|
340
|
+
/**
|
|
341
|
+
* Creates a new LIDMigration instance using the specified properties.
|
|
342
|
+
* @function create
|
|
343
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
344
|
+
* @static
|
|
345
|
+
* @param {DeviceCapabilities.DeviceCapabilities.ILIDMigration=} [properties] Properties to set
|
|
346
|
+
* @returns {DeviceCapabilities.DeviceCapabilities.LIDMigration} LIDMigration instance
|
|
347
|
+
*/
|
|
348
|
+
LIDMigration.create = function create(properties) {
|
|
349
|
+
return new LIDMigration(properties);
|
|
350
|
+
};
|
|
351
|
+
/**
|
|
352
|
+
* Encodes the specified LIDMigration message. Does not implicitly {@link DeviceCapabilities.DeviceCapabilities.LIDMigration.verify|verify} messages.
|
|
353
|
+
* @function encode
|
|
354
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
355
|
+
* @static
|
|
356
|
+
* @param {DeviceCapabilities.DeviceCapabilities.ILIDMigration} message LIDMigration message or plain object to encode
|
|
357
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
358
|
+
* @returns {$protobuf.Writer} Writer
|
|
359
|
+
*/
|
|
360
|
+
LIDMigration.encode = function encode(message, writer) {
|
|
361
|
+
if (!writer)
|
|
362
|
+
writer = $Writer.create();
|
|
363
|
+
if (message.chatDbMigrationTimestamp != null && Object.hasOwnProperty.call(message, "chatDbMigrationTimestamp"))
|
|
364
|
+
writer.uint32(/* id 1, wireType 0 =*/8).uint64(message.chatDbMigrationTimestamp);
|
|
365
|
+
return writer;
|
|
366
|
+
};
|
|
367
|
+
/**
|
|
368
|
+
* Encodes the specified LIDMigration message, length delimited. Does not implicitly {@link DeviceCapabilities.DeviceCapabilities.LIDMigration.verify|verify} messages.
|
|
369
|
+
* @function encodeDelimited
|
|
370
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
371
|
+
* @static
|
|
372
|
+
* @param {DeviceCapabilities.DeviceCapabilities.ILIDMigration} message LIDMigration message or plain object to encode
|
|
373
|
+
* @param {$protobuf.Writer} [writer] Writer to encode to
|
|
374
|
+
* @returns {$protobuf.Writer} Writer
|
|
375
|
+
*/
|
|
376
|
+
LIDMigration.encodeDelimited = function encodeDelimited(message, writer) {
|
|
377
|
+
return this.encode(message, writer).ldelim();
|
|
378
|
+
};
|
|
379
|
+
/**
|
|
380
|
+
* Decodes a LIDMigration message from the specified reader or buffer.
|
|
381
|
+
* @function decode
|
|
382
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
383
|
+
* @static
|
|
384
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
385
|
+
* @param {number} [length] Message length if known beforehand
|
|
386
|
+
* @returns {DeviceCapabilities.DeviceCapabilities.LIDMigration} LIDMigration
|
|
387
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
388
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
389
|
+
*/
|
|
390
|
+
LIDMigration.decode = function decode(reader, length, error) {
|
|
391
|
+
if (!(reader instanceof $Reader))
|
|
392
|
+
reader = $Reader.create(reader);
|
|
393
|
+
var end = length === undefined ? reader.len : reader.pos + length, message = new $root.DeviceCapabilities.DeviceCapabilities.LIDMigration();
|
|
394
|
+
while (reader.pos < end) {
|
|
395
|
+
var tag = reader.uint32();
|
|
396
|
+
if (tag === error)
|
|
397
|
+
break;
|
|
398
|
+
switch (tag >>> 3) {
|
|
399
|
+
case 1: {
|
|
400
|
+
message.chatDbMigrationTimestamp = reader.uint64();
|
|
401
|
+
break;
|
|
402
|
+
}
|
|
403
|
+
default:
|
|
404
|
+
reader.skipType(tag & 7);
|
|
405
|
+
break;
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
return message;
|
|
409
|
+
};
|
|
410
|
+
/**
|
|
411
|
+
* Decodes a LIDMigration message from the specified reader or buffer, length delimited.
|
|
412
|
+
* @function decodeDelimited
|
|
413
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
414
|
+
* @static
|
|
415
|
+
* @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from
|
|
416
|
+
* @returns {DeviceCapabilities.DeviceCapabilities.LIDMigration} LIDMigration
|
|
417
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
418
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
419
|
+
*/
|
|
420
|
+
LIDMigration.decodeDelimited = function decodeDelimited(reader) {
|
|
421
|
+
if (!(reader instanceof $Reader))
|
|
422
|
+
reader = new $Reader(reader);
|
|
423
|
+
return this.decode(reader, reader.uint32());
|
|
424
|
+
};
|
|
425
|
+
/**
|
|
426
|
+
* Verifies a LIDMigration message.
|
|
427
|
+
* @function verify
|
|
428
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
429
|
+
* @static
|
|
430
|
+
* @param {Object.<string,*>} message Plain object to verify
|
|
431
|
+
* @returns {string|null} `null` if valid, otherwise the reason why it is not
|
|
432
|
+
*/
|
|
433
|
+
LIDMigration.verify = function verify(message) {
|
|
434
|
+
if (typeof message !== "object" || message === null)
|
|
435
|
+
return "object expected";
|
|
436
|
+
var properties = {};
|
|
437
|
+
if (message.chatDbMigrationTimestamp != null && message.hasOwnProperty("chatDbMigrationTimestamp")) {
|
|
438
|
+
properties._chatDbMigrationTimestamp = 1;
|
|
439
|
+
if (!$util.isInteger(message.chatDbMigrationTimestamp) && !(message.chatDbMigrationTimestamp && $util.isInteger(message.chatDbMigrationTimestamp.low) && $util.isInteger(message.chatDbMigrationTimestamp.high)))
|
|
440
|
+
return "chatDbMigrationTimestamp: integer|Long expected";
|
|
441
|
+
}
|
|
442
|
+
return null;
|
|
443
|
+
};
|
|
444
|
+
/**
|
|
445
|
+
* Creates a LIDMigration message from a plain object. Also converts values to their respective internal types.
|
|
446
|
+
* @function fromObject
|
|
447
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
448
|
+
* @static
|
|
449
|
+
* @param {Object.<string,*>} object Plain object
|
|
450
|
+
* @returns {DeviceCapabilities.DeviceCapabilities.LIDMigration} LIDMigration
|
|
451
|
+
*/
|
|
452
|
+
LIDMigration.fromObject = function fromObject(object) {
|
|
453
|
+
if (object instanceof $root.DeviceCapabilities.DeviceCapabilities.LIDMigration)
|
|
454
|
+
return object;
|
|
455
|
+
var message = new $root.DeviceCapabilities.DeviceCapabilities.LIDMigration();
|
|
456
|
+
if (object.chatDbMigrationTimestamp != null)
|
|
457
|
+
if ($util.Long)
|
|
458
|
+
(message.chatDbMigrationTimestamp = $util.Long.fromValue(object.chatDbMigrationTimestamp)).unsigned = true;
|
|
459
|
+
else if (typeof object.chatDbMigrationTimestamp === "string")
|
|
460
|
+
message.chatDbMigrationTimestamp = parseInt(object.chatDbMigrationTimestamp, 10);
|
|
461
|
+
else if (typeof object.chatDbMigrationTimestamp === "number")
|
|
462
|
+
message.chatDbMigrationTimestamp = object.chatDbMigrationTimestamp;
|
|
463
|
+
else if (typeof object.chatDbMigrationTimestamp === "object")
|
|
464
|
+
message.chatDbMigrationTimestamp = new $util.LongBits(object.chatDbMigrationTimestamp.low >>> 0, object.chatDbMigrationTimestamp.high >>> 0).toNumber(true);
|
|
465
|
+
return message;
|
|
466
|
+
};
|
|
467
|
+
/**
|
|
468
|
+
* Creates a plain object from a LIDMigration message. Also converts values to other types if specified.
|
|
469
|
+
* @function toObject
|
|
470
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
471
|
+
* @static
|
|
472
|
+
* @param {DeviceCapabilities.DeviceCapabilities.LIDMigration} message LIDMigration
|
|
473
|
+
* @param {$protobuf.IConversionOptions} [options] Conversion options
|
|
474
|
+
* @returns {Object.<string,*>} Plain object
|
|
475
|
+
*/
|
|
476
|
+
LIDMigration.toObject = function toObject(message, options) {
|
|
477
|
+
if (!options)
|
|
478
|
+
options = {};
|
|
479
|
+
var object = {};
|
|
480
|
+
if (message.chatDbMigrationTimestamp != null && message.hasOwnProperty("chatDbMigrationTimestamp")) {
|
|
481
|
+
if (typeof message.chatDbMigrationTimestamp === "number")
|
|
482
|
+
object.chatDbMigrationTimestamp = options.longs === String ? String(message.chatDbMigrationTimestamp) : message.chatDbMigrationTimestamp;
|
|
483
|
+
else
|
|
484
|
+
object.chatDbMigrationTimestamp = options.longs === String ? $util.Long.prototype.toString.call(message.chatDbMigrationTimestamp) : options.longs === Number ? new $util.LongBits(message.chatDbMigrationTimestamp.low >>> 0, message.chatDbMigrationTimestamp.high >>> 0).toNumber(true) : message.chatDbMigrationTimestamp;
|
|
485
|
+
if (options.oneofs)
|
|
486
|
+
object._chatDbMigrationTimestamp = "chatDbMigrationTimestamp";
|
|
487
|
+
}
|
|
488
|
+
return object;
|
|
489
|
+
};
|
|
490
|
+
/**
|
|
491
|
+
* Converts this LIDMigration to JSON.
|
|
492
|
+
* @function toJSON
|
|
493
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
494
|
+
* @instance
|
|
495
|
+
* @returns {Object.<string,*>} JSON object
|
|
496
|
+
*/
|
|
497
|
+
LIDMigration.prototype.toJSON = function toJSON() {
|
|
498
|
+
return this.constructor.toObject(this, $protobuf.util.toJSONOptions);
|
|
499
|
+
};
|
|
500
|
+
/**
|
|
501
|
+
* Gets the default type url for LIDMigration
|
|
502
|
+
* @function getTypeUrl
|
|
503
|
+
* @memberof DeviceCapabilities.DeviceCapabilities.LIDMigration
|
|
504
|
+
* @static
|
|
505
|
+
* @param {string} [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
506
|
+
* @returns {string} The default type url
|
|
507
|
+
*/
|
|
508
|
+
LIDMigration.getTypeUrl = function getTypeUrl(typeUrlPrefix) {
|
|
509
|
+
if (typeUrlPrefix === undefined) {
|
|
510
|
+
typeUrlPrefix = "type.googleapis.com";
|
|
511
|
+
}
|
|
512
|
+
return typeUrlPrefix + "/DeviceCapabilities.DeviceCapabilities.LIDMigration";
|
|
513
|
+
};
|
|
514
|
+
return LIDMigration;
|
|
515
|
+
})();
|
|
516
|
+
return DeviceCapabilities;
|
|
517
|
+
})();
|
|
518
|
+
return DeviceCapabilities;
|
|
519
|
+
})();
|
|
520
|
+
module.exports = $root;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
syntax = "proto3";
|
|
2
|
+
package DeviceCapabilities;
|
|
3
|
+
message DeviceCapabilities {
|
|
4
|
+
optional ChatLockSupportLevel chatLockSupportLevel = 1;
|
|
5
|
+
optional LIDMigration lidMigration = 2;
|
|
6
|
+
enum ChatLockSupportLevel {
|
|
7
|
+
NONE = 0;
|
|
8
|
+
MINIMAL = 1;
|
|
9
|
+
FULL = 2;
|
|
10
|
+
}
|
|
11
|
+
message LIDMigration {
|
|
12
|
+
optional uint64 chatDbMigrationTimestamp = 1;
|
|
13
|
+
}
|
|
14
|
+
}
|