@m1kad0/hannah-proto 3.7.0 → 3.7.2

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.
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  // Code generated by protoc-gen-ts_proto. DO NOT EDIT.
3
3
  // versions:
4
- // protoc-gen-ts_proto v2.12.0
4
+ // protoc-gen-ts_proto v2.12.1
5
5
  // protoc unknown
6
6
  // source: hannah/wakeword_capture.proto
7
7
  Object.defineProperty(exports, "__esModule", { value: true });
@@ -38,32 +38,42 @@ exports.SatelliteCaptureRequest = {
38
38
  },
39
39
  decode(input, length) {
40
40
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
41
- const end = length === undefined ? reader.len : reader.pos + length;
42
- const message = createBaseSatelliteCaptureRequest();
43
- while (reader.pos < end) {
44
- const tag = reader.uint32();
45
- switch (tag >>> 3) {
46
- case 1: {
47
- if (tag !== 10) {
48
- break;
41
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
42
+ if (previousRecursionDepth >= 100) {
43
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
44
+ }
45
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
46
+ try {
47
+ const end = length === undefined ? reader.len : reader.pos + length;
48
+ const message = createBaseSatelliteCaptureRequest();
49
+ while (reader.pos < end) {
50
+ const tag = reader.uint32();
51
+ switch (tag >>> 3) {
52
+ case 1: {
53
+ if (tag !== 10) {
54
+ break;
55
+ }
56
+ message.deviceId = reader.string();
57
+ continue;
49
58
  }
50
- message.deviceId = reader.string();
51
- continue;
52
- }
53
- case 2: {
54
- if (tag !== 18) {
55
- break;
59
+ case 2: {
60
+ if (tag !== 18) {
61
+ break;
62
+ }
63
+ message.sampleType = reader.string();
64
+ continue;
56
65
  }
57
- message.sampleType = reader.string();
58
- continue;
59
66
  }
67
+ if ((tag & 7) === 4 || tag === 0) {
68
+ break;
69
+ }
70
+ reader.skip(tag & 7);
60
71
  }
61
- if ((tag & 7) === 4 || tag === 0) {
62
- break;
63
- }
64
- reader.skip(tag & 7);
72
+ return message;
73
+ }
74
+ finally {
75
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
65
76
  }
66
- return message;
67
77
  },
68
78
  create(base) {
69
79
  return exports.SatelliteCaptureRequest.fromPartial(base ?? {});
@@ -90,32 +100,42 @@ exports.TriggerPlinkRequest = {
90
100
  },
91
101
  decode(input, length) {
92
102
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
93
- const end = length === undefined ? reader.len : reader.pos + length;
94
- const message = createBaseTriggerPlinkRequest();
95
- while (reader.pos < end) {
96
- const tag = reader.uint32();
97
- switch (tag >>> 3) {
98
- case 1: {
99
- if (tag !== 10) {
100
- break;
103
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
104
+ if (previousRecursionDepth >= 100) {
105
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
106
+ }
107
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
108
+ try {
109
+ const end = length === undefined ? reader.len : reader.pos + length;
110
+ const message = createBaseTriggerPlinkRequest();
111
+ while (reader.pos < end) {
112
+ const tag = reader.uint32();
113
+ switch (tag >>> 3) {
114
+ case 1: {
115
+ if (tag !== 10) {
116
+ break;
117
+ }
118
+ message.deviceId = reader.string();
119
+ continue;
101
120
  }
102
- message.deviceId = reader.string();
103
- continue;
104
- }
105
- case 2: {
106
- if (tag !== 21) {
107
- break;
121
+ case 2: {
122
+ if (tag !== 21) {
123
+ break;
124
+ }
125
+ message.recordDuration = reader.float();
126
+ continue;
108
127
  }
109
- message.recordDuration = reader.float();
110
- continue;
111
128
  }
129
+ if ((tag & 7) === 4 || tag === 0) {
130
+ break;
131
+ }
132
+ reader.skip(tag & 7);
112
133
  }
113
- if ((tag & 7) === 4 || tag === 0) {
114
- break;
115
- }
116
- reader.skip(tag & 7);
134
+ return message;
135
+ }
136
+ finally {
137
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
117
138
  }
118
- return message;
119
139
  },
120
140
  create(base) {
121
141
  return exports.TriggerPlinkRequest.fromPartial(base ?? {});
@@ -142,32 +162,42 @@ exports.SatelliteCaptureResponse = {
142
162
  },
143
163
  decode(input, length) {
144
164
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
145
- const end = length === undefined ? reader.len : reader.pos + length;
146
- const message = createBaseSatelliteCaptureResponse();
147
- while (reader.pos < end) {
148
- const tag = reader.uint32();
149
- switch (tag >>> 3) {
150
- case 1: {
151
- if (tag !== 8) {
152
- break;
165
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
166
+ if (previousRecursionDepth >= 100) {
167
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
168
+ }
169
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
170
+ try {
171
+ const end = length === undefined ? reader.len : reader.pos + length;
172
+ const message = createBaseSatelliteCaptureResponse();
173
+ while (reader.pos < end) {
174
+ const tag = reader.uint32();
175
+ switch (tag >>> 3) {
176
+ case 1: {
177
+ if (tag !== 8) {
178
+ break;
179
+ }
180
+ message.ok = reader.bool();
181
+ continue;
153
182
  }
154
- message.ok = reader.bool();
155
- continue;
156
- }
157
- case 2: {
158
- if (tag !== 18) {
159
- break;
183
+ case 2: {
184
+ if (tag !== 18) {
185
+ break;
186
+ }
187
+ message.error = reader.string();
188
+ continue;
160
189
  }
161
- message.error = reader.string();
162
- continue;
163
190
  }
191
+ if ((tag & 7) === 4 || tag === 0) {
192
+ break;
193
+ }
194
+ reader.skip(tag & 7);
164
195
  }
165
- if ((tag & 7) === 4 || tag === 0) {
166
- break;
167
- }
168
- reader.skip(tag & 7);
196
+ return message;
197
+ }
198
+ finally {
199
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
169
200
  }
170
- return message;
171
201
  },
172
202
  create(base) {
173
203
  return exports.SatelliteCaptureResponse.fromPartial(base ?? {});
@@ -197,39 +227,49 @@ exports.SatelliteAudioChunk = {
197
227
  },
198
228
  decode(input, length) {
199
229
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
200
- const end = length === undefined ? reader.len : reader.pos + length;
201
- const message = createBaseSatelliteAudioChunk();
202
- while (reader.pos < end) {
203
- const tag = reader.uint32();
204
- switch (tag >>> 3) {
205
- case 1: {
206
- if (tag !== 10) {
207
- break;
230
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
231
+ if (previousRecursionDepth >= 100) {
232
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
233
+ }
234
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
235
+ try {
236
+ const end = length === undefined ? reader.len : reader.pos + length;
237
+ const message = createBaseSatelliteAudioChunk();
238
+ while (reader.pos < end) {
239
+ const tag = reader.uint32();
240
+ switch (tag >>> 3) {
241
+ case 1: {
242
+ if (tag !== 10) {
243
+ break;
244
+ }
245
+ message.pcm = reader.bytes();
246
+ continue;
208
247
  }
209
- message.pcm = reader.bytes();
210
- continue;
211
- }
212
- case 2: {
213
- if (tag !== 16) {
214
- break;
248
+ case 2: {
249
+ if (tag !== 16) {
250
+ break;
251
+ }
252
+ message.sampleRate = reader.int32();
253
+ continue;
215
254
  }
216
- message.sampleRate = reader.int32();
217
- continue;
218
- }
219
- case 3: {
220
- if (tag !== 24) {
221
- break;
255
+ case 3: {
256
+ if (tag !== 24) {
257
+ break;
258
+ }
259
+ message.endOfUtterance = reader.bool();
260
+ continue;
222
261
  }
223
- message.endOfUtterance = reader.bool();
224
- continue;
225
262
  }
263
+ if ((tag & 7) === 4 || tag === 0) {
264
+ break;
265
+ }
266
+ reader.skip(tag & 7);
226
267
  }
227
- if ((tag & 7) === 4 || tag === 0) {
228
- break;
229
- }
230
- reader.skip(tag & 7);
268
+ return message;
269
+ }
270
+ finally {
271
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
231
272
  }
232
- return message;
233
273
  },
234
274
  create(base) {
235
275
  return exports.SatelliteAudioChunk.fromPartial(base ?? {});
@@ -263,46 +303,56 @@ exports.CaptureCommand = {
263
303
  },
264
304
  decode(input, length) {
265
305
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
266
- const end = length === undefined ? reader.len : reader.pos + length;
267
- const message = createBaseCaptureCommand();
268
- while (reader.pos < end) {
269
- const tag = reader.uint32();
270
- switch (tag >>> 3) {
271
- case 1: {
272
- if (tag !== 10) {
273
- break;
306
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
307
+ if (previousRecursionDepth >= 100) {
308
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
309
+ }
310
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
311
+ try {
312
+ const end = length === undefined ? reader.len : reader.pos + length;
313
+ const message = createBaseCaptureCommand();
314
+ while (reader.pos < end) {
315
+ const tag = reader.uint32();
316
+ switch (tag >>> 3) {
317
+ case 1: {
318
+ if (tag !== 10) {
319
+ break;
320
+ }
321
+ message.deviceId = reader.string();
322
+ continue;
274
323
  }
275
- message.deviceId = reader.string();
276
- continue;
277
- }
278
- case 2: {
279
- if (tag !== 18) {
280
- break;
324
+ case 2: {
325
+ if (tag !== 18) {
326
+ break;
327
+ }
328
+ message.sampleType = exports.SampleType.decode(reader, reader.uint32());
329
+ continue;
281
330
  }
282
- message.sampleType = exports.SampleType.decode(reader, reader.uint32());
283
- continue;
284
- }
285
- case 3: {
286
- if (tag !== 24) {
287
- break;
331
+ case 3: {
332
+ if (tag !== 24) {
333
+ break;
334
+ }
335
+ message.captureMode = reader.int32();
336
+ continue;
288
337
  }
289
- message.captureMode = reader.int32();
290
- continue;
291
- }
292
- case 4: {
293
- if (tag !== 32) {
294
- break;
338
+ case 4: {
339
+ if (tag !== 32) {
340
+ break;
341
+ }
342
+ message.stop = reader.bool();
343
+ continue;
295
344
  }
296
- message.stop = reader.bool();
297
- continue;
298
345
  }
346
+ if ((tag & 7) === 4 || tag === 0) {
347
+ break;
348
+ }
349
+ reader.skip(tag & 7);
299
350
  }
300
- if ((tag & 7) === 4 || tag === 0) {
301
- break;
302
- }
303
- reader.skip(tag & 7);
351
+ return message;
352
+ }
353
+ finally {
354
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
304
355
  }
305
- return message;
306
356
  },
307
357
  create(base) {
308
358
  return exports.CaptureCommand.fromPartial(base ?? {});
@@ -333,32 +383,42 @@ exports.SampleType = {
333
383
  },
334
384
  decode(input, length) {
335
385
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
336
- const end = length === undefined ? reader.len : reader.pos + length;
337
- const message = createBaseSampleType();
338
- while (reader.pos < end) {
339
- const tag = reader.uint32();
340
- switch (tag >>> 3) {
341
- case 1: {
342
- if (tag !== 10) {
343
- break;
386
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
387
+ if (previousRecursionDepth >= 100) {
388
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
389
+ }
390
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
391
+ try {
392
+ const end = length === undefined ? reader.len : reader.pos + length;
393
+ const message = createBaseSampleType();
394
+ while (reader.pos < end) {
395
+ const tag = reader.uint32();
396
+ switch (tag >>> 3) {
397
+ case 1: {
398
+ if (tag !== 10) {
399
+ break;
400
+ }
401
+ message.noise = exports.NoiseSample.decode(reader, reader.uint32());
402
+ continue;
344
403
  }
345
- message.noise = exports.NoiseSample.decode(reader, reader.uint32());
346
- continue;
347
- }
348
- case 2: {
349
- if (tag !== 18) {
350
- break;
404
+ case 2: {
405
+ if (tag !== 18) {
406
+ break;
407
+ }
408
+ message.heyHannah = exports.HeyHannahSample.decode(reader, reader.uint32());
409
+ continue;
351
410
  }
352
- message.heyHannah = exports.HeyHannahSample.decode(reader, reader.uint32());
353
- continue;
354
411
  }
412
+ if ((tag & 7) === 4 || tag === 0) {
413
+ break;
414
+ }
415
+ reader.skip(tag & 7);
355
416
  }
356
- if ((tag & 7) === 4 || tag === 0) {
357
- break;
358
- }
359
- reader.skip(tag & 7);
417
+ return message;
418
+ }
419
+ finally {
420
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
360
421
  }
361
- return message;
362
422
  },
363
423
  create(base) {
364
424
  return exports.SampleType.fromPartial(base ?? {});
@@ -383,18 +443,28 @@ exports.NoiseSample = {
383
443
  },
384
444
  decode(input, length) {
385
445
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
386
- const end = length === undefined ? reader.len : reader.pos + length;
387
- const message = createBaseNoiseSample();
388
- while (reader.pos < end) {
389
- const tag = reader.uint32();
390
- switch (tag >>> 3) {
391
- }
392
- if ((tag & 7) === 4 || tag === 0) {
393
- break;
446
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
447
+ if (previousRecursionDepth >= 100) {
448
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
449
+ }
450
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
451
+ try {
452
+ const end = length === undefined ? reader.len : reader.pos + length;
453
+ const message = createBaseNoiseSample();
454
+ while (reader.pos < end) {
455
+ const tag = reader.uint32();
456
+ switch (tag >>> 3) {
457
+ }
458
+ if ((tag & 7) === 4 || tag === 0) {
459
+ break;
460
+ }
461
+ reader.skip(tag & 7);
394
462
  }
395
- reader.skip(tag & 7);
463
+ return message;
464
+ }
465
+ finally {
466
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
396
467
  }
397
- return message;
398
468
  },
399
469
  create(base) {
400
470
  return exports.NoiseSample.fromPartial(base ?? {});
@@ -413,18 +483,28 @@ exports.HeyHannahSample = {
413
483
  },
414
484
  decode(input, length) {
415
485
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
416
- const end = length === undefined ? reader.len : reader.pos + length;
417
- const message = createBaseHeyHannahSample();
418
- while (reader.pos < end) {
419
- const tag = reader.uint32();
420
- switch (tag >>> 3) {
421
- }
422
- if ((tag & 7) === 4 || tag === 0) {
423
- break;
486
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
487
+ if (previousRecursionDepth >= 100) {
488
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
489
+ }
490
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
491
+ try {
492
+ const end = length === undefined ? reader.len : reader.pos + length;
493
+ const message = createBaseHeyHannahSample();
494
+ while (reader.pos < end) {
495
+ const tag = reader.uint32();
496
+ switch (tag >>> 3) {
497
+ }
498
+ if ((tag & 7) === 4 || tag === 0) {
499
+ break;
500
+ }
501
+ reader.skip(tag & 7);
424
502
  }
425
- reader.skip(tag & 7);
503
+ return message;
504
+ }
505
+ finally {
506
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
426
507
  }
427
- return message;
428
508
  },
429
509
  create(base) {
430
510
  return exports.HeyHannahSample.fromPartial(base ?? {});
@@ -446,25 +526,35 @@ exports.CollectorMessage = {
446
526
  },
447
527
  decode(input, length) {
448
528
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
449
- const end = length === undefined ? reader.len : reader.pos + length;
450
- const message = createBaseCollectorMessage();
451
- while (reader.pos < end) {
452
- const tag = reader.uint32();
453
- switch (tag >>> 3) {
454
- case 1: {
455
- if (tag !== 10) {
456
- break;
529
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
530
+ if (previousRecursionDepth >= 100) {
531
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
532
+ }
533
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
534
+ try {
535
+ const end = length === undefined ? reader.len : reader.pos + length;
536
+ const message = createBaseCollectorMessage();
537
+ while (reader.pos < end) {
538
+ const tag = reader.uint32();
539
+ switch (tag >>> 3) {
540
+ case 1: {
541
+ if (tag !== 10) {
542
+ break;
543
+ }
544
+ message.ack = exports.CollectorAck.decode(reader, reader.uint32());
545
+ continue;
457
546
  }
458
- message.ack = exports.CollectorAck.decode(reader, reader.uint32());
459
- continue;
460
547
  }
548
+ if ((tag & 7) === 4 || tag === 0) {
549
+ break;
550
+ }
551
+ reader.skip(tag & 7);
461
552
  }
462
- if ((tag & 7) === 4 || tag === 0) {
463
- break;
464
- }
465
- reader.skip(tag & 7);
553
+ return message;
554
+ }
555
+ finally {
556
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
466
557
  }
467
- return message;
468
558
  },
469
559
  create(base) {
470
560
  return exports.CollectorMessage.fromPartial(base ?? {});
@@ -487,25 +577,35 @@ exports.CollectorAck = {
487
577
  },
488
578
  decode(input, length) {
489
579
  const reader = input instanceof wire_1.BinaryReader ? input : new wire_1.BinaryReader(input);
490
- const end = length === undefined ? reader.len : reader.pos + length;
491
- const message = createBaseCollectorAck();
492
- while (reader.pos < end) {
493
- const tag = reader.uint32();
494
- switch (tag >>> 3) {
495
- case 1: {
496
- if (tag !== 10) {
497
- break;
580
+ const previousRecursionDepth = reader.__tsProtoDecodeDepth ?? 0;
581
+ if (previousRecursionDepth >= 100) {
582
+ throw new globalThis.Error("protobuf decode recursion limit exceeded");
583
+ }
584
+ reader.__tsProtoDecodeDepth = previousRecursionDepth + 1;
585
+ try {
586
+ const end = length === undefined ? reader.len : reader.pos + length;
587
+ const message = createBaseCollectorAck();
588
+ while (reader.pos < end) {
589
+ const tag = reader.uint32();
590
+ switch (tag >>> 3) {
591
+ case 1: {
592
+ if (tag !== 10) {
593
+ break;
594
+ }
595
+ message.message = reader.string();
596
+ continue;
498
597
  }
499
- message.message = reader.string();
500
- continue;
501
598
  }
599
+ if ((tag & 7) === 4 || tag === 0) {
600
+ break;
601
+ }
602
+ reader.skip(tag & 7);
502
603
  }
503
- if ((tag & 7) === 4 || tag === 0) {
504
- break;
505
- }
506
- reader.skip(tag & 7);
604
+ return message;
605
+ }
606
+ finally {
607
+ reader.__tsProtoDecodeDepth = previousRecursionDepth;
507
608
  }
508
- return message;
509
609
  },
510
610
  create(base) {
511
611
  return exports.CollectorAck.fromPartial(base ?? {});