mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
487 lines
13 KiB
Go
487 lines
13 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 IamProjectsInput type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &IamProjectsInput{}
|
|
|
|
// IamProjectsInput struct for IamProjectsInput
|
|
type IamProjectsInput struct {
|
|
CreatedTime *string `json:"createdTime,omitempty"`
|
|
Description *string `json:"description,omitempty"`
|
|
DisplayName *string `json:"displayName,omitempty"`
|
|
IsDefault *bool `json:"isDefault,omitempty"`
|
|
Metadata *string `json:"metadata,omitempty"`
|
|
Name *string `json:"name,omitempty"`
|
|
Organization *string `json:"organization,omitempty"`
|
|
Owner *string `json:"owner,omitempty"`
|
|
Tags []string `json:"tags,omitempty"`
|
|
Workspace *string `json:"workspace,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _IamProjectsInput IamProjectsInput
|
|
|
|
// NewIamProjectsInput instantiates a new IamProjectsInput 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 NewIamProjectsInput() *IamProjectsInput {
|
|
this := IamProjectsInput{}
|
|
return &this
|
|
}
|
|
|
|
// NewIamProjectsInputWithDefaults instantiates a new IamProjectsInput 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 NewIamProjectsInputWithDefaults() *IamProjectsInput {
|
|
this := IamProjectsInput{}
|
|
return &this
|
|
}
|
|
|
|
// GetCreatedTime returns the CreatedTime field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetCreatedTime() string {
|
|
if o == nil || IsNil(o.CreatedTime) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.CreatedTime
|
|
}
|
|
|
|
// GetCreatedTimeOk returns a tuple with the CreatedTime field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetCreatedTimeOk() (*string, bool) {
|
|
if o == nil || IsNil(o.CreatedTime) {
|
|
return nil, false
|
|
}
|
|
return o.CreatedTime, true
|
|
}
|
|
|
|
// HasCreatedTime returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasCreatedTime() bool {
|
|
if o != nil && !IsNil(o.CreatedTime) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetCreatedTime gets a reference to the given string and assigns it to the CreatedTime field.
|
|
func (o *IamProjectsInput) SetCreatedTime(v string) {
|
|
o.CreatedTime = &v
|
|
}
|
|
|
|
// GetDescription returns the Description field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetDescription() string {
|
|
if o == nil || IsNil(o.Description) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Description
|
|
}
|
|
|
|
// GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetDescriptionOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Description) {
|
|
return nil, false
|
|
}
|
|
return o.Description, true
|
|
}
|
|
|
|
// HasDescription returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasDescription() bool {
|
|
if o != nil && !IsNil(o.Description) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetDescription gets a reference to the given string and assigns it to the Description field.
|
|
func (o *IamProjectsInput) SetDescription(v string) {
|
|
o.Description = &v
|
|
}
|
|
|
|
// GetDisplayName returns the DisplayName field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetDisplayName() string {
|
|
if o == nil || IsNil(o.DisplayName) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.DisplayName
|
|
}
|
|
|
|
// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetDisplayNameOk() (*string, bool) {
|
|
if o == nil || IsNil(o.DisplayName) {
|
|
return nil, false
|
|
}
|
|
return o.DisplayName, true
|
|
}
|
|
|
|
// HasDisplayName returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasDisplayName() bool {
|
|
if o != nil && !IsNil(o.DisplayName) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field.
|
|
func (o *IamProjectsInput) SetDisplayName(v string) {
|
|
o.DisplayName = &v
|
|
}
|
|
|
|
// GetIsDefault returns the IsDefault field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetIsDefault() bool {
|
|
if o == nil || IsNil(o.IsDefault) {
|
|
var ret bool
|
|
return ret
|
|
}
|
|
return *o.IsDefault
|
|
}
|
|
|
|
// GetIsDefaultOk returns a tuple with the IsDefault field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetIsDefaultOk() (*bool, bool) {
|
|
if o == nil || IsNil(o.IsDefault) {
|
|
return nil, false
|
|
}
|
|
return o.IsDefault, true
|
|
}
|
|
|
|
// HasIsDefault returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasIsDefault() bool {
|
|
if o != nil && !IsNil(o.IsDefault) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetIsDefault gets a reference to the given bool and assigns it to the IsDefault field.
|
|
func (o *IamProjectsInput) SetIsDefault(v bool) {
|
|
o.IsDefault = &v
|
|
}
|
|
|
|
// GetMetadata returns the Metadata field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetMetadata() string {
|
|
if o == nil || IsNil(o.Metadata) {
|
|
var ret string
|
|
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 *IamProjectsInput) GetMetadataOk() (*string, 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 *IamProjectsInput) HasMetadata() bool {
|
|
if o != nil && !IsNil(o.Metadata) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetMetadata gets a reference to the given string and assigns it to the Metadata field.
|
|
func (o *IamProjectsInput) SetMetadata(v string) {
|
|
o.Metadata = &v
|
|
}
|
|
|
|
// GetName returns the Name field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) 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 *IamProjectsInput) 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 *IamProjectsInput) 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 *IamProjectsInput) SetName(v string) {
|
|
o.Name = &v
|
|
}
|
|
|
|
// GetOrganization returns the Organization field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetOrganization() string {
|
|
if o == nil || IsNil(o.Organization) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Organization
|
|
}
|
|
|
|
// GetOrganizationOk returns a tuple with the Organization field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetOrganizationOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Organization) {
|
|
return nil, false
|
|
}
|
|
return o.Organization, true
|
|
}
|
|
|
|
// HasOrganization returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasOrganization() bool {
|
|
if o != nil && !IsNil(o.Organization) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetOrganization gets a reference to the given string and assigns it to the Organization field.
|
|
func (o *IamProjectsInput) SetOrganization(v string) {
|
|
o.Organization = &v
|
|
}
|
|
|
|
// GetOwner returns the Owner field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetOwner() string {
|
|
if o == nil || IsNil(o.Owner) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Owner
|
|
}
|
|
|
|
// GetOwnerOk returns a tuple with the Owner field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetOwnerOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Owner) {
|
|
return nil, false
|
|
}
|
|
return o.Owner, true
|
|
}
|
|
|
|
// HasOwner returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasOwner() bool {
|
|
if o != nil && !IsNil(o.Owner) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetOwner gets a reference to the given string and assigns it to the Owner field.
|
|
func (o *IamProjectsInput) SetOwner(v string) {
|
|
o.Owner = &v
|
|
}
|
|
|
|
// GetTags returns the Tags field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetTags() []string {
|
|
if o == nil || IsNil(o.Tags) {
|
|
var ret []string
|
|
return ret
|
|
}
|
|
return o.Tags
|
|
}
|
|
|
|
// GetTagsOk returns a tuple with the Tags field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetTagsOk() ([]string, bool) {
|
|
if o == nil || IsNil(o.Tags) {
|
|
return nil, false
|
|
}
|
|
return o.Tags, true
|
|
}
|
|
|
|
// HasTags returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasTags() bool {
|
|
if o != nil && !IsNil(o.Tags) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetTags gets a reference to the given []string and assigns it to the Tags field.
|
|
func (o *IamProjectsInput) SetTags(v []string) {
|
|
o.Tags = v
|
|
}
|
|
|
|
// GetWorkspace returns the Workspace field value if set, zero value otherwise.
|
|
func (o *IamProjectsInput) GetWorkspace() string {
|
|
if o == nil || IsNil(o.Workspace) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Workspace
|
|
}
|
|
|
|
// GetWorkspaceOk returns a tuple with the Workspace field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *IamProjectsInput) GetWorkspaceOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Workspace) {
|
|
return nil, false
|
|
}
|
|
return o.Workspace, true
|
|
}
|
|
|
|
// HasWorkspace returns a boolean if a field has been set.
|
|
func (o *IamProjectsInput) HasWorkspace() bool {
|
|
if o != nil && !IsNil(o.Workspace) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetWorkspace gets a reference to the given string and assigns it to the Workspace field.
|
|
func (o *IamProjectsInput) SetWorkspace(v string) {
|
|
o.Workspace = &v
|
|
}
|
|
|
|
func (o IamProjectsInput) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o IamProjectsInput) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.CreatedTime) {
|
|
toSerialize["createdTime"] = o.CreatedTime
|
|
}
|
|
if !IsNil(o.Description) {
|
|
toSerialize["description"] = o.Description
|
|
}
|
|
if !IsNil(o.DisplayName) {
|
|
toSerialize["displayName"] = o.DisplayName
|
|
}
|
|
if !IsNil(o.IsDefault) {
|
|
toSerialize["isDefault"] = o.IsDefault
|
|
}
|
|
if !IsNil(o.Metadata) {
|
|
toSerialize["metadata"] = o.Metadata
|
|
}
|
|
if !IsNil(o.Name) {
|
|
toSerialize["name"] = o.Name
|
|
}
|
|
if !IsNil(o.Organization) {
|
|
toSerialize["organization"] = o.Organization
|
|
}
|
|
if !IsNil(o.Owner) {
|
|
toSerialize["owner"] = o.Owner
|
|
}
|
|
if !IsNil(o.Tags) {
|
|
toSerialize["tags"] = o.Tags
|
|
}
|
|
if !IsNil(o.Workspace) {
|
|
toSerialize["workspace"] = o.Workspace
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *IamProjectsInput) UnmarshalJSON(data []byte) (err error) {
|
|
varIamProjectsInput := _IamProjectsInput{}
|
|
|
|
err = json.Unmarshal(data, &varIamProjectsInput)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = IamProjectsInput(varIamProjectsInput)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "createdTime")
|
|
delete(additionalProperties, "description")
|
|
delete(additionalProperties, "displayName")
|
|
delete(additionalProperties, "isDefault")
|
|
delete(additionalProperties, "metadata")
|
|
delete(additionalProperties, "name")
|
|
delete(additionalProperties, "organization")
|
|
delete(additionalProperties, "owner")
|
|
delete(additionalProperties, "tags")
|
|
delete(additionalProperties, "workspace")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableIamProjectsInput struct {
|
|
value *IamProjectsInput
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableIamProjectsInput) Get() *IamProjectsInput {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableIamProjectsInput) Set(val *IamProjectsInput) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableIamProjectsInput) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableIamProjectsInput) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableIamProjectsInput(val *IamProjectsInput) *NullableIamProjectsInput {
|
|
return &NullableIamProjectsInput{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableIamProjectsInput) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableIamProjectsInput) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|