/* * Subset of Influx API covered by Influx CLI * * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * API version: 2.0.0 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. package api import ( "encoding/json" ) // TelegrafRequestMetadata struct for TelegrafRequestMetadata type TelegrafRequestMetadata struct { Buckets *[]string `json:"buckets,omitempty" yaml:"buckets,omitempty"` } // NewTelegrafRequestMetadata instantiates a new TelegrafRequestMetadata 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 NewTelegrafRequestMetadata() *TelegrafRequestMetadata { this := TelegrafRequestMetadata{} return &this } // NewTelegrafRequestMetadataWithDefaults instantiates a new TelegrafRequestMetadata 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 NewTelegrafRequestMetadataWithDefaults() *TelegrafRequestMetadata { this := TelegrafRequestMetadata{} return &this } // GetBuckets returns the Buckets field value if set, zero value otherwise. func (o *TelegrafRequestMetadata) GetBuckets() []string { if o == nil || o.Buckets == nil { var ret []string return ret } return *o.Buckets } // GetBucketsOk returns a tuple with the Buckets field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *TelegrafRequestMetadata) GetBucketsOk() (*[]string, bool) { if o == nil || o.Buckets == nil { return nil, false } return o.Buckets, true } // HasBuckets returns a boolean if a field has been set. func (o *TelegrafRequestMetadata) HasBuckets() bool { if o != nil && o.Buckets != nil { return true } return false } // SetBuckets gets a reference to the given []string and assigns it to the Buckets field. func (o *TelegrafRequestMetadata) SetBuckets(v []string) { o.Buckets = &v } func (o TelegrafRequestMetadata) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} if o.Buckets != nil { toSerialize["buckets"] = o.Buckets } return json.Marshal(toSerialize) } type NullableTelegrafRequestMetadata struct { value *TelegrafRequestMetadata isSet bool } func (v NullableTelegrafRequestMetadata) Get() *TelegrafRequestMetadata { return v.value } func (v *NullableTelegrafRequestMetadata) Set(val *TelegrafRequestMetadata) { v.value = val v.isSet = true } func (v NullableTelegrafRequestMetadata) IsSet() bool { return v.isSet } func (v *NullableTelegrafRequestMetadata) Unset() { v.value = nil v.isSet = false } func NewNullableTelegrafRequestMetadata(val *TelegrafRequestMetadata) *NullableTelegrafRequestMetadata { return &NullableTelegrafRequestMetadata{value: val, isSet: true} } func (v NullableTelegrafRequestMetadata) MarshalJSON() ([]byte, error) { return json.Marshal(v.value) } func (v *NullableTelegrafRequestMetadata) UnmarshalJSON(src []byte) error { v.isSet = true return json.Unmarshal(src, &v.value) }