Files
sdk/model_o11y_ann_queue_list.go

193 lines
4.9 KiB
Go

/*
Hanzo Cloud API
The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
API version: v1
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package hanzoai
import (
"encoding/json"
)
// checks if the O11yAnnQueueList type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &O11yAnnQueueList{}
// O11yAnnQueueList struct for O11yAnnQueueList
type O11yAnnQueueList struct {
// Data is the page of queues.
Data []O11yAnnQueueView `json:"data,omitempty"`
// Meta is the paging that produced it.
Meta *O11yListMeta `json:"meta,omitempty"`
AdditionalProperties map[string]interface{}
}
type _O11yAnnQueueList O11yAnnQueueList
// NewO11yAnnQueueList instantiates a new O11yAnnQueueList 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 NewO11yAnnQueueList() *O11yAnnQueueList {
this := O11yAnnQueueList{}
return &this
}
// NewO11yAnnQueueListWithDefaults instantiates a new O11yAnnQueueList 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 NewO11yAnnQueueListWithDefaults() *O11yAnnQueueList {
this := O11yAnnQueueList{}
return &this
}
// GetData returns the Data field value if set, zero value otherwise.
func (o *O11yAnnQueueList) GetData() []O11yAnnQueueView {
if o == nil || IsNil(o.Data) {
var ret []O11yAnnQueueView
return ret
}
return o.Data
}
// GetDataOk returns a tuple with the Data field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *O11yAnnQueueList) GetDataOk() ([]O11yAnnQueueView, bool) {
if o == nil || IsNil(o.Data) {
return nil, false
}
return o.Data, true
}
// HasData returns a boolean if a field has been set.
func (o *O11yAnnQueueList) HasData() bool {
if o != nil && !IsNil(o.Data) {
return true
}
return false
}
// SetData gets a reference to the given []O11yAnnQueueView and assigns it to the Data field.
func (o *O11yAnnQueueList) SetData(v []O11yAnnQueueView) {
o.Data = v
}
// GetMeta returns the Meta field value if set, zero value otherwise.
func (o *O11yAnnQueueList) GetMeta() O11yListMeta {
if o == nil || IsNil(o.Meta) {
var ret O11yListMeta
return ret
}
return *o.Meta
}
// GetMetaOk returns a tuple with the Meta field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *O11yAnnQueueList) GetMetaOk() (*O11yListMeta, bool) {
if o == nil || IsNil(o.Meta) {
return nil, false
}
return o.Meta, true
}
// HasMeta returns a boolean if a field has been set.
func (o *O11yAnnQueueList) HasMeta() bool {
if o != nil && !IsNil(o.Meta) {
return true
}
return false
}
// SetMeta gets a reference to the given O11yListMeta and assigns it to the Meta field.
func (o *O11yAnnQueueList) SetMeta(v O11yListMeta) {
o.Meta = &v
}
func (o O11yAnnQueueList) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o O11yAnnQueueList) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.Data) {
toSerialize["data"] = o.Data
}
if !IsNil(o.Meta) {
toSerialize["meta"] = o.Meta
}
for key, value := range o.AdditionalProperties {
toSerialize[key] = value
}
return toSerialize, nil
}
func (o *O11yAnnQueueList) UnmarshalJSON(data []byte) (err error) {
varO11yAnnQueueList := _O11yAnnQueueList{}
err = json.Unmarshal(data, &varO11yAnnQueueList)
if err != nil {
return err
}
*o = O11yAnnQueueList(varO11yAnnQueueList)
additionalProperties := make(map[string]interface{})
if err = json.Unmarshal(data, &additionalProperties); err == nil {
delete(additionalProperties, "data")
delete(additionalProperties, "meta")
o.AdditionalProperties = additionalProperties
}
return err
}
type NullableO11yAnnQueueList struct {
value *O11yAnnQueueList
isSet bool
}
func (v NullableO11yAnnQueueList) Get() *O11yAnnQueueList {
return v.value
}
func (v *NullableO11yAnnQueueList) Set(val *O11yAnnQueueList) {
v.value = val
v.isSet = true
}
func (v NullableO11yAnnQueueList) IsSet() bool {
return v.isSet
}
func (v *NullableO11yAnnQueueList) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableO11yAnnQueueList(val *O11yAnnQueueList) *NullableO11yAnnQueueList {
return &NullableO11yAnnQueueList{value: val, isSet: true}
}
func (v NullableO11yAnnQueueList) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableO11yAnnQueueList) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}