/* STACKIT Logs API This API provides endpoints for managing STACKIT Logs. API version: 1alpha.0.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. package logsalpha import ( "encoding/json" ) // checks if the UpdateLogsInstancePayload type satisfies the MappedNullable interface at compile time var _ MappedNullable = &UpdateLogsInstancePayload{} /* types and functions for acl */ // isArray type UpdateLogsInstancePayloadGetAclAttributeType = *[]string type UpdateLogsInstancePayloadGetAclArgType = []string type UpdateLogsInstancePayloadGetAclRetType = []string func getUpdateLogsInstancePayloadGetAclAttributeTypeOk(arg UpdateLogsInstancePayloadGetAclAttributeType) (ret UpdateLogsInstancePayloadGetAclRetType, ok bool) { if arg == nil { return ret, false } return *arg, true } func setUpdateLogsInstancePayloadGetAclAttributeType(arg *UpdateLogsInstancePayloadGetAclAttributeType, val UpdateLogsInstancePayloadGetAclRetType) { *arg = &val } /* types and functions for description */ // isNotNullableString type UpdateLogsInstancePayloadGetDescriptionAttributeType = *string func getUpdateLogsInstancePayloadGetDescriptionAttributeTypeOk(arg UpdateLogsInstancePayloadGetDescriptionAttributeType) (ret UpdateLogsInstancePayloadGetDescriptionRetType, ok bool) { if arg == nil { return ret, false } return *arg, true } func setUpdateLogsInstancePayloadGetDescriptionAttributeType(arg *UpdateLogsInstancePayloadGetDescriptionAttributeType, val UpdateLogsInstancePayloadGetDescriptionRetType) { *arg = &val } type UpdateLogsInstancePayloadGetDescriptionArgType = string type UpdateLogsInstancePayloadGetDescriptionRetType = string /* types and functions for displayName */ // isNotNullableString type UpdateLogsInstancePayloadGetDisplayNameAttributeType = *string func getUpdateLogsInstancePayloadGetDisplayNameAttributeTypeOk(arg UpdateLogsInstancePayloadGetDisplayNameAttributeType) (ret UpdateLogsInstancePayloadGetDisplayNameRetType, ok bool) { if arg == nil { return ret, false } return *arg, true } func setUpdateLogsInstancePayloadGetDisplayNameAttributeType(arg *UpdateLogsInstancePayloadGetDisplayNameAttributeType, val UpdateLogsInstancePayloadGetDisplayNameRetType) { *arg = &val } type UpdateLogsInstancePayloadGetDisplayNameArgType = string type UpdateLogsInstancePayloadGetDisplayNameRetType = string /* types and functions for retentionDays */ // isInteger type UpdateLogsInstancePayloadGetRetentionDaysAttributeType = *int64 type UpdateLogsInstancePayloadGetRetentionDaysArgType = int64 type UpdateLogsInstancePayloadGetRetentionDaysRetType = int64 func getUpdateLogsInstancePayloadGetRetentionDaysAttributeTypeOk(arg UpdateLogsInstancePayloadGetRetentionDaysAttributeType) (ret UpdateLogsInstancePayloadGetRetentionDaysRetType, ok bool) { if arg == nil { return ret, false } return *arg, true } func setUpdateLogsInstancePayloadGetRetentionDaysAttributeType(arg *UpdateLogsInstancePayloadGetRetentionDaysAttributeType, val UpdateLogsInstancePayloadGetRetentionDaysRetType) { *arg = &val } // UpdateLogsInstancePayload struct for UpdateLogsInstancePayload type UpdateLogsInstancePayload struct { // The access control list for the Logs instance. Acl UpdateLogsInstancePayloadGetAclAttributeType `json:"acl,omitempty"` // The description of the Logs instance. Description UpdateLogsInstancePayloadGetDescriptionAttributeType `json:"description,omitempty"` // The displayed name to distinguish multiple Logs instances. DisplayName UpdateLogsInstancePayloadGetDisplayNameAttributeType `json:"displayName,omitempty"` // The log retention time in days. // Can be cast to int32 without loss of precision. RetentionDays UpdateLogsInstancePayloadGetRetentionDaysAttributeType `json:"retentionDays,omitempty"` } // NewUpdateLogsInstancePayload instantiates a new UpdateLogsInstancePayload 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 NewUpdateLogsInstancePayload() *UpdateLogsInstancePayload { this := UpdateLogsInstancePayload{} return &this } // NewUpdateLogsInstancePayloadWithDefaults instantiates a new UpdateLogsInstancePayload 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 NewUpdateLogsInstancePayloadWithDefaults() *UpdateLogsInstancePayload { this := UpdateLogsInstancePayload{} return &this } // GetAcl returns the Acl field value if set, zero value otherwise. func (o *UpdateLogsInstancePayload) GetAcl() (res UpdateLogsInstancePayloadGetAclRetType) { res, _ = o.GetAclOk() return } // GetAclOk returns a tuple with the Acl field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *UpdateLogsInstancePayload) GetAclOk() (ret UpdateLogsInstancePayloadGetAclRetType, ok bool) { return getUpdateLogsInstancePayloadGetAclAttributeTypeOk(o.Acl) } // HasAcl returns a boolean if a field has been set. func (o *UpdateLogsInstancePayload) HasAcl() bool { _, ok := o.GetAclOk() return ok } // SetAcl gets a reference to the given []string and assigns it to the Acl field. func (o *UpdateLogsInstancePayload) SetAcl(v UpdateLogsInstancePayloadGetAclRetType) { setUpdateLogsInstancePayloadGetAclAttributeType(&o.Acl, v) } // GetDescription returns the Description field value if set, zero value otherwise. func (o *UpdateLogsInstancePayload) GetDescription() (res UpdateLogsInstancePayloadGetDescriptionRetType) { res, _ = o.GetDescriptionOk() return } // GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *UpdateLogsInstancePayload) GetDescriptionOk() (ret UpdateLogsInstancePayloadGetDescriptionRetType, ok bool) { return getUpdateLogsInstancePayloadGetDescriptionAttributeTypeOk(o.Description) } // HasDescription returns a boolean if a field has been set. func (o *UpdateLogsInstancePayload) HasDescription() bool { _, ok := o.GetDescriptionOk() return ok } // SetDescription gets a reference to the given string and assigns it to the Description field. func (o *UpdateLogsInstancePayload) SetDescription(v UpdateLogsInstancePayloadGetDescriptionRetType) { setUpdateLogsInstancePayloadGetDescriptionAttributeType(&o.Description, v) } // GetDisplayName returns the DisplayName field value if set, zero value otherwise. func (o *UpdateLogsInstancePayload) GetDisplayName() (res UpdateLogsInstancePayloadGetDisplayNameRetType) { res, _ = o.GetDisplayNameOk() return } // GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *UpdateLogsInstancePayload) GetDisplayNameOk() (ret UpdateLogsInstancePayloadGetDisplayNameRetType, ok bool) { return getUpdateLogsInstancePayloadGetDisplayNameAttributeTypeOk(o.DisplayName) } // HasDisplayName returns a boolean if a field has been set. func (o *UpdateLogsInstancePayload) HasDisplayName() bool { _, ok := o.GetDisplayNameOk() return ok } // SetDisplayName gets a reference to the given string and assigns it to the DisplayName field. func (o *UpdateLogsInstancePayload) SetDisplayName(v UpdateLogsInstancePayloadGetDisplayNameRetType) { setUpdateLogsInstancePayloadGetDisplayNameAttributeType(&o.DisplayName, v) } // GetRetentionDays returns the RetentionDays field value if set, zero value otherwise. func (o *UpdateLogsInstancePayload) GetRetentionDays() (res UpdateLogsInstancePayloadGetRetentionDaysRetType) { res, _ = o.GetRetentionDaysOk() return } // GetRetentionDaysOk returns a tuple with the RetentionDays field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *UpdateLogsInstancePayload) GetRetentionDaysOk() (ret UpdateLogsInstancePayloadGetRetentionDaysRetType, ok bool) { return getUpdateLogsInstancePayloadGetRetentionDaysAttributeTypeOk(o.RetentionDays) } // HasRetentionDays returns a boolean if a field has been set. func (o *UpdateLogsInstancePayload) HasRetentionDays() bool { _, ok := o.GetRetentionDaysOk() return ok } // SetRetentionDays gets a reference to the given int64 and assigns it to the RetentionDays field. func (o *UpdateLogsInstancePayload) SetRetentionDays(v UpdateLogsInstancePayloadGetRetentionDaysRetType) { setUpdateLogsInstancePayloadGetRetentionDaysAttributeType(&o.RetentionDays, v) } func (o UpdateLogsInstancePayload) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} if val, ok := getUpdateLogsInstancePayloadGetAclAttributeTypeOk(o.Acl); ok { toSerialize["Acl"] = val } if val, ok := getUpdateLogsInstancePayloadGetDescriptionAttributeTypeOk(o.Description); ok { toSerialize["Description"] = val } if val, ok := getUpdateLogsInstancePayloadGetDisplayNameAttributeTypeOk(o.DisplayName); ok { toSerialize["DisplayName"] = val } if val, ok := getUpdateLogsInstancePayloadGetRetentionDaysAttributeTypeOk(o.RetentionDays); ok { toSerialize["RetentionDays"] = val } return toSerialize, nil } type NullableUpdateLogsInstancePayload struct { value *UpdateLogsInstancePayload isSet bool } func (v NullableUpdateLogsInstancePayload) Get() *UpdateLogsInstancePayload { return v.value } func (v *NullableUpdateLogsInstancePayload) Set(val *UpdateLogsInstancePayload) { v.value = val v.isSet = true } func (v NullableUpdateLogsInstancePayload) IsSet() bool { return v.isSet } func (v *NullableUpdateLogsInstancePayload) Unset() { v.value = nil v.isSet = false } func NewNullableUpdateLogsInstancePayload(val *UpdateLogsInstancePayload) *NullableUpdateLogsInstancePayload { return &NullableUpdateLogsInstancePayload{value: val, isSet: true} } func (v NullableUpdateLogsInstancePayload) MarshalJSON() ([]byte, error) { return json.Marshal(v.value) } func (v *NullableUpdateLogsInstancePayload) UnmarshalJSON(src []byte) error { v.isSet = true return json.Unmarshal(src, &v.value) }