Class DetachDataDiskProperties

java.lang.Object
com.azure.resourcemanager.devtestlabs.models.DetachDataDiskProperties
All Implemented Interfaces:
com.azure.json.JsonSerializable<DetachDataDiskProperties>

public final class DetachDataDiskProperties extends Object implements com.azure.json.JsonSerializable<DetachDataDiskProperties>
Request body for detaching data disk from a virtual machine.
  • Constructor Details

    • DetachDataDiskProperties

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

    • existingLabDiskId

      public String existingLabDiskId()
      Get the existingLabDiskId property: Specifies the disk resource ID to detach from virtual machine.
      Returns:
      the existingLabDiskId value.
    • withExistingLabDiskId

      public DetachDataDiskProperties withExistingLabDiskId(String existingLabDiskId)
      Set the existingLabDiskId property: Specifies the disk resource ID to detach from virtual machine.
      Parameters:
      existingLabDiskId - the existingLabDiskId value to set.
      Returns:
      the DetachDataDiskProperties object itself.
    • validate

      public void validate()
      Validates the instance.
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.
    • toJson

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

      public static DetachDataDiskProperties fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of DetachDataDiskProperties from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of DetachDataDiskProperties 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 DetachDataDiskProperties.