Files
sdk/model_studio_brand.go

450 lines
11 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 StudioBrand type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &StudioBrand{}
// StudioBrand struct for StudioBrand
type StudioBrand struct {
Created *string `json:"created,omitempty"`
Creator *string `json:"creator,omitempty"`
Id *string `json:"id,omitempty"`
Logos []string `json:"logos,omitempty"`
Name *string `json:"name,omitempty"`
Org *string `json:"org,omitempty"`
Shared *bool `json:"shared,omitempty"`
Tokens map[string]interface{} `json:"tokens,omitempty"`
Updated *string `json:"updated,omitempty"`
AdditionalProperties map[string]interface{}
}
type _StudioBrand StudioBrand
// NewStudioBrand instantiates a new StudioBrand 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 NewStudioBrand() *StudioBrand {
this := StudioBrand{}
return &this
}
// NewStudioBrandWithDefaults instantiates a new StudioBrand 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 NewStudioBrandWithDefaults() *StudioBrand {
this := StudioBrand{}
return &this
}
// GetCreated returns the Created field value if set, zero value otherwise.
func (o *StudioBrand) GetCreated() string {
if o == nil || IsNil(o.Created) {
var ret string
return ret
}
return *o.Created
}
// GetCreatedOk returns a tuple with the Created field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetCreatedOk() (*string, bool) {
if o == nil || IsNil(o.Created) {
return nil, false
}
return o.Created, true
}
// HasCreated returns a boolean if a field has been set.
func (o *StudioBrand) HasCreated() bool {
if o != nil && !IsNil(o.Created) {
return true
}
return false
}
// SetCreated gets a reference to the given string and assigns it to the Created field.
func (o *StudioBrand) SetCreated(v string) {
o.Created = &v
}
// GetCreator returns the Creator field value if set, zero value otherwise.
func (o *StudioBrand) GetCreator() string {
if o == nil || IsNil(o.Creator) {
var ret string
return ret
}
return *o.Creator
}
// GetCreatorOk returns a tuple with the Creator field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetCreatorOk() (*string, bool) {
if o == nil || IsNil(o.Creator) {
return nil, false
}
return o.Creator, true
}
// HasCreator returns a boolean if a field has been set.
func (o *StudioBrand) HasCreator() bool {
if o != nil && !IsNil(o.Creator) {
return true
}
return false
}
// SetCreator gets a reference to the given string and assigns it to the Creator field.
func (o *StudioBrand) SetCreator(v string) {
o.Creator = &v
}
// GetId returns the Id field value if set, zero value otherwise.
func (o *StudioBrand) GetId() string {
if o == nil || IsNil(o.Id) {
var ret string
return ret
}
return *o.Id
}
// GetIdOk returns a tuple with the Id field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetIdOk() (*string, bool) {
if o == nil || IsNil(o.Id) {
return nil, false
}
return o.Id, true
}
// HasId returns a boolean if a field has been set.
func (o *StudioBrand) HasId() bool {
if o != nil && !IsNil(o.Id) {
return true
}
return false
}
// SetId gets a reference to the given string and assigns it to the Id field.
func (o *StudioBrand) SetId(v string) {
o.Id = &v
}
// GetLogos returns the Logos field value if set, zero value otherwise.
func (o *StudioBrand) GetLogos() []string {
if o == nil || IsNil(o.Logos) {
var ret []string
return ret
}
return o.Logos
}
// GetLogosOk returns a tuple with the Logos field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetLogosOk() ([]string, bool) {
if o == nil || IsNil(o.Logos) {
return nil, false
}
return o.Logos, true
}
// HasLogos returns a boolean if a field has been set.
func (o *StudioBrand) HasLogos() bool {
if o != nil && !IsNil(o.Logos) {
return true
}
return false
}
// SetLogos gets a reference to the given []string and assigns it to the Logos field.
func (o *StudioBrand) SetLogos(v []string) {
o.Logos = v
}
// GetName returns the Name field value if set, zero value otherwise.
func (o *StudioBrand) GetName() string {
if o == nil || IsNil(o.Name) {
var ret string
return ret
}
return *o.Name
}
// GetNameOk returns a tuple with the Name field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetNameOk() (*string, bool) {
if o == nil || IsNil(o.Name) {
return nil, false
}
return o.Name, true
}
// HasName returns a boolean if a field has been set.
func (o *StudioBrand) HasName() bool {
if o != nil && !IsNil(o.Name) {
return true
}
return false
}
// SetName gets a reference to the given string and assigns it to the Name field.
func (o *StudioBrand) SetName(v string) {
o.Name = &v
}
// GetOrg returns the Org field value if set, zero value otherwise.
func (o *StudioBrand) GetOrg() string {
if o == nil || IsNil(o.Org) {
var ret string
return ret
}
return *o.Org
}
// GetOrgOk returns a tuple with the Org field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetOrgOk() (*string, bool) {
if o == nil || IsNil(o.Org) {
return nil, false
}
return o.Org, true
}
// HasOrg returns a boolean if a field has been set.
func (o *StudioBrand) HasOrg() bool {
if o != nil && !IsNil(o.Org) {
return true
}
return false
}
// SetOrg gets a reference to the given string and assigns it to the Org field.
func (o *StudioBrand) SetOrg(v string) {
o.Org = &v
}
// GetShared returns the Shared field value if set, zero value otherwise.
func (o *StudioBrand) GetShared() bool {
if o == nil || IsNil(o.Shared) {
var ret bool
return ret
}
return *o.Shared
}
// GetSharedOk returns a tuple with the Shared field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetSharedOk() (*bool, bool) {
if o == nil || IsNil(o.Shared) {
return nil, false
}
return o.Shared, true
}
// HasShared returns a boolean if a field has been set.
func (o *StudioBrand) HasShared() bool {
if o != nil && !IsNil(o.Shared) {
return true
}
return false
}
// SetShared gets a reference to the given bool and assigns it to the Shared field.
func (o *StudioBrand) SetShared(v bool) {
o.Shared = &v
}
// GetTokens returns the Tokens field value if set, zero value otherwise.
func (o *StudioBrand) GetTokens() map[string]interface{} {
if o == nil || IsNil(o.Tokens) {
var ret map[string]interface{}
return ret
}
return o.Tokens
}
// GetTokensOk returns a tuple with the Tokens field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetTokensOk() (map[string]interface{}, bool) {
if o == nil || IsNil(o.Tokens) {
return map[string]interface{}{}, false
}
return o.Tokens, true
}
// HasTokens returns a boolean if a field has been set.
func (o *StudioBrand) HasTokens() bool {
if o != nil && !IsNil(o.Tokens) {
return true
}
return false
}
// SetTokens gets a reference to the given map[string]interface{} and assigns it to the Tokens field.
func (o *StudioBrand) SetTokens(v map[string]interface{}) {
o.Tokens = v
}
// GetUpdated returns the Updated field value if set, zero value otherwise.
func (o *StudioBrand) GetUpdated() string {
if o == nil || IsNil(o.Updated) {
var ret string
return ret
}
return *o.Updated
}
// GetUpdatedOk returns a tuple with the Updated field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *StudioBrand) GetUpdatedOk() (*string, bool) {
if o == nil || IsNil(o.Updated) {
return nil, false
}
return o.Updated, true
}
// HasUpdated returns a boolean if a field has been set.
func (o *StudioBrand) HasUpdated() bool {
if o != nil && !IsNil(o.Updated) {
return true
}
return false
}
// SetUpdated gets a reference to the given string and assigns it to the Updated field.
func (o *StudioBrand) SetUpdated(v string) {
o.Updated = &v
}
func (o StudioBrand) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o StudioBrand) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.Created) {
toSerialize["created"] = o.Created
}
if !IsNil(o.Creator) {
toSerialize["creator"] = o.Creator
}
if !IsNil(o.Id) {
toSerialize["id"] = o.Id
}
if !IsNil(o.Logos) {
toSerialize["logos"] = o.Logos
}
if !IsNil(o.Name) {
toSerialize["name"] = o.Name
}
if !IsNil(o.Org) {
toSerialize["org"] = o.Org
}
if !IsNil(o.Shared) {
toSerialize["shared"] = o.Shared
}
if !IsNil(o.Tokens) {
toSerialize["tokens"] = o.Tokens
}
if !IsNil(o.Updated) {
toSerialize["updated"] = o.Updated
}
for key, value := range o.AdditionalProperties {
toSerialize[key] = value
}
return toSerialize, nil
}
func (o *StudioBrand) UnmarshalJSON(data []byte) (err error) {
varStudioBrand := _StudioBrand{}
err = json.Unmarshal(data, &varStudioBrand)
if err != nil {
return err
}
*o = StudioBrand(varStudioBrand)
additionalProperties := make(map[string]interface{})
if err = json.Unmarshal(data, &additionalProperties); err == nil {
delete(additionalProperties, "created")
delete(additionalProperties, "creator")
delete(additionalProperties, "id")
delete(additionalProperties, "logos")
delete(additionalProperties, "name")
delete(additionalProperties, "org")
delete(additionalProperties, "shared")
delete(additionalProperties, "tokens")
delete(additionalProperties, "updated")
o.AdditionalProperties = additionalProperties
}
return err
}
type NullableStudioBrand struct {
value *StudioBrand
isSet bool
}
func (v NullableStudioBrand) Get() *StudioBrand {
return v.value
}
func (v *NullableStudioBrand) Set(val *StudioBrand) {
v.value = val
v.isSet = true
}
func (v NullableStudioBrand) IsSet() bool {
return v.isSet
}
func (v *NullableStudioBrand) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableStudioBrand(val *StudioBrand) *NullableStudioBrand {
return &NullableStudioBrand{value: val, isSet: true}
}
func (v NullableStudioBrand) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableStudioBrand) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}