Class: CDK8sPlus25::K8S::KubePersistentVolumeClaimProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- CDK8sPlus25::K8S::KubePersistentVolumeClaimProps
- Defined in:
- k8_s/kube_persistent_volume_claim_props.rb
Overview
PersistentVolumeClaim is a user's request for and claim to a persistent volume.
Instance Attribute Summary collapse
-
#metadata ⇒ CDK8sPlus25::K8S::ObjectMeta?
readonly
Standard object's metadata.
-
#spec ⇒ CDK8sPlus25::K8S::PersistentVolumeClaimSpec?
readonly
spec defines the desired characteristics of a volume requested by a pod author.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(metadata: nil, spec: nil) ⇒ KubePersistentVolumeClaimProps
constructor
A new instance of KubePersistentVolumeClaimProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(metadata: nil, spec: nil) ⇒ KubePersistentVolumeClaimProps
Returns a new instance of KubePersistentVolumeClaimProps.
9 10 11 12 13 14 |
# File 'k8_s/kube_persistent_volume_claim_props.rb', line 9 def initialize(metadata: nil, spec: nil) @metadata = .is_a?(Hash) ? ::CDK8sPlus25::K8S::ObjectMeta.new(**.transform_keys(&:to_sym)) : Jsii::Type.check_type(@metadata, "eyJmcW4iOiJjZGs4cy1wbHVzLTI1Lms4cy5PYmplY3RNZXRhIn0=", "metadata") unless @metadata.nil? @spec = spec.is_a?(Hash) ? ::CDK8sPlus25::K8S::PersistentVolumeClaimSpec.new(**spec.transform_keys(&:to_sym)) : spec Jsii::Type.check_type(@spec, "eyJmcW4iOiJjZGs4cy1wbHVzLTI1Lms4cy5QZXJzaXN0ZW50Vm9sdW1lQ2xhaW1TcGVjIn0=", "spec") unless @spec.nil? end |
Instance Attribute Details
#metadata ⇒ CDK8sPlus25::K8S::ObjectMeta? (readonly)
Standard object's metadata.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
21 22 23 |
# File 'k8_s/kube_persistent_volume_claim_props.rb', line 21 def @metadata end |
#spec ⇒ CDK8sPlus25::K8S::PersistentVolumeClaimSpec? (readonly)
spec defines the desired characteristics of a volume requested by a pod author.
More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims
27 28 29 |
# File 'k8_s/kube_persistent_volume_claim_props.rb', line 27 def spec @spec end |
Class Method Details
.jsii_properties ⇒ Object
29 30 31 32 33 34 |
# File 'k8_s/kube_persistent_volume_claim_props.rb', line 29 def self.jsii_properties { :metadata => "metadata", :spec => "spec", } end |
Instance Method Details
#to_jsii ⇒ Object
36 37 38 39 40 41 42 43 |
# File 'k8_s/kube_persistent_volume_claim_props.rb', line 36 def to_jsii result = {} result.merge!({ "metadata" => @metadata, "spec" => @spec, }) result.compact end |