-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy pathmodel_instance.go
More file actions
982 lines (818 loc) · 42.1 KB
/
Copy pathmodel_instance.go
File metadata and controls
982 lines (818 loc) · 42.1 KB
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
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
/*
STACKIT MariaDB API
The STACKIT MariaDB API provides endpoints to list service offerings, manage service instances and service credentials within STACKIT portal projects.
API version: 2.0
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
package mariadb
import (
"encoding/json"
"fmt"
)
// checks if the Instance type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &Instance{}
/*
types and functions for cfGuid
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfGuidAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetCfGuidAttributeTypeOk(arg InstanceGetCfGuidAttributeType) (ret InstanceGetCfGuidRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetCfGuidAttributeType(arg *InstanceGetCfGuidAttributeType, val InstanceGetCfGuidRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfGuidArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfGuidRetType = string
/*
types and functions for cfOrganizationGuid
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfOrganizationGuidAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetCfOrganizationGuidAttributeTypeOk(arg InstanceGetCfOrganizationGuidAttributeType) (ret InstanceGetCfOrganizationGuidRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetCfOrganizationGuidAttributeType(arg *InstanceGetCfOrganizationGuidAttributeType, val InstanceGetCfOrganizationGuidRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfOrganizationGuidArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfOrganizationGuidRetType = string
/*
types and functions for cfSpaceGuid
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfSpaceGuidAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetCfSpaceGuidAttributeTypeOk(arg InstanceGetCfSpaceGuidAttributeType) (ret InstanceGetCfSpaceGuidRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetCfSpaceGuidAttributeType(arg *InstanceGetCfSpaceGuidAttributeType, val InstanceGetCfSpaceGuidRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfSpaceGuidArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetCfSpaceGuidRetType = string
/*
types and functions for dashboardUrl
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetDashboardUrlAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetDashboardUrlAttributeTypeOk(arg InstanceGetDashboardUrlAttributeType) (ret InstanceGetDashboardUrlRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetDashboardUrlAttributeType(arg *InstanceGetDashboardUrlAttributeType, val InstanceGetDashboardUrlRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetDashboardUrlArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetDashboardUrlRetType = string
/*
types and functions for imageUrl
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetImageUrlAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetImageUrlAttributeTypeOk(arg InstanceGetImageUrlAttributeType) (ret InstanceGetImageUrlRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetImageUrlAttributeType(arg *InstanceGetImageUrlAttributeType, val InstanceGetImageUrlRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetImageUrlArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetImageUrlRetType = string
/*
types and functions for instanceId
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetInstanceIdAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetInstanceIdAttributeTypeOk(arg InstanceGetInstanceIdAttributeType) (ret InstanceGetInstanceIdRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetInstanceIdAttributeType(arg *InstanceGetInstanceIdAttributeType, val InstanceGetInstanceIdRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetInstanceIdArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetInstanceIdRetType = string
/*
types and functions for lastOperation
*/
// isModel
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetLastOperationAttributeType = *InstanceLastOperation
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetLastOperationArgType = InstanceLastOperation
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetLastOperationRetType = InstanceLastOperation
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetLastOperationAttributeTypeOk(arg InstanceGetLastOperationAttributeType) (ret InstanceGetLastOperationRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetLastOperationAttributeType(arg *InstanceGetLastOperationAttributeType, val InstanceGetLastOperationRetType) {
*arg = &val
}
/*
types and functions for name
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetNameAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetNameAttributeTypeOk(arg InstanceGetNameAttributeType) (ret InstanceGetNameRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetNameAttributeType(arg *InstanceGetNameAttributeType, val InstanceGetNameRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetNameArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetNameRetType = string
/*
types and functions for offeringName
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetOfferingNameAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetOfferingNameAttributeTypeOk(arg InstanceGetOfferingNameAttributeType) (ret InstanceGetOfferingNameRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetOfferingNameAttributeType(arg *InstanceGetOfferingNameAttributeType, val InstanceGetOfferingNameRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetOfferingNameArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetOfferingNameRetType = string
/*
types and functions for offeringVersion
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetOfferingVersionAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetOfferingVersionAttributeTypeOk(arg InstanceGetOfferingVersionAttributeType) (ret InstanceGetOfferingVersionRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetOfferingVersionAttributeType(arg *InstanceGetOfferingVersionAttributeType, val InstanceGetOfferingVersionRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetOfferingVersionArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetOfferingVersionRetType = string
/*
types and functions for parameters
*/
// isFreeform
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetParametersAttributeType = *map[string]interface{}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetParametersArgType = map[string]interface{}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetParametersRetType = map[string]interface{}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetParametersAttributeTypeOk(arg InstanceGetParametersAttributeType) (ret InstanceGetParametersRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetParametersAttributeType(arg *InstanceGetParametersAttributeType, val InstanceGetParametersRetType) {
*arg = &val
}
/*
types and functions for planId
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetPlanIdAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetPlanIdAttributeTypeOk(arg InstanceGetPlanIdAttributeType) (ret InstanceGetPlanIdRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetPlanIdAttributeType(arg *InstanceGetPlanIdAttributeType, val InstanceGetPlanIdRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetPlanIdArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetPlanIdRetType = string
/*
types and functions for planName
*/
// isNotNullableString
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetPlanNameAttributeType = *string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetPlanNameAttributeTypeOk(arg InstanceGetPlanNameAttributeType) (ret InstanceGetPlanNameRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetPlanNameAttributeType(arg *InstanceGetPlanNameAttributeType, val InstanceGetPlanNameRetType) {
*arg = &val
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetPlanNameArgType = string
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetPlanNameRetType = string
/*
types and functions for status
*/
// isEnum
// InstanceStatus the model 'Instance'
// value type for enums
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceStatus string
// List of Status
const (
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
INSTANCESTATUS_ACTIVE InstanceStatus = "active"
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
INSTANCESTATUS_FAILED InstanceStatus = "failed"
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
INSTANCESTATUS_STOPPED InstanceStatus = "stopped"
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
INSTANCESTATUS_CREATING InstanceStatus = "creating"
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
INSTANCESTATUS_DELETING InstanceStatus = "deleting"
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
INSTANCESTATUS_UPDATING InstanceStatus = "updating"
)
// All allowed values of Instance enum
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
var AllowedInstanceStatusEnumValues = []InstanceStatus{
"active",
"failed",
"stopped",
"creating",
"deleting",
"updating",
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v *InstanceStatus) UnmarshalJSON(src []byte) error {
// use a type alias to prevent infinite recursion during unmarshal,
// see https://biscuit.ninja/posts/go-avoid-an-infitine-loop-with-custom-json-unmarshallers
type TmpJson InstanceStatus
var value TmpJson
err := json.Unmarshal(src, &value)
if err != nil {
return err
}
// Allow unmarshalling zero value for testing purposes
var zeroValue TmpJson
if value == zeroValue {
return nil
}
enumTypeValue := InstanceStatus(value)
for _, existing := range AllowedInstanceStatusEnumValues {
if existing == enumTypeValue {
*v = enumTypeValue
return nil
}
}
return fmt.Errorf("%+v is not a valid Instance", value)
}
// NewInstanceStatusFromValue returns a pointer to a valid InstanceStatus
// for the value passed as argument, or an error if the value passed is not allowed by the enum
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func NewInstanceStatusFromValue(v InstanceStatus) (*InstanceStatus, error) {
ev := InstanceStatus(v)
if ev.IsValid() {
return &ev, nil
} else {
return nil, fmt.Errorf("invalid value '%v' for InstanceStatus: valid values are %v", v, AllowedInstanceStatusEnumValues)
}
}
// IsValid return true if the value is valid for the enum, false otherwise
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v InstanceStatus) IsValid() bool {
for _, existing := range AllowedInstanceStatusEnumValues {
if existing == v {
return true
}
}
return false
}
// Ptr returns reference to StatusStatus value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v InstanceStatus) Ptr() *InstanceStatus {
return &v
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type NullableInstanceStatus struct {
value *InstanceStatus
isSet bool
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v NullableInstanceStatus) Get() *InstanceStatus {
return v.value
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v *NullableInstanceStatus) Set(val *InstanceStatus) {
v.value = val
v.isSet = true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v NullableInstanceStatus) IsSet() bool {
return v.isSet
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v *NullableInstanceStatus) Unset() {
v.value = nil
v.isSet = false
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func NewNullableInstanceStatus(val *InstanceStatus) *NullableInstanceStatus {
return &NullableInstanceStatus{value: val, isSet: true}
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v NullableInstanceStatus) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v *NullableInstanceStatus) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetStatusAttributeType = *InstanceStatus
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetStatusArgType = InstanceStatus
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type InstanceGetStatusRetType = InstanceStatus
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func getInstanceGetStatusAttributeTypeOk(arg InstanceGetStatusAttributeType) (ret InstanceGetStatusRetType, ok bool) {
if arg == nil {
return ret, false
}
return *arg, true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func setInstanceGetStatusAttributeType(arg *InstanceGetStatusAttributeType, val InstanceGetStatusRetType) {
*arg = &val
}
// Instance struct for Instance
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type Instance struct {
// REQUIRED
CfGuid InstanceGetCfGuidAttributeType `json:"cfGuid" required:"true"`
// REQUIRED
CfOrganizationGuid InstanceGetCfOrganizationGuidAttributeType `json:"cfOrganizationGuid" required:"true"`
// REQUIRED
CfSpaceGuid InstanceGetCfSpaceGuidAttributeType `json:"cfSpaceGuid" required:"true"`
// REQUIRED
DashboardUrl InstanceGetDashboardUrlAttributeType `json:"dashboardUrl" required:"true"`
// REQUIRED
ImageUrl InstanceGetImageUrlAttributeType `json:"imageUrl" required:"true"`
InstanceId InstanceGetInstanceIdAttributeType `json:"instanceId,omitempty"`
// REQUIRED
LastOperation InstanceGetLastOperationAttributeType `json:"lastOperation" required:"true"`
// REQUIRED
Name InstanceGetNameAttributeType `json:"name" required:"true"`
// Deprecated: Check the GitHub changelog for alternatives
// REQUIRED
OfferingName InstanceGetOfferingNameAttributeType `json:"offeringName" required:"true"`
// REQUIRED
OfferingVersion InstanceGetOfferingVersionAttributeType `json:"offeringVersion" required:"true"`
// REQUIRED
Parameters InstanceGetParametersAttributeType `json:"parameters" required:"true"`
// REQUIRED
PlanId InstanceGetPlanIdAttributeType `json:"planId" required:"true"`
// REQUIRED
PlanName InstanceGetPlanNameAttributeType `json:"planName" required:"true"`
Status InstanceGetStatusAttributeType `json:"status,omitempty"`
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type _Instance Instance
// NewInstance instantiates a new Instance 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
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func NewInstance(cfGuid InstanceGetCfGuidArgType, cfOrganizationGuid InstanceGetCfOrganizationGuidArgType, cfSpaceGuid InstanceGetCfSpaceGuidArgType, dashboardUrl InstanceGetDashboardUrlArgType, imageUrl InstanceGetImageUrlArgType, lastOperation InstanceGetLastOperationArgType, name InstanceGetNameArgType, offeringName InstanceGetOfferingNameArgType, offeringVersion InstanceGetOfferingVersionArgType, parameters InstanceGetParametersArgType, planId InstanceGetPlanIdArgType, planName InstanceGetPlanNameArgType) *Instance {
this := Instance{}
setInstanceGetCfGuidAttributeType(&this.CfGuid, cfGuid)
setInstanceGetCfOrganizationGuidAttributeType(&this.CfOrganizationGuid, cfOrganizationGuid)
setInstanceGetCfSpaceGuidAttributeType(&this.CfSpaceGuid, cfSpaceGuid)
setInstanceGetDashboardUrlAttributeType(&this.DashboardUrl, dashboardUrl)
setInstanceGetImageUrlAttributeType(&this.ImageUrl, imageUrl)
setInstanceGetLastOperationAttributeType(&this.LastOperation, lastOperation)
setInstanceGetNameAttributeType(&this.Name, name)
setInstanceGetOfferingNameAttributeType(&this.OfferingName, offeringName)
setInstanceGetOfferingVersionAttributeType(&this.OfferingVersion, offeringVersion)
setInstanceGetParametersAttributeType(&this.Parameters, parameters)
setInstanceGetPlanIdAttributeType(&this.PlanId, planId)
setInstanceGetPlanNameAttributeType(&this.PlanName, planName)
return &this
}
// NewInstanceWithDefaults instantiates a new Instance 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
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func NewInstanceWithDefaults() *Instance {
this := Instance{}
return &this
}
// GetCfGuid returns the CfGuid field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetCfGuid() (ret InstanceGetCfGuidRetType) {
ret, _ = o.GetCfGuidOk()
return ret
}
// GetCfGuidOk returns a tuple with the CfGuid field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetCfGuidOk() (ret InstanceGetCfGuidRetType, ok bool) {
return getInstanceGetCfGuidAttributeTypeOk(o.CfGuid)
}
// SetCfGuid sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetCfGuid(v InstanceGetCfGuidRetType) {
setInstanceGetCfGuidAttributeType(&o.CfGuid, v)
}
// GetCfOrganizationGuid returns the CfOrganizationGuid field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetCfOrganizationGuid() (ret InstanceGetCfOrganizationGuidRetType) {
ret, _ = o.GetCfOrganizationGuidOk()
return ret
}
// GetCfOrganizationGuidOk returns a tuple with the CfOrganizationGuid field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetCfOrganizationGuidOk() (ret InstanceGetCfOrganizationGuidRetType, ok bool) {
return getInstanceGetCfOrganizationGuidAttributeTypeOk(o.CfOrganizationGuid)
}
// SetCfOrganizationGuid sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetCfOrganizationGuid(v InstanceGetCfOrganizationGuidRetType) {
setInstanceGetCfOrganizationGuidAttributeType(&o.CfOrganizationGuid, v)
}
// GetCfSpaceGuid returns the CfSpaceGuid field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetCfSpaceGuid() (ret InstanceGetCfSpaceGuidRetType) {
ret, _ = o.GetCfSpaceGuidOk()
return ret
}
// GetCfSpaceGuidOk returns a tuple with the CfSpaceGuid field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetCfSpaceGuidOk() (ret InstanceGetCfSpaceGuidRetType, ok bool) {
return getInstanceGetCfSpaceGuidAttributeTypeOk(o.CfSpaceGuid)
}
// SetCfSpaceGuid sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetCfSpaceGuid(v InstanceGetCfSpaceGuidRetType) {
setInstanceGetCfSpaceGuidAttributeType(&o.CfSpaceGuid, v)
}
// GetDashboardUrl returns the DashboardUrl field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetDashboardUrl() (ret InstanceGetDashboardUrlRetType) {
ret, _ = o.GetDashboardUrlOk()
return ret
}
// GetDashboardUrlOk returns a tuple with the DashboardUrl field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetDashboardUrlOk() (ret InstanceGetDashboardUrlRetType, ok bool) {
return getInstanceGetDashboardUrlAttributeTypeOk(o.DashboardUrl)
}
// SetDashboardUrl sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetDashboardUrl(v InstanceGetDashboardUrlRetType) {
setInstanceGetDashboardUrlAttributeType(&o.DashboardUrl, v)
}
// GetImageUrl returns the ImageUrl field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetImageUrl() (ret InstanceGetImageUrlRetType) {
ret, _ = o.GetImageUrlOk()
return ret
}
// GetImageUrlOk returns a tuple with the ImageUrl field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetImageUrlOk() (ret InstanceGetImageUrlRetType, ok bool) {
return getInstanceGetImageUrlAttributeTypeOk(o.ImageUrl)
}
// SetImageUrl sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetImageUrl(v InstanceGetImageUrlRetType) {
setInstanceGetImageUrlAttributeType(&o.ImageUrl, v)
}
// GetInstanceId returns the InstanceId field value if set, zero value otherwise.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetInstanceId() (res InstanceGetInstanceIdRetType) {
res, _ = o.GetInstanceIdOk()
return
}
// GetInstanceIdOk returns a tuple with the InstanceId field value if set, nil otherwise
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetInstanceIdOk() (ret InstanceGetInstanceIdRetType, ok bool) {
return getInstanceGetInstanceIdAttributeTypeOk(o.InstanceId)
}
// HasInstanceId returns a boolean if a field has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) HasInstanceId() bool {
_, ok := o.GetInstanceIdOk()
return ok
}
// SetInstanceId gets a reference to the given string and assigns it to the InstanceId field.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetInstanceId(v InstanceGetInstanceIdRetType) {
setInstanceGetInstanceIdAttributeType(&o.InstanceId, v)
}
// GetLastOperation returns the LastOperation field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetLastOperation() (ret InstanceGetLastOperationRetType) {
ret, _ = o.GetLastOperationOk()
return ret
}
// GetLastOperationOk returns a tuple with the LastOperation field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetLastOperationOk() (ret InstanceGetLastOperationRetType, ok bool) {
return getInstanceGetLastOperationAttributeTypeOk(o.LastOperation)
}
// SetLastOperation sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetLastOperation(v InstanceGetLastOperationRetType) {
setInstanceGetLastOperationAttributeType(&o.LastOperation, v)
}
// GetName returns the Name field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetName() (ret InstanceGetNameRetType) {
ret, _ = o.GetNameOk()
return ret
}
// GetNameOk returns a tuple with the Name field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetNameOk() (ret InstanceGetNameRetType, ok bool) {
return getInstanceGetNameAttributeTypeOk(o.Name)
}
// SetName sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetName(v InstanceGetNameRetType) {
setInstanceGetNameAttributeType(&o.Name, v)
}
// GetOfferingName returns the OfferingName field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetOfferingName() (ret InstanceGetOfferingNameRetType) {
ret, _ = o.GetOfferingNameOk()
return ret
}
// GetOfferingNameOk returns a tuple with the OfferingName field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetOfferingNameOk() (ret InstanceGetOfferingNameRetType, ok bool) {
return getInstanceGetOfferingNameAttributeTypeOk(o.OfferingName)
}
// SetOfferingName sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetOfferingName(v InstanceGetOfferingNameRetType) {
setInstanceGetOfferingNameAttributeType(&o.OfferingName, v)
}
// GetOfferingVersion returns the OfferingVersion field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetOfferingVersion() (ret InstanceGetOfferingVersionRetType) {
ret, _ = o.GetOfferingVersionOk()
return ret
}
// GetOfferingVersionOk returns a tuple with the OfferingVersion field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetOfferingVersionOk() (ret InstanceGetOfferingVersionRetType, ok bool) {
return getInstanceGetOfferingVersionAttributeTypeOk(o.OfferingVersion)
}
// SetOfferingVersion sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetOfferingVersion(v InstanceGetOfferingVersionRetType) {
setInstanceGetOfferingVersionAttributeType(&o.OfferingVersion, v)
}
// GetParameters returns the Parameters field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetParameters() (ret InstanceGetParametersRetType) {
ret, _ = o.GetParametersOk()
return ret
}
// GetParametersOk returns a tuple with the Parameters field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetParametersOk() (ret InstanceGetParametersRetType, ok bool) {
return getInstanceGetParametersAttributeTypeOk(o.Parameters)
}
// SetParameters sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetParameters(v InstanceGetParametersRetType) {
setInstanceGetParametersAttributeType(&o.Parameters, v)
}
// GetPlanId returns the PlanId field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetPlanId() (ret InstanceGetPlanIdRetType) {
ret, _ = o.GetPlanIdOk()
return ret
}
// GetPlanIdOk returns a tuple with the PlanId field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetPlanIdOk() (ret InstanceGetPlanIdRetType, ok bool) {
return getInstanceGetPlanIdAttributeTypeOk(o.PlanId)
}
// SetPlanId sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetPlanId(v InstanceGetPlanIdRetType) {
setInstanceGetPlanIdAttributeType(&o.PlanId, v)
}
// GetPlanName returns the PlanName field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetPlanName() (ret InstanceGetPlanNameRetType) {
ret, _ = o.GetPlanNameOk()
return ret
}
// GetPlanNameOk returns a tuple with the PlanName field value
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetPlanNameOk() (ret InstanceGetPlanNameRetType, ok bool) {
return getInstanceGetPlanNameAttributeTypeOk(o.PlanName)
}
// SetPlanName sets field value
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetPlanName(v InstanceGetPlanNameRetType) {
setInstanceGetPlanNameAttributeType(&o.PlanName, v)
}
// GetStatus returns the Status field value if set, zero value otherwise.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetStatus() (res InstanceGetStatusRetType) {
res, _ = o.GetStatusOk()
return
}
// GetStatusOk returns a tuple with the Status field value if set, nil otherwise
// and a boolean to check if the value has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) GetStatusOk() (ret InstanceGetStatusRetType, ok bool) {
return getInstanceGetStatusAttributeTypeOk(o.Status)
}
// HasStatus returns a boolean if a field has been set.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) HasStatus() bool {
_, ok := o.GetStatusOk()
return ok
}
// SetStatus gets a reference to the given string and assigns it to the Status field.
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o *Instance) SetStatus(v InstanceGetStatusRetType) {
setInstanceGetStatusAttributeType(&o.Status, v)
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (o Instance) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if val, ok := getInstanceGetCfGuidAttributeTypeOk(o.CfGuid); ok {
toSerialize["CfGuid"] = val
}
if val, ok := getInstanceGetCfOrganizationGuidAttributeTypeOk(o.CfOrganizationGuid); ok {
toSerialize["CfOrganizationGuid"] = val
}
if val, ok := getInstanceGetCfSpaceGuidAttributeTypeOk(o.CfSpaceGuid); ok {
toSerialize["CfSpaceGuid"] = val
}
if val, ok := getInstanceGetDashboardUrlAttributeTypeOk(o.DashboardUrl); ok {
toSerialize["DashboardUrl"] = val
}
if val, ok := getInstanceGetImageUrlAttributeTypeOk(o.ImageUrl); ok {
toSerialize["ImageUrl"] = val
}
if val, ok := getInstanceGetInstanceIdAttributeTypeOk(o.InstanceId); ok {
toSerialize["InstanceId"] = val
}
if val, ok := getInstanceGetLastOperationAttributeTypeOk(o.LastOperation); ok {
toSerialize["LastOperation"] = val
}
if val, ok := getInstanceGetNameAttributeTypeOk(o.Name); ok {
toSerialize["Name"] = val
}
if val, ok := getInstanceGetOfferingNameAttributeTypeOk(o.OfferingName); ok {
toSerialize["OfferingName"] = val
}
if val, ok := getInstanceGetOfferingVersionAttributeTypeOk(o.OfferingVersion); ok {
toSerialize["OfferingVersion"] = val
}
if val, ok := getInstanceGetParametersAttributeTypeOk(o.Parameters); ok {
toSerialize["Parameters"] = val
}
if val, ok := getInstanceGetPlanIdAttributeTypeOk(o.PlanId); ok {
toSerialize["PlanId"] = val
}
if val, ok := getInstanceGetPlanNameAttributeTypeOk(o.PlanName); ok {
toSerialize["PlanName"] = val
}
if val, ok := getInstanceGetStatusAttributeTypeOk(o.Status); ok {
toSerialize["Status"] = val
}
return toSerialize, nil
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
type NullableInstance struct {
value *Instance
isSet bool
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v NullableInstance) Get() *Instance {
return v.value
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v *NullableInstance) Set(val *Instance) {
v.value = val
v.isSet = true
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v NullableInstance) IsSet() bool {
return v.isSet
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v *NullableInstance) Unset() {
v.value = nil
v.isSet = false
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func NewNullableInstance(val *Instance) *NullableInstance {
return &NullableInstance{value: val, isSet: true}
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v NullableInstance) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead
func (v *NullableInstance) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}