## Description
<!-- **Please link some issue here describing what you are trying to achieve.**
In case there is no issue present for your PR, please consider creating one.
At least please give us some description what you are trying to achieve and why your change is needed. -->
relates to #1234
## Checklist
- [ ] Issue was linked above
- [ ] Code format was applied: `make fmt`
- [ ] Examples were added / adjusted (see `examples/` directory)
- [x] Docs are up-to-date: `make generate-docs` (will be checked by CI)
- [ ] Unit tests got implemented or updated
- [ ] Acceptance tests got implemented or updated (see e.g. [here](f5f99d1709/stackit/internal/services/dns/dns_acc_test.go))
- [x] Unit tests are passing: `make test` (will be checked by CI)
- [x] No linter issues: `make lint` (will be checked by CI)
Reviewed-on: #4
Reviewed-by: Andre_Harms <andre.harms@stackit.cloud>
Co-authored-by: Marcel S. Henselin <marcel.henselin@stackit.cloud>
Co-committed-by: Marcel S. Henselin <marcel.henselin@stackit.cloud>
802 lines
28 KiB
Go
802 lines
28 KiB
Go
/*
|
|
STACKIT File Storage (SFS)
|
|
|
|
API used to create and manage NFS Shares.
|
|
|
|
API version: 1beta.0.0
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package sfsbeta
|
|
|
|
import (
|
|
"encoding/json"
|
|
"time"
|
|
)
|
|
|
|
// checks if the ResourcePool type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &ResourcePool{}
|
|
|
|
/*
|
|
types and functions for availabilityZone
|
|
*/
|
|
|
|
// isNotNullableString
|
|
type ResourcePoolGetAvailabilityZoneAttributeType = *string
|
|
|
|
func getResourcePoolGetAvailabilityZoneAttributeTypeOk(arg ResourcePoolGetAvailabilityZoneAttributeType) (ret ResourcePoolGetAvailabilityZoneRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetAvailabilityZoneAttributeType(arg *ResourcePoolGetAvailabilityZoneAttributeType, val ResourcePoolGetAvailabilityZoneRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
type ResourcePoolGetAvailabilityZoneArgType = string
|
|
type ResourcePoolGetAvailabilityZoneRetType = string
|
|
|
|
/*
|
|
types and functions for countShares
|
|
*/
|
|
|
|
// isInteger
|
|
type ResourcePoolGetCountSharesAttributeType = *int64
|
|
type ResourcePoolGetCountSharesArgType = int64
|
|
type ResourcePoolGetCountSharesRetType = int64
|
|
|
|
func getResourcePoolGetCountSharesAttributeTypeOk(arg ResourcePoolGetCountSharesAttributeType) (ret ResourcePoolGetCountSharesRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetCountSharesAttributeType(arg *ResourcePoolGetCountSharesAttributeType, val ResourcePoolGetCountSharesRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for createdAt
|
|
*/
|
|
|
|
// isDateTime
|
|
type ResourcePoolGetCreatedAtAttributeType = *time.Time
|
|
type ResourcePoolGetCreatedAtArgType = time.Time
|
|
type ResourcePoolGetCreatedAtRetType = time.Time
|
|
|
|
func getResourcePoolGetCreatedAtAttributeTypeOk(arg ResourcePoolGetCreatedAtAttributeType) (ret ResourcePoolGetCreatedAtRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetCreatedAtAttributeType(arg *ResourcePoolGetCreatedAtAttributeType, val ResourcePoolGetCreatedAtRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for id
|
|
*/
|
|
|
|
// isNotNullableString
|
|
type ResourcePoolGetIdAttributeType = *string
|
|
|
|
func getResourcePoolGetIdAttributeTypeOk(arg ResourcePoolGetIdAttributeType) (ret ResourcePoolGetIdRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetIdAttributeType(arg *ResourcePoolGetIdAttributeType, val ResourcePoolGetIdRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
type ResourcePoolGetIdArgType = string
|
|
type ResourcePoolGetIdRetType = string
|
|
|
|
/*
|
|
types and functions for ipAcl
|
|
*/
|
|
|
|
// isArray
|
|
type ResourcePoolGetIpAclAttributeType = *[]string
|
|
type ResourcePoolGetIpAclArgType = []string
|
|
type ResourcePoolGetIpAclRetType = []string
|
|
|
|
func getResourcePoolGetIpAclAttributeTypeOk(arg ResourcePoolGetIpAclAttributeType) (ret ResourcePoolGetIpAclRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetIpAclAttributeType(arg *ResourcePoolGetIpAclAttributeType, val ResourcePoolGetIpAclRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for labels
|
|
*/
|
|
|
|
// isContainer
|
|
type ResourcePoolGetLabelsAttributeType = *map[string]string
|
|
type ResourcePoolGetLabelsArgType = map[string]string
|
|
type ResourcePoolGetLabelsRetType = map[string]string
|
|
|
|
func getResourcePoolGetLabelsAttributeTypeOk(arg ResourcePoolGetLabelsAttributeType) (ret ResourcePoolGetLabelsRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetLabelsAttributeType(arg *ResourcePoolGetLabelsAttributeType, val ResourcePoolGetLabelsRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for mountPath
|
|
*/
|
|
|
|
// isNotNullableString
|
|
type ResourcePoolGetMountPathAttributeType = *string
|
|
|
|
func getResourcePoolGetMountPathAttributeTypeOk(arg ResourcePoolGetMountPathAttributeType) (ret ResourcePoolGetMountPathRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetMountPathAttributeType(arg *ResourcePoolGetMountPathAttributeType, val ResourcePoolGetMountPathRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
type ResourcePoolGetMountPathArgType = string
|
|
type ResourcePoolGetMountPathRetType = string
|
|
|
|
/*
|
|
types and functions for name
|
|
*/
|
|
|
|
// isNotNullableString
|
|
type ResourcePoolGetNameAttributeType = *string
|
|
|
|
func getResourcePoolGetNameAttributeTypeOk(arg ResourcePoolGetNameAttributeType) (ret ResourcePoolGetNameRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetNameAttributeType(arg *ResourcePoolGetNameAttributeType, val ResourcePoolGetNameRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
type ResourcePoolGetNameArgType = string
|
|
type ResourcePoolGetNameRetType = string
|
|
|
|
/*
|
|
types and functions for performanceClass
|
|
*/
|
|
|
|
// isModel
|
|
type ResourcePoolGetPerformanceClassAttributeType = *ResourcePoolPerformanceClass
|
|
type ResourcePoolGetPerformanceClassArgType = ResourcePoolPerformanceClass
|
|
type ResourcePoolGetPerformanceClassRetType = ResourcePoolPerformanceClass
|
|
|
|
func getResourcePoolGetPerformanceClassAttributeTypeOk(arg ResourcePoolGetPerformanceClassAttributeType) (ret ResourcePoolGetPerformanceClassRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetPerformanceClassAttributeType(arg *ResourcePoolGetPerformanceClassAttributeType, val ResourcePoolGetPerformanceClassRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for performanceClassDowngradableAt
|
|
*/
|
|
|
|
// isDateTime
|
|
type ResourcePoolGetPerformanceClassDowngradableAtAttributeType = *time.Time
|
|
type ResourcePoolGetPerformanceClassDowngradableAtArgType = time.Time
|
|
type ResourcePoolGetPerformanceClassDowngradableAtRetType = time.Time
|
|
|
|
func getResourcePoolGetPerformanceClassDowngradableAtAttributeTypeOk(arg ResourcePoolGetPerformanceClassDowngradableAtAttributeType) (ret ResourcePoolGetPerformanceClassDowngradableAtRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetPerformanceClassDowngradableAtAttributeType(arg *ResourcePoolGetPerformanceClassDowngradableAtAttributeType, val ResourcePoolGetPerformanceClassDowngradableAtRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for sizeReducibleAt
|
|
*/
|
|
|
|
// isDateTime
|
|
type ResourcePoolGetSizeReducibleAtAttributeType = *time.Time
|
|
type ResourcePoolGetSizeReducibleAtArgType = time.Time
|
|
type ResourcePoolGetSizeReducibleAtRetType = time.Time
|
|
|
|
func getResourcePoolGetSizeReducibleAtAttributeTypeOk(arg ResourcePoolGetSizeReducibleAtAttributeType) (ret ResourcePoolGetSizeReducibleAtRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetSizeReducibleAtAttributeType(arg *ResourcePoolGetSizeReducibleAtAttributeType, val ResourcePoolGetSizeReducibleAtRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for snapshotSchedule
|
|
*/
|
|
|
|
// isModel
|
|
type ResourcePoolGetSnapshotScheduleAttributeType = *SnapshotSchedule
|
|
type ResourcePoolGetSnapshotScheduleArgType = SnapshotSchedule
|
|
type ResourcePoolGetSnapshotScheduleRetType = SnapshotSchedule
|
|
|
|
func getResourcePoolGetSnapshotScheduleAttributeTypeOk(arg ResourcePoolGetSnapshotScheduleAttributeType) (ret ResourcePoolGetSnapshotScheduleRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetSnapshotScheduleAttributeType(arg *ResourcePoolGetSnapshotScheduleAttributeType, val ResourcePoolGetSnapshotScheduleRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for snapshotsAreVisible
|
|
*/
|
|
|
|
// isBoolean
|
|
type ResourcePoolgetSnapshotsAreVisibleAttributeType = *bool
|
|
type ResourcePoolgetSnapshotsAreVisibleArgType = bool
|
|
type ResourcePoolgetSnapshotsAreVisibleRetType = bool
|
|
|
|
func getResourcePoolgetSnapshotsAreVisibleAttributeTypeOk(arg ResourcePoolgetSnapshotsAreVisibleAttributeType) (ret ResourcePoolgetSnapshotsAreVisibleRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolgetSnapshotsAreVisibleAttributeType(arg *ResourcePoolgetSnapshotsAreVisibleAttributeType, val ResourcePoolgetSnapshotsAreVisibleRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for space
|
|
*/
|
|
|
|
// isModel
|
|
type ResourcePoolGetSpaceAttributeType = *ResourcePoolSpace
|
|
type ResourcePoolGetSpaceArgType = ResourcePoolSpace
|
|
type ResourcePoolGetSpaceRetType = ResourcePoolSpace
|
|
|
|
func getResourcePoolGetSpaceAttributeTypeOk(arg ResourcePoolGetSpaceAttributeType) (ret ResourcePoolGetSpaceRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetSpaceAttributeType(arg *ResourcePoolGetSpaceAttributeType, val ResourcePoolGetSpaceRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
/*
|
|
types and functions for state
|
|
*/
|
|
|
|
// isNotNullableString
|
|
type ResourcePoolGetStateAttributeType = *string
|
|
|
|
func getResourcePoolGetStateAttributeTypeOk(arg ResourcePoolGetStateAttributeType) (ret ResourcePoolGetStateRetType, ok bool) {
|
|
if arg == nil {
|
|
return ret, false
|
|
}
|
|
return *arg, true
|
|
}
|
|
|
|
func setResourcePoolGetStateAttributeType(arg *ResourcePoolGetStateAttributeType, val ResourcePoolGetStateRetType) {
|
|
*arg = &val
|
|
}
|
|
|
|
type ResourcePoolGetStateArgType = string
|
|
type ResourcePoolGetStateRetType = string
|
|
|
|
// ResourcePool struct for ResourcePool
|
|
type ResourcePool struct {
|
|
// Name of the respective availability zone
|
|
AvailabilityZone ResourcePoolGetAvailabilityZoneAttributeType `json:"availabilityZone,omitempty"`
|
|
// Number of Shares in the Resource Pool
|
|
// Can be cast to int32 without loss of precision.
|
|
CountShares ResourcePoolGetCountSharesAttributeType `json:"countShares,omitempty"`
|
|
CreatedAt ResourcePoolGetCreatedAtAttributeType `json:"createdAt,omitempty"`
|
|
// ID of the Resource Pool
|
|
Id ResourcePoolGetIdAttributeType `json:"id,omitempty"`
|
|
// List of IPs that can mount the Resource Pool in read-only; IPs must have a subnet mask (e.g. \"172.16.0.0/24\" for a range of IPs, or \"172.16.0.250/32\" for a specific IP)
|
|
IpAcl ResourcePoolGetIpAclAttributeType `json:"ipAcl,omitempty"`
|
|
Labels ResourcePoolGetLabelsAttributeType `json:"labels,omitempty"`
|
|
// Mount path of the Resource Pool, used to mount the Resource Pool Note that a Resource Pool can only be mounted in read-only
|
|
MountPath ResourcePoolGetMountPathAttributeType `json:"mountPath,omitempty"`
|
|
// Name of the Resource Pool
|
|
Name ResourcePoolGetNameAttributeType `json:"name,omitempty"`
|
|
PerformanceClass ResourcePoolGetPerformanceClassAttributeType `json:"performanceClass,omitempty"`
|
|
// Time when the performance class can be downgraded again.
|
|
PerformanceClassDowngradableAt ResourcePoolGetPerformanceClassDowngradableAtAttributeType `json:"performanceClassDowngradableAt,omitempty"`
|
|
// Time when the size can be reduced again.
|
|
SizeReducibleAt ResourcePoolGetSizeReducibleAtAttributeType `json:"sizeReducibleAt,omitempty"`
|
|
SnapshotSchedule ResourcePoolGetSnapshotScheduleAttributeType `json:"snapshotSchedule,omitempty"`
|
|
// Whether the .snapshot directory is visible when mounting the resource pool. Setting this value to false might prevent you from accessing the snapshots (e.g. for security reasons). Additionally, the access to the snapshots is always controlled by the export policy of the resource pool. That means, if snapshots are visible and the export policy allows for reading the resource pool, then it also allows reading the snapshot of all shares.
|
|
SnapshotsAreVisible ResourcePoolgetSnapshotsAreVisibleAttributeType `json:"snapshotsAreVisible,omitempty"`
|
|
Space ResourcePoolGetSpaceAttributeType `json:"space,omitempty"`
|
|
// State of the Resource Pool (possible values: [\"pending\", \"creating\", \"created\", \"updating\", \"error\", \"deleting\"])
|
|
State ResourcePoolGetStateAttributeType `json:"state,omitempty"`
|
|
}
|
|
|
|
// NewResourcePool instantiates a new ResourcePool 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 NewResourcePool() *ResourcePool {
|
|
this := ResourcePool{}
|
|
return &this
|
|
}
|
|
|
|
// NewResourcePoolWithDefaults instantiates a new ResourcePool 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 NewResourcePoolWithDefaults() *ResourcePool {
|
|
this := ResourcePool{}
|
|
return &this
|
|
}
|
|
|
|
// GetAvailabilityZone returns the AvailabilityZone field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetAvailabilityZone() (res ResourcePoolGetAvailabilityZoneRetType) {
|
|
res, _ = o.GetAvailabilityZoneOk()
|
|
return
|
|
}
|
|
|
|
// GetAvailabilityZoneOk returns a tuple with the AvailabilityZone field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetAvailabilityZoneOk() (ret ResourcePoolGetAvailabilityZoneRetType, ok bool) {
|
|
return getResourcePoolGetAvailabilityZoneAttributeTypeOk(o.AvailabilityZone)
|
|
}
|
|
|
|
// HasAvailabilityZone returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasAvailabilityZone() bool {
|
|
_, ok := o.GetAvailabilityZoneOk()
|
|
return ok
|
|
}
|
|
|
|
// SetAvailabilityZone gets a reference to the given string and assigns it to the AvailabilityZone field.
|
|
func (o *ResourcePool) SetAvailabilityZone(v ResourcePoolGetAvailabilityZoneRetType) {
|
|
setResourcePoolGetAvailabilityZoneAttributeType(&o.AvailabilityZone, v)
|
|
}
|
|
|
|
// GetCountShares returns the CountShares field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetCountShares() (res ResourcePoolGetCountSharesRetType) {
|
|
res, _ = o.GetCountSharesOk()
|
|
return
|
|
}
|
|
|
|
// GetCountSharesOk returns a tuple with the CountShares field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetCountSharesOk() (ret ResourcePoolGetCountSharesRetType, ok bool) {
|
|
return getResourcePoolGetCountSharesAttributeTypeOk(o.CountShares)
|
|
}
|
|
|
|
// HasCountShares returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasCountShares() bool {
|
|
_, ok := o.GetCountSharesOk()
|
|
return ok
|
|
}
|
|
|
|
// SetCountShares gets a reference to the given int64 and assigns it to the CountShares field.
|
|
func (o *ResourcePool) SetCountShares(v ResourcePoolGetCountSharesRetType) {
|
|
setResourcePoolGetCountSharesAttributeType(&o.CountShares, v)
|
|
}
|
|
|
|
// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetCreatedAt() (res ResourcePoolGetCreatedAtRetType) {
|
|
res, _ = o.GetCreatedAtOk()
|
|
return
|
|
}
|
|
|
|
// GetCreatedAtOk returns a tuple with the CreatedAt field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetCreatedAtOk() (ret ResourcePoolGetCreatedAtRetType, ok bool) {
|
|
return getResourcePoolGetCreatedAtAttributeTypeOk(o.CreatedAt)
|
|
}
|
|
|
|
// HasCreatedAt returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasCreatedAt() bool {
|
|
_, ok := o.GetCreatedAtOk()
|
|
return ok
|
|
}
|
|
|
|
// SetCreatedAt gets a reference to the given time.Time and assigns it to the CreatedAt field.
|
|
func (o *ResourcePool) SetCreatedAt(v ResourcePoolGetCreatedAtRetType) {
|
|
setResourcePoolGetCreatedAtAttributeType(&o.CreatedAt, v)
|
|
}
|
|
|
|
// GetId returns the Id field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetId() (res ResourcePoolGetIdRetType) {
|
|
res, _ = o.GetIdOk()
|
|
return
|
|
}
|
|
|
|
// 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 *ResourcePool) GetIdOk() (ret ResourcePoolGetIdRetType, ok bool) {
|
|
return getResourcePoolGetIdAttributeTypeOk(o.Id)
|
|
}
|
|
|
|
// HasId returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasId() bool {
|
|
_, ok := o.GetIdOk()
|
|
return ok
|
|
}
|
|
|
|
// SetId gets a reference to the given string and assigns it to the Id field.
|
|
func (o *ResourcePool) SetId(v ResourcePoolGetIdRetType) {
|
|
setResourcePoolGetIdAttributeType(&o.Id, v)
|
|
}
|
|
|
|
// GetIpAcl returns the IpAcl field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetIpAcl() (res ResourcePoolGetIpAclRetType) {
|
|
res, _ = o.GetIpAclOk()
|
|
return
|
|
}
|
|
|
|
// GetIpAclOk returns a tuple with the IpAcl field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetIpAclOk() (ret ResourcePoolGetIpAclRetType, ok bool) {
|
|
return getResourcePoolGetIpAclAttributeTypeOk(o.IpAcl)
|
|
}
|
|
|
|
// HasIpAcl returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasIpAcl() bool {
|
|
_, ok := o.GetIpAclOk()
|
|
return ok
|
|
}
|
|
|
|
// SetIpAcl gets a reference to the given []string and assigns it to the IpAcl field.
|
|
func (o *ResourcePool) SetIpAcl(v ResourcePoolGetIpAclRetType) {
|
|
setResourcePoolGetIpAclAttributeType(&o.IpAcl, v)
|
|
}
|
|
|
|
// GetLabels returns the Labels field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetLabels() (res ResourcePoolGetLabelsRetType) {
|
|
res, _ = o.GetLabelsOk()
|
|
return
|
|
}
|
|
|
|
// 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 *ResourcePool) GetLabelsOk() (ret ResourcePoolGetLabelsRetType, ok bool) {
|
|
return getResourcePoolGetLabelsAttributeTypeOk(o.Labels)
|
|
}
|
|
|
|
// HasLabels returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasLabels() bool {
|
|
_, ok := o.GetLabelsOk()
|
|
return ok
|
|
}
|
|
|
|
// SetLabels gets a reference to the given map[string]string and assigns it to the Labels field.
|
|
func (o *ResourcePool) SetLabels(v ResourcePoolGetLabelsRetType) {
|
|
setResourcePoolGetLabelsAttributeType(&o.Labels, v)
|
|
}
|
|
|
|
// GetMountPath returns the MountPath field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetMountPath() (res ResourcePoolGetMountPathRetType) {
|
|
res, _ = o.GetMountPathOk()
|
|
return
|
|
}
|
|
|
|
// GetMountPathOk returns a tuple with the MountPath field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetMountPathOk() (ret ResourcePoolGetMountPathRetType, ok bool) {
|
|
return getResourcePoolGetMountPathAttributeTypeOk(o.MountPath)
|
|
}
|
|
|
|
// HasMountPath returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasMountPath() bool {
|
|
_, ok := o.GetMountPathOk()
|
|
return ok
|
|
}
|
|
|
|
// SetMountPath gets a reference to the given string and assigns it to the MountPath field.
|
|
func (o *ResourcePool) SetMountPath(v ResourcePoolGetMountPathRetType) {
|
|
setResourcePoolGetMountPathAttributeType(&o.MountPath, v)
|
|
}
|
|
|
|
// GetName returns the Name field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetName() (res ResourcePoolGetNameRetType) {
|
|
res, _ = o.GetNameOk()
|
|
return
|
|
}
|
|
|
|
// 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 *ResourcePool) GetNameOk() (ret ResourcePoolGetNameRetType, ok bool) {
|
|
return getResourcePoolGetNameAttributeTypeOk(o.Name)
|
|
}
|
|
|
|
// HasName returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasName() bool {
|
|
_, ok := o.GetNameOk()
|
|
return ok
|
|
}
|
|
|
|
// SetName gets a reference to the given string and assigns it to the Name field.
|
|
func (o *ResourcePool) SetName(v ResourcePoolGetNameRetType) {
|
|
setResourcePoolGetNameAttributeType(&o.Name, v)
|
|
}
|
|
|
|
// GetPerformanceClass returns the PerformanceClass field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetPerformanceClass() (res ResourcePoolGetPerformanceClassRetType) {
|
|
res, _ = o.GetPerformanceClassOk()
|
|
return
|
|
}
|
|
|
|
// GetPerformanceClassOk returns a tuple with the PerformanceClass field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetPerformanceClassOk() (ret ResourcePoolGetPerformanceClassRetType, ok bool) {
|
|
return getResourcePoolGetPerformanceClassAttributeTypeOk(o.PerformanceClass)
|
|
}
|
|
|
|
// HasPerformanceClass returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasPerformanceClass() bool {
|
|
_, ok := o.GetPerformanceClassOk()
|
|
return ok
|
|
}
|
|
|
|
// SetPerformanceClass gets a reference to the given ResourcePoolPerformanceClass and assigns it to the PerformanceClass field.
|
|
func (o *ResourcePool) SetPerformanceClass(v ResourcePoolGetPerformanceClassRetType) {
|
|
setResourcePoolGetPerformanceClassAttributeType(&o.PerformanceClass, v)
|
|
}
|
|
|
|
// GetPerformanceClassDowngradableAt returns the PerformanceClassDowngradableAt field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetPerformanceClassDowngradableAt() (res ResourcePoolGetPerformanceClassDowngradableAtRetType) {
|
|
res, _ = o.GetPerformanceClassDowngradableAtOk()
|
|
return
|
|
}
|
|
|
|
// GetPerformanceClassDowngradableAtOk returns a tuple with the PerformanceClassDowngradableAt field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetPerformanceClassDowngradableAtOk() (ret ResourcePoolGetPerformanceClassDowngradableAtRetType, ok bool) {
|
|
return getResourcePoolGetPerformanceClassDowngradableAtAttributeTypeOk(o.PerformanceClassDowngradableAt)
|
|
}
|
|
|
|
// HasPerformanceClassDowngradableAt returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasPerformanceClassDowngradableAt() bool {
|
|
_, ok := o.GetPerformanceClassDowngradableAtOk()
|
|
return ok
|
|
}
|
|
|
|
// SetPerformanceClassDowngradableAt gets a reference to the given time.Time and assigns it to the PerformanceClassDowngradableAt field.
|
|
func (o *ResourcePool) SetPerformanceClassDowngradableAt(v ResourcePoolGetPerformanceClassDowngradableAtRetType) {
|
|
setResourcePoolGetPerformanceClassDowngradableAtAttributeType(&o.PerformanceClassDowngradableAt, v)
|
|
}
|
|
|
|
// GetSizeReducibleAt returns the SizeReducibleAt field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetSizeReducibleAt() (res ResourcePoolGetSizeReducibleAtRetType) {
|
|
res, _ = o.GetSizeReducibleAtOk()
|
|
return
|
|
}
|
|
|
|
// GetSizeReducibleAtOk returns a tuple with the SizeReducibleAt field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetSizeReducibleAtOk() (ret ResourcePoolGetSizeReducibleAtRetType, ok bool) {
|
|
return getResourcePoolGetSizeReducibleAtAttributeTypeOk(o.SizeReducibleAt)
|
|
}
|
|
|
|
// HasSizeReducibleAt returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasSizeReducibleAt() bool {
|
|
_, ok := o.GetSizeReducibleAtOk()
|
|
return ok
|
|
}
|
|
|
|
// SetSizeReducibleAt gets a reference to the given time.Time and assigns it to the SizeReducibleAt field.
|
|
func (o *ResourcePool) SetSizeReducibleAt(v ResourcePoolGetSizeReducibleAtRetType) {
|
|
setResourcePoolGetSizeReducibleAtAttributeType(&o.SizeReducibleAt, v)
|
|
}
|
|
|
|
// GetSnapshotSchedule returns the SnapshotSchedule field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetSnapshotSchedule() (res ResourcePoolGetSnapshotScheduleRetType) {
|
|
res, _ = o.GetSnapshotScheduleOk()
|
|
return
|
|
}
|
|
|
|
// GetSnapshotScheduleOk returns a tuple with the SnapshotSchedule field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetSnapshotScheduleOk() (ret ResourcePoolGetSnapshotScheduleRetType, ok bool) {
|
|
return getResourcePoolGetSnapshotScheduleAttributeTypeOk(o.SnapshotSchedule)
|
|
}
|
|
|
|
// HasSnapshotSchedule returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasSnapshotSchedule() bool {
|
|
_, ok := o.GetSnapshotScheduleOk()
|
|
return ok
|
|
}
|
|
|
|
// SetSnapshotSchedule gets a reference to the given SnapshotSchedule and assigns it to the SnapshotSchedule field.
|
|
func (o *ResourcePool) SetSnapshotSchedule(v ResourcePoolGetSnapshotScheduleRetType) {
|
|
setResourcePoolGetSnapshotScheduleAttributeType(&o.SnapshotSchedule, v)
|
|
}
|
|
|
|
// GetSnapshotsAreVisible returns the SnapshotsAreVisible field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetSnapshotsAreVisible() (res ResourcePoolgetSnapshotsAreVisibleRetType) {
|
|
res, _ = o.GetSnapshotsAreVisibleOk()
|
|
return
|
|
}
|
|
|
|
// GetSnapshotsAreVisibleOk returns a tuple with the SnapshotsAreVisible field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetSnapshotsAreVisibleOk() (ret ResourcePoolgetSnapshotsAreVisibleRetType, ok bool) {
|
|
return getResourcePoolgetSnapshotsAreVisibleAttributeTypeOk(o.SnapshotsAreVisible)
|
|
}
|
|
|
|
// HasSnapshotsAreVisible returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasSnapshotsAreVisible() bool {
|
|
_, ok := o.GetSnapshotsAreVisibleOk()
|
|
return ok
|
|
}
|
|
|
|
// SetSnapshotsAreVisible gets a reference to the given bool and assigns it to the SnapshotsAreVisible field.
|
|
func (o *ResourcePool) SetSnapshotsAreVisible(v ResourcePoolgetSnapshotsAreVisibleRetType) {
|
|
setResourcePoolgetSnapshotsAreVisibleAttributeType(&o.SnapshotsAreVisible, v)
|
|
}
|
|
|
|
// GetSpace returns the Space field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetSpace() (res ResourcePoolGetSpaceRetType) {
|
|
res, _ = o.GetSpaceOk()
|
|
return
|
|
}
|
|
|
|
// GetSpaceOk returns a tuple with the Space field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetSpaceOk() (ret ResourcePoolGetSpaceRetType, ok bool) {
|
|
return getResourcePoolGetSpaceAttributeTypeOk(o.Space)
|
|
}
|
|
|
|
// HasSpace returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasSpace() bool {
|
|
_, ok := o.GetSpaceOk()
|
|
return ok
|
|
}
|
|
|
|
// SetSpace gets a reference to the given ResourcePoolSpace and assigns it to the Space field.
|
|
func (o *ResourcePool) SetSpace(v ResourcePoolGetSpaceRetType) {
|
|
setResourcePoolGetSpaceAttributeType(&o.Space, v)
|
|
}
|
|
|
|
// GetState returns the State field value if set, zero value otherwise.
|
|
func (o *ResourcePool) GetState() (res ResourcePoolGetStateRetType) {
|
|
res, _ = o.GetStateOk()
|
|
return
|
|
}
|
|
|
|
// GetStateOk returns a tuple with the State field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ResourcePool) GetStateOk() (ret ResourcePoolGetStateRetType, ok bool) {
|
|
return getResourcePoolGetStateAttributeTypeOk(o.State)
|
|
}
|
|
|
|
// HasState returns a boolean if a field has been set.
|
|
func (o *ResourcePool) HasState() bool {
|
|
_, ok := o.GetStateOk()
|
|
return ok
|
|
}
|
|
|
|
// SetState gets a reference to the given string and assigns it to the State field.
|
|
func (o *ResourcePool) SetState(v ResourcePoolGetStateRetType) {
|
|
setResourcePoolGetStateAttributeType(&o.State, v)
|
|
}
|
|
|
|
func (o ResourcePool) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if val, ok := getResourcePoolGetAvailabilityZoneAttributeTypeOk(o.AvailabilityZone); ok {
|
|
toSerialize["AvailabilityZone"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetCountSharesAttributeTypeOk(o.CountShares); ok {
|
|
toSerialize["CountShares"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetCreatedAtAttributeTypeOk(o.CreatedAt); ok {
|
|
toSerialize["CreatedAt"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetIdAttributeTypeOk(o.Id); ok {
|
|
toSerialize["Id"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetIpAclAttributeTypeOk(o.IpAcl); ok {
|
|
toSerialize["IpAcl"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetLabelsAttributeTypeOk(o.Labels); ok {
|
|
toSerialize["Labels"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetMountPathAttributeTypeOk(o.MountPath); ok {
|
|
toSerialize["MountPath"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetNameAttributeTypeOk(o.Name); ok {
|
|
toSerialize["Name"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetPerformanceClassAttributeTypeOk(o.PerformanceClass); ok {
|
|
toSerialize["PerformanceClass"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetPerformanceClassDowngradableAtAttributeTypeOk(o.PerformanceClassDowngradableAt); ok {
|
|
toSerialize["PerformanceClassDowngradableAt"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetSizeReducibleAtAttributeTypeOk(o.SizeReducibleAt); ok {
|
|
toSerialize["SizeReducibleAt"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetSnapshotScheduleAttributeTypeOk(o.SnapshotSchedule); ok {
|
|
toSerialize["SnapshotSchedule"] = val
|
|
}
|
|
if val, ok := getResourcePoolgetSnapshotsAreVisibleAttributeTypeOk(o.SnapshotsAreVisible); ok {
|
|
toSerialize["SnapshotsAreVisible"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetSpaceAttributeTypeOk(o.Space); ok {
|
|
toSerialize["Space"] = val
|
|
}
|
|
if val, ok := getResourcePoolGetStateAttributeTypeOk(o.State); ok {
|
|
toSerialize["State"] = val
|
|
}
|
|
return toSerialize, nil
|
|
}
|
|
|
|
type NullableResourcePool struct {
|
|
value *ResourcePool
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableResourcePool) Get() *ResourcePool {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableResourcePool) Set(val *ResourcePool) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableResourcePool) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableResourcePool) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableResourcePool(val *ResourcePool) *NullableResourcePool {
|
|
return &NullableResourcePool{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableResourcePool) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableResourcePool) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|