Class OperationRecoverySettings

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

public final class OperationRecoverySettings extends Object implements com.azure.json.JsonSerializable<OperationRecoverySettings>
The configuration parameters used for operation recovery settings on a virtual machine scale set.
  • Constructor Details

    • OperationRecoverySettings

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

    • restartRecoveryPolicy

      public RestartRecoveryPolicy restartRecoveryPolicy()
      Get the restartRecoveryPolicy property: The configuration parameters used for restart recovery policy.
      Returns:
      the restartRecoveryPolicy value.
    • withRestartRecoveryPolicy

      public OperationRecoverySettings withRestartRecoveryPolicy(RestartRecoveryPolicy restartRecoveryPolicy)
      Set the restartRecoveryPolicy property: The configuration parameters used for restart recovery policy.
      Parameters:
      restartRecoveryPolicy - the restartRecoveryPolicy value to set.
      Returns:
      the OperationRecoverySettings object itself.
    • startRecoveryPolicy

      public StartRecoveryPolicy startRecoveryPolicy()
      Get the startRecoveryPolicy property: The configuration parameters used for start recovery policy.
      Returns:
      the startRecoveryPolicy value.
    • withStartRecoveryPolicy

      public OperationRecoverySettings withStartRecoveryPolicy(StartRecoveryPolicy startRecoveryPolicy)
      Set the startRecoveryPolicy property: The configuration parameters used for start recovery policy.
      Parameters:
      startRecoveryPolicy - the startRecoveryPolicy value to set.
      Returns:
      the OperationRecoverySettings object itself.
    • reimageRecoveryPolicy

      public ReimageRecoveryPolicy reimageRecoveryPolicy()
      Get the reimageRecoveryPolicy property: The configuration parameters used for reimage recovery policy.
      Returns:
      the reimageRecoveryPolicy value.
    • withReimageRecoveryPolicy

      public OperationRecoverySettings withReimageRecoveryPolicy(ReimageRecoveryPolicy reimageRecoveryPolicy)
      Set the reimageRecoveryPolicy property: The configuration parameters used for reimage recovery policy.
      Parameters:
      reimageRecoveryPolicy - the reimageRecoveryPolicy value to set.
      Returns:
      the OperationRecoverySettings 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<OperationRecoverySettings>
      Throws:
      IOException
    • fromJson

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