skyeye-sdk-js 1.4.16 → 1.4.18

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.
@@ -24,6 +24,28 @@ var global = (function() {
24
24
  goog.exportSymbol('proto.Series', null, global);
25
25
  goog.exportSymbol('proto.SeriesData', null, global);
26
26
  goog.exportSymbol('proto.TimeData', null, global);
27
+ goog.exportSymbol('proto.Value', null, global);
28
+ /**
29
+ * Generated by JsPbCodeGenerator.
30
+ * @param {Array=} opt_data Optional initial data array, typically from a
31
+ * server response, or constructed directly in Javascript. The array is used
32
+ * in place and becomes part of the constructed object. It is not cloned.
33
+ * If no data is provided, the constructed object will be empty, but still
34
+ * valid.
35
+ * @extends {jspb.Message}
36
+ * @constructor
37
+ */
38
+ proto.Value = function(opt_data) {
39
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
40
+ };
41
+ goog.inherits(proto.Value, jspb.Message);
42
+ if (goog.DEBUG && !COMPILED) {
43
+ /**
44
+ * @public
45
+ * @override
46
+ */
47
+ proto.Value.displayName = 'proto.Value';
48
+ }
27
49
  /**
28
50
  * Generated by JsPbCodeGenerator.
29
51
  * @param {Array=} opt_data Optional initial data array, typically from a
@@ -90,6 +112,226 @@ if (goog.DEBUG && !COMPILED) {
90
112
 
91
113
 
92
114
 
115
+ if (jspb.Message.GENERATE_TO_OBJECT) {
116
+ /**
117
+ * Creates an object representation of this proto.
118
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
119
+ * Optional fields that are not set will be set to undefined.
120
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
121
+ * For the list of reserved names please see:
122
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
123
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
124
+ * JSPB instance for transitional soy proto support:
125
+ * http://goto/soy-param-migration
126
+ * @return {!Object}
127
+ */
128
+ proto.Value.prototype.toObject = function(opt_includeInstance) {
129
+ return proto.Value.toObject(opt_includeInstance, this);
130
+ };
131
+
132
+
133
+ /**
134
+ * Static version of the {@see toObject} method.
135
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
136
+ * the JSPB instance for transitional soy proto support:
137
+ * http://goto/soy-param-migration
138
+ * @param {!proto.Value} msg The msg instance to transform.
139
+ * @return {!Object}
140
+ * @suppress {unusedLocalVariables} f is only used for nested messages
141
+ */
142
+ proto.Value.toObject = function(includeInstance, msg) {
143
+ var f, obj = {
144
+ type: jspb.Message.getFieldWithDefault(msg, 1, ""),
145
+ doublevalue: jspb.Message.getFloatingPointFieldWithDefault(msg, 2, 0.0),
146
+ intvalue: jspb.Message.getFieldWithDefault(msg, 3, 0),
147
+ stringvalue: jspb.Message.getFieldWithDefault(msg, 4, "")
148
+ };
149
+
150
+ if (includeInstance) {
151
+ obj.$jspbMessageInstance = msg;
152
+ }
153
+ return obj;
154
+ };
155
+ }
156
+
157
+
158
+ /**
159
+ * Deserializes binary data (in protobuf wire format).
160
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
161
+ * @return {!proto.Value}
162
+ */
163
+ proto.Value.deserializeBinary = function(bytes) {
164
+ var reader = new jspb.BinaryReader(bytes);
165
+ var msg = new proto.Value;
166
+ return proto.Value.deserializeBinaryFromReader(msg, reader);
167
+ };
168
+
169
+
170
+ /**
171
+ * Deserializes binary data (in protobuf wire format) from the
172
+ * given reader into the given message object.
173
+ * @param {!proto.Value} msg The message object to deserialize into.
174
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
175
+ * @return {!proto.Value}
176
+ */
177
+ proto.Value.deserializeBinaryFromReader = function(msg, reader) {
178
+ while (reader.nextField()) {
179
+ if (reader.isEndGroup()) {
180
+ break;
181
+ }
182
+ var field = reader.getFieldNumber();
183
+ switch (field) {
184
+ case 1:
185
+ var value = /** @type {string} */ (reader.readString());
186
+ msg.setType(value);
187
+ break;
188
+ case 2:
189
+ var value = /** @type {number} */ (reader.readDouble());
190
+ msg.setDoublevalue(value);
191
+ break;
192
+ case 3:
193
+ var value = /** @type {number} */ (reader.readInt64());
194
+ msg.setIntvalue(value);
195
+ break;
196
+ case 4:
197
+ var value = /** @type {string} */ (reader.readString());
198
+ msg.setStringvalue(value);
199
+ break;
200
+ default:
201
+ reader.skipField();
202
+ break;
203
+ }
204
+ }
205
+ return msg;
206
+ };
207
+
208
+
209
+ /**
210
+ * Serializes the message to binary data (in protobuf wire format).
211
+ * @return {!Uint8Array}
212
+ */
213
+ proto.Value.prototype.serializeBinary = function() {
214
+ var writer = new jspb.BinaryWriter();
215
+ proto.Value.serializeBinaryToWriter(this, writer);
216
+ return writer.getResultBuffer();
217
+ };
218
+
219
+
220
+ /**
221
+ * Serializes the given message to binary data (in protobuf wire
222
+ * format), writing to the given BinaryWriter.
223
+ * @param {!proto.Value} message
224
+ * @param {!jspb.BinaryWriter} writer
225
+ * @suppress {unusedLocalVariables} f is only used for nested messages
226
+ */
227
+ proto.Value.serializeBinaryToWriter = function(message, writer) {
228
+ var f = undefined;
229
+ f = message.getType();
230
+ if (f.length > 0) {
231
+ writer.writeString(
232
+ 1,
233
+ f
234
+ );
235
+ }
236
+ f = message.getDoublevalue();
237
+ if (f !== 0.0) {
238
+ writer.writeDouble(
239
+ 2,
240
+ f
241
+ );
242
+ }
243
+ f = message.getIntvalue();
244
+ if (f !== 0) {
245
+ writer.writeInt64(
246
+ 3,
247
+ f
248
+ );
249
+ }
250
+ f = message.getStringvalue();
251
+ if (f.length > 0) {
252
+ writer.writeString(
253
+ 4,
254
+ f
255
+ );
256
+ }
257
+ };
258
+
259
+
260
+ /**
261
+ * optional string type = 1;
262
+ * @return {string}
263
+ */
264
+ proto.Value.prototype.getType = function() {
265
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
266
+ };
267
+
268
+
269
+ /**
270
+ * @param {string} value
271
+ * @return {!proto.Value} returns this
272
+ */
273
+ proto.Value.prototype.setType = function(value) {
274
+ return jspb.Message.setProto3StringField(this, 1, value);
275
+ };
276
+
277
+
278
+ /**
279
+ * optional double doubleValue = 2;
280
+ * @return {number}
281
+ */
282
+ proto.Value.prototype.getDoublevalue = function() {
283
+ return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 2, 0.0));
284
+ };
285
+
286
+
287
+ /**
288
+ * @param {number} value
289
+ * @return {!proto.Value} returns this
290
+ */
291
+ proto.Value.prototype.setDoublevalue = function(value) {
292
+ return jspb.Message.setProto3FloatField(this, 2, value);
293
+ };
294
+
295
+
296
+ /**
297
+ * optional int64 intValue = 3;
298
+ * @return {number}
299
+ */
300
+ proto.Value.prototype.getIntvalue = function() {
301
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
302
+ };
303
+
304
+
305
+ /**
306
+ * @param {number} value
307
+ * @return {!proto.Value} returns this
308
+ */
309
+ proto.Value.prototype.setIntvalue = function(value) {
310
+ return jspb.Message.setProto3IntField(this, 3, value);
311
+ };
312
+
313
+
314
+ /**
315
+ * optional string stringValue = 4;
316
+ * @return {string}
317
+ */
318
+ proto.Value.prototype.getStringvalue = function() {
319
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
320
+ };
321
+
322
+
323
+ /**
324
+ * @param {string} value
325
+ * @return {!proto.Value} returns this
326
+ */
327
+ proto.Value.prototype.setStringvalue = function(value) {
328
+ return jspb.Message.setProto3StringField(this, 4, value);
329
+ };
330
+
331
+
332
+
333
+
334
+
93
335
  if (jspb.Message.GENERATE_TO_OBJECT) {
94
336
  /**
95
337
  * Creates an object representation of this proto.
@@ -119,9 +361,9 @@ proto.TimeData.prototype.toObject = function(opt_includeInstance) {
119
361
  */
120
362
  proto.TimeData.toObject = function(includeInstance, msg) {
121
363
  var f, obj = {
122
- realtime: jspb.Message.getFloatingPointFieldWithDefault(msg, 1, 0.0),
123
- simulationtime: jspb.Message.getFloatingPointFieldWithDefault(msg, 2, 0.0),
124
- customtime: jspb.Message.getFloatingPointFieldWithDefault(msg, 3, 0.0)
364
+ realtime: (f = msg.getRealtime()) && proto.Value.toObject(includeInstance, f),
365
+ simulationtime: (f = msg.getSimulationtime()) && proto.Value.toObject(includeInstance, f),
366
+ customtime: (f = msg.getCustomtime()) && proto.Value.toObject(includeInstance, f)
125
367
  };
126
368
 
127
369
  if (includeInstance) {
@@ -159,15 +401,18 @@ proto.TimeData.deserializeBinaryFromReader = function(msg, reader) {
159
401
  var field = reader.getFieldNumber();
160
402
  switch (field) {
161
403
  case 1:
162
- var value = /** @type {number} */ (reader.readDouble());
404
+ var value = new proto.Value;
405
+ reader.readMessage(value,proto.Value.deserializeBinaryFromReader);
163
406
  msg.setRealtime(value);
164
407
  break;
165
408
  case 2:
166
- var value = /** @type {number} */ (reader.readDouble());
409
+ var value = new proto.Value;
410
+ reader.readMessage(value,proto.Value.deserializeBinaryFromReader);
167
411
  msg.setSimulationtime(value);
168
412
  break;
169
413
  case 3:
170
- var value = /** @type {number} */ (reader.readDouble());
414
+ var value = new proto.Value;
415
+ reader.readMessage(value,proto.Value.deserializeBinaryFromReader);
171
416
  msg.setCustomtime(value);
172
417
  break;
173
418
  default:
@@ -200,80 +445,140 @@ proto.TimeData.prototype.serializeBinary = function() {
200
445
  proto.TimeData.serializeBinaryToWriter = function(message, writer) {
201
446
  var f = undefined;
202
447
  f = message.getRealtime();
203
- if (f !== 0.0) {
204
- writer.writeDouble(
448
+ if (f != null) {
449
+ writer.writeMessage(
205
450
  1,
206
- f
451
+ f,
452
+ proto.Value.serializeBinaryToWriter
207
453
  );
208
454
  }
209
455
  f = message.getSimulationtime();
210
- if (f !== 0.0) {
211
- writer.writeDouble(
456
+ if (f != null) {
457
+ writer.writeMessage(
212
458
  2,
213
- f
459
+ f,
460
+ proto.Value.serializeBinaryToWriter
214
461
  );
215
462
  }
216
463
  f = message.getCustomtime();
217
- if (f !== 0.0) {
218
- writer.writeDouble(
464
+ if (f != null) {
465
+ writer.writeMessage(
219
466
  3,
220
- f
467
+ f,
468
+ proto.Value.serializeBinaryToWriter
221
469
  );
222
470
  }
223
471
  };
224
472
 
225
473
 
226
474
  /**
227
- * optional double realTime = 1;
228
- * @return {number}
475
+ * optional Value realTime = 1;
476
+ * @return {?proto.Value}
229
477
  */
230
478
  proto.TimeData.prototype.getRealtime = function() {
231
- return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 1, 0.0));
479
+ return /** @type{?proto.Value} */ (
480
+ jspb.Message.getWrapperField(this, proto.Value, 1));
232
481
  };
233
482
 
234
483
 
235
484
  /**
236
- * @param {number} value
485
+ * @param {?proto.Value|undefined} value
237
486
  * @return {!proto.TimeData} returns this
238
- */
487
+ */
239
488
  proto.TimeData.prototype.setRealtime = function(value) {
240
- return jspb.Message.setProto3FloatField(this, 1, value);
489
+ return jspb.Message.setWrapperField(this, 1, value);
241
490
  };
242
491
 
243
492
 
244
493
  /**
245
- * optional double simulationTime = 2;
246
- * @return {number}
494
+ * Clears the message field making it undefined.
495
+ * @return {!proto.TimeData} returns this
496
+ */
497
+ proto.TimeData.prototype.clearRealtime = function() {
498
+ return this.setRealtime(undefined);
499
+ };
500
+
501
+
502
+ /**
503
+ * Returns whether this field is set.
504
+ * @return {boolean}
505
+ */
506
+ proto.TimeData.prototype.hasRealtime = function() {
507
+ return jspb.Message.getField(this, 1) != null;
508
+ };
509
+
510
+
511
+ /**
512
+ * optional Value simulationTime = 2;
513
+ * @return {?proto.Value}
247
514
  */
248
515
  proto.TimeData.prototype.getSimulationtime = function() {
249
- return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 2, 0.0));
516
+ return /** @type{?proto.Value} */ (
517
+ jspb.Message.getWrapperField(this, proto.Value, 2));
250
518
  };
251
519
 
252
520
 
253
521
  /**
254
- * @param {number} value
522
+ * @param {?proto.Value|undefined} value
255
523
  * @return {!proto.TimeData} returns this
256
- */
524
+ */
257
525
  proto.TimeData.prototype.setSimulationtime = function(value) {
258
- return jspb.Message.setProto3FloatField(this, 2, value);
526
+ return jspb.Message.setWrapperField(this, 2, value);
259
527
  };
260
528
 
261
529
 
262
530
  /**
263
- * optional double customTime = 3;
264
- * @return {number}
531
+ * Clears the message field making it undefined.
532
+ * @return {!proto.TimeData} returns this
533
+ */
534
+ proto.TimeData.prototype.clearSimulationtime = function() {
535
+ return this.setSimulationtime(undefined);
536
+ };
537
+
538
+
539
+ /**
540
+ * Returns whether this field is set.
541
+ * @return {boolean}
542
+ */
543
+ proto.TimeData.prototype.hasSimulationtime = function() {
544
+ return jspb.Message.getField(this, 2) != null;
545
+ };
546
+
547
+
548
+ /**
549
+ * optional Value customTime = 3;
550
+ * @return {?proto.Value}
265
551
  */
266
552
  proto.TimeData.prototype.getCustomtime = function() {
267
- return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 3, 0.0));
553
+ return /** @type{?proto.Value} */ (
554
+ jspb.Message.getWrapperField(this, proto.Value, 3));
268
555
  };
269
556
 
270
557
 
271
558
  /**
272
- * @param {number} value
559
+ * @param {?proto.Value|undefined} value
273
560
  * @return {!proto.TimeData} returns this
274
- */
561
+ */
275
562
  proto.TimeData.prototype.setCustomtime = function(value) {
276
- return jspb.Message.setProto3FloatField(this, 3, value);
563
+ return jspb.Message.setWrapperField(this, 3, value);
564
+ };
565
+
566
+
567
+ /**
568
+ * Clears the message field making it undefined.
569
+ * @return {!proto.TimeData} returns this
570
+ */
571
+ proto.TimeData.prototype.clearCustomtime = function() {
572
+ return this.setCustomtime(undefined);
573
+ };
574
+
575
+
576
+ /**
577
+ * Returns whether this field is set.
578
+ * @return {boolean}
579
+ */
580
+ proto.TimeData.prototype.hasCustomtime = function() {
581
+ return jspb.Message.getField(this, 3) != null;
277
582
  };
278
583
 
279
584
 
@@ -283,7 +588,7 @@ proto.TimeData.prototype.setCustomtime = function(value) {
283
588
  * @private {!Array<number>}
284
589
  * @const
285
590
  */
286
- proto.SeriesData.repeatedFields_ = [2];
591
+ proto.SeriesData.repeatedFields_ = [3];
287
592
 
288
593
 
289
594
 
@@ -316,8 +621,10 @@ proto.SeriesData.prototype.toObject = function(opt_includeInstance) {
316
621
  */
317
622
  proto.SeriesData.toObject = function(includeInstance, msg) {
318
623
  var f, obj = {
319
- name: jspb.Message.getFieldWithDefault(msg, 1, ""),
320
- valueList: (f = jspb.Message.getRepeatedFloatingPointField(msg, 2)) == null ? undefined : f
624
+ id: jspb.Message.getFieldWithDefault(msg, 1, ""),
625
+ name: jspb.Message.getFieldWithDefault(msg, 2, ""),
626
+ valueList: jspb.Message.toObjectList(msg.getValueList(),
627
+ proto.Value.toObject, includeInstance)
321
628
  };
322
629
 
323
630
  if (includeInstance) {
@@ -356,13 +663,16 @@ proto.SeriesData.deserializeBinaryFromReader = function(msg, reader) {
356
663
  switch (field) {
357
664
  case 1:
358
665
  var value = /** @type {string} */ (reader.readString());
359
- msg.setName(value);
666
+ msg.setId(value);
360
667
  break;
361
668
  case 2:
362
- var values = /** @type {!Array<number>} */ (reader.isDelimited() ? reader.readPackedDouble() : [reader.readDouble()]);
363
- for (var i = 0; i < values.length; i++) {
364
- msg.addValue(values[i]);
365
- }
669
+ var value = /** @type {string} */ (reader.readString());
670
+ msg.setName(value);
671
+ break;
672
+ case 3:
673
+ var value = new proto.Value;
674
+ reader.readMessage(value,proto.Value.deserializeBinaryFromReader);
675
+ msg.addValue(value);
366
676
  break;
367
677
  default:
368
678
  reader.skipField();
@@ -393,28 +703,36 @@ proto.SeriesData.prototype.serializeBinary = function() {
393
703
  */
394
704
  proto.SeriesData.serializeBinaryToWriter = function(message, writer) {
395
705
  var f = undefined;
396
- f = message.getName();
706
+ f = message.getId();
397
707
  if (f.length > 0) {
398
708
  writer.writeString(
399
709
  1,
400
710
  f
401
711
  );
402
712
  }
403
- f = message.getValueList();
713
+ f = message.getName();
404
714
  if (f.length > 0) {
405
- writer.writePackedDouble(
715
+ writer.writeString(
406
716
  2,
407
717
  f
408
718
  );
409
719
  }
720
+ f = message.getValueList();
721
+ if (f.length > 0) {
722
+ writer.writeRepeatedMessage(
723
+ 3,
724
+ f,
725
+ proto.Value.serializeBinaryToWriter
726
+ );
727
+ }
410
728
  };
411
729
 
412
730
 
413
731
  /**
414
- * optional string name = 1;
732
+ * optional string id = 1;
415
733
  * @return {string}
416
734
  */
417
- proto.SeriesData.prototype.getName = function() {
735
+ proto.SeriesData.prototype.getId = function() {
418
736
  return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
419
737
  };
420
738
 
@@ -423,36 +741,55 @@ proto.SeriesData.prototype.getName = function() {
423
741
  * @param {string} value
424
742
  * @return {!proto.SeriesData} returns this
425
743
  */
426
- proto.SeriesData.prototype.setName = function(value) {
744
+ proto.SeriesData.prototype.setId = function(value) {
427
745
  return jspb.Message.setProto3StringField(this, 1, value);
428
746
  };
429
747
 
430
748
 
431
749
  /**
432
- * repeated double value = 2;
433
- * @return {!Array<number>}
750
+ * optional string name = 2;
751
+ * @return {string}
434
752
  */
435
- proto.SeriesData.prototype.getValueList = function() {
436
- return /** @type {!Array<number>} */ (jspb.Message.getRepeatedFloatingPointField(this, 2));
753
+ proto.SeriesData.prototype.getName = function() {
754
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
437
755
  };
438
756
 
439
757
 
440
758
  /**
441
- * @param {!Array<number>} value
759
+ * @param {string} value
442
760
  * @return {!proto.SeriesData} returns this
443
761
  */
762
+ proto.SeriesData.prototype.setName = function(value) {
763
+ return jspb.Message.setProto3StringField(this, 2, value);
764
+ };
765
+
766
+
767
+ /**
768
+ * repeated Value value = 3;
769
+ * @return {!Array<!proto.Value>}
770
+ */
771
+ proto.SeriesData.prototype.getValueList = function() {
772
+ return /** @type{!Array<!proto.Value>} */ (
773
+ jspb.Message.getRepeatedWrapperField(this, proto.Value, 3));
774
+ };
775
+
776
+
777
+ /**
778
+ * @param {!Array<!proto.Value>} value
779
+ * @return {!proto.SeriesData} returns this
780
+ */
444
781
  proto.SeriesData.prototype.setValueList = function(value) {
445
- return jspb.Message.setField(this, 2, value || []);
782
+ return jspb.Message.setRepeatedWrapperField(this, 3, value);
446
783
  };
447
784
 
448
785
 
449
786
  /**
450
- * @param {number} value
787
+ * @param {!proto.Value=} opt_value
451
788
  * @param {number=} opt_index
452
- * @return {!proto.SeriesData} returns this
789
+ * @return {!proto.Value}
453
790
  */
454
- proto.SeriesData.prototype.addValue = function(value, opt_index) {
455
- return jspb.Message.addToRepeatedField(this, 2, value, opt_index);
791
+ proto.SeriesData.prototype.addValue = function(opt_value, opt_index) {
792
+ return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.Value, opt_index);
456
793
  };
457
794
 
458
795
 
@@ -1,7 +1,7 @@
1
1
  // GENERATED CODE -- DO NOT EDIT!
2
2
 
3
3
  'use strict';
4
- var grpc = require('grpc');
4
+ var grpc = require('@grpc/grpc-js');
5
5
  var skyeye_rpc_pb = require('./skyeye_rpc_pb.js');
6
6
 
7
7
  function serialize_JSONRequest(arg) {