Files
sdk/model_deploy_argo_group_kind.go

193 lines
5.0 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 DeployArgoGroupKind type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &DeployArgoGroupKind{}
// DeployArgoGroupKind struct for DeployArgoGroupKind
type DeployArgoGroupKind struct {
// Group is the API group a project admits, \"*\" for any. Empty names the core group.
Group *string `json:"group,omitempty"`
// Kind is the kind it admits, \"*\" for any.
Kind *string `json:"kind,omitempty"`
AdditionalProperties map[string]interface{}
}
type _DeployArgoGroupKind DeployArgoGroupKind
// NewDeployArgoGroupKind instantiates a new DeployArgoGroupKind 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 NewDeployArgoGroupKind() *DeployArgoGroupKind {
this := DeployArgoGroupKind{}
return &this
}
// NewDeployArgoGroupKindWithDefaults instantiates a new DeployArgoGroupKind 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 NewDeployArgoGroupKindWithDefaults() *DeployArgoGroupKind {
this := DeployArgoGroupKind{}
return &this
}
// GetGroup returns the Group field value if set, zero value otherwise.
func (o *DeployArgoGroupKind) GetGroup() string {
if o == nil || IsNil(o.Group) {
var ret string
return ret
}
return *o.Group
}
// GetGroupOk returns a tuple with the Group field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DeployArgoGroupKind) GetGroupOk() (*string, bool) {
if o == nil || IsNil(o.Group) {
return nil, false
}
return o.Group, true
}
// HasGroup returns a boolean if a field has been set.
func (o *DeployArgoGroupKind) HasGroup() bool {
if o != nil && !IsNil(o.Group) {
return true
}
return false
}
// SetGroup gets a reference to the given string and assigns it to the Group field.
func (o *DeployArgoGroupKind) SetGroup(v string) {
o.Group = &v
}
// GetKind returns the Kind field value if set, zero value otherwise.
func (o *DeployArgoGroupKind) 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 *DeployArgoGroupKind) 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 *DeployArgoGroupKind) 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 *DeployArgoGroupKind) SetKind(v string) {
o.Kind = &v
}
func (o DeployArgoGroupKind) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o DeployArgoGroupKind) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.Group) {
toSerialize["group"] = o.Group
}
if !IsNil(o.Kind) {
toSerialize["kind"] = o.Kind
}
for key, value := range o.AdditionalProperties {
toSerialize[key] = value
}
return toSerialize, nil
}
func (o *DeployArgoGroupKind) UnmarshalJSON(data []byte) (err error) {
varDeployArgoGroupKind := _DeployArgoGroupKind{}
err = json.Unmarshal(data, &varDeployArgoGroupKind)
if err != nil {
return err
}
*o = DeployArgoGroupKind(varDeployArgoGroupKind)
additionalProperties := make(map[string]interface{})
if err = json.Unmarshal(data, &additionalProperties); err == nil {
delete(additionalProperties, "group")
delete(additionalProperties, "kind")
o.AdditionalProperties = additionalProperties
}
return err
}
type NullableDeployArgoGroupKind struct {
value *DeployArgoGroupKind
isSet bool
}
func (v NullableDeployArgoGroupKind) Get() *DeployArgoGroupKind {
return v.value
}
func (v *NullableDeployArgoGroupKind) Set(val *DeployArgoGroupKind) {
v.value = val
v.isSet = true
}
func (v NullableDeployArgoGroupKind) IsSet() bool {
return v.isSet
}
func (v *NullableDeployArgoGroupKind) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableDeployArgoGroupKind(val *DeployArgoGroupKind) *NullableDeployArgoGroupKind {
return &NullableDeployArgoGroupKind{value: val, isSet: true}
}
func (v NullableDeployArgoGroupKind) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableDeployArgoGroupKind) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}