-
Notifications
You must be signed in to change notification settings - Fork 0
/
model_execution_step_status.go
425 lines (360 loc) · 12.4 KB
/
model_execution_step_status.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
/*
Flowpipe
Flowpipe is workflow and pipelines for DevSecOps.
API version: 0.1.0
Contact: info@flowpipe.io
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package flowpipeapi
import (
"encoding/json"
)
// checks if the ExecutionStepStatus type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &ExecutionStepStatus{}
// ExecutionStepStatus struct for ExecutionStepStatus
type ExecutionStepStatus struct {
// Indicates that a step is in retry loop so we don't mark it as failed
ErrorHold *bool `json:"error_hold,omitempty"`
// Step executions that are failed.
Failed *map[string]bool `json:"failed,omitempty"`
// Step executions that are finished.
Finished *map[string]bool `json:"finished,omitempty"`
// When the step is initializing it doesn't yet have any executions. We track it as initializing until the first execution is queued.
Initializing *bool `json:"initializing,omitempty"`
// Both LoopHold and ErrorHold must be resolved **before** the \"finish\" event is called, i.e. it needs to be calculated at the end of \"step start command\" and \"step pipeline finish\" command. It can't be calculated at the \"finish\" event because it's already too late. If the planner see that it has an finish event without either a LoopHold or ErrorHold, it will mark the step as completed or failed Indicates that step is in a loop so we don't mark it as finished
LoopHold *bool `json:"loop_hold,omitempty"`
OverralState *string `json:"overral_state,omitempty"`
// Step executions that are queued.
Queued *map[string]bool `json:"queued,omitempty"`
// Step executions that are started.
Started *map[string]bool `json:"started,omitempty"`
// There's the step execution in execution, this is the same but in a list for a given step status The element in this slice should point to the same element in the StepExecutions map (in PipelineExecution)
StepExecutions []ExecutionStepExecution `json:"step_executions,omitempty"`
}
func (o ExecutionStepStatus) GetResourceType() string {
return "ExecutionStepStatus"
}
// NewExecutionStepStatus instantiates a new ExecutionStepStatus 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 NewExecutionStepStatus() *ExecutionStepStatus {
this := ExecutionStepStatus{}
return &this
}
// NewExecutionStepStatusWithDefaults instantiates a new ExecutionStepStatus 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 NewExecutionStepStatusWithDefaults() *ExecutionStepStatus {
this := ExecutionStepStatus{}
return &this
}
// GetErrorHold returns the ErrorHold field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetErrorHold() bool {
if o == nil || IsNil(o.ErrorHold) {
var ret bool
return ret
}
return *o.ErrorHold
}
// GetErrorHoldOk returns a tuple with the ErrorHold field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetErrorHoldOk() (*bool, bool) {
if o == nil || IsNil(o.ErrorHold) {
return nil, false
}
return o.ErrorHold, true
}
// HasErrorHold returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasErrorHold() bool {
if o != nil && !IsNil(o.ErrorHold) {
return true
}
return false
}
// SetErrorHold gets a reference to the given bool and assigns it to the ErrorHold field.
func (o *ExecutionStepStatus) SetErrorHold(v bool) {
o.ErrorHold = &v
}
// GetFailed returns the Failed field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetFailed() map[string]bool {
if o == nil || IsNil(o.Failed) {
var ret map[string]bool
return ret
}
return *o.Failed
}
// GetFailedOk returns a tuple with the Failed field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetFailedOk() (*map[string]bool, bool) {
if o == nil || IsNil(o.Failed) {
return nil, false
}
return o.Failed, true
}
// HasFailed returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasFailed() bool {
if o != nil && !IsNil(o.Failed) {
return true
}
return false
}
// SetFailed gets a reference to the given map[string]bool and assigns it to the Failed field.
func (o *ExecutionStepStatus) SetFailed(v map[string]bool) {
o.Failed = &v
}
// GetFinished returns the Finished field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetFinished() map[string]bool {
if o == nil || IsNil(o.Finished) {
var ret map[string]bool
return ret
}
return *o.Finished
}
// GetFinishedOk returns a tuple with the Finished field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetFinishedOk() (*map[string]bool, bool) {
if o == nil || IsNil(o.Finished) {
return nil, false
}
return o.Finished, true
}
// HasFinished returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasFinished() bool {
if o != nil && !IsNil(o.Finished) {
return true
}
return false
}
// SetFinished gets a reference to the given map[string]bool and assigns it to the Finished field.
func (o *ExecutionStepStatus) SetFinished(v map[string]bool) {
o.Finished = &v
}
// GetInitializing returns the Initializing field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetInitializing() bool {
if o == nil || IsNil(o.Initializing) {
var ret bool
return ret
}
return *o.Initializing
}
// GetInitializingOk returns a tuple with the Initializing field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetInitializingOk() (*bool, bool) {
if o == nil || IsNil(o.Initializing) {
return nil, false
}
return o.Initializing, true
}
// HasInitializing returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasInitializing() bool {
if o != nil && !IsNil(o.Initializing) {
return true
}
return false
}
// SetInitializing gets a reference to the given bool and assigns it to the Initializing field.
func (o *ExecutionStepStatus) SetInitializing(v bool) {
o.Initializing = &v
}
// GetLoopHold returns the LoopHold field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetLoopHold() bool {
if o == nil || IsNil(o.LoopHold) {
var ret bool
return ret
}
return *o.LoopHold
}
// GetLoopHoldOk returns a tuple with the LoopHold field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetLoopHoldOk() (*bool, bool) {
if o == nil || IsNil(o.LoopHold) {
return nil, false
}
return o.LoopHold, true
}
// HasLoopHold returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasLoopHold() bool {
if o != nil && !IsNil(o.LoopHold) {
return true
}
return false
}
// SetLoopHold gets a reference to the given bool and assigns it to the LoopHold field.
func (o *ExecutionStepStatus) SetLoopHold(v bool) {
o.LoopHold = &v
}
// GetOverralState returns the OverralState field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetOverralState() string {
if o == nil || IsNil(o.OverralState) {
var ret string
return ret
}
return *o.OverralState
}
// GetOverralStateOk returns a tuple with the OverralState field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetOverralStateOk() (*string, bool) {
if o == nil || IsNil(o.OverralState) {
return nil, false
}
return o.OverralState, true
}
// HasOverralState returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasOverralState() bool {
if o != nil && !IsNil(o.OverralState) {
return true
}
return false
}
// SetOverralState gets a reference to the given string and assigns it to the OverralState field.
func (o *ExecutionStepStatus) SetOverralState(v string) {
o.OverralState = &v
}
// GetQueued returns the Queued field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetQueued() map[string]bool {
if o == nil || IsNil(o.Queued) {
var ret map[string]bool
return ret
}
return *o.Queued
}
// GetQueuedOk returns a tuple with the Queued field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetQueuedOk() (*map[string]bool, bool) {
if o == nil || IsNil(o.Queued) {
return nil, false
}
return o.Queued, true
}
// HasQueued returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasQueued() bool {
if o != nil && !IsNil(o.Queued) {
return true
}
return false
}
// SetQueued gets a reference to the given map[string]bool and assigns it to the Queued field.
func (o *ExecutionStepStatus) SetQueued(v map[string]bool) {
o.Queued = &v
}
// GetStarted returns the Started field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetStarted() map[string]bool {
if o == nil || IsNil(o.Started) {
var ret map[string]bool
return ret
}
return *o.Started
}
// GetStartedOk returns a tuple with the Started field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetStartedOk() (*map[string]bool, bool) {
if o == nil || IsNil(o.Started) {
return nil, false
}
return o.Started, true
}
// HasStarted returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasStarted() bool {
if o != nil && !IsNil(o.Started) {
return true
}
return false
}
// SetStarted gets a reference to the given map[string]bool and assigns it to the Started field.
func (o *ExecutionStepStatus) SetStarted(v map[string]bool) {
o.Started = &v
}
// GetStepExecutions returns the StepExecutions field value if set, zero value otherwise.
func (o *ExecutionStepStatus) GetStepExecutions() []ExecutionStepExecution {
if o == nil || IsNil(o.StepExecutions) {
var ret []ExecutionStepExecution
return ret
}
return o.StepExecutions
}
// GetStepExecutionsOk returns a tuple with the StepExecutions field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *ExecutionStepStatus) GetStepExecutionsOk() ([]ExecutionStepExecution, bool) {
if o == nil || IsNil(o.StepExecutions) {
return nil, false
}
return o.StepExecutions, true
}
// HasStepExecutions returns a boolean if a field has been set.
func (o *ExecutionStepStatus) HasStepExecutions() bool {
if o != nil && !IsNil(o.StepExecutions) {
return true
}
return false
}
// SetStepExecutions gets a reference to the given []ExecutionStepExecution and assigns it to the StepExecutions field.
func (o *ExecutionStepStatus) SetStepExecutions(v []ExecutionStepExecution) {
o.StepExecutions = v
}
func (o ExecutionStepStatus) MarshalJSON() ([]byte, error) {
toSerialize,err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o ExecutionStepStatus) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.ErrorHold) {
toSerialize["error_hold"] = o.ErrorHold
}
if !IsNil(o.Failed) {
toSerialize["failed"] = o.Failed
}
if !IsNil(o.Finished) {
toSerialize["finished"] = o.Finished
}
if !IsNil(o.Initializing) {
toSerialize["initializing"] = o.Initializing
}
if !IsNil(o.LoopHold) {
toSerialize["loop_hold"] = o.LoopHold
}
if !IsNil(o.OverralState) {
toSerialize["overral_state"] = o.OverralState
}
if !IsNil(o.Queued) {
toSerialize["queued"] = o.Queued
}
if !IsNil(o.Started) {
toSerialize["started"] = o.Started
}
if !IsNil(o.StepExecutions) {
toSerialize["step_executions"] = o.StepExecutions
}
return toSerialize, nil
}
type NullableExecutionStepStatus struct {
value *ExecutionStepStatus
isSet bool
}
func (v NullableExecutionStepStatus) Get() *ExecutionStepStatus {
return v.value
}
func (v *NullableExecutionStepStatus) Set(val *ExecutionStepStatus) {
v.value = val
v.isSet = true
}
func (v NullableExecutionStepStatus) IsSet() bool {
return v.isSet
}
func (v *NullableExecutionStepStatus) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableExecutionStepStatus(val *ExecutionStepStatus) *NullableExecutionStepStatus {
return &NullableExecutionStepStatus{value: val, isSet: true}
}
func (v NullableExecutionStepStatus) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableExecutionStepStatus) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}