protobufjs 6.8.8 → 6.8.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.
Files changed (104) hide show
  1. package/LICENSE +39 -39
  2. package/README.md +879 -879
  3. package/cli/LICENSE +33 -33
  4. package/cli/README.md +11 -11
  5. package/cli/index.d.ts +3 -3
  6. package/cli/index.js +3 -3
  7. package/cli/lib/tsd-jsdoc/LICENSE +20 -20
  8. package/cli/lib/tsd-jsdoc/README.md +23 -23
  9. package/cli/lib/tsd-jsdoc/plugin.js +21 -21
  10. package/cli/lib/tsd-jsdoc/publish.js +693 -693
  11. package/cli/lib/tsd-jsdoc.json +18 -18
  12. package/cli/package.standalone.json +31 -31
  13. package/cli/pbjs.d.ts +9 -9
  14. package/cli/pbjs.js +329 -329
  15. package/cli/pbts.d.ts +9 -9
  16. package/cli/pbts.js +197 -197
  17. package/cli/targets/json-module.js +38 -38
  18. package/cli/targets/json.js +8 -8
  19. package/cli/targets/proto.js +326 -326
  20. package/cli/targets/proto2.js +10 -10
  21. package/cli/targets/proto3.js +10 -10
  22. package/cli/targets/static-module.js +29 -29
  23. package/cli/targets/static.js +702 -702
  24. package/cli/util.js +183 -183
  25. package/cli/wrappers/amd.js +7 -7
  26. package/cli/wrappers/closure.js +7 -7
  27. package/cli/wrappers/commonjs.js +7 -7
  28. package/cli/wrappers/default.js +15 -15
  29. package/cli/wrappers/es6.js +5 -5
  30. package/dist/README.md +31 -31
  31. package/dist/light/README.md +31 -31
  32. package/dist/light/protobuf.js +6030 -6030
  33. package/dist/light/protobuf.js.map +1 -1
  34. package/dist/light/protobuf.min.js +1 -1
  35. package/dist/light/protobuf.min.js.map +1 -1
  36. package/dist/minimal/README.md +31 -31
  37. package/dist/minimal/protobuf.js +1876 -1876
  38. package/dist/minimal/protobuf.js.map +1 -1
  39. package/dist/minimal/protobuf.min.js +1 -1
  40. package/dist/minimal/protobuf.min.js.map +1 -1
  41. package/dist/protobuf.js +7595 -7595
  42. package/dist/protobuf.js.map +1 -1
  43. package/dist/protobuf.min.js +1 -1
  44. package/dist/protobuf.min.js.map +1 -1
  45. package/ext/debug/README.md +4 -4
  46. package/ext/debug/index.js +71 -71
  47. package/ext/descriptor/README.md +72 -72
  48. package/ext/descriptor/index.js +1052 -1052
  49. package/ext/descriptor/test.js +54 -54
  50. package/google/LICENSE +27 -27
  51. package/google/README.md +1 -1
  52. package/google/api/annotations.proto +10 -10
  53. package/google/protobuf/descriptor.proto +286 -286
  54. package/google/protobuf/source_context.proto +7 -7
  55. package/index.js +4 -4
  56. package/light.d.ts +2 -2
  57. package/light.js +3 -3
  58. package/minimal.d.ts +2 -2
  59. package/minimal.js +4 -4
  60. package/package-lock.json +1748 -642
  61. package/package.json +119 -122
  62. package/scripts/changelog.js +150 -150
  63. package/scripts/postinstall.js +35 -35
  64. package/src/common.js +399 -399
  65. package/src/converter.js +293 -293
  66. package/src/decoder.js +106 -106
  67. package/src/encoder.js +99 -99
  68. package/src/enum.js +181 -181
  69. package/src/field.js +371 -371
  70. package/src/index-light.js +104 -104
  71. package/src/index-minimal.js +36 -36
  72. package/src/index.js +12 -12
  73. package/src/mapfield.js +126 -126
  74. package/src/message.js +138 -138
  75. package/src/method.js +151 -151
  76. package/src/namespace.js +433 -433
  77. package/src/object.js +200 -200
  78. package/src/oneof.js +203 -203
  79. package/src/parse.js +758 -758
  80. package/src/reader.js +405 -405
  81. package/src/reader_buffer.js +44 -44
  82. package/src/root.js +351 -351
  83. package/src/roots.js +18 -18
  84. package/src/rpc/service.js +142 -142
  85. package/src/rpc.js +36 -36
  86. package/src/service.js +167 -167
  87. package/src/tokenize.js +397 -397
  88. package/src/type.js +589 -589
  89. package/src/types.js +196 -196
  90. package/src/typescript.jsdoc +15 -15
  91. package/src/util/longbits.js +200 -200
  92. package/src/util/minimal.js +414 -414
  93. package/src/util.js +178 -178
  94. package/src/verifier.js +176 -176
  95. package/src/wrappers.js +83 -83
  96. package/src/writer.js +459 -459
  97. package/src/writer_buffer.js +81 -81
  98. package/tsconfig.json +6 -6
  99. package/cli/node_modules/os-tmpdir/index.js +0 -25
  100. package/cli/node_modules/os-tmpdir/license +0 -21
  101. package/cli/node_modules/os-tmpdir/readme.md +0 -32
  102. package/cli/node_modules/tmp/LICENSE +0 -21
  103. package/cli/node_modules/tmp/README.md +0 -314
  104. package/cli/node_modules/tmp/lib/tmp.js +0 -611
package/src/common.js CHANGED
@@ -1,399 +1,399 @@
1
- "use strict";
2
- module.exports = common;
3
-
4
- var commonRe = /\/|\./;
5
-
6
- /**
7
- * Provides common type definitions.
8
- * Can also be used to provide additional google types or your own custom types.
9
- * @param {string} name Short name as in `google/protobuf/[name].proto` or full file name
10
- * @param {Object.<string,*>} json JSON definition within `google.protobuf` if a short name, otherwise the file's root definition
11
- * @returns {undefined}
12
- * @property {INamespace} google/protobuf/any.proto Any
13
- * @property {INamespace} google/protobuf/duration.proto Duration
14
- * @property {INamespace} google/protobuf/empty.proto Empty
15
- * @property {INamespace} google/protobuf/field_mask.proto FieldMask
16
- * @property {INamespace} google/protobuf/struct.proto Struct, Value, NullValue and ListValue
17
- * @property {INamespace} google/protobuf/timestamp.proto Timestamp
18
- * @property {INamespace} google/protobuf/wrappers.proto Wrappers
19
- * @example
20
- * // manually provides descriptor.proto (assumes google/protobuf/ namespace and .proto extension)
21
- * protobuf.common("descriptor", descriptorJson);
22
- *
23
- * // manually provides a custom definition (uses my.foo namespace)
24
- * protobuf.common("my/foo/bar.proto", myFooBarJson);
25
- */
26
- function common(name, json) {
27
- if (!commonRe.test(name)) {
28
- name = "google/protobuf/" + name + ".proto";
29
- json = { nested: { google: { nested: { protobuf: { nested: json } } } } };
30
- }
31
- common[name] = json;
32
- }
33
-
34
- // Not provided because of limited use (feel free to discuss or to provide yourself):
35
- //
36
- // google/protobuf/descriptor.proto
37
- // google/protobuf/source_context.proto
38
- // google/protobuf/type.proto
39
- //
40
- // Stripped and pre-parsed versions of these non-bundled files are instead available as part of
41
- // the repository or package within the google/protobuf directory.
42
-
43
- common("any", {
44
-
45
- /**
46
- * Properties of a google.protobuf.Any message.
47
- * @interface IAny
48
- * @type {Object}
49
- * @property {string} [typeUrl]
50
- * @property {Uint8Array} [bytes]
51
- * @memberof common
52
- */
53
- Any: {
54
- fields: {
55
- type_url: {
56
- type: "string",
57
- id: 1
58
- },
59
- value: {
60
- type: "bytes",
61
- id: 2
62
- }
63
- }
64
- }
65
- });
66
-
67
- var timeType;
68
-
69
- common("duration", {
70
-
71
- /**
72
- * Properties of a google.protobuf.Duration message.
73
- * @interface IDuration
74
- * @type {Object}
75
- * @property {number|Long} [seconds]
76
- * @property {number} [nanos]
77
- * @memberof common
78
- */
79
- Duration: timeType = {
80
- fields: {
81
- seconds: {
82
- type: "int64",
83
- id: 1
84
- },
85
- nanos: {
86
- type: "int32",
87
- id: 2
88
- }
89
- }
90
- }
91
- });
92
-
93
- common("timestamp", {
94
-
95
- /**
96
- * Properties of a google.protobuf.Timestamp message.
97
- * @interface ITimestamp
98
- * @type {Object}
99
- * @property {number|Long} [seconds]
100
- * @property {number} [nanos]
101
- * @memberof common
102
- */
103
- Timestamp: timeType
104
- });
105
-
106
- common("empty", {
107
-
108
- /**
109
- * Properties of a google.protobuf.Empty message.
110
- * @interface IEmpty
111
- * @memberof common
112
- */
113
- Empty: {
114
- fields: {}
115
- }
116
- });
117
-
118
- common("struct", {
119
-
120
- /**
121
- * Properties of a google.protobuf.Struct message.
122
- * @interface IStruct
123
- * @type {Object}
124
- * @property {Object.<string,IValue>} [fields]
125
- * @memberof common
126
- */
127
- Struct: {
128
- fields: {
129
- fields: {
130
- keyType: "string",
131
- type: "Value",
132
- id: 1
133
- }
134
- }
135
- },
136
-
137
- /**
138
- * Properties of a google.protobuf.Value message.
139
- * @interface IValue
140
- * @type {Object}
141
- * @property {string} [kind]
142
- * @property {0} [nullValue]
143
- * @property {number} [numberValue]
144
- * @property {string} [stringValue]
145
- * @property {boolean} [boolValue]
146
- * @property {IStruct} [structValue]
147
- * @property {IListValue} [listValue]
148
- * @memberof common
149
- */
150
- Value: {
151
- oneofs: {
152
- kind: {
153
- oneof: [
154
- "nullValue",
155
- "numberValue",
156
- "stringValue",
157
- "boolValue",
158
- "structValue",
159
- "listValue"
160
- ]
161
- }
162
- },
163
- fields: {
164
- nullValue: {
165
- type: "NullValue",
166
- id: 1
167
- },
168
- numberValue: {
169
- type: "double",
170
- id: 2
171
- },
172
- stringValue: {
173
- type: "string",
174
- id: 3
175
- },
176
- boolValue: {
177
- type: "bool",
178
- id: 4
179
- },
180
- structValue: {
181
- type: "Struct",
182
- id: 5
183
- },
184
- listValue: {
185
- type: "ListValue",
186
- id: 6
187
- }
188
- }
189
- },
190
-
191
- NullValue: {
192
- values: {
193
- NULL_VALUE: 0
194
- }
195
- },
196
-
197
- /**
198
- * Properties of a google.protobuf.ListValue message.
199
- * @interface IListValue
200
- * @type {Object}
201
- * @property {Array.<IValue>} [values]
202
- * @memberof common
203
- */
204
- ListValue: {
205
- fields: {
206
- values: {
207
- rule: "repeated",
208
- type: "Value",
209
- id: 1
210
- }
211
- }
212
- }
213
- });
214
-
215
- common("wrappers", {
216
-
217
- /**
218
- * Properties of a google.protobuf.DoubleValue message.
219
- * @interface IDoubleValue
220
- * @type {Object}
221
- * @property {number} [value]
222
- * @memberof common
223
- */
224
- DoubleValue: {
225
- fields: {
226
- value: {
227
- type: "double",
228
- id: 1
229
- }
230
- }
231
- },
232
-
233
- /**
234
- * Properties of a google.protobuf.FloatValue message.
235
- * @interface IFloatValue
236
- * @type {Object}
237
- * @property {number} [value]
238
- * @memberof common
239
- */
240
- FloatValue: {
241
- fields: {
242
- value: {
243
- type: "float",
244
- id: 1
245
- }
246
- }
247
- },
248
-
249
- /**
250
- * Properties of a google.protobuf.Int64Value message.
251
- * @interface IInt64Value
252
- * @type {Object}
253
- * @property {number|Long} [value]
254
- * @memberof common
255
- */
256
- Int64Value: {
257
- fields: {
258
- value: {
259
- type: "int64",
260
- id: 1
261
- }
262
- }
263
- },
264
-
265
- /**
266
- * Properties of a google.protobuf.UInt64Value message.
267
- * @interface IUInt64Value
268
- * @type {Object}
269
- * @property {number|Long} [value]
270
- * @memberof common
271
- */
272
- UInt64Value: {
273
- fields: {
274
- value: {
275
- type: "uint64",
276
- id: 1
277
- }
278
- }
279
- },
280
-
281
- /**
282
- * Properties of a google.protobuf.Int32Value message.
283
- * @interface IInt32Value
284
- * @type {Object}
285
- * @property {number} [value]
286
- * @memberof common
287
- */
288
- Int32Value: {
289
- fields: {
290
- value: {
291
- type: "int32",
292
- id: 1
293
- }
294
- }
295
- },
296
-
297
- /**
298
- * Properties of a google.protobuf.UInt32Value message.
299
- * @interface IUInt32Value
300
- * @type {Object}
301
- * @property {number} [value]
302
- * @memberof common
303
- */
304
- UInt32Value: {
305
- fields: {
306
- value: {
307
- type: "uint32",
308
- id: 1
309
- }
310
- }
311
- },
312
-
313
- /**
314
- * Properties of a google.protobuf.BoolValue message.
315
- * @interface IBoolValue
316
- * @type {Object}
317
- * @property {boolean} [value]
318
- * @memberof common
319
- */
320
- BoolValue: {
321
- fields: {
322
- value: {
323
- type: "bool",
324
- id: 1
325
- }
326
- }
327
- },
328
-
329
- /**
330
- * Properties of a google.protobuf.StringValue message.
331
- * @interface IStringValue
332
- * @type {Object}
333
- * @property {string} [value]
334
- * @memberof common
335
- */
336
- StringValue: {
337
- fields: {
338
- value: {
339
- type: "string",
340
- id: 1
341
- }
342
- }
343
- },
344
-
345
- /**
346
- * Properties of a google.protobuf.BytesValue message.
347
- * @interface IBytesValue
348
- * @type {Object}
349
- * @property {Uint8Array} [value]
350
- * @memberof common
351
- */
352
- BytesValue: {
353
- fields: {
354
- value: {
355
- type: "bytes",
356
- id: 1
357
- }
358
- }
359
- }
360
- });
361
-
362
- common("field_mask", {
363
-
364
- /**
365
- * Properties of a google.protobuf.FieldMask message.
366
- * @interface IDoubleValue
367
- * @type {Object}
368
- * @property {number} [value]
369
- * @memberof common
370
- */
371
- FieldMask: {
372
- fields: {
373
- paths: {
374
- rule: "repeated",
375
- type: "string",
376
- id: 1
377
- }
378
- }
379
- }
380
- });
381
-
382
- /**
383
- * Gets the root definition of the specified common proto file.
384
- *
385
- * Bundled definitions are:
386
- * - google/protobuf/any.proto
387
- * - google/protobuf/duration.proto
388
- * - google/protobuf/empty.proto
389
- * - google/protobuf/field_mask.proto
390
- * - google/protobuf/struct.proto
391
- * - google/protobuf/timestamp.proto
392
- * - google/protobuf/wrappers.proto
393
- *
394
- * @param {string} file Proto file name
395
- * @returns {INamespace|null} Root definition or `null` if not defined
396
- */
397
- common.get = function get(file) {
398
- return common[file] || null;
399
- };
1
+ "use strict";
2
+ module.exports = common;
3
+
4
+ var commonRe = /\/|\./;
5
+
6
+ /**
7
+ * Provides common type definitions.
8
+ * Can also be used to provide additional google types or your own custom types.
9
+ * @param {string} name Short name as in `google/protobuf/[name].proto` or full file name
10
+ * @param {Object.<string,*>} json JSON definition within `google.protobuf` if a short name, otherwise the file's root definition
11
+ * @returns {undefined}
12
+ * @property {INamespace} google/protobuf/any.proto Any
13
+ * @property {INamespace} google/protobuf/duration.proto Duration
14
+ * @property {INamespace} google/protobuf/empty.proto Empty
15
+ * @property {INamespace} google/protobuf/field_mask.proto FieldMask
16
+ * @property {INamespace} google/protobuf/struct.proto Struct, Value, NullValue and ListValue
17
+ * @property {INamespace} google/protobuf/timestamp.proto Timestamp
18
+ * @property {INamespace} google/protobuf/wrappers.proto Wrappers
19
+ * @example
20
+ * // manually provides descriptor.proto (assumes google/protobuf/ namespace and .proto extension)
21
+ * protobuf.common("descriptor", descriptorJson);
22
+ *
23
+ * // manually provides a custom definition (uses my.foo namespace)
24
+ * protobuf.common("my/foo/bar.proto", myFooBarJson);
25
+ */
26
+ function common(name, json) {
27
+ if (!commonRe.test(name)) {
28
+ name = "google/protobuf/" + name + ".proto";
29
+ json = { nested: { google: { nested: { protobuf: { nested: json } } } } };
30
+ }
31
+ common[name] = json;
32
+ }
33
+
34
+ // Not provided because of limited use (feel free to discuss or to provide yourself):
35
+ //
36
+ // google/protobuf/descriptor.proto
37
+ // google/protobuf/source_context.proto
38
+ // google/protobuf/type.proto
39
+ //
40
+ // Stripped and pre-parsed versions of these non-bundled files are instead available as part of
41
+ // the repository or package within the google/protobuf directory.
42
+
43
+ common("any", {
44
+
45
+ /**
46
+ * Properties of a google.protobuf.Any message.
47
+ * @interface IAny
48
+ * @type {Object}
49
+ * @property {string} [typeUrl]
50
+ * @property {Uint8Array} [bytes]
51
+ * @memberof common
52
+ */
53
+ Any: {
54
+ fields: {
55
+ type_url: {
56
+ type: "string",
57
+ id: 1
58
+ },
59
+ value: {
60
+ type: "bytes",
61
+ id: 2
62
+ }
63
+ }
64
+ }
65
+ });
66
+
67
+ var timeType;
68
+
69
+ common("duration", {
70
+
71
+ /**
72
+ * Properties of a google.protobuf.Duration message.
73
+ * @interface IDuration
74
+ * @type {Object}
75
+ * @property {number|Long} [seconds]
76
+ * @property {number} [nanos]
77
+ * @memberof common
78
+ */
79
+ Duration: timeType = {
80
+ fields: {
81
+ seconds: {
82
+ type: "int64",
83
+ id: 1
84
+ },
85
+ nanos: {
86
+ type: "int32",
87
+ id: 2
88
+ }
89
+ }
90
+ }
91
+ });
92
+
93
+ common("timestamp", {
94
+
95
+ /**
96
+ * Properties of a google.protobuf.Timestamp message.
97
+ * @interface ITimestamp
98
+ * @type {Object}
99
+ * @property {number|Long} [seconds]
100
+ * @property {number} [nanos]
101
+ * @memberof common
102
+ */
103
+ Timestamp: timeType
104
+ });
105
+
106
+ common("empty", {
107
+
108
+ /**
109
+ * Properties of a google.protobuf.Empty message.
110
+ * @interface IEmpty
111
+ * @memberof common
112
+ */
113
+ Empty: {
114
+ fields: {}
115
+ }
116
+ });
117
+
118
+ common("struct", {
119
+
120
+ /**
121
+ * Properties of a google.protobuf.Struct message.
122
+ * @interface IStruct
123
+ * @type {Object}
124
+ * @property {Object.<string,IValue>} [fields]
125
+ * @memberof common
126
+ */
127
+ Struct: {
128
+ fields: {
129
+ fields: {
130
+ keyType: "string",
131
+ type: "Value",
132
+ id: 1
133
+ }
134
+ }
135
+ },
136
+
137
+ /**
138
+ * Properties of a google.protobuf.Value message.
139
+ * @interface IValue
140
+ * @type {Object}
141
+ * @property {string} [kind]
142
+ * @property {0} [nullValue]
143
+ * @property {number} [numberValue]
144
+ * @property {string} [stringValue]
145
+ * @property {boolean} [boolValue]
146
+ * @property {IStruct} [structValue]
147
+ * @property {IListValue} [listValue]
148
+ * @memberof common
149
+ */
150
+ Value: {
151
+ oneofs: {
152
+ kind: {
153
+ oneof: [
154
+ "nullValue",
155
+ "numberValue",
156
+ "stringValue",
157
+ "boolValue",
158
+ "structValue",
159
+ "listValue"
160
+ ]
161
+ }
162
+ },
163
+ fields: {
164
+ nullValue: {
165
+ type: "NullValue",
166
+ id: 1
167
+ },
168
+ numberValue: {
169
+ type: "double",
170
+ id: 2
171
+ },
172
+ stringValue: {
173
+ type: "string",
174
+ id: 3
175
+ },
176
+ boolValue: {
177
+ type: "bool",
178
+ id: 4
179
+ },
180
+ structValue: {
181
+ type: "Struct",
182
+ id: 5
183
+ },
184
+ listValue: {
185
+ type: "ListValue",
186
+ id: 6
187
+ }
188
+ }
189
+ },
190
+
191
+ NullValue: {
192
+ values: {
193
+ NULL_VALUE: 0
194
+ }
195
+ },
196
+
197
+ /**
198
+ * Properties of a google.protobuf.ListValue message.
199
+ * @interface IListValue
200
+ * @type {Object}
201
+ * @property {Array.<IValue>} [values]
202
+ * @memberof common
203
+ */
204
+ ListValue: {
205
+ fields: {
206
+ values: {
207
+ rule: "repeated",
208
+ type: "Value",
209
+ id: 1
210
+ }
211
+ }
212
+ }
213
+ });
214
+
215
+ common("wrappers", {
216
+
217
+ /**
218
+ * Properties of a google.protobuf.DoubleValue message.
219
+ * @interface IDoubleValue
220
+ * @type {Object}
221
+ * @property {number} [value]
222
+ * @memberof common
223
+ */
224
+ DoubleValue: {
225
+ fields: {
226
+ value: {
227
+ type: "double",
228
+ id: 1
229
+ }
230
+ }
231
+ },
232
+
233
+ /**
234
+ * Properties of a google.protobuf.FloatValue message.
235
+ * @interface IFloatValue
236
+ * @type {Object}
237
+ * @property {number} [value]
238
+ * @memberof common
239
+ */
240
+ FloatValue: {
241
+ fields: {
242
+ value: {
243
+ type: "float",
244
+ id: 1
245
+ }
246
+ }
247
+ },
248
+
249
+ /**
250
+ * Properties of a google.protobuf.Int64Value message.
251
+ * @interface IInt64Value
252
+ * @type {Object}
253
+ * @property {number|Long} [value]
254
+ * @memberof common
255
+ */
256
+ Int64Value: {
257
+ fields: {
258
+ value: {
259
+ type: "int64",
260
+ id: 1
261
+ }
262
+ }
263
+ },
264
+
265
+ /**
266
+ * Properties of a google.protobuf.UInt64Value message.
267
+ * @interface IUInt64Value
268
+ * @type {Object}
269
+ * @property {number|Long} [value]
270
+ * @memberof common
271
+ */
272
+ UInt64Value: {
273
+ fields: {
274
+ value: {
275
+ type: "uint64",
276
+ id: 1
277
+ }
278
+ }
279
+ },
280
+
281
+ /**
282
+ * Properties of a google.protobuf.Int32Value message.
283
+ * @interface IInt32Value
284
+ * @type {Object}
285
+ * @property {number} [value]
286
+ * @memberof common
287
+ */
288
+ Int32Value: {
289
+ fields: {
290
+ value: {
291
+ type: "int32",
292
+ id: 1
293
+ }
294
+ }
295
+ },
296
+
297
+ /**
298
+ * Properties of a google.protobuf.UInt32Value message.
299
+ * @interface IUInt32Value
300
+ * @type {Object}
301
+ * @property {number} [value]
302
+ * @memberof common
303
+ */
304
+ UInt32Value: {
305
+ fields: {
306
+ value: {
307
+ type: "uint32",
308
+ id: 1
309
+ }
310
+ }
311
+ },
312
+
313
+ /**
314
+ * Properties of a google.protobuf.BoolValue message.
315
+ * @interface IBoolValue
316
+ * @type {Object}
317
+ * @property {boolean} [value]
318
+ * @memberof common
319
+ */
320
+ BoolValue: {
321
+ fields: {
322
+ value: {
323
+ type: "bool",
324
+ id: 1
325
+ }
326
+ }
327
+ },
328
+
329
+ /**
330
+ * Properties of a google.protobuf.StringValue message.
331
+ * @interface IStringValue
332
+ * @type {Object}
333
+ * @property {string} [value]
334
+ * @memberof common
335
+ */
336
+ StringValue: {
337
+ fields: {
338
+ value: {
339
+ type: "string",
340
+ id: 1
341
+ }
342
+ }
343
+ },
344
+
345
+ /**
346
+ * Properties of a google.protobuf.BytesValue message.
347
+ * @interface IBytesValue
348
+ * @type {Object}
349
+ * @property {Uint8Array} [value]
350
+ * @memberof common
351
+ */
352
+ BytesValue: {
353
+ fields: {
354
+ value: {
355
+ type: "bytes",
356
+ id: 1
357
+ }
358
+ }
359
+ }
360
+ });
361
+
362
+ common("field_mask", {
363
+
364
+ /**
365
+ * Properties of a google.protobuf.FieldMask message.
366
+ * @interface IDoubleValue
367
+ * @type {Object}
368
+ * @property {number} [value]
369
+ * @memberof common
370
+ */
371
+ FieldMask: {
372
+ fields: {
373
+ paths: {
374
+ rule: "repeated",
375
+ type: "string",
376
+ id: 1
377
+ }
378
+ }
379
+ }
380
+ });
381
+
382
+ /**
383
+ * Gets the root definition of the specified common proto file.
384
+ *
385
+ * Bundled definitions are:
386
+ * - google/protobuf/any.proto
387
+ * - google/protobuf/duration.proto
388
+ * - google/protobuf/empty.proto
389
+ * - google/protobuf/field_mask.proto
390
+ * - google/protobuf/struct.proto
391
+ * - google/protobuf/timestamp.proto
392
+ * - google/protobuf/wrappers.proto
393
+ *
394
+ * @param {string} file Proto file name
395
+ * @returns {INamespace|null} Root definition or `null` if not defined
396
+ */
397
+ common.get = function get(file) {
398
+ return common[file] || null;
399
+ };