/
type-volume-hybrid-cache-attributes.go
84 lines (70 loc) · 2.9 KB
/
type-volume-hybrid-cache-attributes.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
package azgo
import (
"encoding/xml"
"reflect"
log "github.com/sirupsen/logrus"
)
// VolumeHybridCacheAttributesType is a structure to represent a volume-hybrid-cache-attributes ZAPI object
type VolumeHybridCacheAttributesType struct {
XMLName xml.Name `xml:"volume-hybrid-cache-attributes"`
CacheRetentionPriorityPtr *string `xml:"cache-retention-priority"`
CachingPolicyPtr *string `xml:"caching-policy"`
EligibilityPtr *string `xml:"eligibility"`
WriteCacheIneligibilityReasonPtr *string `xml:"write-cache-ineligibility-reason"`
}
// NewVolumeHybridCacheAttributesType is a factory method for creating new instances of VolumeHybridCacheAttributesType objects
func NewVolumeHybridCacheAttributesType() *VolumeHybridCacheAttributesType {
return &VolumeHybridCacheAttributesType{}
}
// ToXML converts this object into an xml string representation
func (o *VolumeHybridCacheAttributesType) ToXML() (string, error) {
output, err := xml.MarshalIndent(o, " ", " ")
if err != nil {
log.Errorf("error: %v", err)
}
return string(output), err
}
// String returns a string representation of this object's fields and implements the Stringer interface
func (o VolumeHybridCacheAttributesType) String() string {
return ToString(reflect.ValueOf(o))
}
// CacheRetentionPriority is a 'getter' method
func (o *VolumeHybridCacheAttributesType) CacheRetentionPriority() string {
r := *o.CacheRetentionPriorityPtr
return r
}
// SetCacheRetentionPriority is a fluent style 'setter' method that can be chained
func (o *VolumeHybridCacheAttributesType) SetCacheRetentionPriority(newValue string) *VolumeHybridCacheAttributesType {
o.CacheRetentionPriorityPtr = &newValue
return o
}
// CachingPolicy is a 'getter' method
func (o *VolumeHybridCacheAttributesType) CachingPolicy() string {
r := *o.CachingPolicyPtr
return r
}
// SetCachingPolicy is a fluent style 'setter' method that can be chained
func (o *VolumeHybridCacheAttributesType) SetCachingPolicy(newValue string) *VolumeHybridCacheAttributesType {
o.CachingPolicyPtr = &newValue
return o
}
// Eligibility is a 'getter' method
func (o *VolumeHybridCacheAttributesType) Eligibility() string {
r := *o.EligibilityPtr
return r
}
// SetEligibility is a fluent style 'setter' method that can be chained
func (o *VolumeHybridCacheAttributesType) SetEligibility(newValue string) *VolumeHybridCacheAttributesType {
o.EligibilityPtr = &newValue
return o
}
// WriteCacheIneligibilityReason is a 'getter' method
func (o *VolumeHybridCacheAttributesType) WriteCacheIneligibilityReason() string {
r := *o.WriteCacheIneligibilityReasonPtr
return r
}
// SetWriteCacheIneligibilityReason is a fluent style 'setter' method that can be chained
func (o *VolumeHybridCacheAttributesType) SetWriteCacheIneligibilityReason(newValue string) *VolumeHybridCacheAttributesType {
o.WriteCacheIneligibilityReasonPtr = &newValue
return o
}