Class VirtualMachineScaleSetOSDisk
- java.lang.Object
-
- com.azure.resourcemanager.compute.models.VirtualMachineScaleSetOSDisk
-
public final class VirtualMachineScaleSetOSDisk extends Object
Describes a virtual machine scale set operating system disk.
-
-
Constructor Summary
Constructors Constructor Description VirtualMachineScaleSetOSDisk()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CachingTypescaching()Get the caching property: Specifies the caching requirements.DiskCreateOptionTypescreateOption()Get the createOption property: Specifies how the virtual machines in the scale set should be created.<br><br> The only allowed value is: **FromImage** – This value is used when you are using an image to create the virtual machine.DiffDiskSettingsdiffDiskSettings()Get the diffDiskSettings property: Specifies the ephemeral disk Settings for the operating system disk used by the virtual machine scale set.IntegerdiskSizeGB()Get the diskSizeGB property: Specifies the size of the operating system disk in gigabytes.VirtualHardDiskimage()Get the image property: Specifies information about the unmanaged user image to base the scale set on.VirtualMachineScaleSetManagedDiskParametersmanagedDisk()Get the managedDisk property: The managed disk parameters.Stringname()Get the name property: The disk name.OperatingSystemTypesosType()Get the osType property: This property allows you to specify the type of the OS that is included in the disk if creating a VM from user-image or a specialized VHD.voidvalidate()Validates the instance.List<String>vhdContainers()Get the vhdContainers property: Specifies the container urls that are used to store operating system disks for the scale set.VirtualMachineScaleSetOSDiskwithCaching(CachingTypes caching)Set the caching property: Specifies the caching requirements.VirtualMachineScaleSetOSDiskwithCreateOption(DiskCreateOptionTypes createOption)Set the createOption property: Specifies how the virtual machines in the scale set should be created.<br><br> The only allowed value is: **FromImage** – This value is used when you are using an image to create the virtual machine.VirtualMachineScaleSetOSDiskwithDiffDiskSettings(DiffDiskSettings diffDiskSettings)Set the diffDiskSettings property: Specifies the ephemeral disk Settings for the operating system disk used by the virtual machine scale set.VirtualMachineScaleSetOSDiskwithDiskSizeGB(Integer diskSizeGB)Set the diskSizeGB property: Specifies the size of the operating system disk in gigabytes.VirtualMachineScaleSetOSDiskwithImage(VirtualHardDisk image)Set the image property: Specifies information about the unmanaged user image to base the scale set on.VirtualMachineScaleSetOSDiskwithManagedDisk(VirtualMachineScaleSetManagedDiskParameters managedDisk)Set the managedDisk property: The managed disk parameters.VirtualMachineScaleSetOSDiskwithName(String name)Set the name property: The disk name.VirtualMachineScaleSetOSDiskwithOsType(OperatingSystemTypes osType)Set the osType property: This property allows you to specify the type of the OS that is included in the disk if creating a VM from user-image or a specialized VHD.VirtualMachineScaleSetOSDiskwithVhdContainers(List<String> vhdContainers)Set the vhdContainers property: Specifies the container urls that are used to store operating system disks for the scale set.VirtualMachineScaleSetOSDiskwithWriteAcceleratorEnabled(Boolean writeAcceleratorEnabled)Set the writeAcceleratorEnabled property: Specifies whether writeAccelerator should be enabled or disabled on the disk.BooleanwriteAcceleratorEnabled()Get the writeAcceleratorEnabled property: Specifies whether writeAccelerator should be enabled or disabled on the disk.
-
-
-
Method Detail
-
name
public String name()
Get the name property: The disk name.- Returns:
- the name value.
-
withName
public VirtualMachineScaleSetOSDisk withName(String name)
Set the name property: The disk name.- Parameters:
name- the name value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
caching
public CachingTypes caching()
Get the caching property: Specifies the caching requirements. <br><br> Possible values are: <br><br> **None** <br><br> **ReadOnly** <br><br> **ReadWrite** <br><br> Default: **None for Standard storage. ReadOnly for Premium storage**.- Returns:
- the caching value.
-
withCaching
public VirtualMachineScaleSetOSDisk withCaching(CachingTypes caching)
Set the caching property: Specifies the caching requirements. <br><br> Possible values are: <br><br> **None** <br><br> **ReadOnly** <br><br> **ReadWrite** <br><br> Default: **None for Standard storage. ReadOnly for Premium storage**.- Parameters:
caching- the caching value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
writeAcceleratorEnabled
public Boolean writeAcceleratorEnabled()
Get the writeAcceleratorEnabled property: Specifies whether writeAccelerator should be enabled or disabled on the disk.- Returns:
- the writeAcceleratorEnabled value.
-
withWriteAcceleratorEnabled
public VirtualMachineScaleSetOSDisk withWriteAcceleratorEnabled(Boolean writeAcceleratorEnabled)
Set the writeAcceleratorEnabled property: Specifies whether writeAccelerator should be enabled or disabled on the disk.- Parameters:
writeAcceleratorEnabled- the writeAcceleratorEnabled value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
createOption
public DiskCreateOptionTypes createOption()
Get the createOption property: Specifies how the virtual machines in the scale set should be created.<br><br> The only allowed value is: **FromImage** – 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.- Returns:
- the createOption value.
-
withCreateOption
public VirtualMachineScaleSetOSDisk withCreateOption(DiskCreateOptionTypes createOption)
Set the createOption property: Specifies how the virtual machines in the scale set should be created.<br><br> The only allowed value is: **FromImage** – 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.- Parameters:
createOption- the createOption value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
diffDiskSettings
public DiffDiskSettings diffDiskSettings()
Get the diffDiskSettings property: Specifies the ephemeral disk Settings for the operating system disk used by the virtual machine scale set.- Returns:
- the diffDiskSettings value.
-
withDiffDiskSettings
public VirtualMachineScaleSetOSDisk withDiffDiskSettings(DiffDiskSettings diffDiskSettings)
Set the diffDiskSettings property: Specifies the ephemeral disk Settings for the operating system disk used by the virtual machine scale set.- Parameters:
diffDiskSettings- the diffDiskSettings value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
diskSizeGB
public Integer diskSizeGB()
Get the diskSizeGB property: Specifies the size of the operating system disk in gigabytes. This element can be used to overwrite the size of the disk in a virtual machine image. <br><br> This value cannot be larger than 1023 GB.- Returns:
- the diskSizeGB value.
-
withDiskSizeGB
public VirtualMachineScaleSetOSDisk withDiskSizeGB(Integer diskSizeGB)
Set the diskSizeGB property: Specifies the size of the operating system disk in gigabytes. This element can be used to overwrite the size of the disk in a virtual machine image. <br><br> This value cannot be larger than 1023 GB.- Parameters:
diskSizeGB- the diskSizeGB value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
osType
public OperatingSystemTypes osType()
Get the osType property: This property allows you to specify the type of the OS that is included in the disk if creating a VM from user-image or a specialized VHD. <br><br> Possible values are: <br><br> **Windows** <br><br> **Linux**.- Returns:
- the osType value.
-
withOsType
public VirtualMachineScaleSetOSDisk withOsType(OperatingSystemTypes osType)
Set the osType property: This property allows you to specify the type of the OS that is included in the disk if creating a VM from user-image or a specialized VHD. <br><br> Possible values are: <br><br> **Windows** <br><br> **Linux**.- Parameters:
osType- the osType value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
image
public VirtualHardDisk image()
Get the image property: Specifies information about the unmanaged user image to base the scale set on.- Returns:
- the image value.
-
withImage
public VirtualMachineScaleSetOSDisk withImage(VirtualHardDisk image)
Set the image property: Specifies information about the unmanaged user image to base the scale set on.- Parameters:
image- the image value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
vhdContainers
public List<String> vhdContainers()
Get the vhdContainers property: Specifies the container urls that are used to store operating system disks for the scale set.- Returns:
- the vhdContainers value.
-
withVhdContainers
public VirtualMachineScaleSetOSDisk withVhdContainers(List<String> vhdContainers)
Set the vhdContainers property: Specifies the container urls that are used to store operating system disks for the scale set.- Parameters:
vhdContainers- the vhdContainers value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
managedDisk
public VirtualMachineScaleSetManagedDiskParameters managedDisk()
Get the managedDisk property: The managed disk parameters.- Returns:
- the managedDisk value.
-
withManagedDisk
public VirtualMachineScaleSetOSDisk withManagedDisk(VirtualMachineScaleSetManagedDiskParameters managedDisk)
Set the managedDisk property: The managed disk parameters.- Parameters:
managedDisk- the managedDisk value to set.- Returns:
- the VirtualMachineScaleSetOSDisk object itself.
-
validate
public void validate()
Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
-