@miradorlabs/web-grpc 2.61.0 → 2.63.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,1261 @@
1
+ // source: proto/gateway/web/v1/model_gateway.proto
2
+ /**
3
+ * @fileoverview
4
+ * @enhanceable
5
+ * @suppress {missingRequire} reports error on implicit type usages.
6
+ * @suppress {messageConventions} JS Compiler reports an error if a variable or
7
+ * field starts with 'MSG_' and isn't a translatable message.
8
+ * @public
9
+ */
10
+ // GENERATED CODE -- DO NOT EDIT!
11
+ /* eslint-disable */
12
+ // @ts-nocheck
13
+
14
+ var jspb = require('google-protobuf');
15
+ var goog = jspb;
16
+ var global = globalThis;
17
+
18
+ var google_protobuf_timestamp_pb = require('google-protobuf/google/protobuf/timestamp_pb.js');
19
+ goog.object.extend(proto, google_protobuf_timestamp_pb);
20
+ var proto_gateway_common_v1_status_pb = require('../../../../proto/gateway/common/v1/status_pb.js');
21
+ goog.object.extend(proto, proto_gateway_common_v1_status_pb);
22
+ goog.exportSymbol('proto.gateway.web.v1.ListModelsRequest', null, global);
23
+ goog.exportSymbol('proto.gateway.web.v1.ListModelsResponse', null, global);
24
+ goog.exportSymbol('proto.gateway.web.v1.ModelPrice', null, global);
25
+ goog.exportSymbol('proto.gateway.web.v1.ModelPricesRequest', null, global);
26
+ goog.exportSymbol('proto.gateway.web.v1.ModelPricesResponse', null, global);
27
+ /**
28
+ * Generated by JsPbCodeGenerator.
29
+ * @param {Array=} opt_data Optional initial data array, typically from a
30
+ * server response, or constructed directly in Javascript. The array is used
31
+ * in place and becomes part of the constructed object. It is not cloned.
32
+ * If no data is provided, the constructed object will be empty, but still
33
+ * valid.
34
+ * @extends {jspb.Message}
35
+ * @constructor
36
+ */
37
+ proto.gateway.web.v1.ListModelsRequest = function(opt_data) {
38
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
39
+ };
40
+ goog.inherits(proto.gateway.web.v1.ListModelsRequest, jspb.Message);
41
+ if (goog.DEBUG && !COMPILED) {
42
+ /**
43
+ * @public
44
+ * @override
45
+ */
46
+ proto.gateway.web.v1.ListModelsRequest.displayName = 'proto.gateway.web.v1.ListModelsRequest';
47
+ }
48
+ /**
49
+ * Generated by JsPbCodeGenerator.
50
+ * @param {Array=} opt_data Optional initial data array, typically from a
51
+ * server response, or constructed directly in Javascript. The array is used
52
+ * in place and becomes part of the constructed object. It is not cloned.
53
+ * If no data is provided, the constructed object will be empty, but still
54
+ * valid.
55
+ * @extends {jspb.Message}
56
+ * @constructor
57
+ */
58
+ proto.gateway.web.v1.ListModelsResponse = function(opt_data) {
59
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.gateway.web.v1.ListModelsResponse.repeatedFields_, null);
60
+ };
61
+ goog.inherits(proto.gateway.web.v1.ListModelsResponse, jspb.Message);
62
+ if (goog.DEBUG && !COMPILED) {
63
+ /**
64
+ * @public
65
+ * @override
66
+ */
67
+ proto.gateway.web.v1.ListModelsResponse.displayName = 'proto.gateway.web.v1.ListModelsResponse';
68
+ }
69
+ /**
70
+ * Generated by JsPbCodeGenerator.
71
+ * @param {Array=} opt_data Optional initial data array, typically from a
72
+ * server response, or constructed directly in Javascript. The array is used
73
+ * in place and becomes part of the constructed object. It is not cloned.
74
+ * If no data is provided, the constructed object will be empty, but still
75
+ * valid.
76
+ * @extends {jspb.Message}
77
+ * @constructor
78
+ */
79
+ proto.gateway.web.v1.ModelPricesRequest = function(opt_data) {
80
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
81
+ };
82
+ goog.inherits(proto.gateway.web.v1.ModelPricesRequest, jspb.Message);
83
+ if (goog.DEBUG && !COMPILED) {
84
+ /**
85
+ * @public
86
+ * @override
87
+ */
88
+ proto.gateway.web.v1.ModelPricesRequest.displayName = 'proto.gateway.web.v1.ModelPricesRequest';
89
+ }
90
+ /**
91
+ * Generated by JsPbCodeGenerator.
92
+ * @param {Array=} opt_data Optional initial data array, typically from a
93
+ * server response, or constructed directly in Javascript. The array is used
94
+ * in place and becomes part of the constructed object. It is not cloned.
95
+ * If no data is provided, the constructed object will be empty, but still
96
+ * valid.
97
+ * @extends {jspb.Message}
98
+ * @constructor
99
+ */
100
+ proto.gateway.web.v1.ModelPricesResponse = function(opt_data) {
101
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.gateway.web.v1.ModelPricesResponse.repeatedFields_, null);
102
+ };
103
+ goog.inherits(proto.gateway.web.v1.ModelPricesResponse, jspb.Message);
104
+ if (goog.DEBUG && !COMPILED) {
105
+ /**
106
+ * @public
107
+ * @override
108
+ */
109
+ proto.gateway.web.v1.ModelPricesResponse.displayName = 'proto.gateway.web.v1.ModelPricesResponse';
110
+ }
111
+ /**
112
+ * Generated by JsPbCodeGenerator.
113
+ * @param {Array=} opt_data Optional initial data array, typically from a
114
+ * server response, or constructed directly in Javascript. The array is used
115
+ * in place and becomes part of the constructed object. It is not cloned.
116
+ * If no data is provided, the constructed object will be empty, but still
117
+ * valid.
118
+ * @extends {jspb.Message}
119
+ * @constructor
120
+ */
121
+ proto.gateway.web.v1.ModelPrice = function(opt_data) {
122
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
123
+ };
124
+ goog.inherits(proto.gateway.web.v1.ModelPrice, jspb.Message);
125
+ if (goog.DEBUG && !COMPILED) {
126
+ /**
127
+ * @public
128
+ * @override
129
+ */
130
+ proto.gateway.web.v1.ModelPrice.displayName = 'proto.gateway.web.v1.ModelPrice';
131
+ }
132
+
133
+
134
+
135
+ if (jspb.Message.GENERATE_TO_OBJECT) {
136
+ /**
137
+ * Creates an object representation of this proto.
138
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
139
+ * Optional fields that are not set will be set to undefined.
140
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
141
+ * For the list of reserved names please see:
142
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
143
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
144
+ * JSPB instance for transitional soy proto support:
145
+ * http://goto/soy-param-migration
146
+ * @return {!Object}
147
+ */
148
+ proto.gateway.web.v1.ListModelsRequest.prototype.toObject = function(opt_includeInstance) {
149
+ return proto.gateway.web.v1.ListModelsRequest.toObject(opt_includeInstance, this);
150
+ };
151
+
152
+
153
+ /**
154
+ * Static version of the {@see toObject} method.
155
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
156
+ * the JSPB instance for transitional soy proto support:
157
+ * http://goto/soy-param-migration
158
+ * @param {!proto.gateway.web.v1.ListModelsRequest} msg The msg instance to transform.
159
+ * @return {!Object}
160
+ * @suppress {unusedLocalVariables} f is only used for nested messages
161
+ */
162
+ proto.gateway.web.v1.ListModelsRequest.toObject = function(includeInstance, msg) {
163
+ var f, obj = {
164
+ organizationId: jspb.Message.getFieldWithDefault(msg, 1, ""),
165
+ projectId: jspb.Message.getFieldWithDefault(msg, 2, "")
166
+ };
167
+
168
+ if (includeInstance) {
169
+ obj.$jspbMessageInstance = msg;
170
+ }
171
+ return obj;
172
+ };
173
+ }
174
+
175
+
176
+ /**
177
+ * Deserializes binary data (in protobuf wire format).
178
+ * @param {jspb.binary.bytesource.ByteSource} bytes The bytes to deserialize.
179
+ * @return {!proto.gateway.web.v1.ListModelsRequest}
180
+ */
181
+ proto.gateway.web.v1.ListModelsRequest.deserializeBinary = function(bytes) {
182
+ var reader = new jspb.BinaryReader(bytes);
183
+ var msg = new proto.gateway.web.v1.ListModelsRequest;
184
+ return proto.gateway.web.v1.ListModelsRequest.deserializeBinaryFromReader(msg, reader);
185
+ };
186
+
187
+
188
+ /**
189
+ * Deserializes binary data (in protobuf wire format) from the
190
+ * given reader into the given message object.
191
+ * @param {!proto.gateway.web.v1.ListModelsRequest} msg The message object to deserialize into.
192
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
193
+ * @return {!proto.gateway.web.v1.ListModelsRequest}
194
+ */
195
+ proto.gateway.web.v1.ListModelsRequest.deserializeBinaryFromReader = function(msg, reader) {
196
+ while (reader.nextField()) {
197
+ if (reader.isEndGroup()) {
198
+ break;
199
+ }
200
+ var field = reader.getFieldNumber();
201
+ switch (field) {
202
+ case 1:
203
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
204
+ msg.setOrganizationId(value);
205
+ break;
206
+ case 2:
207
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
208
+ msg.setProjectId(value);
209
+ break;
210
+ default:
211
+ reader.skipField();
212
+ break;
213
+ }
214
+ }
215
+ return msg;
216
+ };
217
+
218
+
219
+ /**
220
+ * Serializes the message to binary data (in protobuf wire format).
221
+ * @return {!Uint8Array}
222
+ */
223
+ proto.gateway.web.v1.ListModelsRequest.prototype.serializeBinary = function() {
224
+ var writer = new jspb.BinaryWriter();
225
+ proto.gateway.web.v1.ListModelsRequest.serializeBinaryToWriter(this, writer);
226
+ return writer.getResultBuffer();
227
+ };
228
+
229
+
230
+ /**
231
+ * Serializes the given message to binary data (in protobuf wire
232
+ * format), writing to the given BinaryWriter.
233
+ * @param {!proto.gateway.web.v1.ListModelsRequest} message
234
+ * @param {!jspb.BinaryWriter} writer
235
+ * @suppress {unusedLocalVariables} f is only used for nested messages
236
+ */
237
+ proto.gateway.web.v1.ListModelsRequest.serializeBinaryToWriter = function(message, writer) {
238
+ var f = undefined;
239
+ f = message.getOrganizationId();
240
+ if (f.length > 0) {
241
+ writer.writeString(
242
+ 1,
243
+ f
244
+ );
245
+ }
246
+ f = message.getProjectId();
247
+ if (f.length > 0) {
248
+ writer.writeString(
249
+ 2,
250
+ f
251
+ );
252
+ }
253
+ };
254
+
255
+
256
+ /**
257
+ * optional string organization_id = 1;
258
+ * @return {string}
259
+ */
260
+ proto.gateway.web.v1.ListModelsRequest.prototype.getOrganizationId = function() {
261
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
262
+ };
263
+
264
+
265
+ /**
266
+ * @param {string} value
267
+ * @return {!proto.gateway.web.v1.ListModelsRequest} returns this
268
+ */
269
+ proto.gateway.web.v1.ListModelsRequest.prototype.setOrganizationId = function(value) {
270
+ return jspb.Message.setProto3StringField(this, 1, value);
271
+ };
272
+
273
+
274
+ /**
275
+ * optional string project_id = 2;
276
+ * @return {string}
277
+ */
278
+ proto.gateway.web.v1.ListModelsRequest.prototype.getProjectId = function() {
279
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
280
+ };
281
+
282
+
283
+ /**
284
+ * @param {string} value
285
+ * @return {!proto.gateway.web.v1.ListModelsRequest} returns this
286
+ */
287
+ proto.gateway.web.v1.ListModelsRequest.prototype.setProjectId = function(value) {
288
+ return jspb.Message.setProto3StringField(this, 2, value);
289
+ };
290
+
291
+
292
+
293
+ /**
294
+ * List of repeated fields within this message type.
295
+ * @private {!Array<number>}
296
+ * @const
297
+ */
298
+ proto.gateway.web.v1.ListModelsResponse.repeatedFields_ = [2];
299
+
300
+
301
+
302
+ if (jspb.Message.GENERATE_TO_OBJECT) {
303
+ /**
304
+ * Creates an object representation of this proto.
305
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
306
+ * Optional fields that are not set will be set to undefined.
307
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
308
+ * For the list of reserved names please see:
309
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
310
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
311
+ * JSPB instance for transitional soy proto support:
312
+ * http://goto/soy-param-migration
313
+ * @return {!Object}
314
+ */
315
+ proto.gateway.web.v1.ListModelsResponse.prototype.toObject = function(opt_includeInstance) {
316
+ return proto.gateway.web.v1.ListModelsResponse.toObject(opt_includeInstance, this);
317
+ };
318
+
319
+
320
+ /**
321
+ * Static version of the {@see toObject} method.
322
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
323
+ * the JSPB instance for transitional soy proto support:
324
+ * http://goto/soy-param-migration
325
+ * @param {!proto.gateway.web.v1.ListModelsResponse} msg The msg instance to transform.
326
+ * @return {!Object}
327
+ * @suppress {unusedLocalVariables} f is only used for nested messages
328
+ */
329
+ proto.gateway.web.v1.ListModelsResponse.toObject = function(includeInstance, msg) {
330
+ var f, obj = {
331
+ status: (f = msg.getStatus()) && proto_gateway_common_v1_status_pb.ResponseStatus.toObject(includeInstance, f),
332
+ modelsList: (f = jspb.Message.getRepeatedField(msg, 2)) == null ? undefined : f
333
+ };
334
+
335
+ if (includeInstance) {
336
+ obj.$jspbMessageInstance = msg;
337
+ }
338
+ return obj;
339
+ };
340
+ }
341
+
342
+
343
+ /**
344
+ * Deserializes binary data (in protobuf wire format).
345
+ * @param {jspb.binary.bytesource.ByteSource} bytes The bytes to deserialize.
346
+ * @return {!proto.gateway.web.v1.ListModelsResponse}
347
+ */
348
+ proto.gateway.web.v1.ListModelsResponse.deserializeBinary = function(bytes) {
349
+ var reader = new jspb.BinaryReader(bytes);
350
+ var msg = new proto.gateway.web.v1.ListModelsResponse;
351
+ return proto.gateway.web.v1.ListModelsResponse.deserializeBinaryFromReader(msg, reader);
352
+ };
353
+
354
+
355
+ /**
356
+ * Deserializes binary data (in protobuf wire format) from the
357
+ * given reader into the given message object.
358
+ * @param {!proto.gateway.web.v1.ListModelsResponse} msg The message object to deserialize into.
359
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
360
+ * @return {!proto.gateway.web.v1.ListModelsResponse}
361
+ */
362
+ proto.gateway.web.v1.ListModelsResponse.deserializeBinaryFromReader = function(msg, reader) {
363
+ while (reader.nextField()) {
364
+ if (reader.isEndGroup()) {
365
+ break;
366
+ }
367
+ var field = reader.getFieldNumber();
368
+ switch (field) {
369
+ case 1:
370
+ var value = new proto_gateway_common_v1_status_pb.ResponseStatus;
371
+ reader.readMessage(value,proto_gateway_common_v1_status_pb.ResponseStatus.deserializeBinaryFromReader);
372
+ msg.setStatus(value);
373
+ break;
374
+ case 2:
375
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
376
+ msg.addModels(value);
377
+ break;
378
+ default:
379
+ reader.skipField();
380
+ break;
381
+ }
382
+ }
383
+ return msg;
384
+ };
385
+
386
+
387
+ /**
388
+ * Serializes the message to binary data (in protobuf wire format).
389
+ * @return {!Uint8Array}
390
+ */
391
+ proto.gateway.web.v1.ListModelsResponse.prototype.serializeBinary = function() {
392
+ var writer = new jspb.BinaryWriter();
393
+ proto.gateway.web.v1.ListModelsResponse.serializeBinaryToWriter(this, writer);
394
+ return writer.getResultBuffer();
395
+ };
396
+
397
+
398
+ /**
399
+ * Serializes the given message to binary data (in protobuf wire
400
+ * format), writing to the given BinaryWriter.
401
+ * @param {!proto.gateway.web.v1.ListModelsResponse} message
402
+ * @param {!jspb.BinaryWriter} writer
403
+ * @suppress {unusedLocalVariables} f is only used for nested messages
404
+ */
405
+ proto.gateway.web.v1.ListModelsResponse.serializeBinaryToWriter = function(message, writer) {
406
+ var f = undefined;
407
+ f = message.getStatus();
408
+ if (f != null) {
409
+ writer.writeMessage(
410
+ 1,
411
+ f,
412
+ proto_gateway_common_v1_status_pb.ResponseStatus.serializeBinaryToWriter
413
+ );
414
+ }
415
+ f = message.getModelsList();
416
+ if (f.length > 0) {
417
+ writer.writeRepeatedString(
418
+ 2,
419
+ f
420
+ );
421
+ }
422
+ };
423
+
424
+
425
+ /**
426
+ * optional gateway.common.v1.ResponseStatus status = 1;
427
+ * @return {?proto.gateway.common.v1.ResponseStatus}
428
+ */
429
+ proto.gateway.web.v1.ListModelsResponse.prototype.getStatus = function() {
430
+ return /** @type{?proto.gateway.common.v1.ResponseStatus} */ (
431
+ jspb.Message.getWrapperField(this, proto_gateway_common_v1_status_pb.ResponseStatus, 1));
432
+ };
433
+
434
+
435
+ /**
436
+ * @param {?proto.gateway.common.v1.ResponseStatus|undefined} value
437
+ * @return {!proto.gateway.web.v1.ListModelsResponse} returns this
438
+ */
439
+ proto.gateway.web.v1.ListModelsResponse.prototype.setStatus = function(value) {
440
+ return jspb.Message.setWrapperField(this, 1, value);
441
+ };
442
+
443
+
444
+ /**
445
+ * Clears the message field making it undefined.
446
+ * @return {!proto.gateway.web.v1.ListModelsResponse} returns this
447
+ */
448
+ proto.gateway.web.v1.ListModelsResponse.prototype.clearStatus = function() {
449
+ return this.setStatus(undefined);
450
+ };
451
+
452
+
453
+ /**
454
+ * Returns whether this field is set.
455
+ * @return {boolean}
456
+ */
457
+ proto.gateway.web.v1.ListModelsResponse.prototype.hasStatus = function() {
458
+ return jspb.Message.getField(this, 1) != null;
459
+ };
460
+
461
+
462
+ /**
463
+ * repeated string models = 2;
464
+ * @return {!Array<string>}
465
+ */
466
+ proto.gateway.web.v1.ListModelsResponse.prototype.getModelsList = function() {
467
+ return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 2));
468
+ };
469
+
470
+
471
+ /**
472
+ * @param {!Array<string>} value
473
+ * @return {!proto.gateway.web.v1.ListModelsResponse} returns this
474
+ */
475
+ proto.gateway.web.v1.ListModelsResponse.prototype.setModelsList = function(value) {
476
+ return jspb.Message.setField(this, 2, value || []);
477
+ };
478
+
479
+
480
+ /**
481
+ * @param {string} value
482
+ * @param {number=} opt_index
483
+ * @return {!proto.gateway.web.v1.ListModelsResponse} returns this
484
+ */
485
+ proto.gateway.web.v1.ListModelsResponse.prototype.addModels = function(value, opt_index) {
486
+ return jspb.Message.addToRepeatedField(this, 2, value, opt_index);
487
+ };
488
+
489
+
490
+ /**
491
+ * Clears the list making it empty but non-null.
492
+ * @return {!proto.gateway.web.v1.ListModelsResponse} returns this
493
+ */
494
+ proto.gateway.web.v1.ListModelsResponse.prototype.clearModelsList = function() {
495
+ return this.setModelsList([]);
496
+ };
497
+
498
+
499
+
500
+
501
+
502
+ if (jspb.Message.GENERATE_TO_OBJECT) {
503
+ /**
504
+ * Creates an object representation of this proto.
505
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
506
+ * Optional fields that are not set will be set to undefined.
507
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
508
+ * For the list of reserved names please see:
509
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
510
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
511
+ * JSPB instance for transitional soy proto support:
512
+ * http://goto/soy-param-migration
513
+ * @return {!Object}
514
+ */
515
+ proto.gateway.web.v1.ModelPricesRequest.prototype.toObject = function(opt_includeInstance) {
516
+ return proto.gateway.web.v1.ModelPricesRequest.toObject(opt_includeInstance, this);
517
+ };
518
+
519
+
520
+ /**
521
+ * Static version of the {@see toObject} method.
522
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
523
+ * the JSPB instance for transitional soy proto support:
524
+ * http://goto/soy-param-migration
525
+ * @param {!proto.gateway.web.v1.ModelPricesRequest} msg The msg instance to transform.
526
+ * @return {!Object}
527
+ * @suppress {unusedLocalVariables} f is only used for nested messages
528
+ */
529
+ proto.gateway.web.v1.ModelPricesRequest.toObject = function(includeInstance, msg) {
530
+ var f, obj = {
531
+ organizationId: jspb.Message.getFieldWithDefault(msg, 1, ""),
532
+ projectId: jspb.Message.getFieldWithDefault(msg, 2, ""),
533
+ model: jspb.Message.getFieldWithDefault(msg, 3, "")
534
+ };
535
+
536
+ if (includeInstance) {
537
+ obj.$jspbMessageInstance = msg;
538
+ }
539
+ return obj;
540
+ };
541
+ }
542
+
543
+
544
+ /**
545
+ * Deserializes binary data (in protobuf wire format).
546
+ * @param {jspb.binary.bytesource.ByteSource} bytes The bytes to deserialize.
547
+ * @return {!proto.gateway.web.v1.ModelPricesRequest}
548
+ */
549
+ proto.gateway.web.v1.ModelPricesRequest.deserializeBinary = function(bytes) {
550
+ var reader = new jspb.BinaryReader(bytes);
551
+ var msg = new proto.gateway.web.v1.ModelPricesRequest;
552
+ return proto.gateway.web.v1.ModelPricesRequest.deserializeBinaryFromReader(msg, reader);
553
+ };
554
+
555
+
556
+ /**
557
+ * Deserializes binary data (in protobuf wire format) from the
558
+ * given reader into the given message object.
559
+ * @param {!proto.gateway.web.v1.ModelPricesRequest} msg The message object to deserialize into.
560
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
561
+ * @return {!proto.gateway.web.v1.ModelPricesRequest}
562
+ */
563
+ proto.gateway.web.v1.ModelPricesRequest.deserializeBinaryFromReader = function(msg, reader) {
564
+ while (reader.nextField()) {
565
+ if (reader.isEndGroup()) {
566
+ break;
567
+ }
568
+ var field = reader.getFieldNumber();
569
+ switch (field) {
570
+ case 1:
571
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
572
+ msg.setOrganizationId(value);
573
+ break;
574
+ case 2:
575
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
576
+ msg.setProjectId(value);
577
+ break;
578
+ case 3:
579
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
580
+ msg.setModel(value);
581
+ break;
582
+ default:
583
+ reader.skipField();
584
+ break;
585
+ }
586
+ }
587
+ return msg;
588
+ };
589
+
590
+
591
+ /**
592
+ * Serializes the message to binary data (in protobuf wire format).
593
+ * @return {!Uint8Array}
594
+ */
595
+ proto.gateway.web.v1.ModelPricesRequest.prototype.serializeBinary = function() {
596
+ var writer = new jspb.BinaryWriter();
597
+ proto.gateway.web.v1.ModelPricesRequest.serializeBinaryToWriter(this, writer);
598
+ return writer.getResultBuffer();
599
+ };
600
+
601
+
602
+ /**
603
+ * Serializes the given message to binary data (in protobuf wire
604
+ * format), writing to the given BinaryWriter.
605
+ * @param {!proto.gateway.web.v1.ModelPricesRequest} message
606
+ * @param {!jspb.BinaryWriter} writer
607
+ * @suppress {unusedLocalVariables} f is only used for nested messages
608
+ */
609
+ proto.gateway.web.v1.ModelPricesRequest.serializeBinaryToWriter = function(message, writer) {
610
+ var f = undefined;
611
+ f = message.getOrganizationId();
612
+ if (f.length > 0) {
613
+ writer.writeString(
614
+ 1,
615
+ f
616
+ );
617
+ }
618
+ f = message.getProjectId();
619
+ if (f.length > 0) {
620
+ writer.writeString(
621
+ 2,
622
+ f
623
+ );
624
+ }
625
+ f = message.getModel();
626
+ if (f.length > 0) {
627
+ writer.writeString(
628
+ 3,
629
+ f
630
+ );
631
+ }
632
+ };
633
+
634
+
635
+ /**
636
+ * optional string organization_id = 1;
637
+ * @return {string}
638
+ */
639
+ proto.gateway.web.v1.ModelPricesRequest.prototype.getOrganizationId = function() {
640
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
641
+ };
642
+
643
+
644
+ /**
645
+ * @param {string} value
646
+ * @return {!proto.gateway.web.v1.ModelPricesRequest} returns this
647
+ */
648
+ proto.gateway.web.v1.ModelPricesRequest.prototype.setOrganizationId = function(value) {
649
+ return jspb.Message.setProto3StringField(this, 1, value);
650
+ };
651
+
652
+
653
+ /**
654
+ * optional string project_id = 2;
655
+ * @return {string}
656
+ */
657
+ proto.gateway.web.v1.ModelPricesRequest.prototype.getProjectId = function() {
658
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
659
+ };
660
+
661
+
662
+ /**
663
+ * @param {string} value
664
+ * @return {!proto.gateway.web.v1.ModelPricesRequest} returns this
665
+ */
666
+ proto.gateway.web.v1.ModelPricesRequest.prototype.setProjectId = function(value) {
667
+ return jspb.Message.setProto3StringField(this, 2, value);
668
+ };
669
+
670
+
671
+ /**
672
+ * optional string model = 3;
673
+ * @return {string}
674
+ */
675
+ proto.gateway.web.v1.ModelPricesRequest.prototype.getModel = function() {
676
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
677
+ };
678
+
679
+
680
+ /**
681
+ * @param {string} value
682
+ * @return {!proto.gateway.web.v1.ModelPricesRequest} returns this
683
+ */
684
+ proto.gateway.web.v1.ModelPricesRequest.prototype.setModel = function(value) {
685
+ return jspb.Message.setProto3StringField(this, 3, value);
686
+ };
687
+
688
+
689
+
690
+ /**
691
+ * List of repeated fields within this message type.
692
+ * @private {!Array<number>}
693
+ * @const
694
+ */
695
+ proto.gateway.web.v1.ModelPricesResponse.repeatedFields_ = [2];
696
+
697
+
698
+
699
+ if (jspb.Message.GENERATE_TO_OBJECT) {
700
+ /**
701
+ * Creates an object representation of this proto.
702
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
703
+ * Optional fields that are not set will be set to undefined.
704
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
705
+ * For the list of reserved names please see:
706
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
707
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
708
+ * JSPB instance for transitional soy proto support:
709
+ * http://goto/soy-param-migration
710
+ * @return {!Object}
711
+ */
712
+ proto.gateway.web.v1.ModelPricesResponse.prototype.toObject = function(opt_includeInstance) {
713
+ return proto.gateway.web.v1.ModelPricesResponse.toObject(opt_includeInstance, this);
714
+ };
715
+
716
+
717
+ /**
718
+ * Static version of the {@see toObject} method.
719
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
720
+ * the JSPB instance for transitional soy proto support:
721
+ * http://goto/soy-param-migration
722
+ * @param {!proto.gateway.web.v1.ModelPricesResponse} msg The msg instance to transform.
723
+ * @return {!Object}
724
+ * @suppress {unusedLocalVariables} f is only used for nested messages
725
+ */
726
+ proto.gateway.web.v1.ModelPricesResponse.toObject = function(includeInstance, msg) {
727
+ var f, obj = {
728
+ status: (f = msg.getStatus()) && proto_gateway_common_v1_status_pb.ResponseStatus.toObject(includeInstance, f),
729
+ pricesList: jspb.Message.toObjectList(msg.getPricesList(),
730
+ proto.gateway.web.v1.ModelPrice.toObject, includeInstance)
731
+ };
732
+
733
+ if (includeInstance) {
734
+ obj.$jspbMessageInstance = msg;
735
+ }
736
+ return obj;
737
+ };
738
+ }
739
+
740
+
741
+ /**
742
+ * Deserializes binary data (in protobuf wire format).
743
+ * @param {jspb.binary.bytesource.ByteSource} bytes The bytes to deserialize.
744
+ * @return {!proto.gateway.web.v1.ModelPricesResponse}
745
+ */
746
+ proto.gateway.web.v1.ModelPricesResponse.deserializeBinary = function(bytes) {
747
+ var reader = new jspb.BinaryReader(bytes);
748
+ var msg = new proto.gateway.web.v1.ModelPricesResponse;
749
+ return proto.gateway.web.v1.ModelPricesResponse.deserializeBinaryFromReader(msg, reader);
750
+ };
751
+
752
+
753
+ /**
754
+ * Deserializes binary data (in protobuf wire format) from the
755
+ * given reader into the given message object.
756
+ * @param {!proto.gateway.web.v1.ModelPricesResponse} msg The message object to deserialize into.
757
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
758
+ * @return {!proto.gateway.web.v1.ModelPricesResponse}
759
+ */
760
+ proto.gateway.web.v1.ModelPricesResponse.deserializeBinaryFromReader = function(msg, reader) {
761
+ while (reader.nextField()) {
762
+ if (reader.isEndGroup()) {
763
+ break;
764
+ }
765
+ var field = reader.getFieldNumber();
766
+ switch (field) {
767
+ case 1:
768
+ var value = new proto_gateway_common_v1_status_pb.ResponseStatus;
769
+ reader.readMessage(value,proto_gateway_common_v1_status_pb.ResponseStatus.deserializeBinaryFromReader);
770
+ msg.setStatus(value);
771
+ break;
772
+ case 2:
773
+ var value = new proto.gateway.web.v1.ModelPrice;
774
+ reader.readMessage(value,proto.gateway.web.v1.ModelPrice.deserializeBinaryFromReader);
775
+ msg.addPrices(value);
776
+ break;
777
+ default:
778
+ reader.skipField();
779
+ break;
780
+ }
781
+ }
782
+ return msg;
783
+ };
784
+
785
+
786
+ /**
787
+ * Serializes the message to binary data (in protobuf wire format).
788
+ * @return {!Uint8Array}
789
+ */
790
+ proto.gateway.web.v1.ModelPricesResponse.prototype.serializeBinary = function() {
791
+ var writer = new jspb.BinaryWriter();
792
+ proto.gateway.web.v1.ModelPricesResponse.serializeBinaryToWriter(this, writer);
793
+ return writer.getResultBuffer();
794
+ };
795
+
796
+
797
+ /**
798
+ * Serializes the given message to binary data (in protobuf wire
799
+ * format), writing to the given BinaryWriter.
800
+ * @param {!proto.gateway.web.v1.ModelPricesResponse} message
801
+ * @param {!jspb.BinaryWriter} writer
802
+ * @suppress {unusedLocalVariables} f is only used for nested messages
803
+ */
804
+ proto.gateway.web.v1.ModelPricesResponse.serializeBinaryToWriter = function(message, writer) {
805
+ var f = undefined;
806
+ f = message.getStatus();
807
+ if (f != null) {
808
+ writer.writeMessage(
809
+ 1,
810
+ f,
811
+ proto_gateway_common_v1_status_pb.ResponseStatus.serializeBinaryToWriter
812
+ );
813
+ }
814
+ f = message.getPricesList();
815
+ if (f.length > 0) {
816
+ writer.writeRepeatedMessage(
817
+ 2,
818
+ f,
819
+ proto.gateway.web.v1.ModelPrice.serializeBinaryToWriter
820
+ );
821
+ }
822
+ };
823
+
824
+
825
+ /**
826
+ * optional gateway.common.v1.ResponseStatus status = 1;
827
+ * @return {?proto.gateway.common.v1.ResponseStatus}
828
+ */
829
+ proto.gateway.web.v1.ModelPricesResponse.prototype.getStatus = function() {
830
+ return /** @type{?proto.gateway.common.v1.ResponseStatus} */ (
831
+ jspb.Message.getWrapperField(this, proto_gateway_common_v1_status_pb.ResponseStatus, 1));
832
+ };
833
+
834
+
835
+ /**
836
+ * @param {?proto.gateway.common.v1.ResponseStatus|undefined} value
837
+ * @return {!proto.gateway.web.v1.ModelPricesResponse} returns this
838
+ */
839
+ proto.gateway.web.v1.ModelPricesResponse.prototype.setStatus = function(value) {
840
+ return jspb.Message.setWrapperField(this, 1, value);
841
+ };
842
+
843
+
844
+ /**
845
+ * Clears the message field making it undefined.
846
+ * @return {!proto.gateway.web.v1.ModelPricesResponse} returns this
847
+ */
848
+ proto.gateway.web.v1.ModelPricesResponse.prototype.clearStatus = function() {
849
+ return this.setStatus(undefined);
850
+ };
851
+
852
+
853
+ /**
854
+ * Returns whether this field is set.
855
+ * @return {boolean}
856
+ */
857
+ proto.gateway.web.v1.ModelPricesResponse.prototype.hasStatus = function() {
858
+ return jspb.Message.getField(this, 1) != null;
859
+ };
860
+
861
+
862
+ /**
863
+ * repeated ModelPrice prices = 2;
864
+ * @return {!Array<!proto.gateway.web.v1.ModelPrice>}
865
+ */
866
+ proto.gateway.web.v1.ModelPricesResponse.prototype.getPricesList = function() {
867
+ return /** @type{!Array<!proto.gateway.web.v1.ModelPrice>} */ (
868
+ jspb.Message.getRepeatedWrapperField(this, proto.gateway.web.v1.ModelPrice, 2));
869
+ };
870
+
871
+
872
+ /**
873
+ * @param {!Array<!proto.gateway.web.v1.ModelPrice>} value
874
+ * @return {!proto.gateway.web.v1.ModelPricesResponse} returns this
875
+ */
876
+ proto.gateway.web.v1.ModelPricesResponse.prototype.setPricesList = function(value) {
877
+ return jspb.Message.setRepeatedWrapperField(this, 2, value);
878
+ };
879
+
880
+
881
+ /**
882
+ * @param {!proto.gateway.web.v1.ModelPrice=} opt_value
883
+ * @param {number=} opt_index
884
+ * @return {!proto.gateway.web.v1.ModelPrice}
885
+ */
886
+ proto.gateway.web.v1.ModelPricesResponse.prototype.addPrices = function(opt_value, opt_index) {
887
+ return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.gateway.web.v1.ModelPrice, opt_index);
888
+ };
889
+
890
+
891
+ /**
892
+ * Clears the list making it empty but non-null.
893
+ * @return {!proto.gateway.web.v1.ModelPricesResponse} returns this
894
+ */
895
+ proto.gateway.web.v1.ModelPricesResponse.prototype.clearPricesList = function() {
896
+ return this.setPricesList([]);
897
+ };
898
+
899
+
900
+
901
+
902
+
903
+ if (jspb.Message.GENERATE_TO_OBJECT) {
904
+ /**
905
+ * Creates an object representation of this proto.
906
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
907
+ * Optional fields that are not set will be set to undefined.
908
+ * To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
909
+ * For the list of reserved names please see:
910
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
911
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
912
+ * JSPB instance for transitional soy proto support:
913
+ * http://goto/soy-param-migration
914
+ * @return {!Object}
915
+ */
916
+ proto.gateway.web.v1.ModelPrice.prototype.toObject = function(opt_includeInstance) {
917
+ return proto.gateway.web.v1.ModelPrice.toObject(opt_includeInstance, this);
918
+ };
919
+
920
+
921
+ /**
922
+ * Static version of the {@see toObject} method.
923
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
924
+ * the JSPB instance for transitional soy proto support:
925
+ * http://goto/soy-param-migration
926
+ * @param {!proto.gateway.web.v1.ModelPrice} msg The msg instance to transform.
927
+ * @return {!Object}
928
+ * @suppress {unusedLocalVariables} f is only used for nested messages
929
+ */
930
+ proto.gateway.web.v1.ModelPrice.toObject = function(includeInstance, msg) {
931
+ var f, obj = {
932
+ source: jspb.Message.getFieldWithDefault(msg, 1, ""),
933
+ provider: jspb.Message.getFieldWithDefault(msg, 2, ""),
934
+ model: jspb.Message.getFieldWithDefault(msg, 3, ""),
935
+ scrapedAt: (f = msg.getScrapedAt()) && google_protobuf_timestamp_pb.Timestamp.toObject(includeInstance, f),
936
+ inputUsdPerMtok: jspb.Message.getFloatingPointFieldWithDefault(msg, 5, 0.0),
937
+ outputUsdPerMtok: jspb.Message.getFloatingPointFieldWithDefault(msg, 6, 0.0),
938
+ cacheReadUsdPerMtok: jspb.Message.getFloatingPointFieldWithDefault(msg, 7, 0.0),
939
+ cacheWriteUsdPerMtok: jspb.Message.getFloatingPointFieldWithDefault(msg, 8, 0.0)
940
+ };
941
+
942
+ if (includeInstance) {
943
+ obj.$jspbMessageInstance = msg;
944
+ }
945
+ return obj;
946
+ };
947
+ }
948
+
949
+
950
+ /**
951
+ * Deserializes binary data (in protobuf wire format).
952
+ * @param {jspb.binary.bytesource.ByteSource} bytes The bytes to deserialize.
953
+ * @return {!proto.gateway.web.v1.ModelPrice}
954
+ */
955
+ proto.gateway.web.v1.ModelPrice.deserializeBinary = function(bytes) {
956
+ var reader = new jspb.BinaryReader(bytes);
957
+ var msg = new proto.gateway.web.v1.ModelPrice;
958
+ return proto.gateway.web.v1.ModelPrice.deserializeBinaryFromReader(msg, reader);
959
+ };
960
+
961
+
962
+ /**
963
+ * Deserializes binary data (in protobuf wire format) from the
964
+ * given reader into the given message object.
965
+ * @param {!proto.gateway.web.v1.ModelPrice} msg The message object to deserialize into.
966
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
967
+ * @return {!proto.gateway.web.v1.ModelPrice}
968
+ */
969
+ proto.gateway.web.v1.ModelPrice.deserializeBinaryFromReader = function(msg, reader) {
970
+ while (reader.nextField()) {
971
+ if (reader.isEndGroup()) {
972
+ break;
973
+ }
974
+ var field = reader.getFieldNumber();
975
+ switch (field) {
976
+ case 1:
977
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
978
+ msg.setSource(value);
979
+ break;
980
+ case 2:
981
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
982
+ msg.setProvider(value);
983
+ break;
984
+ case 3:
985
+ var value = /** @type {string} */ (reader.readStringRequireUtf8());
986
+ msg.setModel(value);
987
+ break;
988
+ case 4:
989
+ var value = new google_protobuf_timestamp_pb.Timestamp;
990
+ reader.readMessage(value,google_protobuf_timestamp_pb.Timestamp.deserializeBinaryFromReader);
991
+ msg.setScrapedAt(value);
992
+ break;
993
+ case 5:
994
+ var value = /** @type {number} */ (reader.readDouble());
995
+ msg.setInputUsdPerMtok(value);
996
+ break;
997
+ case 6:
998
+ var value = /** @type {number} */ (reader.readDouble());
999
+ msg.setOutputUsdPerMtok(value);
1000
+ break;
1001
+ case 7:
1002
+ var value = /** @type {number} */ (reader.readDouble());
1003
+ msg.setCacheReadUsdPerMtok(value);
1004
+ break;
1005
+ case 8:
1006
+ var value = /** @type {number} */ (reader.readDouble());
1007
+ msg.setCacheWriteUsdPerMtok(value);
1008
+ break;
1009
+ default:
1010
+ reader.skipField();
1011
+ break;
1012
+ }
1013
+ }
1014
+ return msg;
1015
+ };
1016
+
1017
+
1018
+ /**
1019
+ * Serializes the message to binary data (in protobuf wire format).
1020
+ * @return {!Uint8Array}
1021
+ */
1022
+ proto.gateway.web.v1.ModelPrice.prototype.serializeBinary = function() {
1023
+ var writer = new jspb.BinaryWriter();
1024
+ proto.gateway.web.v1.ModelPrice.serializeBinaryToWriter(this, writer);
1025
+ return writer.getResultBuffer();
1026
+ };
1027
+
1028
+
1029
+ /**
1030
+ * Serializes the given message to binary data (in protobuf wire
1031
+ * format), writing to the given BinaryWriter.
1032
+ * @param {!proto.gateway.web.v1.ModelPrice} message
1033
+ * @param {!jspb.BinaryWriter} writer
1034
+ * @suppress {unusedLocalVariables} f is only used for nested messages
1035
+ */
1036
+ proto.gateway.web.v1.ModelPrice.serializeBinaryToWriter = function(message, writer) {
1037
+ var f = undefined;
1038
+ f = message.getSource();
1039
+ if (f.length > 0) {
1040
+ writer.writeString(
1041
+ 1,
1042
+ f
1043
+ );
1044
+ }
1045
+ f = message.getProvider();
1046
+ if (f.length > 0) {
1047
+ writer.writeString(
1048
+ 2,
1049
+ f
1050
+ );
1051
+ }
1052
+ f = message.getModel();
1053
+ if (f.length > 0) {
1054
+ writer.writeString(
1055
+ 3,
1056
+ f
1057
+ );
1058
+ }
1059
+ f = message.getScrapedAt();
1060
+ if (f != null) {
1061
+ writer.writeMessage(
1062
+ 4,
1063
+ f,
1064
+ google_protobuf_timestamp_pb.Timestamp.serializeBinaryToWriter
1065
+ );
1066
+ }
1067
+ f = message.getInputUsdPerMtok();
1068
+ if (f !== 0.0) {
1069
+ writer.writeDouble(
1070
+ 5,
1071
+ f
1072
+ );
1073
+ }
1074
+ f = message.getOutputUsdPerMtok();
1075
+ if (f !== 0.0) {
1076
+ writer.writeDouble(
1077
+ 6,
1078
+ f
1079
+ );
1080
+ }
1081
+ f = message.getCacheReadUsdPerMtok();
1082
+ if (f !== 0.0) {
1083
+ writer.writeDouble(
1084
+ 7,
1085
+ f
1086
+ );
1087
+ }
1088
+ f = message.getCacheWriteUsdPerMtok();
1089
+ if (f !== 0.0) {
1090
+ writer.writeDouble(
1091
+ 8,
1092
+ f
1093
+ );
1094
+ }
1095
+ };
1096
+
1097
+
1098
+ /**
1099
+ * optional string source = 1;
1100
+ * @return {string}
1101
+ */
1102
+ proto.gateway.web.v1.ModelPrice.prototype.getSource = function() {
1103
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
1104
+ };
1105
+
1106
+
1107
+ /**
1108
+ * @param {string} value
1109
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1110
+ */
1111
+ proto.gateway.web.v1.ModelPrice.prototype.setSource = function(value) {
1112
+ return jspb.Message.setProto3StringField(this, 1, value);
1113
+ };
1114
+
1115
+
1116
+ /**
1117
+ * optional string provider = 2;
1118
+ * @return {string}
1119
+ */
1120
+ proto.gateway.web.v1.ModelPrice.prototype.getProvider = function() {
1121
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
1122
+ };
1123
+
1124
+
1125
+ /**
1126
+ * @param {string} value
1127
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1128
+ */
1129
+ proto.gateway.web.v1.ModelPrice.prototype.setProvider = function(value) {
1130
+ return jspb.Message.setProto3StringField(this, 2, value);
1131
+ };
1132
+
1133
+
1134
+ /**
1135
+ * optional string model = 3;
1136
+ * @return {string}
1137
+ */
1138
+ proto.gateway.web.v1.ModelPrice.prototype.getModel = function() {
1139
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
1140
+ };
1141
+
1142
+
1143
+ /**
1144
+ * @param {string} value
1145
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1146
+ */
1147
+ proto.gateway.web.v1.ModelPrice.prototype.setModel = function(value) {
1148
+ return jspb.Message.setProto3StringField(this, 3, value);
1149
+ };
1150
+
1151
+
1152
+ /**
1153
+ * optional google.protobuf.Timestamp scraped_at = 4;
1154
+ * @return {?proto.google.protobuf.Timestamp}
1155
+ */
1156
+ proto.gateway.web.v1.ModelPrice.prototype.getScrapedAt = function() {
1157
+ return /** @type{?proto.google.protobuf.Timestamp} */ (
1158
+ jspb.Message.getWrapperField(this, google_protobuf_timestamp_pb.Timestamp, 4));
1159
+ };
1160
+
1161
+
1162
+ /**
1163
+ * @param {?proto.google.protobuf.Timestamp|undefined} value
1164
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1165
+ */
1166
+ proto.gateway.web.v1.ModelPrice.prototype.setScrapedAt = function(value) {
1167
+ return jspb.Message.setWrapperField(this, 4, value);
1168
+ };
1169
+
1170
+
1171
+ /**
1172
+ * Clears the message field making it undefined.
1173
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1174
+ */
1175
+ proto.gateway.web.v1.ModelPrice.prototype.clearScrapedAt = function() {
1176
+ return this.setScrapedAt(undefined);
1177
+ };
1178
+
1179
+
1180
+ /**
1181
+ * Returns whether this field is set.
1182
+ * @return {boolean}
1183
+ */
1184
+ proto.gateway.web.v1.ModelPrice.prototype.hasScrapedAt = function() {
1185
+ return jspb.Message.getField(this, 4) != null;
1186
+ };
1187
+
1188
+
1189
+ /**
1190
+ * optional double input_usd_per_mtok = 5;
1191
+ * @return {number}
1192
+ */
1193
+ proto.gateway.web.v1.ModelPrice.prototype.getInputUsdPerMtok = function() {
1194
+ return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 5, 0.0));
1195
+ };
1196
+
1197
+
1198
+ /**
1199
+ * @param {number} value
1200
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1201
+ */
1202
+ proto.gateway.web.v1.ModelPrice.prototype.setInputUsdPerMtok = function(value) {
1203
+ return jspb.Message.setProto3FloatField(this, 5, value);
1204
+ };
1205
+
1206
+
1207
+ /**
1208
+ * optional double output_usd_per_mtok = 6;
1209
+ * @return {number}
1210
+ */
1211
+ proto.gateway.web.v1.ModelPrice.prototype.getOutputUsdPerMtok = function() {
1212
+ return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 6, 0.0));
1213
+ };
1214
+
1215
+
1216
+ /**
1217
+ * @param {number} value
1218
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1219
+ */
1220
+ proto.gateway.web.v1.ModelPrice.prototype.setOutputUsdPerMtok = function(value) {
1221
+ return jspb.Message.setProto3FloatField(this, 6, value);
1222
+ };
1223
+
1224
+
1225
+ /**
1226
+ * optional double cache_read_usd_per_mtok = 7;
1227
+ * @return {number}
1228
+ */
1229
+ proto.gateway.web.v1.ModelPrice.prototype.getCacheReadUsdPerMtok = function() {
1230
+ return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 7, 0.0));
1231
+ };
1232
+
1233
+
1234
+ /**
1235
+ * @param {number} value
1236
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1237
+ */
1238
+ proto.gateway.web.v1.ModelPrice.prototype.setCacheReadUsdPerMtok = function(value) {
1239
+ return jspb.Message.setProto3FloatField(this, 7, value);
1240
+ };
1241
+
1242
+
1243
+ /**
1244
+ * optional double cache_write_usd_per_mtok = 8;
1245
+ * @return {number}
1246
+ */
1247
+ proto.gateway.web.v1.ModelPrice.prototype.getCacheWriteUsdPerMtok = function() {
1248
+ return /** @type {number} */ (jspb.Message.getFloatingPointFieldWithDefault(this, 8, 0.0));
1249
+ };
1250
+
1251
+
1252
+ /**
1253
+ * @param {number} value
1254
+ * @return {!proto.gateway.web.v1.ModelPrice} returns this
1255
+ */
1256
+ proto.gateway.web.v1.ModelPrice.prototype.setCacheWriteUsdPerMtok = function(value) {
1257
+ return jspb.Message.setProto3FloatField(this, 8, value);
1258
+ };
1259
+
1260
+
1261
+ goog.object.extend(exports, proto.gateway.web.v1);