From ca08dfb912255ad251d20ac929ac080109822f9b Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Fri, 11 Oct 2024 17:27:47 +0000 Subject: [PATCH 1/2] Generate objectstorage --- services/objectstorage/model_access_key.go | 145 ++++++++++++ services/objectstorage/model_bucket.go | 171 ++++++++++++++ .../model_create_access_key_payload.go | 97 ++++++++ .../model_create_access_key_response.go | 223 ++++++++++++++++++ .../model_create_bucket_response.go | 119 ++++++++++ .../model_create_credentials_group_payload.go | 93 ++++++++ ...model_create_credentials_group_response.go | 119 ++++++++++ .../objectstorage/model_credentials_group.go | 145 ++++++++++++ .../model_delete_access_key_response.go | 119 ++++++++++ .../model_delete_bucket_response.go | 119 ++++++++++ ...model_delete_credentials_group_response.go | 119 ++++++++++ .../objectstorage/model_detailed_error.go | 119 ++++++++++ services/objectstorage/model_error_message.go | 93 ++++++++ .../model_get_bucket_response.go | 119 ++++++++++ .../model_http_validation_error.go | 100 ++++++++ .../model_list_access_keys_response.go | 119 ++++++++++ .../model_list_buckets_response.go | 119 ++++++++++ .../model_list_credentials_groups_response.go | 119 ++++++++++ .../objectstorage/model_project_status.go | 119 ++++++++++ .../objectstorage/model_validation_error.go | 145 ++++++++++++ 20 files changed, 2521 insertions(+) diff --git a/services/objectstorage/model_access_key.go b/services/objectstorage/model_access_key.go index 82bed9f3a..bae041ad3 100644 --- a/services/objectstorage/model_access_key.go +++ b/services/objectstorage/model_access_key.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the AccessKey type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &AccessKey{} + // AccessKey struct for AccessKey type AccessKey struct { // REQUIRED @@ -20,3 +27,141 @@ type AccessKey struct { // REQUIRED KeyId *string `json:"keyId"` } + +type _AccessKey AccessKey + +// NewAccessKey instantiates a new AccessKey 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 NewAccessKey(displayName *string, expires *string, keyId *string) *AccessKey { + this := AccessKey{} + this.DisplayName = displayName + this.Expires = expires + this.KeyId = keyId + return &this +} + +// NewAccessKeyWithDefaults instantiates a new AccessKey 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 NewAccessKeyWithDefaults() *AccessKey { + this := AccessKey{} + return &this +} + +// GetDisplayName returns the DisplayName field value +func (o *AccessKey) GetDisplayName() *string { + if o == nil { + var ret *string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *AccessKey) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *AccessKey) SetDisplayName(v *string) { + o.DisplayName = v +} + +// GetExpires returns the Expires field value +func (o *AccessKey) GetExpires() *string { + if o == nil { + var ret *string + return ret + } + + return o.Expires +} + +// GetExpiresOk returns a tuple with the Expires field value +// and a boolean to check if the value has been set. +func (o *AccessKey) GetExpiresOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Expires, true +} + +// SetExpires sets field value +func (o *AccessKey) SetExpires(v *string) { + o.Expires = v +} + +// GetKeyId returns the KeyId field value +func (o *AccessKey) GetKeyId() *string { + if o == nil { + var ret *string + return ret + } + + return o.KeyId +} + +// GetKeyIdOk returns a tuple with the KeyId field value +// and a boolean to check if the value has been set. +func (o *AccessKey) GetKeyIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.KeyId, true +} + +// SetKeyId sets field value +func (o *AccessKey) SetKeyId(v *string) { + o.KeyId = v +} + +func (o AccessKey) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["displayName"] = o.DisplayName + toSerialize["expires"] = o.Expires + toSerialize["keyId"] = o.KeyId + return toSerialize, nil +} + +type NullableAccessKey struct { + value *AccessKey + isSet bool +} + +func (v NullableAccessKey) Get() *AccessKey { + return v.value +} + +func (v *NullableAccessKey) Set(val *AccessKey) { + v.value = val + v.isSet = true +} + +func (v NullableAccessKey) IsSet() bool { + return v.isSet +} + +func (v *NullableAccessKey) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAccessKey(val *AccessKey) *NullableAccessKey { + return &NullableAccessKey{value: val, isSet: true} +} + +func (v NullableAccessKey) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableAccessKey) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_bucket.go b/services/objectstorage/model_bucket.go index 78b890de4..cc820fba2 100644 --- a/services/objectstorage/model_bucket.go +++ b/services/objectstorage/model_bucket.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the Bucket type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &Bucket{} + // Bucket struct for Bucket type Bucket struct { // REQUIRED @@ -23,3 +30,167 @@ type Bucket struct { // REQUIRED UrlVirtualHostedStyle *string `json:"urlVirtualHostedStyle"` } + +type _Bucket Bucket + +// NewBucket instantiates a new Bucket 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 NewBucket(name *string, region *string, urlPathStyle *string, urlVirtualHostedStyle *string) *Bucket { + this := Bucket{} + this.Name = name + this.Region = region + this.UrlPathStyle = urlPathStyle + this.UrlVirtualHostedStyle = urlVirtualHostedStyle + return &this +} + +// NewBucketWithDefaults instantiates a new Bucket 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 NewBucketWithDefaults() *Bucket { + this := Bucket{} + return &this +} + +// GetName returns the Name field value +func (o *Bucket) GetName() *string { + if o == nil { + var ret *string + return ret + } + + return o.Name +} + +// GetNameOk returns a tuple with the Name field value +// and a boolean to check if the value has been set. +func (o *Bucket) GetNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Name, true +} + +// SetName sets field value +func (o *Bucket) SetName(v *string) { + o.Name = v +} + +// GetRegion returns the Region field value +func (o *Bucket) GetRegion() *string { + if o == nil { + var ret *string + return ret + } + + return o.Region +} + +// GetRegionOk returns a tuple with the Region field value +// and a boolean to check if the value has been set. +func (o *Bucket) GetRegionOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Region, true +} + +// SetRegion sets field value +func (o *Bucket) SetRegion(v *string) { + o.Region = v +} + +// GetUrlPathStyle returns the UrlPathStyle field value +func (o *Bucket) GetUrlPathStyle() *string { + if o == nil { + var ret *string + return ret + } + + return o.UrlPathStyle +} + +// GetUrlPathStyleOk returns a tuple with the UrlPathStyle field value +// and a boolean to check if the value has been set. +func (o *Bucket) GetUrlPathStyleOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.UrlPathStyle, true +} + +// SetUrlPathStyle sets field value +func (o *Bucket) SetUrlPathStyle(v *string) { + o.UrlPathStyle = v +} + +// GetUrlVirtualHostedStyle returns the UrlVirtualHostedStyle field value +func (o *Bucket) GetUrlVirtualHostedStyle() *string { + if o == nil { + var ret *string + return ret + } + + return o.UrlVirtualHostedStyle +} + +// GetUrlVirtualHostedStyleOk returns a tuple with the UrlVirtualHostedStyle field value +// and a boolean to check if the value has been set. +func (o *Bucket) GetUrlVirtualHostedStyleOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.UrlVirtualHostedStyle, true +} + +// SetUrlVirtualHostedStyle sets field value +func (o *Bucket) SetUrlVirtualHostedStyle(v *string) { + o.UrlVirtualHostedStyle = v +} + +func (o Bucket) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["name"] = o.Name + toSerialize["region"] = o.Region + toSerialize["urlPathStyle"] = o.UrlPathStyle + toSerialize["urlVirtualHostedStyle"] = o.UrlVirtualHostedStyle + return toSerialize, nil +} + +type NullableBucket struct { + value *Bucket + isSet bool +} + +func (v NullableBucket) Get() *Bucket { + return v.value +} + +func (v *NullableBucket) Set(val *Bucket) { + v.value = val + v.isSet = true +} + +func (v NullableBucket) IsSet() bool { + return v.isSet +} + +func (v *NullableBucket) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableBucket(val *Bucket) *NullableBucket { + return &NullableBucket{value: val, isSet: true} +} + +func (v NullableBucket) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableBucket) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_create_access_key_payload.go b/services/objectstorage/model_create_access_key_payload.go index 180f641a7..e05785bfd 100644 --- a/services/objectstorage/model_create_access_key_payload.go +++ b/services/objectstorage/model_create_access_key_payload.go @@ -11,11 +11,108 @@ API version: 1.0.9 package objectstorage import ( + "encoding/json" "time" ) +// checks if the CreateAccessKeyPayload type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateAccessKeyPayload{} + // CreateAccessKeyPayload struct for CreateAccessKeyPayload type CreateAccessKeyPayload struct { // Expiration date. Null means never expires. Expires *time.Time `json:"expires,omitempty"` } + +// NewCreateAccessKeyPayload instantiates a new CreateAccessKeyPayload 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 NewCreateAccessKeyPayload() *CreateAccessKeyPayload { + this := CreateAccessKeyPayload{} + return &this +} + +// NewCreateAccessKeyPayloadWithDefaults instantiates a new CreateAccessKeyPayload 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 NewCreateAccessKeyPayloadWithDefaults() *CreateAccessKeyPayload { + this := CreateAccessKeyPayload{} + return &this +} + +// GetExpires returns the Expires field value if set, zero value otherwise. +func (o *CreateAccessKeyPayload) GetExpires() *time.Time { + if o == nil || IsNil(o.Expires) { + var ret *time.Time + return ret + } + return o.Expires +} + +// GetExpiresOk returns a tuple with the Expires field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyPayload) GetExpiresOk() (*time.Time, bool) { + if o == nil || IsNil(o.Expires) { + return nil, false + } + return o.Expires, true +} + +// HasExpires returns a boolean if a field has been set. +func (o *CreateAccessKeyPayload) HasExpires() bool { + if o != nil && !IsNil(o.Expires) { + return true + } + + return false +} + +// SetExpires gets a reference to the given time.Time and assigns it to the Expires field. +func (o *CreateAccessKeyPayload) SetExpires(v *time.Time) { + o.Expires = v +} + +func (o CreateAccessKeyPayload) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Expires) { + toSerialize["expires"] = o.Expires + } + return toSerialize, nil +} + +type NullableCreateAccessKeyPayload struct { + value *CreateAccessKeyPayload + isSet bool +} + +func (v NullableCreateAccessKeyPayload) Get() *CreateAccessKeyPayload { + return v.value +} + +func (v *NullableCreateAccessKeyPayload) Set(val *CreateAccessKeyPayload) { + v.value = val + v.isSet = true +} + +func (v NullableCreateAccessKeyPayload) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateAccessKeyPayload) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateAccessKeyPayload(val *CreateAccessKeyPayload) *NullableCreateAccessKeyPayload { + return &NullableCreateAccessKeyPayload{value: val, isSet: true} +} + +func (v NullableCreateAccessKeyPayload) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateAccessKeyPayload) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_create_access_key_response.go b/services/objectstorage/model_create_access_key_response.go index 4868f34e3..815bbace1 100644 --- a/services/objectstorage/model_create_access_key_response.go +++ b/services/objectstorage/model_create_access_key_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the CreateAccessKeyResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateAccessKeyResponse{} + // CreateAccessKeyResponse struct for CreateAccessKeyResponse type CreateAccessKeyResponse struct { // Access key @@ -31,3 +38,219 @@ type CreateAccessKeyResponse struct { // REQUIRED SecretAccessKey *string `json:"secretAccessKey"` } + +type _CreateAccessKeyResponse CreateAccessKeyResponse + +// NewCreateAccessKeyResponse instantiates a new CreateAccessKeyResponse 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 NewCreateAccessKeyResponse(accessKey *string, displayName *string, expires *string, keyId *string, project *string, secretAccessKey *string) *CreateAccessKeyResponse { + this := CreateAccessKeyResponse{} + this.AccessKey = accessKey + this.DisplayName = displayName + this.Expires = expires + this.KeyId = keyId + this.Project = project + this.SecretAccessKey = secretAccessKey + return &this +} + +// NewCreateAccessKeyResponseWithDefaults instantiates a new CreateAccessKeyResponse 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 NewCreateAccessKeyResponseWithDefaults() *CreateAccessKeyResponse { + this := CreateAccessKeyResponse{} + return &this +} + +// GetAccessKey returns the AccessKey field value +func (o *CreateAccessKeyResponse) GetAccessKey() *string { + if o == nil { + var ret *string + return ret + } + + return o.AccessKey +} + +// GetAccessKeyOk returns a tuple with the AccessKey field value +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetAccessKeyOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.AccessKey, true +} + +// SetAccessKey sets field value +func (o *CreateAccessKeyResponse) SetAccessKey(v *string) { + o.AccessKey = v +} + +// GetDisplayName returns the DisplayName field value +func (o *CreateAccessKeyResponse) GetDisplayName() *string { + if o == nil { + var ret *string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *CreateAccessKeyResponse) SetDisplayName(v *string) { + o.DisplayName = v +} + +// GetExpires returns the Expires field value +func (o *CreateAccessKeyResponse) GetExpires() *string { + if o == nil { + var ret *string + return ret + } + + return o.Expires +} + +// GetExpiresOk returns a tuple with the Expires field value +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetExpiresOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Expires, true +} + +// SetExpires sets field value +func (o *CreateAccessKeyResponse) SetExpires(v *string) { + o.Expires = v +} + +// GetKeyId returns the KeyId field value +func (o *CreateAccessKeyResponse) GetKeyId() *string { + if o == nil { + var ret *string + return ret + } + + return o.KeyId +} + +// GetKeyIdOk returns a tuple with the KeyId field value +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetKeyIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.KeyId, true +} + +// SetKeyId sets field value +func (o *CreateAccessKeyResponse) SetKeyId(v *string) { + o.KeyId = v +} + +// GetProject returns the Project field value +func (o *CreateAccessKeyResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *CreateAccessKeyResponse) SetProject(v *string) { + o.Project = v +} + +// GetSecretAccessKey returns the SecretAccessKey field value +func (o *CreateAccessKeyResponse) GetSecretAccessKey() *string { + if o == nil { + var ret *string + return ret + } + + return o.SecretAccessKey +} + +// GetSecretAccessKeyOk returns a tuple with the SecretAccessKey field value +// and a boolean to check if the value has been set. +func (o *CreateAccessKeyResponse) GetSecretAccessKeyOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.SecretAccessKey, true +} + +// SetSecretAccessKey sets field value +func (o *CreateAccessKeyResponse) SetSecretAccessKey(v *string) { + o.SecretAccessKey = v +} + +func (o CreateAccessKeyResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["accessKey"] = o.AccessKey + toSerialize["displayName"] = o.DisplayName + toSerialize["expires"] = o.Expires + toSerialize["keyId"] = o.KeyId + toSerialize["project"] = o.Project + toSerialize["secretAccessKey"] = o.SecretAccessKey + return toSerialize, nil +} + +type NullableCreateAccessKeyResponse struct { + value *CreateAccessKeyResponse + isSet bool +} + +func (v NullableCreateAccessKeyResponse) Get() *CreateAccessKeyResponse { + return v.value +} + +func (v *NullableCreateAccessKeyResponse) Set(val *CreateAccessKeyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateAccessKeyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateAccessKeyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateAccessKeyResponse(val *CreateAccessKeyResponse) *NullableCreateAccessKeyResponse { + return &NullableCreateAccessKeyResponse{value: val, isSet: true} +} + +func (v NullableCreateAccessKeyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateAccessKeyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_create_bucket_response.go b/services/objectstorage/model_create_bucket_response.go index 186d07dd1..2f7b37453 100644 --- a/services/objectstorage/model_create_bucket_response.go +++ b/services/objectstorage/model_create_bucket_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the CreateBucketResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateBucketResponse{} + // CreateBucketResponse struct for CreateBucketResponse type CreateBucketResponse struct { // Name of the bucket @@ -19,3 +26,115 @@ type CreateBucketResponse struct { // REQUIRED Project *string `json:"project"` } + +type _CreateBucketResponse CreateBucketResponse + +// NewCreateBucketResponse instantiates a new CreateBucketResponse 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 NewCreateBucketResponse(bucket *string, project *string) *CreateBucketResponse { + this := CreateBucketResponse{} + this.Bucket = bucket + this.Project = project + return &this +} + +// NewCreateBucketResponseWithDefaults instantiates a new CreateBucketResponse 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 NewCreateBucketResponseWithDefaults() *CreateBucketResponse { + this := CreateBucketResponse{} + return &this +} + +// GetBucket returns the Bucket field value +func (o *CreateBucketResponse) GetBucket() *string { + if o == nil { + var ret *string + return ret + } + + return o.Bucket +} + +// GetBucketOk returns a tuple with the Bucket field value +// and a boolean to check if the value has been set. +func (o *CreateBucketResponse) GetBucketOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Bucket, true +} + +// SetBucket sets field value +func (o *CreateBucketResponse) SetBucket(v *string) { + o.Bucket = v +} + +// GetProject returns the Project field value +func (o *CreateBucketResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *CreateBucketResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *CreateBucketResponse) SetProject(v *string) { + o.Project = v +} + +func (o CreateBucketResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["bucket"] = o.Bucket + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableCreateBucketResponse struct { + value *CreateBucketResponse + isSet bool +} + +func (v NullableCreateBucketResponse) Get() *CreateBucketResponse { + return v.value +} + +func (v *NullableCreateBucketResponse) Set(val *CreateBucketResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateBucketResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateBucketResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateBucketResponse(val *CreateBucketResponse) *NullableCreateBucketResponse { + return &NullableCreateBucketResponse{value: val, isSet: true} +} + +func (v NullableCreateBucketResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateBucketResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_create_credentials_group_payload.go b/services/objectstorage/model_create_credentials_group_payload.go index 550037089..98dd3a938 100644 --- a/services/objectstorage/model_create_credentials_group_payload.go +++ b/services/objectstorage/model_create_credentials_group_payload.go @@ -10,9 +10,102 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the CreateCredentialsGroupPayload type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateCredentialsGroupPayload{} + // CreateCredentialsGroupPayload struct for CreateCredentialsGroupPayload type CreateCredentialsGroupPayload struct { // Name of the group holding credentials // REQUIRED DisplayName *string `json:"displayName"` } + +type _CreateCredentialsGroupPayload CreateCredentialsGroupPayload + +// NewCreateCredentialsGroupPayload instantiates a new CreateCredentialsGroupPayload 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 NewCreateCredentialsGroupPayload(displayName *string) *CreateCredentialsGroupPayload { + this := CreateCredentialsGroupPayload{} + this.DisplayName = displayName + return &this +} + +// NewCreateCredentialsGroupPayloadWithDefaults instantiates a new CreateCredentialsGroupPayload 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 NewCreateCredentialsGroupPayloadWithDefaults() *CreateCredentialsGroupPayload { + this := CreateCredentialsGroupPayload{} + return &this +} + +// GetDisplayName returns the DisplayName field value +func (o *CreateCredentialsGroupPayload) GetDisplayName() *string { + if o == nil { + var ret *string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *CreateCredentialsGroupPayload) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *CreateCredentialsGroupPayload) SetDisplayName(v *string) { + o.DisplayName = v +} + +func (o CreateCredentialsGroupPayload) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["displayName"] = o.DisplayName + return toSerialize, nil +} + +type NullableCreateCredentialsGroupPayload struct { + value *CreateCredentialsGroupPayload + isSet bool +} + +func (v NullableCreateCredentialsGroupPayload) Get() *CreateCredentialsGroupPayload { + return v.value +} + +func (v *NullableCreateCredentialsGroupPayload) Set(val *CreateCredentialsGroupPayload) { + v.value = val + v.isSet = true +} + +func (v NullableCreateCredentialsGroupPayload) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateCredentialsGroupPayload) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateCredentialsGroupPayload(val *CreateCredentialsGroupPayload) *NullableCreateCredentialsGroupPayload { + return &NullableCreateCredentialsGroupPayload{value: val, isSet: true} +} + +func (v NullableCreateCredentialsGroupPayload) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateCredentialsGroupPayload) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_create_credentials_group_response.go b/services/objectstorage/model_create_credentials_group_response.go index b8e320237..d2e4baeb4 100644 --- a/services/objectstorage/model_create_credentials_group_response.go +++ b/services/objectstorage/model_create_credentials_group_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the CreateCredentialsGroupResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CreateCredentialsGroupResponse{} + // CreateCredentialsGroupResponse struct for CreateCredentialsGroupResponse type CreateCredentialsGroupResponse struct { // REQUIRED @@ -18,3 +25,115 @@ type CreateCredentialsGroupResponse struct { // REQUIRED Project *string `json:"project"` } + +type _CreateCredentialsGroupResponse CreateCredentialsGroupResponse + +// NewCreateCredentialsGroupResponse instantiates a new CreateCredentialsGroupResponse 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 NewCreateCredentialsGroupResponse(credentialsGroup *CredentialsGroup, project *string) *CreateCredentialsGroupResponse { + this := CreateCredentialsGroupResponse{} + this.CredentialsGroup = credentialsGroup + this.Project = project + return &this +} + +// NewCreateCredentialsGroupResponseWithDefaults instantiates a new CreateCredentialsGroupResponse 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 NewCreateCredentialsGroupResponseWithDefaults() *CreateCredentialsGroupResponse { + this := CreateCredentialsGroupResponse{} + return &this +} + +// GetCredentialsGroup returns the CredentialsGroup field value +func (o *CreateCredentialsGroupResponse) GetCredentialsGroup() *CredentialsGroup { + if o == nil { + var ret *CredentialsGroup + return ret + } + + return o.CredentialsGroup +} + +// GetCredentialsGroupOk returns a tuple with the CredentialsGroup field value +// and a boolean to check if the value has been set. +func (o *CreateCredentialsGroupResponse) GetCredentialsGroupOk() (*CredentialsGroup, bool) { + if o == nil { + return nil, false + } + return o.CredentialsGroup, true +} + +// SetCredentialsGroup sets field value +func (o *CreateCredentialsGroupResponse) SetCredentialsGroup(v *CredentialsGroup) { + o.CredentialsGroup = v +} + +// GetProject returns the Project field value +func (o *CreateCredentialsGroupResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *CreateCredentialsGroupResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *CreateCredentialsGroupResponse) SetProject(v *string) { + o.Project = v +} + +func (o CreateCredentialsGroupResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["credentialsGroup"] = o.CredentialsGroup + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableCreateCredentialsGroupResponse struct { + value *CreateCredentialsGroupResponse + isSet bool +} + +func (v NullableCreateCredentialsGroupResponse) Get() *CreateCredentialsGroupResponse { + return v.value +} + +func (v *NullableCreateCredentialsGroupResponse) Set(val *CreateCredentialsGroupResponse) { + v.value = val + v.isSet = true +} + +func (v NullableCreateCredentialsGroupResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableCreateCredentialsGroupResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCreateCredentialsGroupResponse(val *CreateCredentialsGroupResponse) *NullableCreateCredentialsGroupResponse { + return &NullableCreateCredentialsGroupResponse{value: val, isSet: true} +} + +func (v NullableCreateCredentialsGroupResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCreateCredentialsGroupResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_credentials_group.go b/services/objectstorage/model_credentials_group.go index 2eb6e08d4..95dcf0d62 100644 --- a/services/objectstorage/model_credentials_group.go +++ b/services/objectstorage/model_credentials_group.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the CredentialsGroup type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &CredentialsGroup{} + // CredentialsGroup struct for CredentialsGroup type CredentialsGroup struct { // The ID of the credentials group @@ -22,3 +29,141 @@ type CredentialsGroup struct { // REQUIRED Urn *string `json:"urn"` } + +type _CredentialsGroup CredentialsGroup + +// NewCredentialsGroup instantiates a new CredentialsGroup 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 NewCredentialsGroup(credentialsGroupId *string, displayName *string, urn *string) *CredentialsGroup { + this := CredentialsGroup{} + this.CredentialsGroupId = credentialsGroupId + this.DisplayName = displayName + this.Urn = urn + return &this +} + +// NewCredentialsGroupWithDefaults instantiates a new CredentialsGroup 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 NewCredentialsGroupWithDefaults() *CredentialsGroup { + this := CredentialsGroup{} + return &this +} + +// GetCredentialsGroupId returns the CredentialsGroupId field value +func (o *CredentialsGroup) GetCredentialsGroupId() *string { + if o == nil { + var ret *string + return ret + } + + return o.CredentialsGroupId +} + +// GetCredentialsGroupIdOk returns a tuple with the CredentialsGroupId field value +// and a boolean to check if the value has been set. +func (o *CredentialsGroup) GetCredentialsGroupIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.CredentialsGroupId, true +} + +// SetCredentialsGroupId sets field value +func (o *CredentialsGroup) SetCredentialsGroupId(v *string) { + o.CredentialsGroupId = v +} + +// GetDisplayName returns the DisplayName field value +func (o *CredentialsGroup) GetDisplayName() *string { + if o == nil { + var ret *string + return ret + } + + return o.DisplayName +} + +// GetDisplayNameOk returns a tuple with the DisplayName field value +// and a boolean to check if the value has been set. +func (o *CredentialsGroup) GetDisplayNameOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.DisplayName, true +} + +// SetDisplayName sets field value +func (o *CredentialsGroup) SetDisplayName(v *string) { + o.DisplayName = v +} + +// GetUrn returns the Urn field value +func (o *CredentialsGroup) GetUrn() *string { + if o == nil { + var ret *string + return ret + } + + return o.Urn +} + +// GetUrnOk returns a tuple with the Urn field value +// and a boolean to check if the value has been set. +func (o *CredentialsGroup) GetUrnOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Urn, true +} + +// SetUrn sets field value +func (o *CredentialsGroup) SetUrn(v *string) { + o.Urn = v +} + +func (o CredentialsGroup) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["credentialsGroupId"] = o.CredentialsGroupId + toSerialize["displayName"] = o.DisplayName + toSerialize["urn"] = o.Urn + return toSerialize, nil +} + +type NullableCredentialsGroup struct { + value *CredentialsGroup + isSet bool +} + +func (v NullableCredentialsGroup) Get() *CredentialsGroup { + return v.value +} + +func (v *NullableCredentialsGroup) Set(val *CredentialsGroup) { + v.value = val + v.isSet = true +} + +func (v NullableCredentialsGroup) IsSet() bool { + return v.isSet +} + +func (v *NullableCredentialsGroup) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableCredentialsGroup(val *CredentialsGroup) *NullableCredentialsGroup { + return &NullableCredentialsGroup{value: val, isSet: true} +} + +func (v NullableCredentialsGroup) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableCredentialsGroup) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_delete_access_key_response.go b/services/objectstorage/model_delete_access_key_response.go index 97ef3a4ce..8332cd4b7 100644 --- a/services/objectstorage/model_delete_access_key_response.go +++ b/services/objectstorage/model_delete_access_key_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the DeleteAccessKeyResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DeleteAccessKeyResponse{} + // DeleteAccessKeyResponse struct for DeleteAccessKeyResponse type DeleteAccessKeyResponse struct { // Identifies the pair of access key and secret access key for deletion @@ -19,3 +26,115 @@ type DeleteAccessKeyResponse struct { // REQUIRED Project *string `json:"project"` } + +type _DeleteAccessKeyResponse DeleteAccessKeyResponse + +// NewDeleteAccessKeyResponse instantiates a new DeleteAccessKeyResponse 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 NewDeleteAccessKeyResponse(keyId *string, project *string) *DeleteAccessKeyResponse { + this := DeleteAccessKeyResponse{} + this.KeyId = keyId + this.Project = project + return &this +} + +// NewDeleteAccessKeyResponseWithDefaults instantiates a new DeleteAccessKeyResponse 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 NewDeleteAccessKeyResponseWithDefaults() *DeleteAccessKeyResponse { + this := DeleteAccessKeyResponse{} + return &this +} + +// GetKeyId returns the KeyId field value +func (o *DeleteAccessKeyResponse) GetKeyId() *string { + if o == nil { + var ret *string + return ret + } + + return o.KeyId +} + +// GetKeyIdOk returns a tuple with the KeyId field value +// and a boolean to check if the value has been set. +func (o *DeleteAccessKeyResponse) GetKeyIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.KeyId, true +} + +// SetKeyId sets field value +func (o *DeleteAccessKeyResponse) SetKeyId(v *string) { + o.KeyId = v +} + +// GetProject returns the Project field value +func (o *DeleteAccessKeyResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *DeleteAccessKeyResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *DeleteAccessKeyResponse) SetProject(v *string) { + o.Project = v +} + +func (o DeleteAccessKeyResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["keyId"] = o.KeyId + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableDeleteAccessKeyResponse struct { + value *DeleteAccessKeyResponse + isSet bool +} + +func (v NullableDeleteAccessKeyResponse) Get() *DeleteAccessKeyResponse { + return v.value +} + +func (v *NullableDeleteAccessKeyResponse) Set(val *DeleteAccessKeyResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteAccessKeyResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteAccessKeyResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteAccessKeyResponse(val *DeleteAccessKeyResponse) *NullableDeleteAccessKeyResponse { + return &NullableDeleteAccessKeyResponse{value: val, isSet: true} +} + +func (v NullableDeleteAccessKeyResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteAccessKeyResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_delete_bucket_response.go b/services/objectstorage/model_delete_bucket_response.go index bd9fc6b97..164129bbf 100644 --- a/services/objectstorage/model_delete_bucket_response.go +++ b/services/objectstorage/model_delete_bucket_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the DeleteBucketResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DeleteBucketResponse{} + // DeleteBucketResponse struct for DeleteBucketResponse type DeleteBucketResponse struct { // Name of the bucket @@ -19,3 +26,115 @@ type DeleteBucketResponse struct { // REQUIRED Project *string `json:"project"` } + +type _DeleteBucketResponse DeleteBucketResponse + +// NewDeleteBucketResponse instantiates a new DeleteBucketResponse 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 NewDeleteBucketResponse(bucket *string, project *string) *DeleteBucketResponse { + this := DeleteBucketResponse{} + this.Bucket = bucket + this.Project = project + return &this +} + +// NewDeleteBucketResponseWithDefaults instantiates a new DeleteBucketResponse 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 NewDeleteBucketResponseWithDefaults() *DeleteBucketResponse { + this := DeleteBucketResponse{} + return &this +} + +// GetBucket returns the Bucket field value +func (o *DeleteBucketResponse) GetBucket() *string { + if o == nil { + var ret *string + return ret + } + + return o.Bucket +} + +// GetBucketOk returns a tuple with the Bucket field value +// and a boolean to check if the value has been set. +func (o *DeleteBucketResponse) GetBucketOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Bucket, true +} + +// SetBucket sets field value +func (o *DeleteBucketResponse) SetBucket(v *string) { + o.Bucket = v +} + +// GetProject returns the Project field value +func (o *DeleteBucketResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *DeleteBucketResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *DeleteBucketResponse) SetProject(v *string) { + o.Project = v +} + +func (o DeleteBucketResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["bucket"] = o.Bucket + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableDeleteBucketResponse struct { + value *DeleteBucketResponse + isSet bool +} + +func (v NullableDeleteBucketResponse) Get() *DeleteBucketResponse { + return v.value +} + +func (v *NullableDeleteBucketResponse) Set(val *DeleteBucketResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteBucketResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteBucketResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteBucketResponse(val *DeleteBucketResponse) *NullableDeleteBucketResponse { + return &NullableDeleteBucketResponse{value: val, isSet: true} +} + +func (v NullableDeleteBucketResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteBucketResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_delete_credentials_group_response.go b/services/objectstorage/model_delete_credentials_group_response.go index 502dec060..53756f451 100644 --- a/services/objectstorage/model_delete_credentials_group_response.go +++ b/services/objectstorage/model_delete_credentials_group_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the DeleteCredentialsGroupResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DeleteCredentialsGroupResponse{} + // DeleteCredentialsGroupResponse struct for DeleteCredentialsGroupResponse type DeleteCredentialsGroupResponse struct { // The ID of the credentials group @@ -19,3 +26,115 @@ type DeleteCredentialsGroupResponse struct { // REQUIRED Project *string `json:"project"` } + +type _DeleteCredentialsGroupResponse DeleteCredentialsGroupResponse + +// NewDeleteCredentialsGroupResponse instantiates a new DeleteCredentialsGroupResponse 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 NewDeleteCredentialsGroupResponse(credentialsGroupId *string, project *string) *DeleteCredentialsGroupResponse { + this := DeleteCredentialsGroupResponse{} + this.CredentialsGroupId = credentialsGroupId + this.Project = project + return &this +} + +// NewDeleteCredentialsGroupResponseWithDefaults instantiates a new DeleteCredentialsGroupResponse 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 NewDeleteCredentialsGroupResponseWithDefaults() *DeleteCredentialsGroupResponse { + this := DeleteCredentialsGroupResponse{} + return &this +} + +// GetCredentialsGroupId returns the CredentialsGroupId field value +func (o *DeleteCredentialsGroupResponse) GetCredentialsGroupId() *string { + if o == nil { + var ret *string + return ret + } + + return o.CredentialsGroupId +} + +// GetCredentialsGroupIdOk returns a tuple with the CredentialsGroupId field value +// and a boolean to check if the value has been set. +func (o *DeleteCredentialsGroupResponse) GetCredentialsGroupIdOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.CredentialsGroupId, true +} + +// SetCredentialsGroupId sets field value +func (o *DeleteCredentialsGroupResponse) SetCredentialsGroupId(v *string) { + o.CredentialsGroupId = v +} + +// GetProject returns the Project field value +func (o *DeleteCredentialsGroupResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *DeleteCredentialsGroupResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *DeleteCredentialsGroupResponse) SetProject(v *string) { + o.Project = v +} + +func (o DeleteCredentialsGroupResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["credentialsGroupId"] = o.CredentialsGroupId + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableDeleteCredentialsGroupResponse struct { + value *DeleteCredentialsGroupResponse + isSet bool +} + +func (v NullableDeleteCredentialsGroupResponse) Get() *DeleteCredentialsGroupResponse { + return v.value +} + +func (v *NullableDeleteCredentialsGroupResponse) Set(val *DeleteCredentialsGroupResponse) { + v.value = val + v.isSet = true +} + +func (v NullableDeleteCredentialsGroupResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableDeleteCredentialsGroupResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDeleteCredentialsGroupResponse(val *DeleteCredentialsGroupResponse) *NullableDeleteCredentialsGroupResponse { + return &NullableDeleteCredentialsGroupResponse{value: val, isSet: true} +} + +func (v NullableDeleteCredentialsGroupResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDeleteCredentialsGroupResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_detailed_error.go b/services/objectstorage/model_detailed_error.go index 488f1a9df..f506e11c6 100644 --- a/services/objectstorage/model_detailed_error.go +++ b/services/objectstorage/model_detailed_error.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the DetailedError type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &DetailedError{} + // DetailedError struct for DetailedError type DetailedError struct { // REQUIRED @@ -17,3 +24,115 @@ type DetailedError struct { // REQUIRED Msg *string `json:"msg"` } + +type _DetailedError DetailedError + +// NewDetailedError instantiates a new DetailedError 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 NewDetailedError(key *string, msg *string) *DetailedError { + this := DetailedError{} + this.Key = key + this.Msg = msg + return &this +} + +// NewDetailedErrorWithDefaults instantiates a new DetailedError 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 NewDetailedErrorWithDefaults() *DetailedError { + this := DetailedError{} + return &this +} + +// GetKey returns the Key field value +func (o *DetailedError) GetKey() *string { + if o == nil { + var ret *string + return ret + } + + return o.Key +} + +// GetKeyOk returns a tuple with the Key field value +// and a boolean to check if the value has been set. +func (o *DetailedError) GetKeyOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Key, true +} + +// SetKey sets field value +func (o *DetailedError) SetKey(v *string) { + o.Key = v +} + +// GetMsg returns the Msg field value +func (o *DetailedError) GetMsg() *string { + if o == nil { + var ret *string + return ret + } + + return o.Msg +} + +// GetMsgOk returns a tuple with the Msg field value +// and a boolean to check if the value has been set. +func (o *DetailedError) GetMsgOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Msg, true +} + +// SetMsg sets field value +func (o *DetailedError) SetMsg(v *string) { + o.Msg = v +} + +func (o DetailedError) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["key"] = o.Key + toSerialize["msg"] = o.Msg + return toSerialize, nil +} + +type NullableDetailedError struct { + value *DetailedError + isSet bool +} + +func (v NullableDetailedError) Get() *DetailedError { + return v.value +} + +func (v *NullableDetailedError) Set(val *DetailedError) { + v.value = val + v.isSet = true +} + +func (v NullableDetailedError) IsSet() bool { + return v.isSet +} + +func (v *NullableDetailedError) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableDetailedError(val *DetailedError) *NullableDetailedError { + return &NullableDetailedError{value: val, isSet: true} +} + +func (v NullableDetailedError) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableDetailedError) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_error_message.go b/services/objectstorage/model_error_message.go index 061411a83..05944b26a 100644 --- a/services/objectstorage/model_error_message.go +++ b/services/objectstorage/model_error_message.go @@ -10,8 +10,101 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the ErrorMessage type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ErrorMessage{} + // ErrorMessage struct for ErrorMessage type ErrorMessage struct { // REQUIRED Detail *[]DetailedError `json:"detail"` } + +type _ErrorMessage ErrorMessage + +// NewErrorMessage instantiates a new ErrorMessage 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 NewErrorMessage(detail *[]DetailedError) *ErrorMessage { + this := ErrorMessage{} + this.Detail = detail + return &this +} + +// NewErrorMessageWithDefaults instantiates a new ErrorMessage 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 NewErrorMessageWithDefaults() *ErrorMessage { + this := ErrorMessage{} + return &this +} + +// GetDetail returns the Detail field value +func (o *ErrorMessage) GetDetail() *[]DetailedError { + if o == nil { + var ret *[]DetailedError + return ret + } + + return o.Detail +} + +// GetDetailOk returns a tuple with the Detail field value +// and a boolean to check if the value has been set. +func (o *ErrorMessage) GetDetailOk() (*[]DetailedError, bool) { + if o == nil { + return nil, false + } + return o.Detail, true +} + +// SetDetail sets field value +func (o *ErrorMessage) SetDetail(v *[]DetailedError) { + o.Detail = v +} + +func (o ErrorMessage) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["detail"] = o.Detail + return toSerialize, nil +} + +type NullableErrorMessage struct { + value *ErrorMessage + isSet bool +} + +func (v NullableErrorMessage) Get() *ErrorMessage { + return v.value +} + +func (v *NullableErrorMessage) Set(val *ErrorMessage) { + v.value = val + v.isSet = true +} + +func (v NullableErrorMessage) IsSet() bool { + return v.isSet +} + +func (v *NullableErrorMessage) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableErrorMessage(val *ErrorMessage) *NullableErrorMessage { + return &NullableErrorMessage{value: val, isSet: true} +} + +func (v NullableErrorMessage) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableErrorMessage) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_get_bucket_response.go b/services/objectstorage/model_get_bucket_response.go index 5f6d3e63b..60362f120 100644 --- a/services/objectstorage/model_get_bucket_response.go +++ b/services/objectstorage/model_get_bucket_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the GetBucketResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &GetBucketResponse{} + // GetBucketResponse struct for GetBucketResponse type GetBucketResponse struct { // REQUIRED @@ -18,3 +25,115 @@ type GetBucketResponse struct { // REQUIRED Project *string `json:"project"` } + +type _GetBucketResponse GetBucketResponse + +// NewGetBucketResponse instantiates a new GetBucketResponse 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 NewGetBucketResponse(bucket *Bucket, project *string) *GetBucketResponse { + this := GetBucketResponse{} + this.Bucket = bucket + this.Project = project + return &this +} + +// NewGetBucketResponseWithDefaults instantiates a new GetBucketResponse 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 NewGetBucketResponseWithDefaults() *GetBucketResponse { + this := GetBucketResponse{} + return &this +} + +// GetBucket returns the Bucket field value +func (o *GetBucketResponse) GetBucket() *Bucket { + if o == nil { + var ret *Bucket + return ret + } + + return o.Bucket +} + +// GetBucketOk returns a tuple with the Bucket field value +// and a boolean to check if the value has been set. +func (o *GetBucketResponse) GetBucketOk() (*Bucket, bool) { + if o == nil { + return nil, false + } + return o.Bucket, true +} + +// SetBucket sets field value +func (o *GetBucketResponse) SetBucket(v *Bucket) { + o.Bucket = v +} + +// GetProject returns the Project field value +func (o *GetBucketResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *GetBucketResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *GetBucketResponse) SetProject(v *string) { + o.Project = v +} + +func (o GetBucketResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["bucket"] = o.Bucket + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableGetBucketResponse struct { + value *GetBucketResponse + isSet bool +} + +func (v NullableGetBucketResponse) Get() *GetBucketResponse { + return v.value +} + +func (v *NullableGetBucketResponse) Set(val *GetBucketResponse) { + v.value = val + v.isSet = true +} + +func (v NullableGetBucketResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableGetBucketResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableGetBucketResponse(val *GetBucketResponse) *NullableGetBucketResponse { + return &NullableGetBucketResponse{value: val, isSet: true} +} + +func (v NullableGetBucketResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableGetBucketResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_http_validation_error.go b/services/objectstorage/model_http_validation_error.go index a0cd1ca58..37b6ea45c 100644 --- a/services/objectstorage/model_http_validation_error.go +++ b/services/objectstorage/model_http_validation_error.go @@ -10,7 +10,107 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the HTTPValidationError type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &HTTPValidationError{} + // HTTPValidationError struct for HTTPValidationError type HTTPValidationError struct { Detail *[]ValidationError `json:"detail,omitempty"` } + +// NewHTTPValidationError instantiates a new HTTPValidationError 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 NewHTTPValidationError() *HTTPValidationError { + this := HTTPValidationError{} + return &this +} + +// NewHTTPValidationErrorWithDefaults instantiates a new HTTPValidationError 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 NewHTTPValidationErrorWithDefaults() *HTTPValidationError { + this := HTTPValidationError{} + return &this +} + +// GetDetail returns the Detail field value if set, zero value otherwise. +func (o *HTTPValidationError) GetDetail() *[]ValidationError { + if o == nil || IsNil(o.Detail) { + var ret *[]ValidationError + return ret + } + return o.Detail +} + +// GetDetailOk returns a tuple with the Detail field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *HTTPValidationError) GetDetailOk() (*[]ValidationError, bool) { + if o == nil || IsNil(o.Detail) { + return nil, false + } + return o.Detail, true +} + +// HasDetail returns a boolean if a field has been set. +func (o *HTTPValidationError) HasDetail() bool { + if o != nil && !IsNil(o.Detail) { + return true + } + + return false +} + +// SetDetail gets a reference to the given []ValidationError and assigns it to the Detail field. +func (o *HTTPValidationError) SetDetail(v *[]ValidationError) { + o.Detail = v +} + +func (o HTTPValidationError) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + if !IsNil(o.Detail) { + toSerialize["detail"] = o.Detail + } + return toSerialize, nil +} + +type NullableHTTPValidationError struct { + value *HTTPValidationError + isSet bool +} + +func (v NullableHTTPValidationError) Get() *HTTPValidationError { + return v.value +} + +func (v *NullableHTTPValidationError) Set(val *HTTPValidationError) { + v.value = val + v.isSet = true +} + +func (v NullableHTTPValidationError) IsSet() bool { + return v.isSet +} + +func (v *NullableHTTPValidationError) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableHTTPValidationError(val *HTTPValidationError) *NullableHTTPValidationError { + return &NullableHTTPValidationError{value: val, isSet: true} +} + +func (v NullableHTTPValidationError) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableHTTPValidationError) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_list_access_keys_response.go b/services/objectstorage/model_list_access_keys_response.go index c31d52747..06aa39c2d 100644 --- a/services/objectstorage/model_list_access_keys_response.go +++ b/services/objectstorage/model_list_access_keys_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the ListAccessKeysResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ListAccessKeysResponse{} + // ListAccessKeysResponse struct for ListAccessKeysResponse type ListAccessKeysResponse struct { // REQUIRED @@ -18,3 +25,115 @@ type ListAccessKeysResponse struct { // REQUIRED Project *string `json:"project"` } + +type _ListAccessKeysResponse ListAccessKeysResponse + +// NewListAccessKeysResponse instantiates a new ListAccessKeysResponse 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 NewListAccessKeysResponse(accessKeys *[]AccessKey, project *string) *ListAccessKeysResponse { + this := ListAccessKeysResponse{} + this.AccessKeys = accessKeys + this.Project = project + return &this +} + +// NewListAccessKeysResponseWithDefaults instantiates a new ListAccessKeysResponse 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 NewListAccessKeysResponseWithDefaults() *ListAccessKeysResponse { + this := ListAccessKeysResponse{} + return &this +} + +// GetAccessKeys returns the AccessKeys field value +func (o *ListAccessKeysResponse) GetAccessKeys() *[]AccessKey { + if o == nil { + var ret *[]AccessKey + return ret + } + + return o.AccessKeys +} + +// GetAccessKeysOk returns a tuple with the AccessKeys field value +// and a boolean to check if the value has been set. +func (o *ListAccessKeysResponse) GetAccessKeysOk() (*[]AccessKey, bool) { + if o == nil { + return nil, false + } + return o.AccessKeys, true +} + +// SetAccessKeys sets field value +func (o *ListAccessKeysResponse) SetAccessKeys(v *[]AccessKey) { + o.AccessKeys = v +} + +// GetProject returns the Project field value +func (o *ListAccessKeysResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *ListAccessKeysResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *ListAccessKeysResponse) SetProject(v *string) { + o.Project = v +} + +func (o ListAccessKeysResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["accessKeys"] = o.AccessKeys + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableListAccessKeysResponse struct { + value *ListAccessKeysResponse + isSet bool +} + +func (v NullableListAccessKeysResponse) Get() *ListAccessKeysResponse { + return v.value +} + +func (v *NullableListAccessKeysResponse) Set(val *ListAccessKeysResponse) { + v.value = val + v.isSet = true +} + +func (v NullableListAccessKeysResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableListAccessKeysResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListAccessKeysResponse(val *ListAccessKeysResponse) *NullableListAccessKeysResponse { + return &NullableListAccessKeysResponse{value: val, isSet: true} +} + +func (v NullableListAccessKeysResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListAccessKeysResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_list_buckets_response.go b/services/objectstorage/model_list_buckets_response.go index 2d78cf9bd..50294d3aa 100644 --- a/services/objectstorage/model_list_buckets_response.go +++ b/services/objectstorage/model_list_buckets_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the ListBucketsResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ListBucketsResponse{} + // ListBucketsResponse struct for ListBucketsResponse type ListBucketsResponse struct { // REQUIRED @@ -18,3 +25,115 @@ type ListBucketsResponse struct { // REQUIRED Project *string `json:"project"` } + +type _ListBucketsResponse ListBucketsResponse + +// NewListBucketsResponse instantiates a new ListBucketsResponse 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 NewListBucketsResponse(buckets *[]Bucket, project *string) *ListBucketsResponse { + this := ListBucketsResponse{} + this.Buckets = buckets + this.Project = project + return &this +} + +// NewListBucketsResponseWithDefaults instantiates a new ListBucketsResponse 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 NewListBucketsResponseWithDefaults() *ListBucketsResponse { + this := ListBucketsResponse{} + return &this +} + +// GetBuckets returns the Buckets field value +func (o *ListBucketsResponse) GetBuckets() *[]Bucket { + if o == nil { + var ret *[]Bucket + return ret + } + + return o.Buckets +} + +// GetBucketsOk returns a tuple with the Buckets field value +// and a boolean to check if the value has been set. +func (o *ListBucketsResponse) GetBucketsOk() (*[]Bucket, bool) { + if o == nil { + return nil, false + } + return o.Buckets, true +} + +// SetBuckets sets field value +func (o *ListBucketsResponse) SetBuckets(v *[]Bucket) { + o.Buckets = v +} + +// GetProject returns the Project field value +func (o *ListBucketsResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *ListBucketsResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *ListBucketsResponse) SetProject(v *string) { + o.Project = v +} + +func (o ListBucketsResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["buckets"] = o.Buckets + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableListBucketsResponse struct { + value *ListBucketsResponse + isSet bool +} + +func (v NullableListBucketsResponse) Get() *ListBucketsResponse { + return v.value +} + +func (v *NullableListBucketsResponse) Set(val *ListBucketsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableListBucketsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableListBucketsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListBucketsResponse(val *ListBucketsResponse) *NullableListBucketsResponse { + return &NullableListBucketsResponse{value: val, isSet: true} +} + +func (v NullableListBucketsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListBucketsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_list_credentials_groups_response.go b/services/objectstorage/model_list_credentials_groups_response.go index f4da4f3df..067bac162 100644 --- a/services/objectstorage/model_list_credentials_groups_response.go +++ b/services/objectstorage/model_list_credentials_groups_response.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the ListCredentialsGroupsResponse type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ListCredentialsGroupsResponse{} + // ListCredentialsGroupsResponse struct for ListCredentialsGroupsResponse type ListCredentialsGroupsResponse struct { // REQUIRED @@ -18,3 +25,115 @@ type ListCredentialsGroupsResponse struct { // REQUIRED Project *string `json:"project"` } + +type _ListCredentialsGroupsResponse ListCredentialsGroupsResponse + +// NewListCredentialsGroupsResponse instantiates a new ListCredentialsGroupsResponse 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 NewListCredentialsGroupsResponse(credentialsGroups *[]CredentialsGroup, project *string) *ListCredentialsGroupsResponse { + this := ListCredentialsGroupsResponse{} + this.CredentialsGroups = credentialsGroups + this.Project = project + return &this +} + +// NewListCredentialsGroupsResponseWithDefaults instantiates a new ListCredentialsGroupsResponse 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 NewListCredentialsGroupsResponseWithDefaults() *ListCredentialsGroupsResponse { + this := ListCredentialsGroupsResponse{} + return &this +} + +// GetCredentialsGroups returns the CredentialsGroups field value +func (o *ListCredentialsGroupsResponse) GetCredentialsGroups() *[]CredentialsGroup { + if o == nil { + var ret *[]CredentialsGroup + return ret + } + + return o.CredentialsGroups +} + +// GetCredentialsGroupsOk returns a tuple with the CredentialsGroups field value +// and a boolean to check if the value has been set. +func (o *ListCredentialsGroupsResponse) GetCredentialsGroupsOk() (*[]CredentialsGroup, bool) { + if o == nil { + return nil, false + } + return o.CredentialsGroups, true +} + +// SetCredentialsGroups sets field value +func (o *ListCredentialsGroupsResponse) SetCredentialsGroups(v *[]CredentialsGroup) { + o.CredentialsGroups = v +} + +// GetProject returns the Project field value +func (o *ListCredentialsGroupsResponse) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *ListCredentialsGroupsResponse) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *ListCredentialsGroupsResponse) SetProject(v *string) { + o.Project = v +} + +func (o ListCredentialsGroupsResponse) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["credentialsGroups"] = o.CredentialsGroups + toSerialize["project"] = o.Project + return toSerialize, nil +} + +type NullableListCredentialsGroupsResponse struct { + value *ListCredentialsGroupsResponse + isSet bool +} + +func (v NullableListCredentialsGroupsResponse) Get() *ListCredentialsGroupsResponse { + return v.value +} + +func (v *NullableListCredentialsGroupsResponse) Set(val *ListCredentialsGroupsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableListCredentialsGroupsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableListCredentialsGroupsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableListCredentialsGroupsResponse(val *ListCredentialsGroupsResponse) *NullableListCredentialsGroupsResponse { + return &NullableListCredentialsGroupsResponse{value: val, isSet: true} +} + +func (v NullableListCredentialsGroupsResponse) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableListCredentialsGroupsResponse) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_project_status.go b/services/objectstorage/model_project_status.go index 8186d0239..b13c80642 100644 --- a/services/objectstorage/model_project_status.go +++ b/services/objectstorage/model_project_status.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the ProjectStatus type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ProjectStatus{} + // ProjectStatus struct for ProjectStatus type ProjectStatus struct { // Project ID @@ -18,3 +25,115 @@ type ProjectStatus struct { // REQUIRED Scope *ProjectScope `json:"scope"` } + +type _ProjectStatus ProjectStatus + +// NewProjectStatus instantiates a new ProjectStatus 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 NewProjectStatus(project *string, scope *ProjectScope) *ProjectStatus { + this := ProjectStatus{} + this.Project = project + this.Scope = scope + return &this +} + +// NewProjectStatusWithDefaults instantiates a new ProjectStatus 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 NewProjectStatusWithDefaults() *ProjectStatus { + this := ProjectStatus{} + return &this +} + +// GetProject returns the Project field value +func (o *ProjectStatus) GetProject() *string { + if o == nil { + var ret *string + return ret + } + + return o.Project +} + +// GetProjectOk returns a tuple with the Project field value +// and a boolean to check if the value has been set. +func (o *ProjectStatus) GetProjectOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Project, true +} + +// SetProject sets field value +func (o *ProjectStatus) SetProject(v *string) { + o.Project = v +} + +// GetScope returns the Scope field value +func (o *ProjectStatus) GetScope() *ProjectScope { + if o == nil { + var ret *ProjectScope + return ret + } + + return o.Scope +} + +// GetScopeOk returns a tuple with the Scope field value +// and a boolean to check if the value has been set. +func (o *ProjectStatus) GetScopeOk() (*ProjectScope, bool) { + if o == nil { + return nil, false + } + return o.Scope, true +} + +// SetScope sets field value +func (o *ProjectStatus) SetScope(v *ProjectScope) { + o.Scope = v +} + +func (o ProjectStatus) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["project"] = o.Project + toSerialize["scope"] = o.Scope + return toSerialize, nil +} + +type NullableProjectStatus struct { + value *ProjectStatus + isSet bool +} + +func (v NullableProjectStatus) Get() *ProjectStatus { + return v.value +} + +func (v *NullableProjectStatus) Set(val *ProjectStatus) { + v.value = val + v.isSet = true +} + +func (v NullableProjectStatus) IsSet() bool { + return v.isSet +} + +func (v *NullableProjectStatus) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableProjectStatus(val *ProjectStatus) *NullableProjectStatus { + return &NullableProjectStatus{value: val, isSet: true} +} + +func (v NullableProjectStatus) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableProjectStatus) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/services/objectstorage/model_validation_error.go b/services/objectstorage/model_validation_error.go index 711f213b7..ce44aae1c 100644 --- a/services/objectstorage/model_validation_error.go +++ b/services/objectstorage/model_validation_error.go @@ -10,6 +10,13 @@ API version: 1.0.9 package objectstorage +import ( + "encoding/json" +) + +// checks if the ValidationError type satisfies the MappedNullable interface at compile time +var _ MappedNullable = &ValidationError{} + // ValidationError struct for ValidationError type ValidationError struct { // REQUIRED @@ -19,3 +26,141 @@ type ValidationError struct { // REQUIRED Type *string `json:"type"` } + +type _ValidationError ValidationError + +// NewValidationError instantiates a new ValidationError 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 NewValidationError(loc *[]LocationInner, msg *string, type_ *string) *ValidationError { + this := ValidationError{} + this.Loc = loc + this.Msg = msg + this.Type = type_ + return &this +} + +// NewValidationErrorWithDefaults instantiates a new ValidationError 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 NewValidationErrorWithDefaults() *ValidationError { + this := ValidationError{} + return &this +} + +// GetLoc returns the Loc field value +func (o *ValidationError) GetLoc() *[]LocationInner { + if o == nil { + var ret *[]LocationInner + return ret + } + + return o.Loc +} + +// GetLocOk returns a tuple with the Loc field value +// and a boolean to check if the value has been set. +func (o *ValidationError) GetLocOk() (*[]LocationInner, bool) { + if o == nil { + return nil, false + } + return o.Loc, true +} + +// SetLoc sets field value +func (o *ValidationError) SetLoc(v *[]LocationInner) { + o.Loc = v +} + +// GetMsg returns the Msg field value +func (o *ValidationError) GetMsg() *string { + if o == nil { + var ret *string + return ret + } + + return o.Msg +} + +// GetMsgOk returns a tuple with the Msg field value +// and a boolean to check if the value has been set. +func (o *ValidationError) GetMsgOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Msg, true +} + +// SetMsg sets field value +func (o *ValidationError) SetMsg(v *string) { + o.Msg = v +} + +// GetType returns the Type field value +func (o *ValidationError) GetType() *string { + if o == nil { + var ret *string + return ret + } + + return o.Type +} + +// GetTypeOk returns a tuple with the Type field value +// and a boolean to check if the value has been set. +func (o *ValidationError) GetTypeOk() (*string, bool) { + if o == nil { + return nil, false + } + return o.Type, true +} + +// SetType sets field value +func (o *ValidationError) SetType(v *string) { + o.Type = v +} + +func (o ValidationError) ToMap() (map[string]interface{}, error) { + toSerialize := map[string]interface{}{} + toSerialize["loc"] = o.Loc + toSerialize["msg"] = o.Msg + toSerialize["type"] = o.Type + return toSerialize, nil +} + +type NullableValidationError struct { + value *ValidationError + isSet bool +} + +func (v NullableValidationError) Get() *ValidationError { + return v.value +} + +func (v *NullableValidationError) Set(val *ValidationError) { + v.value = val + v.isSet = true +} + +func (v NullableValidationError) IsSet() bool { + return v.isSet +} + +func (v *NullableValidationError) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableValidationError(val *ValidationError) *NullableValidationError { + return &NullableValidationError{value: val, isSet: true} +} + +func (v NullableValidationError) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableValidationError) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} From 622b01331404ded141c975f9dbcb0d0ba6e1a341 Mon Sep 17 00:00:00 2001 From: Vicente Pinto Date: Fri, 11 Oct 2024 18:46:24 +0100 Subject: [PATCH 2/2] Update changelog --- services/objectstorage/CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/services/objectstorage/CHANGELOG.md b/services/objectstorage/CHANGELOG.md index 36a70ad57..de6605e70 100644 --- a/services/objectstorage/CHANGELOG.md +++ b/services/objectstorage/CHANGELOG.md @@ -1,3 +1,7 @@ +## v0.11.0 (2024-10-14) + +- **Feature:** Add support for nullable models + ## v0.10.0 (2024-06-14) - **Breaking change**: Remove unused data types.