garage-admin-sdk-golang/model_update_bucket_request_website_access.go

188 lines
6 KiB
Go
Raw Normal View History

2022-11-13 13:22:00 +00:00
/*
Garage Administration API v0+garage-v0.8.0
Administrate your Garage cluster programatically, including status, layout, keys, buckets, and maintainance tasks. *Disclaimer: The API is not stable yet, hence its v0 tag. The API can change at any time, and changes can include breaking backward compatibility. Read the changelog and upgrade your scripts before upgrading. Additionnaly, this specification is very early stage and can contain bugs, especially on error return codes/types that are not tested yet. Do not expect a well finished and polished product!*
API version: v0.8.0
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package garage
import (
"encoding/json"
)
// UpdateBucketRequestWebsiteAccess struct for UpdateBucketRequestWebsiteAccess
type UpdateBucketRequestWebsiteAccess struct {
Enabled *bool `json:"enabled,omitempty"`
IndexDocument *string `json:"indexDocument,omitempty"`
ErrorDocument *string `json:"errorDocument,omitempty"`
}
// NewUpdateBucketRequestWebsiteAccess instantiates a new UpdateBucketRequestWebsiteAccess 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 NewUpdateBucketRequestWebsiteAccess() *UpdateBucketRequestWebsiteAccess {
this := UpdateBucketRequestWebsiteAccess{}
return &this
}
// NewUpdateBucketRequestWebsiteAccessWithDefaults instantiates a new UpdateBucketRequestWebsiteAccess 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 NewUpdateBucketRequestWebsiteAccessWithDefaults() *UpdateBucketRequestWebsiteAccess {
this := UpdateBucketRequestWebsiteAccess{}
return &this
}
// GetEnabled returns the Enabled field value if set, zero value otherwise.
func (o *UpdateBucketRequestWebsiteAccess) GetEnabled() bool {
if o == nil || o.Enabled == nil {
var ret bool
return ret
}
return *o.Enabled
}
// GetEnabledOk returns a tuple with the Enabled field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *UpdateBucketRequestWebsiteAccess) GetEnabledOk() (*bool, bool) {
if o == nil || o.Enabled == nil {
return nil, false
}
return o.Enabled, true
}
// HasEnabled returns a boolean if a field has been set.
func (o *UpdateBucketRequestWebsiteAccess) HasEnabled() bool {
if o != nil && o.Enabled != nil {
return true
}
return false
}
// SetEnabled gets a reference to the given bool and assigns it to the Enabled field.
func (o *UpdateBucketRequestWebsiteAccess) SetEnabled(v bool) {
o.Enabled = &v
}
// GetIndexDocument returns the IndexDocument field value if set, zero value otherwise.
func (o *UpdateBucketRequestWebsiteAccess) GetIndexDocument() string {
if o == nil || o.IndexDocument == nil {
var ret string
return ret
}
return *o.IndexDocument
}
// GetIndexDocumentOk returns a tuple with the IndexDocument field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *UpdateBucketRequestWebsiteAccess) GetIndexDocumentOk() (*string, bool) {
if o == nil || o.IndexDocument == nil {
return nil, false
}
return o.IndexDocument, true
}
// HasIndexDocument returns a boolean if a field has been set.
func (o *UpdateBucketRequestWebsiteAccess) HasIndexDocument() bool {
if o != nil && o.IndexDocument != nil {
return true
}
return false
}
// SetIndexDocument gets a reference to the given string and assigns it to the IndexDocument field.
func (o *UpdateBucketRequestWebsiteAccess) SetIndexDocument(v string) {
o.IndexDocument = &v
}
// GetErrorDocument returns the ErrorDocument field value if set, zero value otherwise.
func (o *UpdateBucketRequestWebsiteAccess) GetErrorDocument() string {
if o == nil || o.ErrorDocument == nil {
var ret string
return ret
}
return *o.ErrorDocument
}
// GetErrorDocumentOk returns a tuple with the ErrorDocument field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *UpdateBucketRequestWebsiteAccess) GetErrorDocumentOk() (*string, bool) {
if o == nil || o.ErrorDocument == nil {
return nil, false
}
return o.ErrorDocument, true
}
// HasErrorDocument returns a boolean if a field has been set.
func (o *UpdateBucketRequestWebsiteAccess) HasErrorDocument() bool {
if o != nil && o.ErrorDocument != nil {
return true
}
return false
}
// SetErrorDocument gets a reference to the given string and assigns it to the ErrorDocument field.
func (o *UpdateBucketRequestWebsiteAccess) SetErrorDocument(v string) {
o.ErrorDocument = &v
}
func (o UpdateBucketRequestWebsiteAccess) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
if o.Enabled != nil {
toSerialize["enabled"] = o.Enabled
}
if o.IndexDocument != nil {
toSerialize["indexDocument"] = o.IndexDocument
}
if o.ErrorDocument != nil {
toSerialize["errorDocument"] = o.ErrorDocument
}
return json.Marshal(toSerialize)
}
type NullableUpdateBucketRequestWebsiteAccess struct {
value *UpdateBucketRequestWebsiteAccess
isSet bool
}
func (v NullableUpdateBucketRequestWebsiteAccess) Get() *UpdateBucketRequestWebsiteAccess {
return v.value
}
func (v *NullableUpdateBucketRequestWebsiteAccess) Set(val *UpdateBucketRequestWebsiteAccess) {
v.value = val
v.isSet = true
}
func (v NullableUpdateBucketRequestWebsiteAccess) IsSet() bool {
return v.isSet
}
func (v *NullableUpdateBucketRequestWebsiteAccess) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableUpdateBucketRequestWebsiteAccess(val *UpdateBucketRequestWebsiteAccess) *NullableUpdateBucketRequestWebsiteAccess {
return &NullableUpdateBucketRequestWebsiteAccess{value: val, isSet: true}
}
func (v NullableUpdateBucketRequestWebsiteAccess) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableUpdateBucketRequestWebsiteAccess) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}