Class: AWSCDK::Lightsail::CfnInstance::DiskProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Lightsail::CfnInstance::DiskProperty
- Defined in:
- lightsail/cfn_instance.rb
Overview
Disk is a property of the Hardware property. It describes a disk attached to an instance.
Instance Attribute Summary collapse
-
#attached_to ⇒ String?
readonly
The resources to which the disk is attached.
-
#attachment_state ⇒ String?
readonly
(Deprecated) The attachment state of the disk.
-
#disk_name ⇒ String
readonly
The unique name of the disk.
-
#iops ⇒ Numeric?
readonly
The input/output operations per second (IOPS) of the disk.
-
#is_system_disk ⇒ Boolean, ...
readonly
A Boolean value indicating whether this disk is a system disk (has an operating system loaded on it).
-
#path ⇒ String
readonly
The disk path.
-
#size_in_gb ⇒ String?
readonly
The size of the disk in GB.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(disk_name:, path:, attached_to: nil, attachment_state: nil, iops: nil, is_system_disk: nil, size_in_gb: nil) ⇒ DiskProperty
constructor
A new instance of DiskProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(disk_name:, path:, attached_to: nil, attachment_state: nil, iops: nil, is_system_disk: nil, size_in_gb: nil) ⇒ DiskProperty
Returns a new instance of DiskProperty.
888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 |
# File 'lightsail/cfn_instance.rb', line 888 def initialize(disk_name:, path:, attached_to: nil, attachment_state: nil, iops: nil, is_system_disk: nil, size_in_gb: nil) @disk_name = disk_name Jsii::Type.check_type(@disk_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "diskName") @path = path Jsii::Type.check_type(@path, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "path") @attached_to = attached_to Jsii::Type.check_type(@attached_to, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "attachedTo") unless @attached_to.nil? @attachment_state = Jsii::Type.check_type(@attachment_state, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "attachmentState") unless @attachment_state.nil? @iops = iops Jsii::Type.check_type(@iops, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "iops") unless @iops.nil? @is_system_disk = is_system_disk Jsii::Type.check_type(@is_system_disk, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "isSystemDisk") unless @is_system_disk.nil? @size_in_gb = size_in_gb Jsii::Type.check_type(@size_in_gb, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "sizeInGb") unless @size_in_gb.nil? end |
Instance Attribute Details
#attached_to ⇒ String? (readonly)
The resources to which the disk is attached.
919 920 921 |
# File 'lightsail/cfn_instance.rb', line 919 def attached_to @attached_to end |
#attachment_state ⇒ String? (readonly)
(Deprecated) The attachment state of the disk.
In releases prior to November 14, 2017, this parameter returned
attachedfor system disks in the API response. It is now deprecated, but still included in the response. Useis_attachedinstead.
926 927 928 |
# File 'lightsail/cfn_instance.rb', line 926 def @attachment_state end |
#disk_name ⇒ String (readonly)
The unique name of the disk.
909 910 911 |
# File 'lightsail/cfn_instance.rb', line 909 def disk_name @disk_name end |
#iops ⇒ Numeric? (readonly)
The input/output operations per second (IOPS) of the disk.
931 932 933 |
# File 'lightsail/cfn_instance.rb', line 931 def iops @iops end |
#is_system_disk ⇒ Boolean, ... (readonly)
A Boolean value indicating whether this disk is a system disk (has an operating system loaded on it).
936 937 938 |
# File 'lightsail/cfn_instance.rb', line 936 def is_system_disk @is_system_disk end |
#path ⇒ String (readonly)
The disk path.
914 915 916 |
# File 'lightsail/cfn_instance.rb', line 914 def path @path end |
#size_in_gb ⇒ String? (readonly)
The size of the disk in GB.
941 942 943 |
# File 'lightsail/cfn_instance.rb', line 941 def size_in_gb @size_in_gb end |
Class Method Details
.jsii_properties ⇒ Object
943 944 945 946 947 948 949 950 951 952 953 |
# File 'lightsail/cfn_instance.rb', line 943 def self.jsii_properties { :disk_name => "diskName", :path => "path", :attached_to => "attachedTo", :attachment_state => "attachmentState", :iops => "iops", :is_system_disk => "isSystemDisk", :size_in_gb => "sizeInGb", } end |
Instance Method Details
#to_jsii ⇒ Object
955 956 957 958 959 960 961 962 963 964 965 966 967 |
# File 'lightsail/cfn_instance.rb', line 955 def to_jsii result = {} result.merge!({ "diskName" => @disk_name, "path" => @path, "attachedTo" => @attached_to, "attachmentState" => @attachment_state, "iops" => @iops, "isSystemDisk" => @is_system_disk, "sizeInGb" => @size_in_gb, }) result.compact end |