mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
378 lines
10 KiB
Go
378 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 O11yDeploymentListRequest type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &O11yDeploymentListRequest{}
|
|
|
|
// O11yDeploymentListRequest struct for O11yDeploymentListRequest
|
|
type O11yDeploymentListRequest struct {
|
|
// epoch time in ms
|
|
End *int64 `json:"end,omitempty"`
|
|
Filters *O11yFilterSet `json:"filters,omitempty"`
|
|
GroupBy []O11yAttributeKey `json:"groupBy,omitempty"`
|
|
Limit *int64 `json:"limit,omitempty"`
|
|
Offset *int64 `json:"offset,omitempty"`
|
|
OrderBy *O11yOrderBy `json:"orderBy,omitempty"`
|
|
// epoch time in ms
|
|
Start *int64 `json:"start,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _O11yDeploymentListRequest O11yDeploymentListRequest
|
|
|
|
// NewO11yDeploymentListRequest instantiates a new O11yDeploymentListRequest 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 NewO11yDeploymentListRequest() *O11yDeploymentListRequest {
|
|
this := O11yDeploymentListRequest{}
|
|
return &this
|
|
}
|
|
|
|
// NewO11yDeploymentListRequestWithDefaults instantiates a new O11yDeploymentListRequest 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 NewO11yDeploymentListRequestWithDefaults() *O11yDeploymentListRequest {
|
|
this := O11yDeploymentListRequest{}
|
|
return &this
|
|
}
|
|
|
|
// GetEnd returns the End field value if set, zero value otherwise.
|
|
func (o *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) SetEnd(v int64) {
|
|
o.End = &v
|
|
}
|
|
|
|
// GetFilters returns the Filters field value if set, zero value otherwise.
|
|
func (o *O11yDeploymentListRequest) GetFilters() O11yFilterSet {
|
|
if o == nil || IsNil(o.Filters) {
|
|
var ret O11yFilterSet
|
|
return ret
|
|
}
|
|
return *o.Filters
|
|
}
|
|
|
|
// GetFiltersOk returns a tuple with the Filters field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *O11yDeploymentListRequest) GetFiltersOk() (*O11yFilterSet, bool) {
|
|
if o == nil || IsNil(o.Filters) {
|
|
return nil, false
|
|
}
|
|
return o.Filters, true
|
|
}
|
|
|
|
// HasFilters returns a boolean if a field has been set.
|
|
func (o *O11yDeploymentListRequest) HasFilters() bool {
|
|
if o != nil && !IsNil(o.Filters) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetFilters gets a reference to the given O11yFilterSet and assigns it to the Filters field.
|
|
func (o *O11yDeploymentListRequest) SetFilters(v O11yFilterSet) {
|
|
o.Filters = &v
|
|
}
|
|
|
|
// GetGroupBy returns the GroupBy field value if set, zero value otherwise.
|
|
func (o *O11yDeploymentListRequest) GetGroupBy() []O11yAttributeKey {
|
|
if o == nil || IsNil(o.GroupBy) {
|
|
var ret []O11yAttributeKey
|
|
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 *O11yDeploymentListRequest) GetGroupByOk() ([]O11yAttributeKey, 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 *O11yDeploymentListRequest) HasGroupBy() bool {
|
|
if o != nil && !IsNil(o.GroupBy) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetGroupBy gets a reference to the given []O11yAttributeKey and assigns it to the GroupBy field.
|
|
func (o *O11yDeploymentListRequest) SetGroupBy(v []O11yAttributeKey) {
|
|
o.GroupBy = v
|
|
}
|
|
|
|
// GetLimit returns the Limit field value if set, zero value otherwise.
|
|
func (o *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) SetLimit(v int64) {
|
|
o.Limit = &v
|
|
}
|
|
|
|
// GetOffset returns the Offset field value if set, zero value otherwise.
|
|
func (o *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) SetOffset(v int64) {
|
|
o.Offset = &v
|
|
}
|
|
|
|
// GetOrderBy returns the OrderBy field value if set, zero value otherwise.
|
|
func (o *O11yDeploymentListRequest) GetOrderBy() O11yOrderBy {
|
|
if o == nil || IsNil(o.OrderBy) {
|
|
var ret O11yOrderBy
|
|
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 *O11yDeploymentListRequest) GetOrderByOk() (*O11yOrderBy, 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 *O11yDeploymentListRequest) HasOrderBy() bool {
|
|
if o != nil && !IsNil(o.OrderBy) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetOrderBy gets a reference to the given O11yOrderBy and assigns it to the OrderBy field.
|
|
func (o *O11yDeploymentListRequest) SetOrderBy(v O11yOrderBy) {
|
|
o.OrderBy = &v
|
|
}
|
|
|
|
// GetStart returns the Start field value if set, zero value otherwise.
|
|
func (o *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) 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 *O11yDeploymentListRequest) SetStart(v int64) {
|
|
o.Start = &v
|
|
}
|
|
|
|
func (o O11yDeploymentListRequest) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o O11yDeploymentListRequest) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.End) {
|
|
toSerialize["end"] = o.End
|
|
}
|
|
if !IsNil(o.Filters) {
|
|
toSerialize["filters"] = o.Filters
|
|
}
|
|
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 *O11yDeploymentListRequest) UnmarshalJSON(data []byte) (err error) {
|
|
varO11yDeploymentListRequest := _O11yDeploymentListRequest{}
|
|
|
|
err = json.Unmarshal(data, &varO11yDeploymentListRequest)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = O11yDeploymentListRequest(varO11yDeploymentListRequest)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "end")
|
|
delete(additionalProperties, "filters")
|
|
delete(additionalProperties, "groupBy")
|
|
delete(additionalProperties, "limit")
|
|
delete(additionalProperties, "offset")
|
|
delete(additionalProperties, "orderBy")
|
|
delete(additionalProperties, "start")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableO11yDeploymentListRequest struct {
|
|
value *O11yDeploymentListRequest
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableO11yDeploymentListRequest) Get() *O11yDeploymentListRequest {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableO11yDeploymentListRequest) Set(val *O11yDeploymentListRequest) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableO11yDeploymentListRequest) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableO11yDeploymentListRequest) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableO11yDeploymentListRequest(val *O11yDeploymentListRequest) *NullableO11yDeploymentListRequest {
|
|
return &NullableO11yDeploymentListRequest{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableO11yDeploymentListRequest) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableO11yDeploymentListRequest) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|