Files
sdk/model_deploy_argo_app_list.go

269 lines
7.4 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 DeployArgoAppList type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &DeployArgoAppList{}
// DeployArgoAppList struct for DeployArgoAppList
type DeployArgoAppList struct {
// APIVersion is the constant \"argoproj.io/v1alpha1\".
ApiVersion *string `json:"apiVersion,omitempty"`
// Items is one entry per operator App CR the caller may see — its own org's, or every platform namespace's for a SuperAdmin — followed, for a SuperAdmin only, by every Hanzo CD Application in the cluster. Empty (never null) rather than absent when the caller owns nothing.
Items []DeployArgoApp `json:"items,omitempty"`
// Kind is the constant \"ApplicationList\".
Kind *string `json:"kind,omitempty"`
// Metadata is the list envelope the SPA expects; it carries no resume point.
Metadata *DeployArgoListMeta `json:"metadata,omitempty"`
AdditionalProperties map[string]interface{}
}
type _DeployArgoAppList DeployArgoAppList
// NewDeployArgoAppList instantiates a new DeployArgoAppList 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 NewDeployArgoAppList() *DeployArgoAppList {
this := DeployArgoAppList{}
return &this
}
// NewDeployArgoAppListWithDefaults instantiates a new DeployArgoAppList 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 NewDeployArgoAppListWithDefaults() *DeployArgoAppList {
this := DeployArgoAppList{}
return &this
}
// GetApiVersion returns the ApiVersion field value if set, zero value otherwise.
func (o *DeployArgoAppList) GetApiVersion() string {
if o == nil || IsNil(o.ApiVersion) {
var ret string
return ret
}
return *o.ApiVersion
}
// GetApiVersionOk returns a tuple with the ApiVersion field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DeployArgoAppList) GetApiVersionOk() (*string, bool) {
if o == nil || IsNil(o.ApiVersion) {
return nil, false
}
return o.ApiVersion, true
}
// HasApiVersion returns a boolean if a field has been set.
func (o *DeployArgoAppList) HasApiVersion() bool {
if o != nil && !IsNil(o.ApiVersion) {
return true
}
return false
}
// SetApiVersion gets a reference to the given string and assigns it to the ApiVersion field.
func (o *DeployArgoAppList) SetApiVersion(v string) {
o.ApiVersion = &v
}
// GetItems returns the Items field value if set, zero value otherwise.
func (o *DeployArgoAppList) GetItems() []DeployArgoApp {
if o == nil || IsNil(o.Items) {
var ret []DeployArgoApp
return ret
}
return o.Items
}
// GetItemsOk returns a tuple with the Items field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DeployArgoAppList) GetItemsOk() ([]DeployArgoApp, bool) {
if o == nil || IsNil(o.Items) {
return nil, false
}
return o.Items, true
}
// HasItems returns a boolean if a field has been set.
func (o *DeployArgoAppList) HasItems() bool {
if o != nil && !IsNil(o.Items) {
return true
}
return false
}
// SetItems gets a reference to the given []DeployArgoApp and assigns it to the Items field.
func (o *DeployArgoAppList) SetItems(v []DeployArgoApp) {
o.Items = v
}
// GetKind returns the Kind field value if set, zero value otherwise.
func (o *DeployArgoAppList) GetKind() string {
if o == nil || IsNil(o.Kind) {
var ret string
return ret
}
return *o.Kind
}
// GetKindOk returns a tuple with the Kind field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DeployArgoAppList) GetKindOk() (*string, bool) {
if o == nil || IsNil(o.Kind) {
return nil, false
}
return o.Kind, true
}
// HasKind returns a boolean if a field has been set.
func (o *DeployArgoAppList) HasKind() bool {
if o != nil && !IsNil(o.Kind) {
return true
}
return false
}
// SetKind gets a reference to the given string and assigns it to the Kind field.
func (o *DeployArgoAppList) SetKind(v string) {
o.Kind = &v
}
// GetMetadata returns the Metadata field value if set, zero value otherwise.
func (o *DeployArgoAppList) GetMetadata() DeployArgoListMeta {
if o == nil || IsNil(o.Metadata) {
var ret DeployArgoListMeta
return ret
}
return *o.Metadata
}
// GetMetadataOk returns a tuple with the Metadata field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DeployArgoAppList) GetMetadataOk() (*DeployArgoListMeta, bool) {
if o == nil || IsNil(o.Metadata) {
return nil, false
}
return o.Metadata, true
}
// HasMetadata returns a boolean if a field has been set.
func (o *DeployArgoAppList) HasMetadata() bool {
if o != nil && !IsNil(o.Metadata) {
return true
}
return false
}
// SetMetadata gets a reference to the given DeployArgoListMeta and assigns it to the Metadata field.
func (o *DeployArgoAppList) SetMetadata(v DeployArgoListMeta) {
o.Metadata = &v
}
func (o DeployArgoAppList) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o DeployArgoAppList) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.ApiVersion) {
toSerialize["apiVersion"] = o.ApiVersion
}
if !IsNil(o.Items) {
toSerialize["items"] = o.Items
}
if !IsNil(o.Kind) {
toSerialize["kind"] = o.Kind
}
if !IsNil(o.Metadata) {
toSerialize["metadata"] = o.Metadata
}
for key, value := range o.AdditionalProperties {
toSerialize[key] = value
}
return toSerialize, nil
}
func (o *DeployArgoAppList) UnmarshalJSON(data []byte) (err error) {
varDeployArgoAppList := _DeployArgoAppList{}
err = json.Unmarshal(data, &varDeployArgoAppList)
if err != nil {
return err
}
*o = DeployArgoAppList(varDeployArgoAppList)
additionalProperties := make(map[string]interface{})
if err = json.Unmarshal(data, &additionalProperties); err == nil {
delete(additionalProperties, "apiVersion")
delete(additionalProperties, "items")
delete(additionalProperties, "kind")
delete(additionalProperties, "metadata")
o.AdditionalProperties = additionalProperties
}
return err
}
type NullableDeployArgoAppList struct {
value *DeployArgoAppList
isSet bool
}
func (v NullableDeployArgoAppList) Get() *DeployArgoAppList {
return v.value
}
func (v *NullableDeployArgoAppList) Set(val *DeployArgoAppList) {
v.value = val
v.isSet = true
}
func (v NullableDeployArgoAppList) IsSet() bool {
return v.isSet
}
func (v *NullableDeployArgoAppList) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableDeployArgoAppList(val *DeployArgoAppList) *NullableDeployArgoAppList {
return &NullableDeployArgoAppList{value: val, isSet: true}
}
func (v NullableDeployArgoAppList) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableDeployArgoAppList) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}