public final class DataDisk extends Object
Constructor and Description |
---|
DataDisk() |
Modifier and Type | Method and Description |
---|---|
CachingTypes |
caching()
Get the caching property: Specifies the caching requirements.
|
DiskCreateOptionTypes |
createOption()
Get the createOption property: Specifies how the virtual machine should be created.<br><br> Possible
values are:<br><br> **Attach** – This value is used when you are using a specialized disk to
create the virtual machine.<br><br> **FromImage** – This value is used when you are using an
image to create the virtual machine.
|
Long |
diskIopsReadWrite()
Get the diskIopsReadWrite property: Specifies the Read-Write IOPS for the managed disk when StorageAccountType is
UltraSSD_LRS.
|
Long |
diskMBpsReadWrite()
Get the diskMBpsReadWrite property: Specifies the bandwidth in MB per second for the managed disk when
StorageAccountType is UltraSSD_LRS.
|
Integer |
diskSizeGB()
Get the diskSizeGB property: Specifies the size of an empty data disk in gigabytes.
|
VirtualHardDisk |
image()
Get the image property: The source user image virtual hard disk.
|
int |
lun()
Get the lun property: Specifies the logical unit number of the data disk.
|
ManagedDiskParameters |
managedDisk()
Get the managedDisk property: The managed disk parameters.
|
String |
name()
Get the name property: The disk name.
|
Boolean |
toBeDetached()
Get the toBeDetached property: Specifies whether the data disk is in process of detachment from the
VirtualMachine/VirtualMachineScaleset.
|
void |
validate()
Validates the instance.
|
VirtualHardDisk |
vhd()
Get the vhd property: The virtual hard disk.
|
DataDisk |
withCaching(CachingTypes caching)
Set the caching property: Specifies the caching requirements.
|
DataDisk |
withCreateOption(DiskCreateOptionTypes createOption)
Set the createOption property: Specifies how the virtual machine should be created.<br><br> Possible
values are:<br><br> **Attach** – This value is used when you are using a specialized disk to
create the virtual machine.<br><br> **FromImage** – This value is used when you are using an
image to create the virtual machine.
|
DataDisk |
withDiskSizeGB(Integer diskSizeGB)
Set the diskSizeGB property: Specifies the size of an empty data disk in gigabytes.
|
DataDisk |
withImage(VirtualHardDisk image)
Set the image property: The source user image virtual hard disk.
|
DataDisk |
withLun(int lun)
Set the lun property: Specifies the logical unit number of the data disk.
|
DataDisk |
withManagedDisk(ManagedDiskParameters managedDisk)
Set the managedDisk property: The managed disk parameters.
|
DataDisk |
withName(String name)
Set the name property: The disk name.
|
DataDisk |
withToBeDetached(Boolean toBeDetached)
Set the toBeDetached property: Specifies whether the data disk is in process of detachment from the
VirtualMachine/VirtualMachineScaleset.
|
DataDisk |
withVhd(VirtualHardDisk vhd)
Set the vhd property: The virtual hard disk.
|
DataDisk |
withWriteAcceleratorEnabled(Boolean writeAcceleratorEnabled)
Set the writeAcceleratorEnabled property: Specifies whether writeAccelerator should be enabled or disabled on the
disk.
|
Boolean |
writeAcceleratorEnabled()
Get the writeAcceleratorEnabled property: Specifies whether writeAccelerator should be enabled or disabled on the
disk.
|
public int lun()
public DataDisk withLun(int lun)
lun
- the lun value to set.public String name()
public DataDisk withName(String name)
name
- the name value to set.public VirtualHardDisk vhd()
public DataDisk withVhd(VirtualHardDisk vhd)
vhd
- the vhd value to set.public VirtualHardDisk image()
public DataDisk withImage(VirtualHardDisk image)
image
- the image value to set.public CachingTypes caching()
public DataDisk withCaching(CachingTypes caching)
caching
- the caching value to set.public Boolean writeAcceleratorEnabled()
public DataDisk withWriteAcceleratorEnabled(Boolean writeAcceleratorEnabled)
writeAcceleratorEnabled
- the writeAcceleratorEnabled value to set.public DiskCreateOptionTypes createOption()
public DataDisk withCreateOption(DiskCreateOptionTypes createOption)
createOption
- the createOption value to set.public Integer diskSizeGB()
public DataDisk withDiskSizeGB(Integer diskSizeGB)
diskSizeGB
- the diskSizeGB value to set.public ManagedDiskParameters managedDisk()
public DataDisk withManagedDisk(ManagedDiskParameters managedDisk)
managedDisk
- the managedDisk value to set.public Boolean toBeDetached()
public DataDisk withToBeDetached(Boolean toBeDetached)
toBeDetached
- the toBeDetached value to set.public Long diskIopsReadWrite()
public Long diskMBpsReadWrite()
public void validate()
IllegalArgumentException
- thrown if the instance is not valid.Copyright © 2020 Microsoft Corporation. All rights reserved.