Class OSDisk

java.lang.Object
com.azure.compute.batch.models.OSDisk
All Implemented Interfaces:
com.azure.json.JsonSerializable<OSDisk>

public final class OSDisk extends Object implements com.azure.json.JsonSerializable<OSDisk>
Settings for the operating system disk of the compute node (VM).
  • Constructor Details

    • OSDisk

      public OSDisk()
      Creates an instance of OSDisk class.
  • Method Details

    • getEphemeralOSDiskSettings

      public DiffDiskSettings getEphemeralOSDiskSettings()
      Get the ephemeralOSDiskSettings property: Specifies the ephemeral Disk Settings for the operating system disk used by the compute node (VM).
      Returns:
      the ephemeralOSDiskSettings value.
    • setEphemeralOSDiskSettings

      public OSDisk setEphemeralOSDiskSettings(DiffDiskSettings ephemeralOSDiskSettings)
      Set the ephemeralOSDiskSettings property: Specifies the ephemeral Disk Settings for the operating system disk used by the compute node (VM).
      Parameters:
      ephemeralOSDiskSettings - the ephemeralOSDiskSettings value to set.
      Returns:
      the OSDisk object itself.
    • getCaching

      public CachingType getCaching()
      Get the caching property: Specifies the caching requirements. Possible values are: None, ReadOnly, ReadWrite. The default values are: None for Standard storage. ReadOnly for Premium storage.
      Returns:
      the caching value.
    • setCaching

      public OSDisk setCaching(CachingType caching)
      Set the caching property: Specifies the caching requirements. Possible values are: None, ReadOnly, ReadWrite. The default values are: None for Standard storage. ReadOnly for Premium storage.
      Parameters:
      caching - the caching value to set.
      Returns:
      the OSDisk object itself.
    • getDiskSizeGB

      public Integer getDiskSizeGB()
      Get the diskSizeGB property: The initial disk size in GB when creating new OS disk.
      Returns:
      the diskSizeGB value.
    • setDiskSizeGB

      public OSDisk setDiskSizeGB(Integer diskSizeGB)
      Set the diskSizeGB property: The initial disk size in GB when creating new OS disk.
      Parameters:
      diskSizeGB - the diskSizeGB value to set.
      Returns:
      the OSDisk object itself.
    • getManagedDisk

      public ManagedDisk getManagedDisk()
      Get the managedDisk property: The managed disk parameters.
      Returns:
      the managedDisk value.
    • setManagedDisk

      public OSDisk setManagedDisk(ManagedDisk managedDisk)
      Set the managedDisk property: The managed disk parameters.
      Parameters:
      managedDisk - the managedDisk value to set.
      Returns:
      the OSDisk object itself.
    • isWriteAcceleratorEnabled

      public Boolean isWriteAcceleratorEnabled()
      Get the writeAcceleratorEnabled property: Specifies whether writeAccelerator should be enabled or disabled on the disk.
      Returns:
      the writeAcceleratorEnabled value.
    • setWriteAcceleratorEnabled

      public OSDisk setWriteAcceleratorEnabled(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 OSDisk object itself.
    • toJson

      public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter) throws IOException
      Specified by:
      toJson in interface com.azure.json.JsonSerializable<OSDisk>
      Throws:
      IOException
    • fromJson

      public static OSDisk fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of OSDisk from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of OSDisk if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
      Throws:
      IOException - If an error occurs while reading the OSDisk.