From 557bf7a682a8eb27ab49046e404a31548ca48a4e Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Tue, 14 Apr 2026 08:03:06 +0000 Subject: [PATCH] Generate ske --- services/ske/go.mod | 2 +- services/ske/go.sum | 4 +- services/ske/model_cluster_status.go | 58 +++ services/ske/model_expiration_status.go | 209 +++++++++ .../ske/model_expiration_status_kubernetes.go | 210 +++++++++ ...model_expiration_status_kubernetes_test.go | 11 + .../ske/model_expiration_status_nodepool.go | 442 ++++++++++++++++++ .../model_expiration_status_nodepool_test.go | 11 + services/ske/model_expiration_status_test.go | 11 + services/ske/oas_commit | 2 +- services/ske/v2api/model_cluster_status.go | 47 +- services/ske/v2api/model_expiration_status.go | 190 ++++++++ .../model_expiration_status_kubernetes.go | 191 ++++++++ .../v2api/model_expiration_status_nodepool.go | 339 ++++++++++++++ 14 files changed, 1718 insertions(+), 9 deletions(-) create mode 100644 services/ske/model_expiration_status.go create mode 100644 services/ske/model_expiration_status_kubernetes.go create mode 100644 services/ske/model_expiration_status_kubernetes_test.go create mode 100644 services/ske/model_expiration_status_nodepool.go create mode 100644 services/ske/model_expiration_status_nodepool_test.go create mode 100644 services/ske/model_expiration_status_test.go create mode 100644 services/ske/v2api/model_expiration_status.go create mode 100644 services/ske/v2api/model_expiration_status_kubernetes.go create mode 100644 services/ske/v2api/model_expiration_status_nodepool.go diff --git a/services/ske/go.mod b/services/ske/go.mod index bcf26de48..5a941a530 100644 --- a/services/ske/go.mod +++ b/services/ske/go.mod @@ -4,7 +4,7 @@ go 1.25 require ( github.com/google/go-cmp v0.7.0 - github.com/stackitcloud/stackit-sdk-go/core v0.24.1 + github.com/stackitcloud/stackit-sdk-go/core v0.25.0 ) require ( diff --git a/services/ske/go.sum b/services/ske/go.sum index 516c6a66d..f66cfd445 100644 --- a/services/ske/go.sum +++ b/services/ske/go.sum @@ -4,5 +4,5 @@ github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/stackitcloud/stackit-sdk-go/core v0.24.1 h1:IrG0XBlJivUpXC4Y6TE+6FeSxNPs1JQXsero0ivwh0o= -github.com/stackitcloud/stackit-sdk-go/core v0.24.1/go.mod h1:osMglDby4csGZ5sIfhNyYq1bS1TxIdPY88+skE/kkmI= +github.com/stackitcloud/stackit-sdk-go/core v0.25.0 h1:ra3VEk684MNoq741g+xbZrKjZzhyztq5liUAwwew4DY= +github.com/stackitcloud/stackit-sdk-go/core v0.25.0/go.mod h1:WU1hhxnjXw2EV7CYa1nlEvNpMiRY6CvmIOaHuL3pOaA= diff --git a/services/ske/model_cluster_status.go b/services/ske/model_cluster_status.go index 136dbecec..d70ddf989 100644 --- a/services/ske/model_cluster_status.go +++ b/services/ske/model_cluster_status.go @@ -181,6 +181,33 @@ func setClusterStatusGetErrorsAttributeType(arg *ClusterStatusGetErrorsAttribute *arg = &val } +/* + types and functions for expiration +*/ + +// isModel +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetExpirationAttributeType = *ExpirationStatus + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetExpirationArgType = ExpirationStatus + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ClusterStatusGetExpirationRetType = ExpirationStatus + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getClusterStatusGetExpirationAttributeTypeOk(arg ClusterStatusGetExpirationAttributeType) (ret ClusterStatusGetExpirationRetType, 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 setClusterStatusGetExpirationAttributeType(arg *ClusterStatusGetExpirationAttributeType, val ClusterStatusGetExpirationRetType) { + *arg = &val +} + /* types and functions for hibernated */ @@ -273,6 +300,7 @@ type ClusterStatus struct { EgressAddressRanges ClusterStatusGetEgressAddressRangesAttributeType `json:"egressAddressRanges,omitempty"` Error ClusterStatusGetErrorAttributeType `json:"error,omitempty"` Errors ClusterStatusGetErrorsAttributeType `json:"errors,omitempty"` + Expiration ClusterStatusGetExpirationAttributeType `json:"expiration,omitempty"` Hibernated ClusterStatusgetHibernatedAttributeType `json:"hibernated,omitempty"` Identity ClusterStatusGetIdentityAttributeType `json:"identity,omitempty"` // The network ranges (in CIDR notation) used by pods of the cluster. @@ -460,6 +488,33 @@ func (o *ClusterStatus) SetErrors(v ClusterStatusGetErrorsRetType) { setClusterStatusGetErrorsAttributeType(&o.Errors, v) } +// GetExpiration returns the Expiration 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 *ClusterStatus) GetExpiration() (res ClusterStatusGetExpirationRetType) { + res, _ = o.GetExpirationOk() + return +} + +// GetExpirationOk returns a tuple with the Expiration 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 *ClusterStatus) GetExpirationOk() (ret ClusterStatusGetExpirationRetType, ok bool) { + return getClusterStatusGetExpirationAttributeTypeOk(o.Expiration) +} + +// HasExpiration 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 *ClusterStatus) HasExpiration() bool { + _, ok := o.GetExpirationOk() + return ok +} + +// SetExpiration gets a reference to the given ExpirationStatus and assigns it to the Expiration field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ClusterStatus) SetExpiration(v ClusterStatusGetExpirationRetType) { + setClusterStatusGetExpirationAttributeType(&o.Expiration, v) +} + // GetHibernated returns the Hibernated 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 *ClusterStatus) GetHibernated() (res ClusterStatusgetHibernatedRetType) { @@ -562,6 +617,9 @@ func (o ClusterStatus) ToMap() (map[string]interface{}, error) { if val, ok := getClusterStatusGetErrorsAttributeTypeOk(o.Errors); ok { toSerialize["Errors"] = val } + if val, ok := getClusterStatusGetExpirationAttributeTypeOk(o.Expiration); ok { + toSerialize["Expiration"] = val + } if val, ok := getClusterStatusgetHibernatedAttributeTypeOk(o.Hibernated); ok { toSerialize["Hibernated"] = val } diff --git a/services/ske/model_expiration_status.go b/services/ske/model_expiration_status.go new file mode 100644 index 000000000..692f51bf4 --- /dev/null +++ b/services/ske/model_expiration_status.go @@ -0,0 +1,209 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +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 ske + +import ( + "encoding/json" +) + +// checks if the ExpirationStatus type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ExpirationStatus{} + +/* + types and functions for kubernetes +*/ + +// isModel +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusGetKubernetesAttributeType = *ExpirationStatusKubernetes + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusGetKubernetesArgType = ExpirationStatusKubernetes + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusGetKubernetesRetType = ExpirationStatusKubernetes + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusGetKubernetesAttributeTypeOk(arg ExpirationStatusGetKubernetesAttributeType) (ret ExpirationStatusGetKubernetesRetType, 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 setExpirationStatusGetKubernetesAttributeType(arg *ExpirationStatusGetKubernetesAttributeType, val ExpirationStatusGetKubernetesRetType) { + *arg = &val +} + +/* + types and functions for nodepools +*/ + +// isArray +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusGetNodepoolsAttributeType = *[]ExpirationStatusNodepool + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusGetNodepoolsArgType = []ExpirationStatusNodepool + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusGetNodepoolsRetType = []ExpirationStatusNodepool + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusGetNodepoolsAttributeTypeOk(arg ExpirationStatusGetNodepoolsAttributeType) (ret ExpirationStatusGetNodepoolsRetType, 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 setExpirationStatusGetNodepoolsAttributeType(arg *ExpirationStatusGetNodepoolsAttributeType, val ExpirationStatusGetNodepoolsRetType) { + *arg = &val +} + +// ExpirationStatus struct for ExpirationStatus +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatus struct { + Kubernetes ExpirationStatusGetKubernetesAttributeType `json:"kubernetes,omitempty"` + Nodepools ExpirationStatusGetNodepoolsAttributeType `json:"nodepools,omitempty"` +} + +// NewExpirationStatus instantiates a new ExpirationStatus 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 NewExpirationStatus() *ExpirationStatus { + this := ExpirationStatus{} + return &this +} + +// NewExpirationStatusWithDefaults instantiates a new ExpirationStatus 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 NewExpirationStatusWithDefaults() *ExpirationStatus { + this := ExpirationStatus{} + return &this +} + +// GetKubernetes returns the Kubernetes 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 *ExpirationStatus) GetKubernetes() (res ExpirationStatusGetKubernetesRetType) { + res, _ = o.GetKubernetesOk() + return +} + +// GetKubernetesOk returns a tuple with the Kubernetes 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 *ExpirationStatus) GetKubernetesOk() (ret ExpirationStatusGetKubernetesRetType, ok bool) { + return getExpirationStatusGetKubernetesAttributeTypeOk(o.Kubernetes) +} + +// HasKubernetes 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 *ExpirationStatus) HasKubernetes() bool { + _, ok := o.GetKubernetesOk() + return ok +} + +// SetKubernetes gets a reference to the given ExpirationStatusKubernetes and assigns it to the Kubernetes field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatus) SetKubernetes(v ExpirationStatusGetKubernetesRetType) { + setExpirationStatusGetKubernetesAttributeType(&o.Kubernetes, v) +} + +// GetNodepools returns the Nodepools 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 *ExpirationStatus) GetNodepools() (res ExpirationStatusGetNodepoolsRetType) { + res, _ = o.GetNodepoolsOk() + return +} + +// GetNodepoolsOk returns a tuple with the Nodepools 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 *ExpirationStatus) GetNodepoolsOk() (ret ExpirationStatusGetNodepoolsRetType, ok bool) { + return getExpirationStatusGetNodepoolsAttributeTypeOk(o.Nodepools) +} + +// HasNodepools 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 *ExpirationStatus) HasNodepools() bool { + _, ok := o.GetNodepoolsOk() + return ok +} + +// SetNodepools gets a reference to the given []ExpirationStatusNodepool and assigns it to the Nodepools field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatus) SetNodepools(v ExpirationStatusGetNodepoolsRetType) { + setExpirationStatusGetNodepoolsAttributeType(&o.Nodepools, v) +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o ExpirationStatus) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if val, ok := getExpirationStatusGetKubernetesAttributeTypeOk(o.Kubernetes); ok { + toSerialize["Kubernetes"] = val + } + if val, ok := getExpirationStatusGetNodepoolsAttributeTypeOk(o.Nodepools); ok { + toSerialize["Nodepools"] = val + } + return toSerialize, nil +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NullableExpirationStatus struct { + value *ExpirationStatus + isSet bool +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v NullableExpirationStatus) Get() *ExpirationStatus { + return v.value +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v *NullableExpirationStatus) Set(val *ExpirationStatus) { + 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 NullableExpirationStatus) 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 *NullableExpirationStatus) 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 NewNullableExpirationStatus(val *ExpirationStatus) *NullableExpirationStatus { + return &NullableExpirationStatus{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 NullableExpirationStatus) 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 *NullableExpirationStatus) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/ske/model_expiration_status_kubernetes.go b/services/ske/model_expiration_status_kubernetes.go new file mode 100644 index 000000000..3f5f9c215 --- /dev/null +++ b/services/ske/model_expiration_status_kubernetes.go @@ -0,0 +1,210 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +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 ske + +import ( + "encoding/json" + "time" +) + +// checks if the ExpirationStatusKubernetes type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ExpirationStatusKubernetes{} + +/* + types and functions for expirationDate +*/ + +// isDateTime +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusKubernetesGetExpirationDateAttributeType = *time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusKubernetesGetExpirationDateArgType = time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusKubernetesGetExpirationDateRetType = time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusKubernetesGetExpirationDateAttributeTypeOk(arg ExpirationStatusKubernetesGetExpirationDateAttributeType) (ret ExpirationStatusKubernetesGetExpirationDateRetType, 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 setExpirationStatusKubernetesGetExpirationDateAttributeType(arg *ExpirationStatusKubernetesGetExpirationDateAttributeType, val ExpirationStatusKubernetesGetExpirationDateRetType) { + *arg = &val +} + +/* + types and functions for version +*/ + +// isNotNullableString +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusKubernetesGetVersionAttributeType = *string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusKubernetesGetVersionAttributeTypeOk(arg ExpirationStatusKubernetesGetVersionAttributeType) (ret ExpirationStatusKubernetesGetVersionRetType, 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 setExpirationStatusKubernetesGetVersionAttributeType(arg *ExpirationStatusKubernetesGetVersionAttributeType, val ExpirationStatusKubernetesGetVersionRetType) { + *arg = &val +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusKubernetesGetVersionArgType = string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusKubernetesGetVersionRetType = string + +// ExpirationStatusKubernetes struct for ExpirationStatusKubernetes +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusKubernetes struct { + ExpirationDate ExpirationStatusKubernetesGetExpirationDateAttributeType `json:"expirationDate,omitempty"` + Version ExpirationStatusKubernetesGetVersionAttributeType `json:"version,omitempty"` +} + +// NewExpirationStatusKubernetes instantiates a new ExpirationStatusKubernetes 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 NewExpirationStatusKubernetes() *ExpirationStatusKubernetes { + this := ExpirationStatusKubernetes{} + return &this +} + +// NewExpirationStatusKubernetesWithDefaults instantiates a new ExpirationStatusKubernetes 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 NewExpirationStatusKubernetesWithDefaults() *ExpirationStatusKubernetes { + this := ExpirationStatusKubernetes{} + return &this +} + +// GetExpirationDate returns the ExpirationDate 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 *ExpirationStatusKubernetes) GetExpirationDate() (res ExpirationStatusKubernetesGetExpirationDateRetType) { + res, _ = o.GetExpirationDateOk() + return +} + +// GetExpirationDateOk returns a tuple with the ExpirationDate 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 *ExpirationStatusKubernetes) GetExpirationDateOk() (ret ExpirationStatusKubernetesGetExpirationDateRetType, ok bool) { + return getExpirationStatusKubernetesGetExpirationDateAttributeTypeOk(o.ExpirationDate) +} + +// HasExpirationDate 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 *ExpirationStatusKubernetes) HasExpirationDate() bool { + _, ok := o.GetExpirationDateOk() + return ok +} + +// SetExpirationDate gets a reference to the given time.Time and assigns it to the ExpirationDate field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusKubernetes) SetExpirationDate(v ExpirationStatusKubernetesGetExpirationDateRetType) { + setExpirationStatusKubernetesGetExpirationDateAttributeType(&o.ExpirationDate, v) +} + +// GetVersion returns the Version 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 *ExpirationStatusKubernetes) GetVersion() (res ExpirationStatusKubernetesGetVersionRetType) { + res, _ = o.GetVersionOk() + return +} + +// GetVersionOk returns a tuple with the Version 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 *ExpirationStatusKubernetes) GetVersionOk() (ret ExpirationStatusKubernetesGetVersionRetType, ok bool) { + return getExpirationStatusKubernetesGetVersionAttributeTypeOk(o.Version) +} + +// HasVersion 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 *ExpirationStatusKubernetes) HasVersion() bool { + _, ok := o.GetVersionOk() + return ok +} + +// SetVersion gets a reference to the given string and assigns it to the Version field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusKubernetes) SetVersion(v ExpirationStatusKubernetesGetVersionRetType) { + setExpirationStatusKubernetesGetVersionAttributeType(&o.Version, v) +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o ExpirationStatusKubernetes) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if val, ok := getExpirationStatusKubernetesGetExpirationDateAttributeTypeOk(o.ExpirationDate); ok { + toSerialize["ExpirationDate"] = val + } + if val, ok := getExpirationStatusKubernetesGetVersionAttributeTypeOk(o.Version); ok { + toSerialize["Version"] = val + } + return toSerialize, nil +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NullableExpirationStatusKubernetes struct { + value *ExpirationStatusKubernetes + isSet bool +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v NullableExpirationStatusKubernetes) Get() *ExpirationStatusKubernetes { + return v.value +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v *NullableExpirationStatusKubernetes) Set(val *ExpirationStatusKubernetes) { + 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 NullableExpirationStatusKubernetes) 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 *NullableExpirationStatusKubernetes) 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 NewNullableExpirationStatusKubernetes(val *ExpirationStatusKubernetes) *NullableExpirationStatusKubernetes { + return &NullableExpirationStatusKubernetes{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 NullableExpirationStatusKubernetes) 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 *NullableExpirationStatusKubernetes) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/ske/model_expiration_status_kubernetes_test.go b/services/ske/model_expiration_status_kubernetes_test.go new file mode 100644 index 000000000..be50da75a --- /dev/null +++ b/services/ske/model_expiration_status_kubernetes_test.go @@ -0,0 +1,11 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package ske diff --git a/services/ske/model_expiration_status_nodepool.go b/services/ske/model_expiration_status_nodepool.go new file mode 100644 index 000000000..c73ce14ad --- /dev/null +++ b/services/ske/model_expiration_status_nodepool.go @@ -0,0 +1,442 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +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 ske + +import ( + "encoding/json" + "time" +) + +// checks if the ExpirationStatusNodepool type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ExpirationStatusNodepool{} + +/* + types and functions for kubernetesExpirationDate +*/ + +// isDateTime +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetKubernetesExpirationDateAttributeType = *time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetKubernetesExpirationDateArgType = time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetKubernetesExpirationDateRetType = time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusNodepoolGetKubernetesExpirationDateAttributeTypeOk(arg ExpirationStatusNodepoolGetKubernetesExpirationDateAttributeType) (ret ExpirationStatusNodepoolGetKubernetesExpirationDateRetType, 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 setExpirationStatusNodepoolGetKubernetesExpirationDateAttributeType(arg *ExpirationStatusNodepoolGetKubernetesExpirationDateAttributeType, val ExpirationStatusNodepoolGetKubernetesExpirationDateRetType) { + *arg = &val +} + +/* + types and functions for kubernetesVersion +*/ + +// isNotNullableString +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetKubernetesVersionAttributeType = *string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusNodepoolGetKubernetesVersionAttributeTypeOk(arg ExpirationStatusNodepoolGetKubernetesVersionAttributeType) (ret ExpirationStatusNodepoolGetKubernetesVersionRetType, 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 setExpirationStatusNodepoolGetKubernetesVersionAttributeType(arg *ExpirationStatusNodepoolGetKubernetesVersionAttributeType, val ExpirationStatusNodepoolGetKubernetesVersionRetType) { + *arg = &val +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetKubernetesVersionArgType = string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetKubernetesVersionRetType = string + +/* + 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 ExpirationStatusNodepoolGetNameAttributeType = *string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusNodepoolGetNameAttributeTypeOk(arg ExpirationStatusNodepoolGetNameAttributeType) (ret ExpirationStatusNodepoolGetNameRetType, 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 setExpirationStatusNodepoolGetNameAttributeType(arg *ExpirationStatusNodepoolGetNameAttributeType, val ExpirationStatusNodepoolGetNameRetType) { + *arg = &val +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetNameArgType = string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetNameRetType = string + +/* + types and functions for osExpirationDate +*/ + +// isDateTime +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsExpirationDateAttributeType = *time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsExpirationDateArgType = time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsExpirationDateRetType = time.Time + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusNodepoolGetOsExpirationDateAttributeTypeOk(arg ExpirationStatusNodepoolGetOsExpirationDateAttributeType) (ret ExpirationStatusNodepoolGetOsExpirationDateRetType, 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 setExpirationStatusNodepoolGetOsExpirationDateAttributeType(arg *ExpirationStatusNodepoolGetOsExpirationDateAttributeType, val ExpirationStatusNodepoolGetOsExpirationDateRetType) { + *arg = &val +} + +/* + types and functions for osName +*/ + +// isNotNullableString +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsNameAttributeType = *string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusNodepoolGetOsNameAttributeTypeOk(arg ExpirationStatusNodepoolGetOsNameAttributeType) (ret ExpirationStatusNodepoolGetOsNameRetType, 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 setExpirationStatusNodepoolGetOsNameAttributeType(arg *ExpirationStatusNodepoolGetOsNameAttributeType, val ExpirationStatusNodepoolGetOsNameRetType) { + *arg = &val +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsNameArgType = string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsNameRetType = string + +/* + types and functions for osVersion +*/ + +// isNotNullableString +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsVersionAttributeType = *string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func getExpirationStatusNodepoolGetOsVersionAttributeTypeOk(arg ExpirationStatusNodepoolGetOsVersionAttributeType) (ret ExpirationStatusNodepoolGetOsVersionRetType, 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 setExpirationStatusNodepoolGetOsVersionAttributeType(arg *ExpirationStatusNodepoolGetOsVersionAttributeType, val ExpirationStatusNodepoolGetOsVersionRetType) { + *arg = &val +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsVersionArgType = string + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepoolGetOsVersionRetType = string + +// ExpirationStatusNodepool struct for ExpirationStatusNodepool +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type ExpirationStatusNodepool struct { + KubernetesExpirationDate ExpirationStatusNodepoolGetKubernetesExpirationDateAttributeType `json:"kubernetesExpirationDate,omitempty"` + KubernetesVersion ExpirationStatusNodepoolGetKubernetesVersionAttributeType `json:"kubernetesVersion,omitempty"` + Name ExpirationStatusNodepoolGetNameAttributeType `json:"name,omitempty"` + OsExpirationDate ExpirationStatusNodepoolGetOsExpirationDateAttributeType `json:"osExpirationDate,omitempty"` + OsName ExpirationStatusNodepoolGetOsNameAttributeType `json:"osName,omitempty"` + OsVersion ExpirationStatusNodepoolGetOsVersionAttributeType `json:"osVersion,omitempty"` +} + +// NewExpirationStatusNodepool instantiates a new ExpirationStatusNodepool 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 NewExpirationStatusNodepool() *ExpirationStatusNodepool { + this := ExpirationStatusNodepool{} + return &this +} + +// NewExpirationStatusNodepoolWithDefaults instantiates a new ExpirationStatusNodepool 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 NewExpirationStatusNodepoolWithDefaults() *ExpirationStatusNodepool { + this := ExpirationStatusNodepool{} + return &this +} + +// GetKubernetesExpirationDate returns the KubernetesExpirationDate 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 *ExpirationStatusNodepool) GetKubernetesExpirationDate() (res ExpirationStatusNodepoolGetKubernetesExpirationDateRetType) { + res, _ = o.GetKubernetesExpirationDateOk() + return +} + +// GetKubernetesExpirationDateOk returns a tuple with the KubernetesExpirationDate 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 *ExpirationStatusNodepool) GetKubernetesExpirationDateOk() (ret ExpirationStatusNodepoolGetKubernetesExpirationDateRetType, ok bool) { + return getExpirationStatusNodepoolGetKubernetesExpirationDateAttributeTypeOk(o.KubernetesExpirationDate) +} + +// HasKubernetesExpirationDate 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 *ExpirationStatusNodepool) HasKubernetesExpirationDate() bool { + _, ok := o.GetKubernetesExpirationDateOk() + return ok +} + +// SetKubernetesExpirationDate gets a reference to the given time.Time and assigns it to the KubernetesExpirationDate field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusNodepool) SetKubernetesExpirationDate(v ExpirationStatusNodepoolGetKubernetesExpirationDateRetType) { + setExpirationStatusNodepoolGetKubernetesExpirationDateAttributeType(&o.KubernetesExpirationDate, v) +} + +// GetKubernetesVersion returns the KubernetesVersion 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 *ExpirationStatusNodepool) GetKubernetesVersion() (res ExpirationStatusNodepoolGetKubernetesVersionRetType) { + res, _ = o.GetKubernetesVersionOk() + return +} + +// GetKubernetesVersionOk returns a tuple with the KubernetesVersion 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 *ExpirationStatusNodepool) GetKubernetesVersionOk() (ret ExpirationStatusNodepoolGetKubernetesVersionRetType, ok bool) { + return getExpirationStatusNodepoolGetKubernetesVersionAttributeTypeOk(o.KubernetesVersion) +} + +// HasKubernetesVersion 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 *ExpirationStatusNodepool) HasKubernetesVersion() bool { + _, ok := o.GetKubernetesVersionOk() + return ok +} + +// SetKubernetesVersion gets a reference to the given string and assigns it to the KubernetesVersion field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusNodepool) SetKubernetesVersion(v ExpirationStatusNodepoolGetKubernetesVersionRetType) { + setExpirationStatusNodepoolGetKubernetesVersionAttributeType(&o.KubernetesVersion, v) +} + +// GetName returns the Name 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 *ExpirationStatusNodepool) GetName() (res ExpirationStatusNodepoolGetNameRetType) { + res, _ = o.GetNameOk() + return +} + +// GetNameOk returns a tuple with the Name 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 *ExpirationStatusNodepool) GetNameOk() (ret ExpirationStatusNodepoolGetNameRetType, ok bool) { + return getExpirationStatusNodepoolGetNameAttributeTypeOk(o.Name) +} + +// HasName 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 *ExpirationStatusNodepool) HasName() bool { + _, ok := o.GetNameOk() + return ok +} + +// SetName gets a reference to the given string and assigns it to the Name field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusNodepool) SetName(v ExpirationStatusNodepoolGetNameRetType) { + setExpirationStatusNodepoolGetNameAttributeType(&o.Name, v) +} + +// GetOsExpirationDate returns the OsExpirationDate 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 *ExpirationStatusNodepool) GetOsExpirationDate() (res ExpirationStatusNodepoolGetOsExpirationDateRetType) { + res, _ = o.GetOsExpirationDateOk() + return +} + +// GetOsExpirationDateOk returns a tuple with the OsExpirationDate 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 *ExpirationStatusNodepool) GetOsExpirationDateOk() (ret ExpirationStatusNodepoolGetOsExpirationDateRetType, ok bool) { + return getExpirationStatusNodepoolGetOsExpirationDateAttributeTypeOk(o.OsExpirationDate) +} + +// HasOsExpirationDate 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 *ExpirationStatusNodepool) HasOsExpirationDate() bool { + _, ok := o.GetOsExpirationDateOk() + return ok +} + +// SetOsExpirationDate gets a reference to the given time.Time and assigns it to the OsExpirationDate field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusNodepool) SetOsExpirationDate(v ExpirationStatusNodepoolGetOsExpirationDateRetType) { + setExpirationStatusNodepoolGetOsExpirationDateAttributeType(&o.OsExpirationDate, v) +} + +// GetOsName returns the OsName 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 *ExpirationStatusNodepool) GetOsName() (res ExpirationStatusNodepoolGetOsNameRetType) { + res, _ = o.GetOsNameOk() + return +} + +// GetOsNameOk returns a tuple with the OsName 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 *ExpirationStatusNodepool) GetOsNameOk() (ret ExpirationStatusNodepoolGetOsNameRetType, ok bool) { + return getExpirationStatusNodepoolGetOsNameAttributeTypeOk(o.OsName) +} + +// HasOsName 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 *ExpirationStatusNodepool) HasOsName() bool { + _, ok := o.GetOsNameOk() + return ok +} + +// SetOsName gets a reference to the given string and assigns it to the OsName field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusNodepool) SetOsName(v ExpirationStatusNodepoolGetOsNameRetType) { + setExpirationStatusNodepoolGetOsNameAttributeType(&o.OsName, v) +} + +// GetOsVersion returns the OsVersion 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 *ExpirationStatusNodepool) GetOsVersion() (res ExpirationStatusNodepoolGetOsVersionRetType) { + res, _ = o.GetOsVersionOk() + return +} + +// GetOsVersionOk returns a tuple with the OsVersion 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 *ExpirationStatusNodepool) GetOsVersionOk() (ret ExpirationStatusNodepoolGetOsVersionRetType, ok bool) { + return getExpirationStatusNodepoolGetOsVersionAttributeTypeOk(o.OsVersion) +} + +// HasOsVersion 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 *ExpirationStatusNodepool) HasOsVersion() bool { + _, ok := o.GetOsVersionOk() + return ok +} + +// SetOsVersion gets a reference to the given string and assigns it to the OsVersion field. +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o *ExpirationStatusNodepool) SetOsVersion(v ExpirationStatusNodepoolGetOsVersionRetType) { + setExpirationStatusNodepoolGetOsVersionAttributeType(&o.OsVersion, v) +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (o ExpirationStatusNodepool) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if val, ok := getExpirationStatusNodepoolGetKubernetesExpirationDateAttributeTypeOk(o.KubernetesExpirationDate); ok { + toSerialize["KubernetesExpirationDate"] = val + } + if val, ok := getExpirationStatusNodepoolGetKubernetesVersionAttributeTypeOk(o.KubernetesVersion); ok { + toSerialize["KubernetesVersion"] = val + } + if val, ok := getExpirationStatusNodepoolGetNameAttributeTypeOk(o.Name); ok { + toSerialize["Name"] = val + } + if val, ok := getExpirationStatusNodepoolGetOsExpirationDateAttributeTypeOk(o.OsExpirationDate); ok { + toSerialize["OsExpirationDate"] = val + } + if val, ok := getExpirationStatusNodepoolGetOsNameAttributeTypeOk(o.OsName); ok { + toSerialize["OsName"] = val + } + if val, ok := getExpirationStatusNodepoolGetOsVersionAttributeTypeOk(o.OsVersion); ok { + toSerialize["OsVersion"] = val + } + return toSerialize, nil +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +type NullableExpirationStatusNodepool struct { + value *ExpirationStatusNodepool + isSet bool +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v NullableExpirationStatusNodepool) Get() *ExpirationStatusNodepool { + return v.value +} + +// Deprecated: Will be removed after 2026-09-30. Move to the packages generated for each available API version instead +func (v *NullableExpirationStatusNodepool) Set(val *ExpirationStatusNodepool) { + 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 NullableExpirationStatusNodepool) 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 *NullableExpirationStatusNodepool) 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 NewNullableExpirationStatusNodepool(val *ExpirationStatusNodepool) *NullableExpirationStatusNodepool { + return &NullableExpirationStatusNodepool{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 NullableExpirationStatusNodepool) 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 *NullableExpirationStatusNodepool) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/ske/model_expiration_status_nodepool_test.go b/services/ske/model_expiration_status_nodepool_test.go new file mode 100644 index 000000000..be50da75a --- /dev/null +++ b/services/ske/model_expiration_status_nodepool_test.go @@ -0,0 +1,11 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package ske diff --git a/services/ske/model_expiration_status_test.go b/services/ske/model_expiration_status_test.go new file mode 100644 index 000000000..be50da75a --- /dev/null +++ b/services/ske/model_expiration_status_test.go @@ -0,0 +1,11 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package ske diff --git a/services/ske/oas_commit b/services/ske/oas_commit index 6460cce17..39bada35c 100644 --- a/services/ske/oas_commit +++ b/services/ske/oas_commit @@ -1 +1 @@ -bd1f0bdf70ded8202c46141b84f07b38d55de227 +a35d8f28738a45005b098b66b6debd08a67ab018 diff --git a/services/ske/v2api/model_cluster_status.go b/services/ske/v2api/model_cluster_status.go index 2ff8d29b4..bb3edd28a 100644 --- a/services/ske/v2api/model_cluster_status.go +++ b/services/ske/v2api/model_cluster_status.go @@ -25,11 +25,12 @@ type ClusterStatus struct { CreationTime *time.Time `json:"creationTime,omitempty"` CredentialsRotation *CredentialsRotationState `json:"credentialsRotation,omitempty"` // The outgoing network ranges (in CIDR notation) of traffic originating from workload on the cluster. - EgressAddressRanges []string `json:"egressAddressRanges,omitempty"` - Error *RuntimeError `json:"error,omitempty"` - Errors []ClusterError `json:"errors,omitempty"` - Hibernated *bool `json:"hibernated,omitempty"` - Identity *string `json:"identity,omitempty"` + EgressAddressRanges []string `json:"egressAddressRanges,omitempty"` + Error *RuntimeError `json:"error,omitempty"` + Errors []ClusterError `json:"errors,omitempty"` + Expiration *ExpirationStatus `json:"expiration,omitempty"` + Hibernated *bool `json:"hibernated,omitempty"` + Identity *string `json:"identity,omitempty"` // The network ranges (in CIDR notation) used by pods of the cluster. PodAddressRanges []string `json:"podAddressRanges,omitempty"` AdditionalProperties map[string]interface{} @@ -246,6 +247,38 @@ func (o *ClusterStatus) SetErrors(v []ClusterError) { o.Errors = v } +// GetExpiration returns the Expiration field value if set, zero value otherwise. +func (o *ClusterStatus) GetExpiration() ExpirationStatus { + if o == nil || IsNil(o.Expiration) { + var ret ExpirationStatus + return ret + } + return *o.Expiration +} + +// GetExpirationOk returns a tuple with the Expiration field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ClusterStatus) GetExpirationOk() (*ExpirationStatus, bool) { + if o == nil || IsNil(o.Expiration) { + return nil, false + } + return o.Expiration, true +} + +// HasExpiration returns a boolean if a field has been set. +func (o *ClusterStatus) HasExpiration() bool { + if o != nil && !IsNil(o.Expiration) { + return true + } + + return false +} + +// SetExpiration gets a reference to the given ExpirationStatus and assigns it to the Expiration field. +func (o *ClusterStatus) SetExpiration(v ExpirationStatus) { + o.Expiration = &v +} + // GetHibernated returns the Hibernated field value if set, zero value otherwise. func (o *ClusterStatus) GetHibernated() bool { if o == nil || IsNil(o.Hibernated) { @@ -370,6 +403,9 @@ func (o ClusterStatus) ToMap() (map[string]interface{}, error) { if !IsNil(o.Errors) { toSerialize["errors"] = o.Errors } + if !IsNil(o.Expiration) { + toSerialize["expiration"] = o.Expiration + } if !IsNil(o.Hibernated) { toSerialize["hibernated"] = o.Hibernated } @@ -407,6 +443,7 @@ func (o *ClusterStatus) UnmarshalJSON(data []byte) (err error) { delete(additionalProperties, "egressAddressRanges") delete(additionalProperties, "error") delete(additionalProperties, "errors") + delete(additionalProperties, "expiration") delete(additionalProperties, "hibernated") delete(additionalProperties, "identity") delete(additionalProperties, "podAddressRanges") diff --git a/services/ske/v2api/model_expiration_status.go b/services/ske/v2api/model_expiration_status.go new file mode 100644 index 000000000..b775a385f --- /dev/null +++ b/services/ske/v2api/model_expiration_status.go @@ -0,0 +1,190 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package v2api + +import ( + "encoding/json" +) + +// checks if the ExpirationStatus type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ExpirationStatus{} + +// ExpirationStatus struct for ExpirationStatus +type ExpirationStatus struct { + Kubernetes *ExpirationStatusKubernetes `json:"kubernetes,omitempty"` + Nodepools []ExpirationStatusNodepool `json:"nodepools,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ExpirationStatus ExpirationStatus + +// NewExpirationStatus instantiates a new ExpirationStatus 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 NewExpirationStatus() *ExpirationStatus { + this := ExpirationStatus{} + return &this +} + +// NewExpirationStatusWithDefaults instantiates a new ExpirationStatus 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 NewExpirationStatusWithDefaults() *ExpirationStatus { + this := ExpirationStatus{} + return &this +} + +// GetKubernetes returns the Kubernetes field value if set, zero value otherwise. +func (o *ExpirationStatus) GetKubernetes() ExpirationStatusKubernetes { + if o == nil || IsNil(o.Kubernetes) { + var ret ExpirationStatusKubernetes + return ret + } + return *o.Kubernetes +} + +// GetKubernetesOk returns a tuple with the Kubernetes field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatus) GetKubernetesOk() (*ExpirationStatusKubernetes, bool) { + if o == nil || IsNil(o.Kubernetes) { + return nil, false + } + return o.Kubernetes, true +} + +// HasKubernetes returns a boolean if a field has been set. +func (o *ExpirationStatus) HasKubernetes() bool { + if o != nil && !IsNil(o.Kubernetes) { + return true + } + + return false +} + +// SetKubernetes gets a reference to the given ExpirationStatusKubernetes and assigns it to the Kubernetes field. +func (o *ExpirationStatus) SetKubernetes(v ExpirationStatusKubernetes) { + o.Kubernetes = &v +} + +// GetNodepools returns the Nodepools field value if set, zero value otherwise. +func (o *ExpirationStatus) GetNodepools() []ExpirationStatusNodepool { + if o == nil || IsNil(o.Nodepools) { + var ret []ExpirationStatusNodepool + return ret + } + return o.Nodepools +} + +// GetNodepoolsOk returns a tuple with the Nodepools field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatus) GetNodepoolsOk() ([]ExpirationStatusNodepool, bool) { + if o == nil || IsNil(o.Nodepools) { + return nil, false + } + return o.Nodepools, true +} + +// HasNodepools returns a boolean if a field has been set. +func (o *ExpirationStatus) HasNodepools() bool { + if o != nil && !IsNil(o.Nodepools) { + return true + } + + return false +} + +// SetNodepools gets a reference to the given []ExpirationStatusNodepool and assigns it to the Nodepools field. +func (o *ExpirationStatus) SetNodepools(v []ExpirationStatusNodepool) { + o.Nodepools = v +} + +func (o ExpirationStatus) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ExpirationStatus) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Kubernetes) { + toSerialize["kubernetes"] = o.Kubernetes + } + if !IsNil(o.Nodepools) { + toSerialize["nodepools"] = o.Nodepools + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ExpirationStatus) UnmarshalJSON(data []byte) (err error) { + varExpirationStatus := _ExpirationStatus{} + + err = json.Unmarshal(data, &varExpirationStatus) + + if err != nil { + return err + } + + *o = ExpirationStatus(varExpirationStatus) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "kubernetes") + delete(additionalProperties, "nodepools") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableExpirationStatus struct { + value *ExpirationStatus + isSet bool +} + +func (v NullableExpirationStatus) Get() *ExpirationStatus { + return v.value +} + +func (v *NullableExpirationStatus) Set(val *ExpirationStatus) { + v.value = val + v.isSet = true +} + +func (v NullableExpirationStatus) IsSet() bool { + return v.isSet +} + +func (v *NullableExpirationStatus) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableExpirationStatus(val *ExpirationStatus) *NullableExpirationStatus { + return &NullableExpirationStatus{value: val, isSet: true} +} + +func (v NullableExpirationStatus) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableExpirationStatus) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/ske/v2api/model_expiration_status_kubernetes.go b/services/ske/v2api/model_expiration_status_kubernetes.go new file mode 100644 index 000000000..4ab9c9a3e --- /dev/null +++ b/services/ske/v2api/model_expiration_status_kubernetes.go @@ -0,0 +1,191 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package v2api + +import ( + "encoding/json" + "time" +) + +// checks if the ExpirationStatusKubernetes type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ExpirationStatusKubernetes{} + +// ExpirationStatusKubernetes struct for ExpirationStatusKubernetes +type ExpirationStatusKubernetes struct { + ExpirationDate *time.Time `json:"expirationDate,omitempty"` + Version *string `json:"version,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ExpirationStatusKubernetes ExpirationStatusKubernetes + +// NewExpirationStatusKubernetes instantiates a new ExpirationStatusKubernetes 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 NewExpirationStatusKubernetes() *ExpirationStatusKubernetes { + this := ExpirationStatusKubernetes{} + return &this +} + +// NewExpirationStatusKubernetesWithDefaults instantiates a new ExpirationStatusKubernetes 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 NewExpirationStatusKubernetesWithDefaults() *ExpirationStatusKubernetes { + this := ExpirationStatusKubernetes{} + return &this +} + +// GetExpirationDate returns the ExpirationDate field value if set, zero value otherwise. +func (o *ExpirationStatusKubernetes) GetExpirationDate() time.Time { + if o == nil || IsNil(o.ExpirationDate) { + var ret time.Time + return ret + } + return *o.ExpirationDate +} + +// GetExpirationDateOk returns a tuple with the ExpirationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusKubernetes) GetExpirationDateOk() (*time.Time, bool) { + if o == nil || IsNil(o.ExpirationDate) { + return nil, false + } + return o.ExpirationDate, true +} + +// HasExpirationDate returns a boolean if a field has been set. +func (o *ExpirationStatusKubernetes) HasExpirationDate() bool { + if o != nil && !IsNil(o.ExpirationDate) { + return true + } + + return false +} + +// SetExpirationDate gets a reference to the given time.Time and assigns it to the ExpirationDate field. +func (o *ExpirationStatusKubernetes) SetExpirationDate(v time.Time) { + o.ExpirationDate = &v +} + +// GetVersion returns the Version field value if set, zero value otherwise. +func (o *ExpirationStatusKubernetes) GetVersion() string { + if o == nil || IsNil(o.Version) { + var ret string + return ret + } + return *o.Version +} + +// GetVersionOk returns a tuple with the Version field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusKubernetes) GetVersionOk() (*string, bool) { + if o == nil || IsNil(o.Version) { + return nil, false + } + return o.Version, true +} + +// HasVersion returns a boolean if a field has been set. +func (o *ExpirationStatusKubernetes) HasVersion() bool { + if o != nil && !IsNil(o.Version) { + return true + } + + return false +} + +// SetVersion gets a reference to the given string and assigns it to the Version field. +func (o *ExpirationStatusKubernetes) SetVersion(v string) { + o.Version = &v +} + +func (o ExpirationStatusKubernetes) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ExpirationStatusKubernetes) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.ExpirationDate) { + toSerialize["expirationDate"] = o.ExpirationDate + } + if !IsNil(o.Version) { + toSerialize["version"] = o.Version + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ExpirationStatusKubernetes) UnmarshalJSON(data []byte) (err error) { + varExpirationStatusKubernetes := _ExpirationStatusKubernetes{} + + err = json.Unmarshal(data, &varExpirationStatusKubernetes) + + if err != nil { + return err + } + + *o = ExpirationStatusKubernetes(varExpirationStatusKubernetes) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "expirationDate") + delete(additionalProperties, "version") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableExpirationStatusKubernetes struct { + value *ExpirationStatusKubernetes + isSet bool +} + +func (v NullableExpirationStatusKubernetes) Get() *ExpirationStatusKubernetes { + return v.value +} + +func (v *NullableExpirationStatusKubernetes) Set(val *ExpirationStatusKubernetes) { + v.value = val + v.isSet = true +} + +func (v NullableExpirationStatusKubernetes) IsSet() bool { + return v.isSet +} + +func (v *NullableExpirationStatusKubernetes) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableExpirationStatusKubernetes(val *ExpirationStatusKubernetes) *NullableExpirationStatusKubernetes { + return &NullableExpirationStatusKubernetes{value: val, isSet: true} +} + +func (v NullableExpirationStatusKubernetes) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableExpirationStatusKubernetes) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/ske/v2api/model_expiration_status_nodepool.go b/services/ske/v2api/model_expiration_status_nodepool.go new file mode 100644 index 000000000..e591e0aa1 --- /dev/null +++ b/services/ske/v2api/model_expiration_status_nodepool.go @@ -0,0 +1,339 @@ +/* +STACKIT Kubernetes Engine API + +The SKE API provides endpoints to create, update or delete clusters within STACKIT projects and to trigger further cluster management tasks. + +API version: 2.0 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package v2api + +import ( + "encoding/json" + "time" +) + +// checks if the ExpirationStatusNodepool type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ExpirationStatusNodepool{} + +// ExpirationStatusNodepool struct for ExpirationStatusNodepool +type ExpirationStatusNodepool struct { + KubernetesExpirationDate *time.Time `json:"kubernetesExpirationDate,omitempty"` + KubernetesVersion *string `json:"kubernetesVersion,omitempty"` + Name *string `json:"name,omitempty"` + OsExpirationDate *time.Time `json:"osExpirationDate,omitempty"` + OsName *string `json:"osName,omitempty"` + OsVersion *string `json:"osVersion,omitempty"` + AdditionalProperties map[string]interface{} +} + +type _ExpirationStatusNodepool ExpirationStatusNodepool + +// NewExpirationStatusNodepool instantiates a new ExpirationStatusNodepool 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 NewExpirationStatusNodepool() *ExpirationStatusNodepool { + this := ExpirationStatusNodepool{} + return &this +} + +// NewExpirationStatusNodepoolWithDefaults instantiates a new ExpirationStatusNodepool 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 NewExpirationStatusNodepoolWithDefaults() *ExpirationStatusNodepool { + this := ExpirationStatusNodepool{} + return &this +} + +// GetKubernetesExpirationDate returns the KubernetesExpirationDate field value if set, zero value otherwise. +func (o *ExpirationStatusNodepool) GetKubernetesExpirationDate() time.Time { + if o == nil || IsNil(o.KubernetesExpirationDate) { + var ret time.Time + return ret + } + return *o.KubernetesExpirationDate +} + +// GetKubernetesExpirationDateOk returns a tuple with the KubernetesExpirationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusNodepool) GetKubernetesExpirationDateOk() (*time.Time, bool) { + if o == nil || IsNil(o.KubernetesExpirationDate) { + return nil, false + } + return o.KubernetesExpirationDate, true +} + +// HasKubernetesExpirationDate returns a boolean if a field has been set. +func (o *ExpirationStatusNodepool) HasKubernetesExpirationDate() bool { + if o != nil && !IsNil(o.KubernetesExpirationDate) { + return true + } + + return false +} + +// SetKubernetesExpirationDate gets a reference to the given time.Time and assigns it to the KubernetesExpirationDate field. +func (o *ExpirationStatusNodepool) SetKubernetesExpirationDate(v time.Time) { + o.KubernetesExpirationDate = &v +} + +// GetKubernetesVersion returns the KubernetesVersion field value if set, zero value otherwise. +func (o *ExpirationStatusNodepool) GetKubernetesVersion() string { + if o == nil || IsNil(o.KubernetesVersion) { + var ret string + return ret + } + return *o.KubernetesVersion +} + +// GetKubernetesVersionOk returns a tuple with the KubernetesVersion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusNodepool) GetKubernetesVersionOk() (*string, bool) { + if o == nil || IsNil(o.KubernetesVersion) { + return nil, false + } + return o.KubernetesVersion, true +} + +// HasKubernetesVersion returns a boolean if a field has been set. +func (o *ExpirationStatusNodepool) HasKubernetesVersion() bool { + if o != nil && !IsNil(o.KubernetesVersion) { + return true + } + + return false +} + +// SetKubernetesVersion gets a reference to the given string and assigns it to the KubernetesVersion field. +func (o *ExpirationStatusNodepool) SetKubernetesVersion(v string) { + o.KubernetesVersion = &v +} + +// GetName returns the Name field value if set, zero value otherwise. +func (o *ExpirationStatusNodepool) GetName() string { + if o == nil || IsNil(o.Name) { + var ret string + return ret + } + return *o.Name +} + +// GetNameOk returns a tuple with the Name field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusNodepool) GetNameOk() (*string, bool) { + if o == nil || IsNil(o.Name) { + return nil, false + } + return o.Name, true +} + +// HasName returns a boolean if a field has been set. +func (o *ExpirationStatusNodepool) HasName() bool { + if o != nil && !IsNil(o.Name) { + return true + } + + return false +} + +// SetName gets a reference to the given string and assigns it to the Name field. +func (o *ExpirationStatusNodepool) SetName(v string) { + o.Name = &v +} + +// GetOsExpirationDate returns the OsExpirationDate field value if set, zero value otherwise. +func (o *ExpirationStatusNodepool) GetOsExpirationDate() time.Time { + if o == nil || IsNil(o.OsExpirationDate) { + var ret time.Time + return ret + } + return *o.OsExpirationDate +} + +// GetOsExpirationDateOk returns a tuple with the OsExpirationDate field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusNodepool) GetOsExpirationDateOk() (*time.Time, bool) { + if o == nil || IsNil(o.OsExpirationDate) { + return nil, false + } + return o.OsExpirationDate, true +} + +// HasOsExpirationDate returns a boolean if a field has been set. +func (o *ExpirationStatusNodepool) HasOsExpirationDate() bool { + if o != nil && !IsNil(o.OsExpirationDate) { + return true + } + + return false +} + +// SetOsExpirationDate gets a reference to the given time.Time and assigns it to the OsExpirationDate field. +func (o *ExpirationStatusNodepool) SetOsExpirationDate(v time.Time) { + o.OsExpirationDate = &v +} + +// GetOsName returns the OsName field value if set, zero value otherwise. +func (o *ExpirationStatusNodepool) GetOsName() string { + if o == nil || IsNil(o.OsName) { + var ret string + return ret + } + return *o.OsName +} + +// GetOsNameOk returns a tuple with the OsName field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusNodepool) GetOsNameOk() (*string, bool) { + if o == nil || IsNil(o.OsName) { + return nil, false + } + return o.OsName, true +} + +// HasOsName returns a boolean if a field has been set. +func (o *ExpirationStatusNodepool) HasOsName() bool { + if o != nil && !IsNil(o.OsName) { + return true + } + + return false +} + +// SetOsName gets a reference to the given string and assigns it to the OsName field. +func (o *ExpirationStatusNodepool) SetOsName(v string) { + o.OsName = &v +} + +// GetOsVersion returns the OsVersion field value if set, zero value otherwise. +func (o *ExpirationStatusNodepool) GetOsVersion() string { + if o == nil || IsNil(o.OsVersion) { + var ret string + return ret + } + return *o.OsVersion +} + +// GetOsVersionOk returns a tuple with the OsVersion field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *ExpirationStatusNodepool) GetOsVersionOk() (*string, bool) { + if o == nil || IsNil(o.OsVersion) { + return nil, false + } + return o.OsVersion, true +} + +// HasOsVersion returns a boolean if a field has been set. +func (o *ExpirationStatusNodepool) HasOsVersion() bool { + if o != nil && !IsNil(o.OsVersion) { + return true + } + + return false +} + +// SetOsVersion gets a reference to the given string and assigns it to the OsVersion field. +func (o *ExpirationStatusNodepool) SetOsVersion(v string) { + o.OsVersion = &v +} + +func (o ExpirationStatusNodepool) MarshalJSON() ([]byte, error) { + toSerialize, err := o.ToMap() + if err != nil { + return []byte{}, err + } + return json.Marshal(toSerialize) +} + +func (o ExpirationStatusNodepool) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.KubernetesExpirationDate) { + toSerialize["kubernetesExpirationDate"] = o.KubernetesExpirationDate + } + if !IsNil(o.KubernetesVersion) { + toSerialize["kubernetesVersion"] = o.KubernetesVersion + } + if !IsNil(o.Name) { + toSerialize["name"] = o.Name + } + if !IsNil(o.OsExpirationDate) { + toSerialize["osExpirationDate"] = o.OsExpirationDate + } + if !IsNil(o.OsName) { + toSerialize["osName"] = o.OsName + } + if !IsNil(o.OsVersion) { + toSerialize["osVersion"] = o.OsVersion + } + + for key, value := range o.AdditionalProperties { + toSerialize[key] = value + } + + return toSerialize, nil +} + +func (o *ExpirationStatusNodepool) UnmarshalJSON(data []byte) (err error) { + varExpirationStatusNodepool := _ExpirationStatusNodepool{} + + err = json.Unmarshal(data, &varExpirationStatusNodepool) + + if err != nil { + return err + } + + *o = ExpirationStatusNodepool(varExpirationStatusNodepool) + + additionalProperties := make(map[string]interface{}) + + if err = json.Unmarshal(data, &additionalProperties); err == nil { + delete(additionalProperties, "kubernetesExpirationDate") + delete(additionalProperties, "kubernetesVersion") + delete(additionalProperties, "name") + delete(additionalProperties, "osExpirationDate") + delete(additionalProperties, "osName") + delete(additionalProperties, "osVersion") + o.AdditionalProperties = additionalProperties + } + + return err +} + +type NullableExpirationStatusNodepool struct { + value *ExpirationStatusNodepool + isSet bool +} + +func (v NullableExpirationStatusNodepool) Get() *ExpirationStatusNodepool { + return v.value +} + +func (v *NullableExpirationStatusNodepool) Set(val *ExpirationStatusNodepool) { + v.value = val + v.isSet = true +} + +func (v NullableExpirationStatusNodepool) IsSet() bool { + return v.isSet +} + +func (v *NullableExpirationStatusNodepool) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableExpirationStatusNodepool(val *ExpirationStatusNodepool) *NullableExpirationStatusNodepool { + return &NullableExpirationStatusNodepool{value: val, isSet: true} +} + +func (v NullableExpirationStatusNodepool) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableExpirationStatusNodepool) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +}