mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
376 lines
10 KiB
Go
376 lines
10 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 O11yPostableNamespaces type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &O11yPostableNamespaces{}
|
|
|
|
// O11yPostableNamespaces struct for O11yPostableNamespaces
|
|
type O11yPostableNamespaces struct {
|
|
End *int64 `json:"end,omitempty"`
|
|
Filter *O11yFilter `json:"filter,omitempty"`
|
|
GroupBy []O11yGroupByKey `json:"groupBy,omitempty"`
|
|
Limit *int64 `json:"limit,omitempty"`
|
|
Offset *int64 `json:"offset,omitempty"`
|
|
OrderBy *O11yQuerybuildertypesv5OrderBy `json:"orderBy,omitempty"`
|
|
Start *int64 `json:"start,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _O11yPostableNamespaces O11yPostableNamespaces
|
|
|
|
// NewO11yPostableNamespaces instantiates a new O11yPostableNamespaces 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 NewO11yPostableNamespaces() *O11yPostableNamespaces {
|
|
this := O11yPostableNamespaces{}
|
|
return &this
|
|
}
|
|
|
|
// NewO11yPostableNamespacesWithDefaults instantiates a new O11yPostableNamespaces 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 NewO11yPostableNamespacesWithDefaults() *O11yPostableNamespaces {
|
|
this := O11yPostableNamespaces{}
|
|
return &this
|
|
}
|
|
|
|
// GetEnd returns the End field value if set, zero value otherwise.
|
|
func (o *O11yPostableNamespaces) GetEnd() int64 {
|
|
if o == nil || IsNil(o.End) {
|
|
var ret int64
|
|
return ret
|
|
}
|
|
return *o.End
|
|
}
|
|
|
|
// GetEndOk returns a tuple with the End field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yPostableNamespaces) GetEndOk() (*int64, bool) {
|
|
if o == nil || IsNil(o.End) {
|
|
return nil, false
|
|
}
|
|
return o.End, true
|
|
}
|
|
|
|
// HasEnd returns a boolean if a field has been set.
|
|
func (o *O11yPostableNamespaces) HasEnd() bool {
|
|
if o != nil && !IsNil(o.End) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetEnd gets a reference to the given int64 and assigns it to the End field.
|
|
func (o *O11yPostableNamespaces) SetEnd(v int64) {
|
|
o.End = &v
|
|
}
|
|
|
|
// GetFilter returns the Filter field value if set, zero value otherwise.
|
|
func (o *O11yPostableNamespaces) GetFilter() O11yFilter {
|
|
if o == nil || IsNil(o.Filter) {
|
|
var ret O11yFilter
|
|
return ret
|
|
}
|
|
return *o.Filter
|
|
}
|
|
|
|
// GetFilterOk returns a tuple with the Filter field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yPostableNamespaces) GetFilterOk() (*O11yFilter, bool) {
|
|
if o == nil || IsNil(o.Filter) {
|
|
return nil, false
|
|
}
|
|
return o.Filter, true
|
|
}
|
|
|
|
// HasFilter returns a boolean if a field has been set.
|
|
func (o *O11yPostableNamespaces) HasFilter() bool {
|
|
if o != nil && !IsNil(o.Filter) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetFilter gets a reference to the given O11yFilter and assigns it to the Filter field.
|
|
func (o *O11yPostableNamespaces) SetFilter(v O11yFilter) {
|
|
o.Filter = &v
|
|
}
|
|
|
|
// GetGroupBy returns the GroupBy field value if set, zero value otherwise.
|
|
func (o *O11yPostableNamespaces) GetGroupBy() []O11yGroupByKey {
|
|
if o == nil || IsNil(o.GroupBy) {
|
|
var ret []O11yGroupByKey
|
|
return ret
|
|
}
|
|
return o.GroupBy
|
|
}
|
|
|
|
// GetGroupByOk returns a tuple with the GroupBy field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yPostableNamespaces) GetGroupByOk() ([]O11yGroupByKey, bool) {
|
|
if o == nil || IsNil(o.GroupBy) {
|
|
return nil, false
|
|
}
|
|
return o.GroupBy, true
|
|
}
|
|
|
|
// HasGroupBy returns a boolean if a field has been set.
|
|
func (o *O11yPostableNamespaces) HasGroupBy() bool {
|
|
if o != nil && !IsNil(o.GroupBy) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetGroupBy gets a reference to the given []O11yGroupByKey and assigns it to the GroupBy field.
|
|
func (o *O11yPostableNamespaces) SetGroupBy(v []O11yGroupByKey) {
|
|
o.GroupBy = v
|
|
}
|
|
|
|
// GetLimit returns the Limit field value if set, zero value otherwise.
|
|
func (o *O11yPostableNamespaces) GetLimit() int64 {
|
|
if o == nil || IsNil(o.Limit) {
|
|
var ret int64
|
|
return ret
|
|
}
|
|
return *o.Limit
|
|
}
|
|
|
|
// GetLimitOk returns a tuple with the Limit field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yPostableNamespaces) GetLimitOk() (*int64, bool) {
|
|
if o == nil || IsNil(o.Limit) {
|
|
return nil, false
|
|
}
|
|
return o.Limit, true
|
|
}
|
|
|
|
// HasLimit returns a boolean if a field has been set.
|
|
func (o *O11yPostableNamespaces) HasLimit() bool {
|
|
if o != nil && !IsNil(o.Limit) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetLimit gets a reference to the given int64 and assigns it to the Limit field.
|
|
func (o *O11yPostableNamespaces) SetLimit(v int64) {
|
|
o.Limit = &v
|
|
}
|
|
|
|
// GetOffset returns the Offset field value if set, zero value otherwise.
|
|
func (o *O11yPostableNamespaces) GetOffset() int64 {
|
|
if o == nil || IsNil(o.Offset) {
|
|
var ret int64
|
|
return ret
|
|
}
|
|
return *o.Offset
|
|
}
|
|
|
|
// GetOffsetOk returns a tuple with the Offset field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yPostableNamespaces) GetOffsetOk() (*int64, bool) {
|
|
if o == nil || IsNil(o.Offset) {
|
|
return nil, false
|
|
}
|
|
return o.Offset, true
|
|
}
|
|
|
|
// HasOffset returns a boolean if a field has been set.
|
|
func (o *O11yPostableNamespaces) HasOffset() bool {
|
|
if o != nil && !IsNil(o.Offset) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetOffset gets a reference to the given int64 and assigns it to the Offset field.
|
|
func (o *O11yPostableNamespaces) SetOffset(v int64) {
|
|
o.Offset = &v
|
|
}
|
|
|
|
// GetOrderBy returns the OrderBy field value if set, zero value otherwise.
|
|
func (o *O11yPostableNamespaces) GetOrderBy() O11yQuerybuildertypesv5OrderBy {
|
|
if o == nil || IsNil(o.OrderBy) {
|
|
var ret O11yQuerybuildertypesv5OrderBy
|
|
return ret
|
|
}
|
|
return *o.OrderBy
|
|
}
|
|
|
|
// GetOrderByOk returns a tuple with the OrderBy field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yPostableNamespaces) GetOrderByOk() (*O11yQuerybuildertypesv5OrderBy, bool) {
|
|
if o == nil || IsNil(o.OrderBy) {
|
|
return nil, false
|
|
}
|
|
return o.OrderBy, true
|
|
}
|
|
|
|
// HasOrderBy returns a boolean if a field has been set.
|
|
func (o *O11yPostableNamespaces) HasOrderBy() bool {
|
|
if o != nil && !IsNil(o.OrderBy) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetOrderBy gets a reference to the given O11yQuerybuildertypesv5OrderBy and assigns it to the OrderBy field.
|
|
func (o *O11yPostableNamespaces) SetOrderBy(v O11yQuerybuildertypesv5OrderBy) {
|
|
o.OrderBy = &v
|
|
}
|
|
|
|
// GetStart returns the Start field value if set, zero value otherwise.
|
|
func (o *O11yPostableNamespaces) GetStart() int64 {
|
|
if o == nil || IsNil(o.Start) {
|
|
var ret int64
|
|
return ret
|
|
}
|
|
return *o.Start
|
|
}
|
|
|
|
// GetStartOk returns a tuple with the Start field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yPostableNamespaces) GetStartOk() (*int64, bool) {
|
|
if o == nil || IsNil(o.Start) {
|
|
return nil, false
|
|
}
|
|
return o.Start, true
|
|
}
|
|
|
|
// HasStart returns a boolean if a field has been set.
|
|
func (o *O11yPostableNamespaces) HasStart() bool {
|
|
if o != nil && !IsNil(o.Start) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetStart gets a reference to the given int64 and assigns it to the Start field.
|
|
func (o *O11yPostableNamespaces) SetStart(v int64) {
|
|
o.Start = &v
|
|
}
|
|
|
|
func (o O11yPostableNamespaces) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o O11yPostableNamespaces) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.End) {
|
|
toSerialize["end"] = o.End
|
|
}
|
|
if !IsNil(o.Filter) {
|
|
toSerialize["filter"] = o.Filter
|
|
}
|
|
if !IsNil(o.GroupBy) {
|
|
toSerialize["groupBy"] = o.GroupBy
|
|
}
|
|
if !IsNil(o.Limit) {
|
|
toSerialize["limit"] = o.Limit
|
|
}
|
|
if !IsNil(o.Offset) {
|
|
toSerialize["offset"] = o.Offset
|
|
}
|
|
if !IsNil(o.OrderBy) {
|
|
toSerialize["orderBy"] = o.OrderBy
|
|
}
|
|
if !IsNil(o.Start) {
|
|
toSerialize["start"] = o.Start
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *O11yPostableNamespaces) UnmarshalJSON(data []byte) (err error) {
|
|
varO11yPostableNamespaces := _O11yPostableNamespaces{}
|
|
|
|
err = json.Unmarshal(data, &varO11yPostableNamespaces)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = O11yPostableNamespaces(varO11yPostableNamespaces)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "end")
|
|
delete(additionalProperties, "filter")
|
|
delete(additionalProperties, "groupBy")
|
|
delete(additionalProperties, "limit")
|
|
delete(additionalProperties, "offset")
|
|
delete(additionalProperties, "orderBy")
|
|
delete(additionalProperties, "start")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableO11yPostableNamespaces struct {
|
|
value *O11yPostableNamespaces
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableO11yPostableNamespaces) Get() *O11yPostableNamespaces {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableO11yPostableNamespaces) Set(val *O11yPostableNamespaces) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableO11yPostableNamespaces) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableO11yPostableNamespaces) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableO11yPostableNamespaces(val *O11yPostableNamespaces) *NullableO11yPostableNamespaces {
|
|
return &NullableO11yPostableNamespaces{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableO11yPostableNamespaces) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableO11yPostableNamespaces) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|