Class: Azure::ARM::Compute::Models::DataDisk
- Inherits:
-
Object
- Object
- Azure::ARM::Compute::Models::DataDisk
- Includes:
- MsRest::JSONable, MsRestAzure
- Defined in:
- lib/generated/azure_mgmt_compute/models/data_disk.rb
Overview
Describes a data disk.
Instance Attribute Summary collapse
-
#caching ⇒ CachingTypes
Possible values are:
None
ReadOnly
ReadWrite
Default: **None for Standard storage. -
#create_option ⇒ DiskCreateOptionTypes
should be created.
Possible values are:
Attach u2013 This value is used when you are using a specialized disk to create the virtual machine.
FromImage u2013 This value is used when you are using an image to create the virtual machine. -
#disk_size_gb ⇒ Integer
gigabytes.
-
#image ⇒ VirtualHardDisk
virtual hard disk will be copied before being attached to the virtual machine.
-
#lun ⇒ Integer
This value is used to identify data disks within the VM and therefore must be unique for each data disk attached to a VM.
-
#managed_disk ⇒ ManagedDiskParameters
The managed disk parameters.
-
#name ⇒ String
The disk name.
-
#vhd ⇒ VirtualHardDisk
The virtual hard disk..
Class Method Summary collapse
-
.mapper ⇒ Object
Mapper for DataDisk class as Ruby Hash.
Instance Attribute Details
#caching ⇒ CachingTypes
Possible values are:
None
ReadOnly
ReadWrite
Default: **None for Standard storage. ReadOnly for Premium storage**. Possible values include: ‘None’, ‘ReadOnly’, ‘ReadWrite’
38 39 40 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 38 def caching @caching end |
#create_option ⇒ DiskCreateOptionTypes
should be created.
Possible values are:
Attach u2013 This value is used when you are using a specialized disk to create the virtual machine.
FromImage u2013 This value is used when you are using an image to create the virtual machine. If you are using a platform image, you also use the imageReference element described above. If you are using a marketplace image, you also use the plan element previously described. Possible values include: ‘fromImage’, ‘empty’, ‘attach’
49 50 51 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 49 def create_option @create_option end |
#disk_size_gb ⇒ Integer
gigabytes. This element can be used to overwrite the name of the disk in a virtual machine image.
This value cannot be larger than 1023 GB
55 56 57 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 55 def disk_size_gb @disk_size_gb end |
#image ⇒ VirtualHardDisk
virtual hard disk will be copied before being attached to the virtual machine. If SourceImage is provided, the destination virtual hard drive must not exist.
31 32 33 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 31 def image @image end |
#lun ⇒ Integer
This value is used to identify data disks within the VM and therefore must be unique for each data disk attached to a VM.
19 20 21 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 19 def lun @lun end |
#managed_disk ⇒ ManagedDiskParameters
Returns The managed disk parameters.
58 59 60 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 58 def managed_disk @managed_disk end |
#name ⇒ String
Returns The disk name.
22 23 24 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 22 def name @name end |
#vhd ⇒ VirtualHardDisk
Returns The virtual hard disk..
25 26 27 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 25 def vhd @vhd end |
Class Method Details
.mapper ⇒ Object
Mapper for DataDisk class as Ruby Hash. This will be used for serialization/deserialization.
65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 |
# File 'lib/generated/azure_mgmt_compute/models/data_disk.rb', line 65 def self.mapper() { required: false, serialized_name: 'DataDisk', type: { name: 'Composite', class_name: 'DataDisk', model_properties: { lun: { required: true, serialized_name: 'lun', type: { name: 'Number' } }, name: { required: false, serialized_name: 'name', type: { name: 'String' } }, vhd: { required: false, serialized_name: 'vhd', type: { name: 'Composite', class_name: 'VirtualHardDisk' } }, image: { required: false, serialized_name: 'image', type: { name: 'Composite', class_name: 'VirtualHardDisk' } }, caching: { required: false, serialized_name: 'caching', type: { name: 'Enum', module: 'CachingTypes' } }, create_option: { required: true, serialized_name: 'createOption', type: { name: 'Enum', module: 'DiskCreateOptionTypes' } }, disk_size_gb: { required: false, serialized_name: 'diskSizeGB', type: { name: 'Number' } }, managed_disk: { required: false, serialized_name: 'managedDisk', type: { name: 'Composite', class_name: 'ManagedDiskParameters' } } } } } end |