Class PeriodicModeBackupPolicy
java.lang.Object
com.azure.resourcemanager.cosmos.models.BackupPolicy
com.azure.resourcemanager.cosmos.models.PeriodicModeBackupPolicy
- All Implemented Interfaces:
com.azure.json.JsonSerializable<BackupPolicy>
The object representing periodic mode backup policy.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of PeriodicModeBackupPolicy class. -
Method Summary
Modifier and TypeMethodDescriptionstatic PeriodicModeBackupPolicyfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of PeriodicModeBackupPolicy from the JsonReader.Get the periodicModeProperties property: Configuration values for periodic mode backup.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) type()Get the type property: Describes the mode of backups.voidvalidate()Validates the instance.withMigrationState(BackupPolicyMigrationState migrationState) Set the migrationState property: The object representing the state of the migration between the backup policies.withPeriodicModeProperties(PeriodicModeProperties periodicModeProperties) Set the periodicModeProperties property: Configuration values for periodic mode backup.Methods inherited from class BackupPolicy
migrationStateMethods 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
-
PeriodicModeBackupPolicy
public PeriodicModeBackupPolicy()Creates an instance of PeriodicModeBackupPolicy class.
-
-
Method Details
-
type
Get the type property: Describes the mode of backups.- Overrides:
typein classBackupPolicy- Returns:
- the type value.
-
periodicModeProperties
Get the periodicModeProperties property: Configuration values for periodic mode backup.- Returns:
- the periodicModeProperties value.
-
withPeriodicModeProperties
public PeriodicModeBackupPolicy withPeriodicModeProperties(PeriodicModeProperties periodicModeProperties) Set the periodicModeProperties property: Configuration values for periodic mode backup.- Parameters:
periodicModeProperties- the periodicModeProperties value to set.- Returns:
- the PeriodicModeBackupPolicy object itself.
-
withMigrationState
Set the migrationState property: The object representing the state of the migration between the backup policies.- Overrides:
withMigrationStatein classBackupPolicy- Parameters:
migrationState- the migrationState value to set.- Returns:
- the BackupPolicy object itself.
-
validate
public void validate()Validates the instance.- Overrides:
validatein classBackupPolicy- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<BackupPolicy>- Overrides:
toJsonin classBackupPolicy- Throws:
IOException
-
fromJson
public static PeriodicModeBackupPolicy fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of PeriodicModeBackupPolicy from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of PeriodicModeBackupPolicy 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 PeriodicModeBackupPolicy.
-