/
model_status_mongo_db.go
486 lines (414 loc) · 15.5 KB
/
model_status_mongo_db.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
/*
* REST API
*
* Rockset's REST API allows for creating and managing all resources in Rockset. Each supported endpoint is documented below. All requests must be authorized with a Rockset API key, which can be created in the [Rockset console](https://console.rockset.com). The API key must be provided as `ApiKey <api_key>` in the `Authorization` request header. For example: ``` Authorization: ApiKey aB35kDjg93J5nsf4GjwMeErAVd832F7ad4vhsW1S02kfZiab42sTsfW5Sxt25asT ``` All endpoints are only accessible via https. Build something awesome!
*
* API version: v1
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package openapi
import (
"encoding/json"
)
// StatusMongoDb struct for StatusMongoDb
type StatusMongoDb struct {
// MongoDB scan start time
ScanStartTime *string `json:"scan_start_time,omitempty"`
// MongoDB scan end time
ScanEndTime *string `json:"scan_end_time,omitempty"`
// Number of records inserted using scan
ScanRecordsProcessed *int64 `json:"scan_records_processed,omitempty"`
// Number of records in MongoDB table at time of scan
ScanTotalRecords *int64 `json:"scan_total_records,omitempty"`
// state of current ingest for this table
State *string `json:"state,omitempty"`
// ISO-8601 date when new insert from source was last processed
StreamLastInsertProcessedAt *string `json:"stream_last_insert_processed_at,omitempty"`
// ISO-8601 date when update from source was last processed
StreamLastUpdateProcessedAt *string `json:"stream_last_update_processed_at,omitempty"`
// ISO-8601 date when delete from source was last processed
StreamLastDeleteProcessedAt *string `json:"stream_last_delete_processed_at,omitempty"`
// Number of new records inserted using stream
StreamRecordsInserted *int64 `json:"stream_records_inserted,omitempty"`
// Number of new records updated using stream
StreamRecordsUpdated *int64 `json:"stream_records_updated,omitempty"`
// Number of new records deleted using stream
StreamRecordsDeleted *int64 `json:"stream_records_deleted,omitempty"`
}
// NewStatusMongoDb instantiates a new StatusMongoDb object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
func NewStatusMongoDb() *StatusMongoDb {
this := StatusMongoDb{}
return &this
}
// NewStatusMongoDbWithDefaults instantiates a new StatusMongoDb object
// This constructor will only assign default values to properties that have it defined,
// but it doesn't guarantee that properties required by API are set
func NewStatusMongoDbWithDefaults() *StatusMongoDb {
this := StatusMongoDb{}
return &this
}
// GetScanStartTime returns the ScanStartTime field value if set, zero value otherwise.
func (o *StatusMongoDb) GetScanStartTime() string {
if o == nil || o.ScanStartTime == nil {
var ret string
return ret
}
return *o.ScanStartTime
}
// GetScanStartTimeOk returns a tuple with the ScanStartTime field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetScanStartTimeOk() (*string, bool) {
if o == nil || o.ScanStartTime == nil {
return nil, false
}
return o.ScanStartTime, true
}
// HasScanStartTime returns a boolean if a field has been set.
func (o *StatusMongoDb) HasScanStartTime() bool {
if o != nil && o.ScanStartTime != nil {
return true
}
return false
}
// SetScanStartTime gets a reference to the given string and assigns it to the ScanStartTime field.
func (o *StatusMongoDb) SetScanStartTime(v string) {
o.ScanStartTime = &v
}
// GetScanEndTime returns the ScanEndTime field value if set, zero value otherwise.
func (o *StatusMongoDb) GetScanEndTime() string {
if o == nil || o.ScanEndTime == nil {
var ret string
return ret
}
return *o.ScanEndTime
}
// GetScanEndTimeOk returns a tuple with the ScanEndTime field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetScanEndTimeOk() (*string, bool) {
if o == nil || o.ScanEndTime == nil {
return nil, false
}
return o.ScanEndTime, true
}
// HasScanEndTime returns a boolean if a field has been set.
func (o *StatusMongoDb) HasScanEndTime() bool {
if o != nil && o.ScanEndTime != nil {
return true
}
return false
}
// SetScanEndTime gets a reference to the given string and assigns it to the ScanEndTime field.
func (o *StatusMongoDb) SetScanEndTime(v string) {
o.ScanEndTime = &v
}
// GetScanRecordsProcessed returns the ScanRecordsProcessed field value if set, zero value otherwise.
func (o *StatusMongoDb) GetScanRecordsProcessed() int64 {
if o == nil || o.ScanRecordsProcessed == nil {
var ret int64
return ret
}
return *o.ScanRecordsProcessed
}
// GetScanRecordsProcessedOk returns a tuple with the ScanRecordsProcessed field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetScanRecordsProcessedOk() (*int64, bool) {
if o == nil || o.ScanRecordsProcessed == nil {
return nil, false
}
return o.ScanRecordsProcessed, true
}
// HasScanRecordsProcessed returns a boolean if a field has been set.
func (o *StatusMongoDb) HasScanRecordsProcessed() bool {
if o != nil && o.ScanRecordsProcessed != nil {
return true
}
return false
}
// SetScanRecordsProcessed gets a reference to the given int64 and assigns it to the ScanRecordsProcessed field.
func (o *StatusMongoDb) SetScanRecordsProcessed(v int64) {
o.ScanRecordsProcessed = &v
}
// GetScanTotalRecords returns the ScanTotalRecords field value if set, zero value otherwise.
func (o *StatusMongoDb) GetScanTotalRecords() int64 {
if o == nil || o.ScanTotalRecords == nil {
var ret int64
return ret
}
return *o.ScanTotalRecords
}
// GetScanTotalRecordsOk returns a tuple with the ScanTotalRecords field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetScanTotalRecordsOk() (*int64, bool) {
if o == nil || o.ScanTotalRecords == nil {
return nil, false
}
return o.ScanTotalRecords, true
}
// HasScanTotalRecords returns a boolean if a field has been set.
func (o *StatusMongoDb) HasScanTotalRecords() bool {
if o != nil && o.ScanTotalRecords != nil {
return true
}
return false
}
// SetScanTotalRecords gets a reference to the given int64 and assigns it to the ScanTotalRecords field.
func (o *StatusMongoDb) SetScanTotalRecords(v int64) {
o.ScanTotalRecords = &v
}
// GetState returns the State field value if set, zero value otherwise.
func (o *StatusMongoDb) GetState() string {
if o == nil || o.State == nil {
var ret string
return ret
}
return *o.State
}
// GetStateOk returns a tuple with the State field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetStateOk() (*string, bool) {
if o == nil || o.State == nil {
return nil, false
}
return o.State, true
}
// HasState returns a boolean if a field has been set.
func (o *StatusMongoDb) HasState() bool {
if o != nil && o.State != nil {
return true
}
return false
}
// SetState gets a reference to the given string and assigns it to the State field.
func (o *StatusMongoDb) SetState(v string) {
o.State = &v
}
// GetStreamLastInsertProcessedAt returns the StreamLastInsertProcessedAt field value if set, zero value otherwise.
func (o *StatusMongoDb) GetStreamLastInsertProcessedAt() string {
if o == nil || o.StreamLastInsertProcessedAt == nil {
var ret string
return ret
}
return *o.StreamLastInsertProcessedAt
}
// GetStreamLastInsertProcessedAtOk returns a tuple with the StreamLastInsertProcessedAt field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetStreamLastInsertProcessedAtOk() (*string, bool) {
if o == nil || o.StreamLastInsertProcessedAt == nil {
return nil, false
}
return o.StreamLastInsertProcessedAt, true
}
// HasStreamLastInsertProcessedAt returns a boolean if a field has been set.
func (o *StatusMongoDb) HasStreamLastInsertProcessedAt() bool {
if o != nil && o.StreamLastInsertProcessedAt != nil {
return true
}
return false
}
// SetStreamLastInsertProcessedAt gets a reference to the given string and assigns it to the StreamLastInsertProcessedAt field.
func (o *StatusMongoDb) SetStreamLastInsertProcessedAt(v string) {
o.StreamLastInsertProcessedAt = &v
}
// GetStreamLastUpdateProcessedAt returns the StreamLastUpdateProcessedAt field value if set, zero value otherwise.
func (o *StatusMongoDb) GetStreamLastUpdateProcessedAt() string {
if o == nil || o.StreamLastUpdateProcessedAt == nil {
var ret string
return ret
}
return *o.StreamLastUpdateProcessedAt
}
// GetStreamLastUpdateProcessedAtOk returns a tuple with the StreamLastUpdateProcessedAt field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetStreamLastUpdateProcessedAtOk() (*string, bool) {
if o == nil || o.StreamLastUpdateProcessedAt == nil {
return nil, false
}
return o.StreamLastUpdateProcessedAt, true
}
// HasStreamLastUpdateProcessedAt returns a boolean if a field has been set.
func (o *StatusMongoDb) HasStreamLastUpdateProcessedAt() bool {
if o != nil && o.StreamLastUpdateProcessedAt != nil {
return true
}
return false
}
// SetStreamLastUpdateProcessedAt gets a reference to the given string and assigns it to the StreamLastUpdateProcessedAt field.
func (o *StatusMongoDb) SetStreamLastUpdateProcessedAt(v string) {
o.StreamLastUpdateProcessedAt = &v
}
// GetStreamLastDeleteProcessedAt returns the StreamLastDeleteProcessedAt field value if set, zero value otherwise.
func (o *StatusMongoDb) GetStreamLastDeleteProcessedAt() string {
if o == nil || o.StreamLastDeleteProcessedAt == nil {
var ret string
return ret
}
return *o.StreamLastDeleteProcessedAt
}
// GetStreamLastDeleteProcessedAtOk returns a tuple with the StreamLastDeleteProcessedAt field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetStreamLastDeleteProcessedAtOk() (*string, bool) {
if o == nil || o.StreamLastDeleteProcessedAt == nil {
return nil, false
}
return o.StreamLastDeleteProcessedAt, true
}
// HasStreamLastDeleteProcessedAt returns a boolean if a field has been set.
func (o *StatusMongoDb) HasStreamLastDeleteProcessedAt() bool {
if o != nil && o.StreamLastDeleteProcessedAt != nil {
return true
}
return false
}
// SetStreamLastDeleteProcessedAt gets a reference to the given string and assigns it to the StreamLastDeleteProcessedAt field.
func (o *StatusMongoDb) SetStreamLastDeleteProcessedAt(v string) {
o.StreamLastDeleteProcessedAt = &v
}
// GetStreamRecordsInserted returns the StreamRecordsInserted field value if set, zero value otherwise.
func (o *StatusMongoDb) GetStreamRecordsInserted() int64 {
if o == nil || o.StreamRecordsInserted == nil {
var ret int64
return ret
}
return *o.StreamRecordsInserted
}
// GetStreamRecordsInsertedOk returns a tuple with the StreamRecordsInserted field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetStreamRecordsInsertedOk() (*int64, bool) {
if o == nil || o.StreamRecordsInserted == nil {
return nil, false
}
return o.StreamRecordsInserted, true
}
// HasStreamRecordsInserted returns a boolean if a field has been set.
func (o *StatusMongoDb) HasStreamRecordsInserted() bool {
if o != nil && o.StreamRecordsInserted != nil {
return true
}
return false
}
// SetStreamRecordsInserted gets a reference to the given int64 and assigns it to the StreamRecordsInserted field.
func (o *StatusMongoDb) SetStreamRecordsInserted(v int64) {
o.StreamRecordsInserted = &v
}
// GetStreamRecordsUpdated returns the StreamRecordsUpdated field value if set, zero value otherwise.
func (o *StatusMongoDb) GetStreamRecordsUpdated() int64 {
if o == nil || o.StreamRecordsUpdated == nil {
var ret int64
return ret
}
return *o.StreamRecordsUpdated
}
// GetStreamRecordsUpdatedOk returns a tuple with the StreamRecordsUpdated field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetStreamRecordsUpdatedOk() (*int64, bool) {
if o == nil || o.StreamRecordsUpdated == nil {
return nil, false
}
return o.StreamRecordsUpdated, true
}
// HasStreamRecordsUpdated returns a boolean if a field has been set.
func (o *StatusMongoDb) HasStreamRecordsUpdated() bool {
if o != nil && o.StreamRecordsUpdated != nil {
return true
}
return false
}
// SetStreamRecordsUpdated gets a reference to the given int64 and assigns it to the StreamRecordsUpdated field.
func (o *StatusMongoDb) SetStreamRecordsUpdated(v int64) {
o.StreamRecordsUpdated = &v
}
// GetStreamRecordsDeleted returns the StreamRecordsDeleted field value if set, zero value otherwise.
func (o *StatusMongoDb) GetStreamRecordsDeleted() int64 {
if o == nil || o.StreamRecordsDeleted == nil {
var ret int64
return ret
}
return *o.StreamRecordsDeleted
}
// GetStreamRecordsDeletedOk returns a tuple with the StreamRecordsDeleted field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StatusMongoDb) GetStreamRecordsDeletedOk() (*int64, bool) {
if o == nil || o.StreamRecordsDeleted == nil {
return nil, false
}
return o.StreamRecordsDeleted, true
}
// HasStreamRecordsDeleted returns a boolean if a field has been set.
func (o *StatusMongoDb) HasStreamRecordsDeleted() bool {
if o != nil && o.StreamRecordsDeleted != nil {
return true
}
return false
}
// SetStreamRecordsDeleted gets a reference to the given int64 and assigns it to the StreamRecordsDeleted field.
func (o *StatusMongoDb) SetStreamRecordsDeleted(v int64) {
o.StreamRecordsDeleted = &v
}
func (o StatusMongoDb) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
if o.ScanStartTime != nil {
toSerialize["scan_start_time"] = o.ScanStartTime
}
if o.ScanEndTime != nil {
toSerialize["scan_end_time"] = o.ScanEndTime
}
if o.ScanRecordsProcessed != nil {
toSerialize["scan_records_processed"] = o.ScanRecordsProcessed
}
if o.ScanTotalRecords != nil {
toSerialize["scan_total_records"] = o.ScanTotalRecords
}
if o.State != nil {
toSerialize["state"] = o.State
}
if o.StreamLastInsertProcessedAt != nil {
toSerialize["stream_last_insert_processed_at"] = o.StreamLastInsertProcessedAt
}
if o.StreamLastUpdateProcessedAt != nil {
toSerialize["stream_last_update_processed_at"] = o.StreamLastUpdateProcessedAt
}
if o.StreamLastDeleteProcessedAt != nil {
toSerialize["stream_last_delete_processed_at"] = o.StreamLastDeleteProcessedAt
}
if o.StreamRecordsInserted != nil {
toSerialize["stream_records_inserted"] = o.StreamRecordsInserted
}
if o.StreamRecordsUpdated != nil {
toSerialize["stream_records_updated"] = o.StreamRecordsUpdated
}
if o.StreamRecordsDeleted != nil {
toSerialize["stream_records_deleted"] = o.StreamRecordsDeleted
}
return json.Marshal(toSerialize)
}
type NullableStatusMongoDb struct {
value *StatusMongoDb
isSet bool
}
func (v NullableStatusMongoDb) Get() *StatusMongoDb {
return v.value
}
func (v *NullableStatusMongoDb) Set(val *StatusMongoDb) {
v.value = val
v.isSet = true
}
func (v NullableStatusMongoDb) IsSet() bool {
return v.isSet
}
func (v *NullableStatusMongoDb) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableStatusMongoDb(val *StatusMongoDb) *NullableStatusMongoDb {
return &NullableStatusMongoDb{value: val, isSet: true}
}
func (v NullableStatusMongoDb) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableStatusMongoDb) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}