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 Summary
ConstructorsConstructorDescriptionCreates an instance of OperationRecoverySettings class. -
Method Summary
Modifier and TypeMethodDescriptionstatic OperationRecoverySettingsfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of OperationRecoverySettings from the JsonReader.Get the reimageRecoveryPolicy property: The configuration parameters used for reimage recovery policy.Get the restartRecoveryPolicy property: The configuration parameters used for restart recovery policy.Get the startRecoveryPolicy property: The configuration parameters used for start recovery policy.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) voidvalidate()Validates the instance.withReimageRecoveryPolicy(ReimageRecoveryPolicy reimageRecoveryPolicy) Set the reimageRecoveryPolicy property: The configuration parameters used for reimage recovery policy.withRestartRecoveryPolicy(RestartRecoveryPolicy restartRecoveryPolicy) Set the restartRecoveryPolicy property: The configuration parameters used for restart recovery policy.withStartRecoveryPolicy(StartRecoveryPolicy startRecoveryPolicy) Set the startRecoveryPolicy property: The configuration parameters used for start recovery policy.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
OperationRecoverySettings
public OperationRecoverySettings()Creates an instance of OperationRecoverySettings class.
-
-
Method Details
-
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
Get the startRecoveryPolicy property: The configuration parameters used for start recovery policy.- Returns:
- the startRecoveryPolicy value.
-
withStartRecoveryPolicy
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
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
- Specified by:
toJsonin interfacecom.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.
-