From cf603ce2df99838f2ec5b48406bc25c5ae431c42 Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Wed, 14 Aug 2024 06:31:17 +0000 Subject: [PATCH] Generate resourcemanager --- .../model_create_project_payload.go | 180 ---------- .../resourcemanager/model_error_response.go | 194 ----------- .../model_get_project_response.go | 316 ------------------ .../model_list_organizations_response.go | 149 --------- ...list_organizations_response_items_inner.go | 255 -------------- .../model_list_projects_response.go | 149 --------- services/resourcemanager/model_member.go | 119 ------- .../model_organization_response.go | 255 -------------- services/resourcemanager/model_parent.go | 145 -------- .../model_parent_list_inner.go | 223 ------------ .../model_partial_update_project_payload.go | 170 ---------- services/resourcemanager/model_project.go | 281 ---------------- 12 files changed, 2436 deletions(-) diff --git a/services/resourcemanager/model_create_project_payload.go b/services/resourcemanager/model_create_project_payload.go index 8dbd9c3be..bd34972e8 100644 --- a/services/resourcemanager/model_create_project_payload.go +++ b/services/resourcemanager/model_create_project_payload.go @@ -10,13 +10,6 @@ API version: 2.0 package resourcemanager -import ( - "encoding/json" -) - -// checks if the CreateProjectPayload type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &CreateProjectPayload{} - // CreateProjectPayload struct for CreateProjectPayload type CreateProjectPayload struct { // Identifier of the parent resource container - containerId as well as UUID identifier is supported. @@ -31,176 +24,3 @@ type CreateProjectPayload struct { // REQUIRED Name *string `json:"name"` } - -type _CreateProjectPayload CreateProjectPayload - -// NewCreateProjectPayload instantiates a new CreateProjectPayload 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 NewCreateProjectPayload(containerParentId *string, members *[]Member, name *string) *CreateProjectPayload { - this := CreateProjectPayload{} - this.ContainerParentId = containerParentId - this.Members = members - this.Name = name - return &this -} - -// NewCreateProjectPayloadWithDefaults instantiates a new CreateProjectPayload 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 NewCreateProjectPayloadWithDefaults() *CreateProjectPayload { - this := CreateProjectPayload{} - return &this -} - -// GetContainerParentId returns the ContainerParentId field value -func (o *CreateProjectPayload) GetContainerParentId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerParentId -} - -// GetContainerParentIdOk returns a tuple with the ContainerParentId field value -// and a boolean to check if the value has been set. -func (o *CreateProjectPayload) GetContainerParentIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerParentId, true -} - -// SetContainerParentId sets field value -func (o *CreateProjectPayload) SetContainerParentId(v *string) { - o.ContainerParentId = v -} - -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *CreateProjectPayload) GetLabels() *map[string]string { - if o == nil || IsNil(o.Labels) { - var ret *map[string]string - return ret - } - return o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *CreateProjectPayload) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *CreateProjectPayload) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *CreateProjectPayload) SetLabels(v *map[string]string) { - o.Labels = v -} - -// GetMembers returns the Members field value -func (o *CreateProjectPayload) GetMembers() *[]Member { - if o == nil { - var ret *[]Member - return ret - } - - return o.Members -} - -// GetMembersOk returns a tuple with the Members field value -// and a boolean to check if the value has been set. -func (o *CreateProjectPayload) GetMembersOk() (*[]Member, bool) { - if o == nil { - return nil, false - } - return o.Members, true -} - -// SetMembers sets field value -func (o *CreateProjectPayload) SetMembers(v *[]Member) { - o.Members = v -} - -// GetName returns the Name field value -func (o *CreateProjectPayload) GetName() *string { - if o == nil { - var ret *string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *CreateProjectPayload) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Name, true -} - -// SetName sets field value -func (o *CreateProjectPayload) SetName(v *string) { - o.Name = v -} - -func (o CreateProjectPayload) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["containerParentId"] = o.ContainerParentId - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } - toSerialize["members"] = o.Members - toSerialize["name"] = o.Name - return toSerialize, nil -} - -type NullableCreateProjectPayload struct { - value *CreateProjectPayload - isSet bool -} - -func (v NullableCreateProjectPayload) Get() *CreateProjectPayload { - return v.value -} - -func (v *NullableCreateProjectPayload) Set(val *CreateProjectPayload) { - v.value = val - v.isSet = true -} - -func (v NullableCreateProjectPayload) IsSet() bool { - return v.isSet -} - -func (v *NullableCreateProjectPayload) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableCreateProjectPayload(val *CreateProjectPayload) *NullableCreateProjectPayload { - return &NullableCreateProjectPayload{value: val, isSet: true} -} - -func (v NullableCreateProjectPayload) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableCreateProjectPayload) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_error_response.go b/services/resourcemanager/model_error_response.go index 854415f06..9c095a18d 100644 --- a/services/resourcemanager/model_error_response.go +++ b/services/resourcemanager/model_error_response.go @@ -11,13 +11,9 @@ API version: 2.0 package resourcemanager import ( - "encoding/json" "time" ) -// checks if the ErrorResponse type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &ErrorResponse{} - // ErrorResponse struct for ErrorResponse type ErrorResponse struct { // The reason phrase of the status code. @@ -36,193 +32,3 @@ type ErrorResponse struct { // REQUIRED TimeStamp *time.Time `json:"timeStamp"` } - -type _ErrorResponse ErrorResponse - -// NewErrorResponse instantiates a new ErrorResponse 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 NewErrorResponse(error_ *string, message *string, path *string, status *float64, timeStamp *time.Time) *ErrorResponse { - this := ErrorResponse{} - this.Error = error_ - this.Message = message - this.Path = path - this.Status = status - this.TimeStamp = timeStamp - return &this -} - -// NewErrorResponseWithDefaults instantiates a new ErrorResponse 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 NewErrorResponseWithDefaults() *ErrorResponse { - this := ErrorResponse{} - return &this -} - -// GetError returns the Error field value -func (o *ErrorResponse) GetError() *string { - if o == nil { - var ret *string - return ret - } - - return o.Error -} - -// GetErrorOk returns a tuple with the Error field value -// and a boolean to check if the value has been set. -func (o *ErrorResponse) GetErrorOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Error, true -} - -// SetError sets field value -func (o *ErrorResponse) SetError(v *string) { - o.Error = v -} - -// GetMessage returns the Message field value -func (o *ErrorResponse) GetMessage() *string { - if o == nil { - var ret *string - return ret - } - - return o.Message -} - -// GetMessageOk returns a tuple with the Message field value -// and a boolean to check if the value has been set. -func (o *ErrorResponse) GetMessageOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Message, true -} - -// SetMessage sets field value -func (o *ErrorResponse) SetMessage(v *string) { - o.Message = v -} - -// GetPath returns the Path field value -func (o *ErrorResponse) GetPath() *string { - if o == nil { - var ret *string - return ret - } - - return o.Path -} - -// GetPathOk returns a tuple with the Path field value -// and a boolean to check if the value has been set. -func (o *ErrorResponse) GetPathOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Path, true -} - -// SetPath sets field value -func (o *ErrorResponse) SetPath(v *string) { - o.Path = v -} - -// GetStatus returns the Status field value -func (o *ErrorResponse) GetStatus() *float64 { - if o == nil { - var ret *float64 - return ret - } - - return o.Status -} - -// GetStatusOk returns a tuple with the Status field value -// and a boolean to check if the value has been set. -func (o *ErrorResponse) GetStatusOk() (*float64, bool) { - if o == nil { - return nil, false - } - return o.Status, true -} - -// SetStatus sets field value -func (o *ErrorResponse) SetStatus(v *float64) { - o.Status = v -} - -// GetTimeStamp returns the TimeStamp field value -func (o *ErrorResponse) GetTimeStamp() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.TimeStamp -} - -// GetTimeStampOk returns a tuple with the TimeStamp field value -// and a boolean to check if the value has been set. -func (o *ErrorResponse) GetTimeStampOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.TimeStamp, true -} - -// SetTimeStamp sets field value -func (o *ErrorResponse) SetTimeStamp(v *time.Time) { - o.TimeStamp = v -} - -func (o ErrorResponse) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["error"] = o.Error - toSerialize["message"] = o.Message - toSerialize["path"] = o.Path - toSerialize["status"] = o.Status - toSerialize["timeStamp"] = o.TimeStamp - return toSerialize, nil -} - -type NullableErrorResponse struct { - value *ErrorResponse - isSet bool -} - -func (v NullableErrorResponse) Get() *ErrorResponse { - return v.value -} - -func (v *NullableErrorResponse) Set(val *ErrorResponse) { - v.value = val - v.isSet = true -} - -func (v NullableErrorResponse) IsSet() bool { - return v.isSet -} - -func (v *NullableErrorResponse) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableErrorResponse(val *ErrorResponse) *NullableErrorResponse { - return &NullableErrorResponse{value: val, isSet: true} -} - -func (v NullableErrorResponse) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableErrorResponse) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_get_project_response.go b/services/resourcemanager/model_get_project_response.go index 5094966cb..c63613952 100644 --- a/services/resourcemanager/model_get_project_response.go +++ b/services/resourcemanager/model_get_project_response.go @@ -11,13 +11,9 @@ API version: 2.0 package resourcemanager import ( - "encoding/json" "time" ) -// checks if the GetProjectResponse type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &GetProjectResponse{} - // GetProjectResponse struct for GetProjectResponse type GetProjectResponse struct { // Globally unique identifier. @@ -43,315 +39,3 @@ type GetProjectResponse struct { // REQUIRED UpdateTime *time.Time `json:"updateTime"` } - -type _GetProjectResponse GetProjectResponse - -// NewGetProjectResponse instantiates a new GetProjectResponse 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 NewGetProjectResponse(containerId *string, creationTime *time.Time, lifecycleState *LifecycleState, name *string, parent *Parent, projectId *string, updateTime *time.Time) *GetProjectResponse { - this := GetProjectResponse{} - this.ContainerId = containerId - this.CreationTime = creationTime - this.LifecycleState = lifecycleState - this.Name = name - this.Parent = parent - this.ProjectId = projectId - this.UpdateTime = updateTime - return &this -} - -// NewGetProjectResponseWithDefaults instantiates a new GetProjectResponse 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 NewGetProjectResponseWithDefaults() *GetProjectResponse { - this := GetProjectResponse{} - return &this -} - -// GetContainerId returns the ContainerId field value -func (o *GetProjectResponse) GetContainerId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerId -} - -// GetContainerIdOk returns a tuple with the ContainerId field value -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetContainerIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerId, true -} - -// SetContainerId sets field value -func (o *GetProjectResponse) SetContainerId(v *string) { - o.ContainerId = v -} - -// GetCreationTime returns the CreationTime field value -func (o *GetProjectResponse) GetCreationTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.CreationTime -} - -// GetCreationTimeOk returns a tuple with the CreationTime field value -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetCreationTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.CreationTime, true -} - -// SetCreationTime sets field value -func (o *GetProjectResponse) SetCreationTime(v *time.Time) { - o.CreationTime = v -} - -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *GetProjectResponse) GetLabels() *map[string]string { - if o == nil || IsNil(o.Labels) { - var ret *map[string]string - return ret - } - return o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *GetProjectResponse) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *GetProjectResponse) SetLabels(v *map[string]string) { - o.Labels = v -} - -// GetLifecycleState returns the LifecycleState field value -func (o *GetProjectResponse) GetLifecycleState() *LifecycleState { - if o == nil { - var ret *LifecycleState - return ret - } - - return o.LifecycleState -} - -// GetLifecycleStateOk returns a tuple with the LifecycleState field value -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetLifecycleStateOk() (*LifecycleState, bool) { - if o == nil { - return nil, false - } - return o.LifecycleState, true -} - -// SetLifecycleState sets field value -func (o *GetProjectResponse) SetLifecycleState(v *LifecycleState) { - o.LifecycleState = v -} - -// GetName returns the Name field value -func (o *GetProjectResponse) GetName() *string { - if o == nil { - var ret *string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Name, true -} - -// SetName sets field value -func (o *GetProjectResponse) SetName(v *string) { - o.Name = v -} - -// GetParent returns the Parent field value -func (o *GetProjectResponse) GetParent() *Parent { - if o == nil { - var ret *Parent - return ret - } - - return o.Parent -} - -// GetParentOk returns a tuple with the Parent field value -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetParentOk() (*Parent, bool) { - if o == nil { - return nil, false - } - return o.Parent, true -} - -// SetParent sets field value -func (o *GetProjectResponse) SetParent(v *Parent) { - o.Parent = v -} - -// GetParents returns the Parents field value if set, zero value otherwise. -func (o *GetProjectResponse) GetParents() *[]ParentListInner { - if o == nil || IsNil(o.Parents) { - var ret *[]ParentListInner - return ret - } - return o.Parents -} - -// GetParentsOk returns a tuple with the Parents field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetParentsOk() (*[]ParentListInner, bool) { - if o == nil || IsNil(o.Parents) { - return nil, false - } - return o.Parents, true -} - -// HasParents returns a boolean if a field has been set. -func (o *GetProjectResponse) HasParents() bool { - if o != nil && !IsNil(o.Parents) { - return true - } - - return false -} - -// SetParents gets a reference to the given []ParentListInner and assigns it to the Parents field. -func (o *GetProjectResponse) SetParents(v *[]ParentListInner) { - o.Parents = v -} - -// GetProjectId returns the ProjectId field value -func (o *GetProjectResponse) GetProjectId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ProjectId -} - -// GetProjectIdOk returns a tuple with the ProjectId field value -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetProjectIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ProjectId, true -} - -// SetProjectId sets field value -func (o *GetProjectResponse) SetProjectId(v *string) { - o.ProjectId = v -} - -// GetUpdateTime returns the UpdateTime field value -func (o *GetProjectResponse) GetUpdateTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.UpdateTime -} - -// GetUpdateTimeOk returns a tuple with the UpdateTime field value -// and a boolean to check if the value has been set. -func (o *GetProjectResponse) GetUpdateTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.UpdateTime, true -} - -// SetUpdateTime sets field value -func (o *GetProjectResponse) SetUpdateTime(v *time.Time) { - o.UpdateTime = v -} - -func (o GetProjectResponse) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["containerId"] = o.ContainerId - toSerialize["creationTime"] = o.CreationTime - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } - toSerialize["lifecycleState"] = o.LifecycleState - toSerialize["name"] = o.Name - toSerialize["parent"] = o.Parent - if !IsNil(o.Parents) { - toSerialize["parents"] = o.Parents - } - toSerialize["projectId"] = o.ProjectId - toSerialize["updateTime"] = o.UpdateTime - return toSerialize, nil -} - -type NullableGetProjectResponse struct { - value *GetProjectResponse - isSet bool -} - -func (v NullableGetProjectResponse) Get() *GetProjectResponse { - return v.value -} - -func (v *NullableGetProjectResponse) Set(val *GetProjectResponse) { - v.value = val - v.isSet = true -} - -func (v NullableGetProjectResponse) IsSet() bool { - return v.isSet -} - -func (v *NullableGetProjectResponse) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableGetProjectResponse(val *GetProjectResponse) *NullableGetProjectResponse { - return &NullableGetProjectResponse{value: val, isSet: true} -} - -func (v NullableGetProjectResponse) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableGetProjectResponse) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_list_organizations_response.go b/services/resourcemanager/model_list_organizations_response.go index 68f4f73a9..c07b2ab59 100644 --- a/services/resourcemanager/model_list_organizations_response.go +++ b/services/resourcemanager/model_list_organizations_response.go @@ -10,13 +10,6 @@ API version: 2.0 package resourcemanager -import ( - "encoding/json" -) - -// checks if the ListOrganizationsResponse type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &ListOrganizationsResponse{} - // ListOrganizationsResponse struct for ListOrganizationsResponse type ListOrganizationsResponse struct { // REQUIRED @@ -28,145 +21,3 @@ type ListOrganizationsResponse struct { // REQUIRED Offset *float64 `json:"offset"` } - -type _ListOrganizationsResponse ListOrganizationsResponse - -// NewListOrganizationsResponse instantiates a new ListOrganizationsResponse 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 NewListOrganizationsResponse(items *[]ListOrganizationsResponseItemsInner, limit *float64, offset *float64) *ListOrganizationsResponse { - this := ListOrganizationsResponse{} - this.Items = items - this.Limit = limit - this.Offset = offset - return &this -} - -// NewListOrganizationsResponseWithDefaults instantiates a new ListOrganizationsResponse 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 NewListOrganizationsResponseWithDefaults() *ListOrganizationsResponse { - this := ListOrganizationsResponse{} - var limit float64 = 50 - this.Limit = &limit - var offset float64 = 0 - this.Offset = &offset - return &this -} - -// GetItems returns the Items field value -func (o *ListOrganizationsResponse) GetItems() *[]ListOrganizationsResponseItemsInner { - if o == nil { - var ret *[]ListOrganizationsResponseItemsInner - return ret - } - - return o.Items -} - -// GetItemsOk returns a tuple with the Items field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponse) GetItemsOk() (*[]ListOrganizationsResponseItemsInner, bool) { - if o == nil { - return nil, false - } - return o.Items, true -} - -// SetItems sets field value -func (o *ListOrganizationsResponse) SetItems(v *[]ListOrganizationsResponseItemsInner) { - o.Items = v -} - -// GetLimit returns the Limit field value -func (o *ListOrganizationsResponse) GetLimit() *float64 { - if o == nil { - var ret *float64 - return ret - } - - return o.Limit -} - -// GetLimitOk returns a tuple with the Limit field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponse) GetLimitOk() (*float64, bool) { - if o == nil { - return nil, false - } - return o.Limit, true -} - -// SetLimit sets field value -func (o *ListOrganizationsResponse) SetLimit(v *float64) { - o.Limit = v -} - -// GetOffset returns the Offset field value -func (o *ListOrganizationsResponse) GetOffset() *float64 { - if o == nil { - var ret *float64 - return ret - } - - return o.Offset -} - -// GetOffsetOk returns a tuple with the Offset field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponse) GetOffsetOk() (*float64, bool) { - if o == nil { - return nil, false - } - return o.Offset, true -} - -// SetOffset sets field value -func (o *ListOrganizationsResponse) SetOffset(v *float64) { - o.Offset = v -} - -func (o ListOrganizationsResponse) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["items"] = o.Items - toSerialize["limit"] = o.Limit - toSerialize["offset"] = o.Offset - return toSerialize, nil -} - -type NullableListOrganizationsResponse struct { - value *ListOrganizationsResponse - isSet bool -} - -func (v NullableListOrganizationsResponse) Get() *ListOrganizationsResponse { - return v.value -} - -func (v *NullableListOrganizationsResponse) Set(val *ListOrganizationsResponse) { - v.value = val - v.isSet = true -} - -func (v NullableListOrganizationsResponse) IsSet() bool { - return v.isSet -} - -func (v *NullableListOrganizationsResponse) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableListOrganizationsResponse(val *ListOrganizationsResponse) *NullableListOrganizationsResponse { - return &NullableListOrganizationsResponse{value: val, isSet: true} -} - -func (v NullableListOrganizationsResponse) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableListOrganizationsResponse) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_list_organizations_response_items_inner.go b/services/resourcemanager/model_list_organizations_response_items_inner.go index ab600d5ed..9aaf63c87 100644 --- a/services/resourcemanager/model_list_organizations_response_items_inner.go +++ b/services/resourcemanager/model_list_organizations_response_items_inner.go @@ -11,13 +11,9 @@ API version: 2.0 package resourcemanager import ( - "encoding/json" "time" ) -// checks if the ListOrganizationsResponseItemsInner type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &ListOrganizationsResponseItemsInner{} - // ListOrganizationsResponseItemsInner struct for ListOrganizationsResponseItemsInner type ListOrganizationsResponseItemsInner struct { // Globally unique, user-friendly identifier. @@ -40,254 +36,3 @@ type ListOrganizationsResponseItemsInner struct { // REQUIRED UpdateTime *time.Time `json:"updateTime"` } - -type _ListOrganizationsResponseItemsInner ListOrganizationsResponseItemsInner - -// NewListOrganizationsResponseItemsInner instantiates a new ListOrganizationsResponseItemsInner 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 NewListOrganizationsResponseItemsInner(containerId *string, creationTime *time.Time, lifecycleState *LifecycleState, name *string, organizationId *string, updateTime *time.Time) *ListOrganizationsResponseItemsInner { - this := ListOrganizationsResponseItemsInner{} - this.ContainerId = containerId - this.CreationTime = creationTime - this.LifecycleState = lifecycleState - this.Name = name - this.OrganizationId = organizationId - this.UpdateTime = updateTime - return &this -} - -// NewListOrganizationsResponseItemsInnerWithDefaults instantiates a new ListOrganizationsResponseItemsInner 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 NewListOrganizationsResponseItemsInnerWithDefaults() *ListOrganizationsResponseItemsInner { - this := ListOrganizationsResponseItemsInner{} - return &this -} - -// GetContainerId returns the ContainerId field value -func (o *ListOrganizationsResponseItemsInner) GetContainerId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerId -} - -// GetContainerIdOk returns a tuple with the ContainerId field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponseItemsInner) GetContainerIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerId, true -} - -// SetContainerId sets field value -func (o *ListOrganizationsResponseItemsInner) SetContainerId(v *string) { - o.ContainerId = v -} - -// GetCreationTime returns the CreationTime field value -func (o *ListOrganizationsResponseItemsInner) GetCreationTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.CreationTime -} - -// GetCreationTimeOk returns a tuple with the CreationTime field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponseItemsInner) GetCreationTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.CreationTime, true -} - -// SetCreationTime sets field value -func (o *ListOrganizationsResponseItemsInner) SetCreationTime(v *time.Time) { - o.CreationTime = v -} - -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *ListOrganizationsResponseItemsInner) GetLabels() *map[string]string { - if o == nil || IsNil(o.Labels) { - var ret *map[string]string - return ret - } - return o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponseItemsInner) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *ListOrganizationsResponseItemsInner) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *ListOrganizationsResponseItemsInner) SetLabels(v *map[string]string) { - o.Labels = v -} - -// GetLifecycleState returns the LifecycleState field value -func (o *ListOrganizationsResponseItemsInner) GetLifecycleState() *LifecycleState { - if o == nil { - var ret *LifecycleState - return ret - } - - return o.LifecycleState -} - -// GetLifecycleStateOk returns a tuple with the LifecycleState field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponseItemsInner) GetLifecycleStateOk() (*LifecycleState, bool) { - if o == nil { - return nil, false - } - return o.LifecycleState, true -} - -// SetLifecycleState sets field value -func (o *ListOrganizationsResponseItemsInner) SetLifecycleState(v *LifecycleState) { - o.LifecycleState = v -} - -// GetName returns the Name field value -func (o *ListOrganizationsResponseItemsInner) GetName() *string { - if o == nil { - var ret *string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponseItemsInner) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Name, true -} - -// SetName sets field value -func (o *ListOrganizationsResponseItemsInner) SetName(v *string) { - o.Name = v -} - -// GetOrganizationId returns the OrganizationId field value -func (o *ListOrganizationsResponseItemsInner) GetOrganizationId() *string { - if o == nil { - var ret *string - return ret - } - - return o.OrganizationId -} - -// GetOrganizationIdOk returns a tuple with the OrganizationId field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponseItemsInner) GetOrganizationIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.OrganizationId, true -} - -// SetOrganizationId sets field value -func (o *ListOrganizationsResponseItemsInner) SetOrganizationId(v *string) { - o.OrganizationId = v -} - -// GetUpdateTime returns the UpdateTime field value -func (o *ListOrganizationsResponseItemsInner) GetUpdateTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.UpdateTime -} - -// GetUpdateTimeOk returns a tuple with the UpdateTime field value -// and a boolean to check if the value has been set. -func (o *ListOrganizationsResponseItemsInner) GetUpdateTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.UpdateTime, true -} - -// SetUpdateTime sets field value -func (o *ListOrganizationsResponseItemsInner) SetUpdateTime(v *time.Time) { - o.UpdateTime = v -} - -func (o ListOrganizationsResponseItemsInner) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["containerId"] = o.ContainerId - toSerialize["creationTime"] = o.CreationTime - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } - toSerialize["lifecycleState"] = o.LifecycleState - toSerialize["name"] = o.Name - toSerialize["organizationId"] = o.OrganizationId - toSerialize["updateTime"] = o.UpdateTime - return toSerialize, nil -} - -type NullableListOrganizationsResponseItemsInner struct { - value *ListOrganizationsResponseItemsInner - isSet bool -} - -func (v NullableListOrganizationsResponseItemsInner) Get() *ListOrganizationsResponseItemsInner { - return v.value -} - -func (v *NullableListOrganizationsResponseItemsInner) Set(val *ListOrganizationsResponseItemsInner) { - v.value = val - v.isSet = true -} - -func (v NullableListOrganizationsResponseItemsInner) IsSet() bool { - return v.isSet -} - -func (v *NullableListOrganizationsResponseItemsInner) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableListOrganizationsResponseItemsInner(val *ListOrganizationsResponseItemsInner) *NullableListOrganizationsResponseItemsInner { - return &NullableListOrganizationsResponseItemsInner{value: val, isSet: true} -} - -func (v NullableListOrganizationsResponseItemsInner) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableListOrganizationsResponseItemsInner) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_list_projects_response.go b/services/resourcemanager/model_list_projects_response.go index 6a6e5c355..c0b9c44a9 100644 --- a/services/resourcemanager/model_list_projects_response.go +++ b/services/resourcemanager/model_list_projects_response.go @@ -10,13 +10,6 @@ API version: 2.0 package resourcemanager -import ( - "encoding/json" -) - -// checks if the ListProjectsResponse type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &ListProjectsResponse{} - // ListProjectsResponse struct for ListProjectsResponse type ListProjectsResponse struct { // REQUIRED @@ -28,145 +21,3 @@ type ListProjectsResponse struct { // REQUIRED Offset *float64 `json:"offset"` } - -type _ListProjectsResponse ListProjectsResponse - -// NewListProjectsResponse instantiates a new ListProjectsResponse 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 NewListProjectsResponse(items *[]Project, limit *float64, offset *float64) *ListProjectsResponse { - this := ListProjectsResponse{} - this.Items = items - this.Limit = limit - this.Offset = offset - return &this -} - -// NewListProjectsResponseWithDefaults instantiates a new ListProjectsResponse 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 NewListProjectsResponseWithDefaults() *ListProjectsResponse { - this := ListProjectsResponse{} - var limit float64 = 50 - this.Limit = &limit - var offset float64 = 0 - this.Offset = &offset - return &this -} - -// GetItems returns the Items field value -func (o *ListProjectsResponse) GetItems() *[]Project { - if o == nil { - var ret *[]Project - return ret - } - - return o.Items -} - -// GetItemsOk returns a tuple with the Items field value -// and a boolean to check if the value has been set. -func (o *ListProjectsResponse) GetItemsOk() (*[]Project, bool) { - if o == nil { - return nil, false - } - return o.Items, true -} - -// SetItems sets field value -func (o *ListProjectsResponse) SetItems(v *[]Project) { - o.Items = v -} - -// GetLimit returns the Limit field value -func (o *ListProjectsResponse) GetLimit() *float64 { - if o == nil { - var ret *float64 - return ret - } - - return o.Limit -} - -// GetLimitOk returns a tuple with the Limit field value -// and a boolean to check if the value has been set. -func (o *ListProjectsResponse) GetLimitOk() (*float64, bool) { - if o == nil { - return nil, false - } - return o.Limit, true -} - -// SetLimit sets field value -func (o *ListProjectsResponse) SetLimit(v *float64) { - o.Limit = v -} - -// GetOffset returns the Offset field value -func (o *ListProjectsResponse) GetOffset() *float64 { - if o == nil { - var ret *float64 - return ret - } - - return o.Offset -} - -// GetOffsetOk returns a tuple with the Offset field value -// and a boolean to check if the value has been set. -func (o *ListProjectsResponse) GetOffsetOk() (*float64, bool) { - if o == nil { - return nil, false - } - return o.Offset, true -} - -// SetOffset sets field value -func (o *ListProjectsResponse) SetOffset(v *float64) { - o.Offset = v -} - -func (o ListProjectsResponse) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["items"] = o.Items - toSerialize["limit"] = o.Limit - toSerialize["offset"] = o.Offset - return toSerialize, nil -} - -type NullableListProjectsResponse struct { - value *ListProjectsResponse - isSet bool -} - -func (v NullableListProjectsResponse) Get() *ListProjectsResponse { - return v.value -} - -func (v *NullableListProjectsResponse) Set(val *ListProjectsResponse) { - v.value = val - v.isSet = true -} - -func (v NullableListProjectsResponse) IsSet() bool { - return v.isSet -} - -func (v *NullableListProjectsResponse) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableListProjectsResponse(val *ListProjectsResponse) *NullableListProjectsResponse { - return &NullableListProjectsResponse{value: val, isSet: true} -} - -func (v NullableListProjectsResponse) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableListProjectsResponse) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_member.go b/services/resourcemanager/model_member.go index 363da48ed..eac77fa49 100644 --- a/services/resourcemanager/model_member.go +++ b/services/resourcemanager/model_member.go @@ -10,13 +10,6 @@ API version: 2.0 package resourcemanager -import ( - "encoding/json" -) - -// checks if the Member type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &Member{} - // Member struct for Member type Member struct { // A valid role defined for the resource. @@ -26,115 +19,3 @@ type Member struct { // REQUIRED Subject *string `json:"subject"` } - -type _Member Member - -// NewMember instantiates a new Member 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 NewMember(role *string, subject *string) *Member { - this := Member{} - this.Role = role - this.Subject = subject - return &this -} - -// NewMemberWithDefaults instantiates a new Member 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 NewMemberWithDefaults() *Member { - this := Member{} - return &this -} - -// GetRole returns the Role field value -func (o *Member) GetRole() *string { - if o == nil { - var ret *string - return ret - } - - return o.Role -} - -// GetRoleOk returns a tuple with the Role field value -// and a boolean to check if the value has been set. -func (o *Member) GetRoleOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Role, true -} - -// SetRole sets field value -func (o *Member) SetRole(v *string) { - o.Role = v -} - -// GetSubject returns the Subject field value -func (o *Member) GetSubject() *string { - if o == nil { - var ret *string - return ret - } - - return o.Subject -} - -// GetSubjectOk returns a tuple with the Subject field value -// and a boolean to check if the value has been set. -func (o *Member) GetSubjectOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Subject, true -} - -// SetSubject sets field value -func (o *Member) SetSubject(v *string) { - o.Subject = v -} - -func (o Member) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["role"] = o.Role - toSerialize["subject"] = o.Subject - return toSerialize, nil -} - -type NullableMember struct { - value *Member - isSet bool -} - -func (v NullableMember) Get() *Member { - return v.value -} - -func (v *NullableMember) Set(val *Member) { - v.value = val - v.isSet = true -} - -func (v NullableMember) IsSet() bool { - return v.isSet -} - -func (v *NullableMember) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableMember(val *Member) *NullableMember { - return &NullableMember{value: val, isSet: true} -} - -func (v NullableMember) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableMember) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_organization_response.go b/services/resourcemanager/model_organization_response.go index ef0946f8f..7fd66e098 100644 --- a/services/resourcemanager/model_organization_response.go +++ b/services/resourcemanager/model_organization_response.go @@ -11,13 +11,9 @@ API version: 2.0 package resourcemanager import ( - "encoding/json" "time" ) -// checks if the OrganizationResponse type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &OrganizationResponse{} - // OrganizationResponse struct for OrganizationResponse type OrganizationResponse struct { // Globally unique, user-friendly identifier. @@ -40,254 +36,3 @@ type OrganizationResponse struct { // REQUIRED UpdateTime *time.Time `json:"updateTime"` } - -type _OrganizationResponse OrganizationResponse - -// NewOrganizationResponse instantiates a new OrganizationResponse 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 NewOrganizationResponse(containerId *string, creationTime *time.Time, lifecycleState *LifecycleState, name *string, organizationId *string, updateTime *time.Time) *OrganizationResponse { - this := OrganizationResponse{} - this.ContainerId = containerId - this.CreationTime = creationTime - this.LifecycleState = lifecycleState - this.Name = name - this.OrganizationId = organizationId - this.UpdateTime = updateTime - return &this -} - -// NewOrganizationResponseWithDefaults instantiates a new OrganizationResponse 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 NewOrganizationResponseWithDefaults() *OrganizationResponse { - this := OrganizationResponse{} - return &this -} - -// GetContainerId returns the ContainerId field value -func (o *OrganizationResponse) GetContainerId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerId -} - -// GetContainerIdOk returns a tuple with the ContainerId field value -// and a boolean to check if the value has been set. -func (o *OrganizationResponse) GetContainerIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerId, true -} - -// SetContainerId sets field value -func (o *OrganizationResponse) SetContainerId(v *string) { - o.ContainerId = v -} - -// GetCreationTime returns the CreationTime field value -func (o *OrganizationResponse) GetCreationTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.CreationTime -} - -// GetCreationTimeOk returns a tuple with the CreationTime field value -// and a boolean to check if the value has been set. -func (o *OrganizationResponse) GetCreationTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.CreationTime, true -} - -// SetCreationTime sets field value -func (o *OrganizationResponse) SetCreationTime(v *time.Time) { - o.CreationTime = v -} - -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *OrganizationResponse) GetLabels() *map[string]string { - if o == nil || IsNil(o.Labels) { - var ret *map[string]string - return ret - } - return o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *OrganizationResponse) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *OrganizationResponse) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *OrganizationResponse) SetLabels(v *map[string]string) { - o.Labels = v -} - -// GetLifecycleState returns the LifecycleState field value -func (o *OrganizationResponse) GetLifecycleState() *LifecycleState { - if o == nil { - var ret *LifecycleState - return ret - } - - return o.LifecycleState -} - -// GetLifecycleStateOk returns a tuple with the LifecycleState field value -// and a boolean to check if the value has been set. -func (o *OrganizationResponse) GetLifecycleStateOk() (*LifecycleState, bool) { - if o == nil { - return nil, false - } - return o.LifecycleState, true -} - -// SetLifecycleState sets field value -func (o *OrganizationResponse) SetLifecycleState(v *LifecycleState) { - o.LifecycleState = v -} - -// GetName returns the Name field value -func (o *OrganizationResponse) GetName() *string { - if o == nil { - var ret *string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *OrganizationResponse) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Name, true -} - -// SetName sets field value -func (o *OrganizationResponse) SetName(v *string) { - o.Name = v -} - -// GetOrganizationId returns the OrganizationId field value -func (o *OrganizationResponse) GetOrganizationId() *string { - if o == nil { - var ret *string - return ret - } - - return o.OrganizationId -} - -// GetOrganizationIdOk returns a tuple with the OrganizationId field value -// and a boolean to check if the value has been set. -func (o *OrganizationResponse) GetOrganizationIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.OrganizationId, true -} - -// SetOrganizationId sets field value -func (o *OrganizationResponse) SetOrganizationId(v *string) { - o.OrganizationId = v -} - -// GetUpdateTime returns the UpdateTime field value -func (o *OrganizationResponse) GetUpdateTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.UpdateTime -} - -// GetUpdateTimeOk returns a tuple with the UpdateTime field value -// and a boolean to check if the value has been set. -func (o *OrganizationResponse) GetUpdateTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.UpdateTime, true -} - -// SetUpdateTime sets field value -func (o *OrganizationResponse) SetUpdateTime(v *time.Time) { - o.UpdateTime = v -} - -func (o OrganizationResponse) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["containerId"] = o.ContainerId - toSerialize["creationTime"] = o.CreationTime - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } - toSerialize["lifecycleState"] = o.LifecycleState - toSerialize["name"] = o.Name - toSerialize["organizationId"] = o.OrganizationId - toSerialize["updateTime"] = o.UpdateTime - return toSerialize, nil -} - -type NullableOrganizationResponse struct { - value *OrganizationResponse - isSet bool -} - -func (v NullableOrganizationResponse) Get() *OrganizationResponse { - return v.value -} - -func (v *NullableOrganizationResponse) Set(val *OrganizationResponse) { - v.value = val - v.isSet = true -} - -func (v NullableOrganizationResponse) IsSet() bool { - return v.isSet -} - -func (v *NullableOrganizationResponse) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableOrganizationResponse(val *OrganizationResponse) *NullableOrganizationResponse { - return &NullableOrganizationResponse{value: val, isSet: true} -} - -func (v NullableOrganizationResponse) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableOrganizationResponse) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_parent.go b/services/resourcemanager/model_parent.go index 6f93c2216..b330c67ca 100644 --- a/services/resourcemanager/model_parent.go +++ b/services/resourcemanager/model_parent.go @@ -10,13 +10,6 @@ API version: 2.0 package resourcemanager -import ( - "encoding/json" -) - -// checks if the Parent type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &Parent{} - // Parent Parent container. type Parent struct { // User-friendly identifier of either organization or folder (will replace id). @@ -29,141 +22,3 @@ type Parent struct { // REQUIRED Type *string `json:"type"` } - -type _Parent Parent - -// NewParent instantiates a new Parent 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 NewParent(containerId *string, id *string, type_ *string) *Parent { - this := Parent{} - this.ContainerId = containerId - this.Id = id - this.Type = type_ - return &this -} - -// NewParentWithDefaults instantiates a new Parent 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 NewParentWithDefaults() *Parent { - this := Parent{} - return &this -} - -// GetContainerId returns the ContainerId field value -func (o *Parent) GetContainerId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerId -} - -// GetContainerIdOk returns a tuple with the ContainerId field value -// and a boolean to check if the value has been set. -func (o *Parent) GetContainerIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerId, true -} - -// SetContainerId sets field value -func (o *Parent) SetContainerId(v *string) { - o.ContainerId = v -} - -// GetId returns the Id field value -func (o *Parent) GetId() *string { - if o == nil { - var ret *string - return ret - } - - return o.Id -} - -// GetIdOk returns a tuple with the Id field value -// and a boolean to check if the value has been set. -func (o *Parent) GetIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Id, true -} - -// SetId sets field value -func (o *Parent) SetId(v *string) { - o.Id = v -} - -// GetType returns the Type field value -func (o *Parent) GetType() *string { - if o == nil { - var ret *string - return ret - } - - return o.Type -} - -// GetTypeOk returns a tuple with the Type field value -// and a boolean to check if the value has been set. -func (o *Parent) GetTypeOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Type, true -} - -// SetType sets field value -func (o *Parent) SetType(v *string) { - o.Type = v -} - -func (o Parent) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["containerId"] = o.ContainerId - toSerialize["id"] = o.Id - toSerialize["type"] = o.Type - return toSerialize, nil -} - -type NullableParent struct { - value *Parent - isSet bool -} - -func (v NullableParent) Get() *Parent { - return v.value -} - -func (v *NullableParent) Set(val *Parent) { - v.value = val - v.isSet = true -} - -func (v NullableParent) IsSet() bool { - return v.isSet -} - -func (v *NullableParent) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableParent(val *Parent) *NullableParent { - return &NullableParent{value: val, isSet: true} -} - -func (v NullableParent) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableParent) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_parent_list_inner.go b/services/resourcemanager/model_parent_list_inner.go index f741bfc7c..abfe9c481 100644 --- a/services/resourcemanager/model_parent_list_inner.go +++ b/services/resourcemanager/model_parent_list_inner.go @@ -10,13 +10,6 @@ API version: 2.0 package resourcemanager -import ( - "encoding/json" -) - -// checks if the ParentListInner type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &ParentListInner{} - // ParentListInner struct for ParentListInner type ParentListInner struct { // User-friendly identifier of either organization or folder (will replace id). @@ -38,219 +31,3 @@ type ParentListInner struct { // REQUIRED Type *string `json:"type"` } - -type _ParentListInner ParentListInner - -// NewParentListInner instantiates a new ParentListInner 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 NewParentListInner(containerId *string, containerParentId *string, id *string, name *string, parentId *string, type_ *string) *ParentListInner { - this := ParentListInner{} - this.ContainerId = containerId - this.ContainerParentId = containerParentId - this.Id = id - this.Name = name - this.ParentId = parentId - this.Type = type_ - return &this -} - -// NewParentListInnerWithDefaults instantiates a new ParentListInner 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 NewParentListInnerWithDefaults() *ParentListInner { - this := ParentListInner{} - return &this -} - -// GetContainerId returns the ContainerId field value -func (o *ParentListInner) GetContainerId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerId -} - -// GetContainerIdOk returns a tuple with the ContainerId field value -// and a boolean to check if the value has been set. -func (o *ParentListInner) GetContainerIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerId, true -} - -// SetContainerId sets field value -func (o *ParentListInner) SetContainerId(v *string) { - o.ContainerId = v -} - -// GetContainerParentId returns the ContainerParentId field value -func (o *ParentListInner) GetContainerParentId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerParentId -} - -// GetContainerParentIdOk returns a tuple with the ContainerParentId field value -// and a boolean to check if the value has been set. -func (o *ParentListInner) GetContainerParentIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerParentId, true -} - -// SetContainerParentId sets field value -func (o *ParentListInner) SetContainerParentId(v *string) { - o.ContainerParentId = v -} - -// GetId returns the Id field value -func (o *ParentListInner) GetId() *string { - if o == nil { - var ret *string - return ret - } - - return o.Id -} - -// GetIdOk returns a tuple with the Id field value -// and a boolean to check if the value has been set. -func (o *ParentListInner) GetIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Id, true -} - -// SetId sets field value -func (o *ParentListInner) SetId(v *string) { - o.Id = v -} - -// GetName returns the Name field value -func (o *ParentListInner) GetName() *string { - if o == nil { - var ret *string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *ParentListInner) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Name, true -} - -// SetName sets field value -func (o *ParentListInner) SetName(v *string) { - o.Name = v -} - -// GetParentId returns the ParentId field value -func (o *ParentListInner) GetParentId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ParentId -} - -// GetParentIdOk returns a tuple with the ParentId field value -// and a boolean to check if the value has been set. -func (o *ParentListInner) GetParentIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ParentId, true -} - -// SetParentId sets field value -func (o *ParentListInner) SetParentId(v *string) { - o.ParentId = v -} - -// GetType returns the Type field value -func (o *ParentListInner) GetType() *string { - if o == nil { - var ret *string - return ret - } - - return o.Type -} - -// GetTypeOk returns a tuple with the Type field value -// and a boolean to check if the value has been set. -func (o *ParentListInner) GetTypeOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Type, true -} - -// SetType sets field value -func (o *ParentListInner) SetType(v *string) { - o.Type = v -} - -func (o ParentListInner) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["containerId"] = o.ContainerId - toSerialize["containerParentId"] = o.ContainerParentId - toSerialize["id"] = o.Id - toSerialize["name"] = o.Name - toSerialize["parentId"] = o.ParentId - toSerialize["type"] = o.Type - return toSerialize, nil -} - -type NullableParentListInner struct { - value *ParentListInner - isSet bool -} - -func (v NullableParentListInner) Get() *ParentListInner { - return v.value -} - -func (v *NullableParentListInner) Set(val *ParentListInner) { - v.value = val - v.isSet = true -} - -func (v NullableParentListInner) IsSet() bool { - return v.isSet -} - -func (v *NullableParentListInner) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableParentListInner(val *ParentListInner) *NullableParentListInner { - return &NullableParentListInner{value: val, isSet: true} -} - -func (v NullableParentListInner) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableParentListInner) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_partial_update_project_payload.go b/services/resourcemanager/model_partial_update_project_payload.go index e3568fedb..d9ae8bc91 100644 --- a/services/resourcemanager/model_partial_update_project_payload.go +++ b/services/resourcemanager/model_partial_update_project_payload.go @@ -10,13 +10,6 @@ API version: 2.0 package resourcemanager -import ( - "encoding/json" -) - -// checks if the PartialUpdateProjectPayload type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &PartialUpdateProjectPayload{} - // PartialUpdateProjectPayload struct for PartialUpdateProjectPayload type PartialUpdateProjectPayload struct { // New parent identifier for the resource container - containerId as well as UUID identifier is supported. @@ -26,166 +19,3 @@ type PartialUpdateProjectPayload struct { // New name for the resource container matching the regex `^[a-zA-ZäüöÄÜÖ0-9]( ?[a-zA-ZäüöÄÜÖß0-9_+&-]){0,39}$`. Name *string `json:"name,omitempty"` } - -// NewPartialUpdateProjectPayload instantiates a new PartialUpdateProjectPayload 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 NewPartialUpdateProjectPayload() *PartialUpdateProjectPayload { - this := PartialUpdateProjectPayload{} - return &this -} - -// NewPartialUpdateProjectPayloadWithDefaults instantiates a new PartialUpdateProjectPayload 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 NewPartialUpdateProjectPayloadWithDefaults() *PartialUpdateProjectPayload { - this := PartialUpdateProjectPayload{} - return &this -} - -// GetContainerParentId returns the ContainerParentId field value if set, zero value otherwise. -func (o *PartialUpdateProjectPayload) GetContainerParentId() *string { - if o == nil || IsNil(o.ContainerParentId) { - var ret *string - return ret - } - return o.ContainerParentId -} - -// GetContainerParentIdOk returns a tuple with the ContainerParentId field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PartialUpdateProjectPayload) GetContainerParentIdOk() (*string, bool) { - if o == nil || IsNil(o.ContainerParentId) { - return nil, false - } - return o.ContainerParentId, true -} - -// HasContainerParentId returns a boolean if a field has been set. -func (o *PartialUpdateProjectPayload) HasContainerParentId() bool { - if o != nil && !IsNil(o.ContainerParentId) { - return true - } - - return false -} - -// SetContainerParentId gets a reference to the given string and assigns it to the ContainerParentId field. -func (o *PartialUpdateProjectPayload) SetContainerParentId(v *string) { - o.ContainerParentId = v -} - -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *PartialUpdateProjectPayload) GetLabels() *map[string]string { - if o == nil || IsNil(o.Labels) { - var ret *map[string]string - return ret - } - return o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *PartialUpdateProjectPayload) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *PartialUpdateProjectPayload) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *PartialUpdateProjectPayload) SetLabels(v *map[string]string) { - o.Labels = v -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *PartialUpdateProjectPayload) 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 *PartialUpdateProjectPayload) 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 *PartialUpdateProjectPayload) 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 *PartialUpdateProjectPayload) SetName(v *string) { - o.Name = v -} - -func (o PartialUpdateProjectPayload) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - if !IsNil(o.ContainerParentId) { - toSerialize["containerParentId"] = o.ContainerParentId - } - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } - if !IsNil(o.Name) { - toSerialize["name"] = o.Name - } - return toSerialize, nil -} - -type NullablePartialUpdateProjectPayload struct { - value *PartialUpdateProjectPayload - isSet bool -} - -func (v NullablePartialUpdateProjectPayload) Get() *PartialUpdateProjectPayload { - return v.value -} - -func (v *NullablePartialUpdateProjectPayload) Set(val *PartialUpdateProjectPayload) { - v.value = val - v.isSet = true -} - -func (v NullablePartialUpdateProjectPayload) IsSet() bool { - return v.isSet -} - -func (v *NullablePartialUpdateProjectPayload) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullablePartialUpdateProjectPayload(val *PartialUpdateProjectPayload) *NullablePartialUpdateProjectPayload { - return &NullablePartialUpdateProjectPayload{value: val, isSet: true} -} - -func (v NullablePartialUpdateProjectPayload) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullablePartialUpdateProjectPayload) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -} diff --git a/services/resourcemanager/model_project.go b/services/resourcemanager/model_project.go index ca164525c..01387b7d4 100644 --- a/services/resourcemanager/model_project.go +++ b/services/resourcemanager/model_project.go @@ -11,13 +11,9 @@ API version: 2.0 package resourcemanager import ( - "encoding/json" "time" ) -// checks if the Project type satisfies the MappedNullable interface at compile time -var _ MappedNullable = &Project{} - // Project struct for Project type Project struct { // Globally unique, user-friendly identifier. @@ -42,280 +38,3 @@ type Project struct { // REQUIRED UpdateTime *time.Time `json:"updateTime"` } - -type _Project Project - -// NewProject instantiates a new Project 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 NewProject(containerId *string, creationTime *time.Time, lifecycleState *LifecycleState, name *string, parent *Parent, projectId *string, updateTime *time.Time) *Project { - this := Project{} - this.ContainerId = containerId - this.CreationTime = creationTime - this.LifecycleState = lifecycleState - this.Name = name - this.Parent = parent - this.ProjectId = projectId - this.UpdateTime = updateTime - return &this -} - -// NewProjectWithDefaults instantiates a new Project 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 NewProjectWithDefaults() *Project { - this := Project{} - return &this -} - -// GetContainerId returns the ContainerId field value -func (o *Project) GetContainerId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ContainerId -} - -// GetContainerIdOk returns a tuple with the ContainerId field value -// and a boolean to check if the value has been set. -func (o *Project) GetContainerIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ContainerId, true -} - -// SetContainerId sets field value -func (o *Project) SetContainerId(v *string) { - o.ContainerId = v -} - -// GetCreationTime returns the CreationTime field value -func (o *Project) GetCreationTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.CreationTime -} - -// GetCreationTimeOk returns a tuple with the CreationTime field value -// and a boolean to check if the value has been set. -func (o *Project) GetCreationTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.CreationTime, true -} - -// SetCreationTime sets field value -func (o *Project) SetCreationTime(v *time.Time) { - o.CreationTime = v -} - -// GetLabels returns the Labels field value if set, zero value otherwise. -func (o *Project) GetLabels() *map[string]string { - if o == nil || IsNil(o.Labels) { - var ret *map[string]string - return ret - } - return o.Labels -} - -// GetLabelsOk returns a tuple with the Labels field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *Project) GetLabelsOk() (*map[string]string, bool) { - if o == nil || IsNil(o.Labels) { - return nil, false - } - return o.Labels, true -} - -// HasLabels returns a boolean if a field has been set. -func (o *Project) HasLabels() bool { - if o != nil && !IsNil(o.Labels) { - return true - } - - return false -} - -// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field. -func (o *Project) SetLabels(v *map[string]string) { - o.Labels = v -} - -// GetLifecycleState returns the LifecycleState field value -func (o *Project) GetLifecycleState() *LifecycleState { - if o == nil { - var ret *LifecycleState - return ret - } - - return o.LifecycleState -} - -// GetLifecycleStateOk returns a tuple with the LifecycleState field value -// and a boolean to check if the value has been set. -func (o *Project) GetLifecycleStateOk() (*LifecycleState, bool) { - if o == nil { - return nil, false - } - return o.LifecycleState, true -} - -// SetLifecycleState sets field value -func (o *Project) SetLifecycleState(v *LifecycleState) { - o.LifecycleState = v -} - -// GetName returns the Name field value -func (o *Project) GetName() *string { - if o == nil { - var ret *string - return ret - } - - return o.Name -} - -// GetNameOk returns a tuple with the Name field value -// and a boolean to check if the value has been set. -func (o *Project) GetNameOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Name, true -} - -// SetName sets field value -func (o *Project) SetName(v *string) { - o.Name = v -} - -// GetParent returns the Parent field value -func (o *Project) GetParent() *Parent { - if o == nil { - var ret *Parent - return ret - } - - return o.Parent -} - -// GetParentOk returns a tuple with the Parent field value -// and a boolean to check if the value has been set. -func (o *Project) GetParentOk() (*Parent, bool) { - if o == nil { - return nil, false - } - return o.Parent, true -} - -// SetParent sets field value -func (o *Project) SetParent(v *Parent) { - o.Parent = v -} - -// GetProjectId returns the ProjectId field value -func (o *Project) GetProjectId() *string { - if o == nil { - var ret *string - return ret - } - - return o.ProjectId -} - -// GetProjectIdOk returns a tuple with the ProjectId field value -// and a boolean to check if the value has been set. -func (o *Project) GetProjectIdOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.ProjectId, true -} - -// SetProjectId sets field value -func (o *Project) SetProjectId(v *string) { - o.ProjectId = v -} - -// GetUpdateTime returns the UpdateTime field value -func (o *Project) GetUpdateTime() *time.Time { - if o == nil { - var ret *time.Time - return ret - } - - return o.UpdateTime -} - -// GetUpdateTimeOk returns a tuple with the UpdateTime field value -// and a boolean to check if the value has been set. -func (o *Project) GetUpdateTimeOk() (*time.Time, bool) { - if o == nil { - return nil, false - } - return o.UpdateTime, true -} - -// SetUpdateTime sets field value -func (o *Project) SetUpdateTime(v *time.Time) { - o.UpdateTime = v -} - -func (o Project) ToMap() (map[string]interface{}, error) { - toSerialize := map[string]interface{}{} - toSerialize["containerId"] = o.ContainerId - toSerialize["creationTime"] = o.CreationTime - if !IsNil(o.Labels) { - toSerialize["labels"] = o.Labels - } - toSerialize["lifecycleState"] = o.LifecycleState - toSerialize["name"] = o.Name - toSerialize["parent"] = o.Parent - toSerialize["projectId"] = o.ProjectId - toSerialize["updateTime"] = o.UpdateTime - return toSerialize, nil -} - -type NullableProject struct { - value *Project - isSet bool -} - -func (v NullableProject) Get() *Project { - return v.value -} - -func (v *NullableProject) Set(val *Project) { - v.value = val - v.isSet = true -} - -func (v NullableProject) IsSet() bool { - return v.isSet -} - -func (v *NullableProject) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableProject(val *Project) *NullableProject { - return &NullableProject{value: val, isSet: true} -} - -func (v NullableProject) MarshalJSON() ([]byte, error) { - return json.Marshal(v.value) -} - -func (v *NullableProject) UnmarshalJSON(src []byte) error { - v.isSet = true - return json.Unmarshal(src, &v.value) -}