Documentation ¶
Index ¶
- Variables
- type CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) APIVersion(v string) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) Capacity(v *resource.Quantity) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) CapacityString(s string) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DeepCopy() *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DeepCopyObject() runtime.Object
- func (d *CSIStorageCapacityDie) DieDefaultTypeMetadata() *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieDiff(opts ...cmp.Option) string
- func (d *CSIStorageCapacityDie) DieFeed(r storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieFeedJSON(j []byte) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieFeedPtr(r *storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieFeedRawExtension(raw runtime.RawExtension) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieFeedYAML(y []byte) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieFeedYAMLFile(name string) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieImmutable(immutable bool) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DiePatch(patchType types.PatchType) ([]byte, error)
- func (d *CSIStorageCapacityDie) DieRelease() storagev1beta1.CSIStorageCapacity
- func (d *CSIStorageCapacityDie) DieReleaseJSON() []byte
- func (d *CSIStorageCapacityDie) DieReleasePtr() *storagev1beta1.CSIStorageCapacity
- func (d *CSIStorageCapacityDie) DieReleaseRawExtension() runtime.RawExtension
- func (d *CSIStorageCapacityDie) DieReleaseUnstructured() *unstructured.Unstructured
- func (d *CSIStorageCapacityDie) DieReleaseYAML() []byte
- func (d *CSIStorageCapacityDie) DieSeal() *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieSealFeed(r storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieSealFeedPtr(r *storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieSealRelease() storagev1beta1.CSIStorageCapacity
- func (d *CSIStorageCapacityDie) DieSealReleasePtr() *storagev1beta1.CSIStorageCapacity
- func (d *CSIStorageCapacityDie) DieStamp(fn func(r *storagev1beta1.CSIStorageCapacity)) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieStampAt(jp string, fn interface{}) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) DieWith(fns ...func(d *CSIStorageCapacityDie)) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) GetObjectKind() schema.ObjectKind
- func (d *CSIStorageCapacityDie) Kind(v string) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) MarshalJSON() ([]byte, error)
- func (d *CSIStorageCapacityDie) MaximumVolumeSize(v *resource.Quantity) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) MaximumVolumeSizeString(s string) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) Metadata(v metav1.ObjectMeta) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) MetadataDie(fn func(d *v1.ObjectMetaDie)) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) NodeTopology(v *metav1.LabelSelector) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) NodeTopologyDie(fn func(d *v1.LabelSelectorDie)) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) StorageClassName(v string) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) TypeMetadata(v metav1.TypeMeta) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) TypeMetadataDie(fn func(d *v1.TypeMetaDie)) *CSIStorageCapacityDie
- func (d *CSIStorageCapacityDie) UnmarshalJSON(b []byte) error
Constants ¶
This section is empty.
Variables ¶
var CSIStorageCapacityBlank = (&CSIStorageCapacityDie{}).DieFeed(storagev1beta1.CSIStorageCapacity{})
Functions ¶
This section is empty.
Types ¶
type CSIStorageCapacityDie ¶
type CSIStorageCapacityDie struct { v1.FrozenObjectMeta // contains filtered or unexported fields }
func (*CSIStorageCapacityDie) APIVersion ¶
func (d *CSIStorageCapacityDie) APIVersion(v string) *CSIStorageCapacityDie
APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
func (*CSIStorageCapacityDie) Capacity ¶
func (d *CSIStorageCapacityDie) Capacity(v *resource.Quantity) *CSIStorageCapacityDie
capacity is the value reported by the CSI driver in its GetCapacityResponse
for a GetCapacityRequest with topology and parameters that match the
previous fields.
The semantic is currently (CSI spec 1.2) defined as:
The available capacity, in bytes, of the storage that can be used ¶
to provision volumes. If not set, that information is currently
unavailable.
func (*CSIStorageCapacityDie) CapacityString ¶
func (d *CSIStorageCapacityDie) CapacityString(s string) *CSIStorageCapacityDie
CapacityString sets Capacity by parsing the string as a Quantity. Panics if the string is not parsable.
capacity is the value reported by the CSI driver in its GetCapacityResponse
for a GetCapacityRequest with topology and parameters that match the
previous fields.
The semantic is currently (CSI spec 1.2) defined as:
The available capacity, in bytes, of the storage that can be used ¶
to provision volumes. If not set, that information is currently
unavailable.
func (*CSIStorageCapacityDie) DeepCopy ¶
func (d *CSIStorageCapacityDie) DeepCopy() *CSIStorageCapacityDie
DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.
func (*CSIStorageCapacityDie) DeepCopyObject ¶
func (d *CSIStorageCapacityDie) DeepCopyObject() runtime.Object
func (*CSIStorageCapacityDie) DieDefaultTypeMetadata ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DieDefaultTypeMetadata() *CSIStorageCapacityDie
DieDefaultTypeMetadata sets the APIVersion and Kind to "storage.k8s.io/v1beta1" and "CSIStorageCapacity" respectively.
func (*CSIStorageCapacityDie) DieDiff ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DieDiff(opts ...cmp.Option) string
DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.
func (*CSIStorageCapacityDie) DieFeed ¶
func (d *CSIStorageCapacityDie) DieFeed(r storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
DieFeed returns a new die with the provided resource.
func (*CSIStorageCapacityDie) DieFeedJSON ¶
func (d *CSIStorageCapacityDie) DieFeedJSON(j []byte) *CSIStorageCapacityDie
DieFeedJSON returns a new die with the provided JSON. Panics on error.
func (*CSIStorageCapacityDie) DieFeedPtr ¶
func (d *CSIStorageCapacityDie) DieFeedPtr(r *storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.
func (*CSIStorageCapacityDie) DieFeedRawExtension ¶
func (d *CSIStorageCapacityDie) DieFeedRawExtension(raw runtime.RawExtension) *CSIStorageCapacityDie
DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.
func (*CSIStorageCapacityDie) DieFeedYAML ¶
func (d *CSIStorageCapacityDie) DieFeedYAML(y []byte) *CSIStorageCapacityDie
DieFeedYAML returns a new die with the provided YAML. Panics on error.
func (*CSIStorageCapacityDie) DieFeedYAMLFile ¶
func (d *CSIStorageCapacityDie) DieFeedYAMLFile(name string) *CSIStorageCapacityDie
DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.
func (*CSIStorageCapacityDie) DieImmutable ¶
func (d *CSIStorageCapacityDie) DieImmutable(immutable bool) *CSIStorageCapacityDie
DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).
func (*CSIStorageCapacityDie) DiePatch ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DiePatch(patchType types.PatchType) ([]byte, error)
DiePatch generates a patch between the current value of the die and the sealed value.
func (*CSIStorageCapacityDie) DieRelease ¶
func (d *CSIStorageCapacityDie) DieRelease() storagev1beta1.CSIStorageCapacity
DieRelease returns the resource managed by the die.
func (*CSIStorageCapacityDie) DieReleaseJSON ¶
func (d *CSIStorageCapacityDie) DieReleaseJSON() []byte
DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.
func (*CSIStorageCapacityDie) DieReleasePtr ¶
func (d *CSIStorageCapacityDie) DieReleasePtr() *storagev1beta1.CSIStorageCapacity
DieReleasePtr returns a pointer to the resource managed by the die.
func (*CSIStorageCapacityDie) DieReleaseRawExtension ¶
func (d *CSIStorageCapacityDie) DieReleaseRawExtension() runtime.RawExtension
DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.
func (*CSIStorageCapacityDie) DieReleaseUnstructured ¶
func (d *CSIStorageCapacityDie) DieReleaseUnstructured() *unstructured.Unstructured
DieReleaseUnstructured returns the resource managed by the die as an unstructured object. Panics on error.
func (*CSIStorageCapacityDie) DieReleaseYAML ¶
func (d *CSIStorageCapacityDie) DieReleaseYAML() []byte
DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.
func (*CSIStorageCapacityDie) DieSeal ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DieSeal() *CSIStorageCapacityDie
DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.
func (*CSIStorageCapacityDie) DieSealFeed ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DieSealFeed(r storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.
func (*CSIStorageCapacityDie) DieSealFeedPtr ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DieSealFeedPtr(r *storagev1beta1.CSIStorageCapacity) *CSIStorageCapacityDie
DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.
func (*CSIStorageCapacityDie) DieSealRelease ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DieSealRelease() storagev1beta1.CSIStorageCapacity
DieSealRelease returns the sealed resource managed by the die.
func (*CSIStorageCapacityDie) DieSealReleasePtr ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) DieSealReleasePtr() *storagev1beta1.CSIStorageCapacity
DieSealReleasePtr returns the sealed resource pointer managed by the die.
func (*CSIStorageCapacityDie) DieStamp ¶
func (d *CSIStorageCapacityDie) DieStamp(fn func(r *storagev1beta1.CSIStorageCapacity)) *CSIStorageCapacityDie
DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.
func (*CSIStorageCapacityDie) DieStampAt ¶
func (d *CSIStorageCapacityDie) DieStampAt(jp string, fn interface{}) *CSIStorageCapacityDie
Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.
Future iterations will improve type coercion from the resource to the callback argument.
func (*CSIStorageCapacityDie) DieWith ¶
func (d *CSIStorageCapacityDie) DieWith(fns ...func(d *CSIStorageCapacityDie)) *CSIStorageCapacityDie
DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.
func (*CSIStorageCapacityDie) GetObjectKind ¶
func (d *CSIStorageCapacityDie) GetObjectKind() schema.ObjectKind
func (*CSIStorageCapacityDie) Kind ¶
func (d *CSIStorageCapacityDie) Kind(v string) *CSIStorageCapacityDie
Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
func (*CSIStorageCapacityDie) MarshalJSON ¶
func (d *CSIStorageCapacityDie) MarshalJSON() ([]byte, error)
func (*CSIStorageCapacityDie) MaximumVolumeSize ¶
func (d *CSIStorageCapacityDie) MaximumVolumeSize(v *resource.Quantity) *CSIStorageCapacityDie
maximumVolumeSize is the value reported by the CSI driver in its GetCapacityResponse
for a GetCapacityRequest with topology and parameters that match the
previous fields.
This is defined since CSI spec 1.4.0 as the largest size ¶
that may be used in a
CreateVolumeRequest.capacity_range.required_bytes field to
create a volume with the same parameters as those in
GetCapacityRequest. The corresponding value in the Kubernetes
API is ResourceRequirements.Requests in a volume claim.
func (*CSIStorageCapacityDie) MaximumVolumeSizeString ¶
func (d *CSIStorageCapacityDie) MaximumVolumeSizeString(s string) *CSIStorageCapacityDie
MaximumVolumeSizeString sets MaximumVolumeSize by parsing the string as a Quantity. Panics if the string is not parsable.
maximumVolumeSize is the value reported by the CSI driver in its GetCapacityResponse
for a GetCapacityRequest with topology and parameters that match the
previous fields.
This is defined since CSI spec 1.4.0 as the largest size ¶
that may be used in a
CreateVolumeRequest.capacity_range.required_bytes field to
create a volume with the same parameters as those in
GetCapacityRequest. The corresponding value in the Kubernetes
API is ResourceRequirements.Requests in a volume claim.
func (*CSIStorageCapacityDie) Metadata ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) Metadata(v metav1.ObjectMeta) *CSIStorageCapacityDie
Metadata standard object's metadata.
func (*CSIStorageCapacityDie) MetadataDie ¶
func (d *CSIStorageCapacityDie) MetadataDie(fn func(d *v1.ObjectMetaDie)) *CSIStorageCapacityDie
MetadataDie stamps the resource's ObjectMeta field with a mutable die.
func (*CSIStorageCapacityDie) NodeTopology ¶
func (d *CSIStorageCapacityDie) NodeTopology(v *metav1.LabelSelector) *CSIStorageCapacityDie
nodeTopology defines which nodes have access to the storage
for which capacity was reported. If not set, the storage is
not accessible from any node in the cluster. If empty, the
storage is accessible from all nodes. This field is
immutable.
func (*CSIStorageCapacityDie) NodeTopologyDie ¶
func (d *CSIStorageCapacityDie) NodeTopologyDie(fn func(d *v1.LabelSelectorDie)) *CSIStorageCapacityDie
NodeTopologyDie mutates NodeTopology as a die.
nodeTopology defines which nodes have access to the storage
for which capacity was reported. If not set, the storage is
not accessible from any node in the cluster. If empty, the
storage is accessible from all nodes. This field is
immutable.
func (*CSIStorageCapacityDie) StorageClassName ¶
func (d *CSIStorageCapacityDie) StorageClassName(v string) *CSIStorageCapacityDie
storageClassName represents the name of the StorageClass that the reported capacity applies to.
It must meet the same requirements as the name of a StorageClass ¶
object (non-empty, DNS subdomain). If that object no longer exists,
the CSIStorageCapacity object is obsolete and should be removed by its
creator.
This field is immutable.
func (*CSIStorageCapacityDie) TypeMetadata ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) TypeMetadata(v metav1.TypeMeta) *CSIStorageCapacityDie
TypeMetadata standard object's type metadata.
func (*CSIStorageCapacityDie) TypeMetadataDie ¶ added in v0.13.0
func (d *CSIStorageCapacityDie) TypeMetadataDie(fn func(d *v1.TypeMetaDie)) *CSIStorageCapacityDie
TypeMetadataDie stamps the resource's TypeMeta field with a mutable die.
func (*CSIStorageCapacityDie) UnmarshalJSON ¶
func (d *CSIStorageCapacityDie) UnmarshalJSON(b []byte) error