Class PeriodicModeProperties

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

public final class PeriodicModeProperties extends Object implements com.azure.json.JsonSerializable<PeriodicModeProperties>
Configuration values for periodic mode backup.
  • Constructor Details

    • PeriodicModeProperties

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

    • backupIntervalInMinutes

      public Integer backupIntervalInMinutes()
      Get the backupIntervalInMinutes property: An integer representing the interval in minutes between two backups.
      Returns:
      the backupIntervalInMinutes value.
    • withBackupIntervalInMinutes

      public PeriodicModeProperties withBackupIntervalInMinutes(Integer backupIntervalInMinutes)
      Set the backupIntervalInMinutes property: An integer representing the interval in minutes between two backups.
      Parameters:
      backupIntervalInMinutes - the backupIntervalInMinutes value to set.
      Returns:
      the PeriodicModeProperties object itself.
    • backupRetentionIntervalInHours

      public Integer backupRetentionIntervalInHours()
      Get the backupRetentionIntervalInHours property: An integer representing the time (in hours) that each backup is retained.
      Returns:
      the backupRetentionIntervalInHours value.
    • withBackupRetentionIntervalInHours

      public PeriodicModeProperties withBackupRetentionIntervalInHours(Integer backupRetentionIntervalInHours)
      Set the backupRetentionIntervalInHours property: An integer representing the time (in hours) that each backup is retained.
      Parameters:
      backupRetentionIntervalInHours - the backupRetentionIntervalInHours value to set.
      Returns:
      the PeriodicModeProperties object itself.
    • backupStorageRedundancy

      public BackupStorageRedundancy backupStorageRedundancy()
      Get the backupStorageRedundancy property: Enum to indicate type of backup residency.
      Returns:
      the backupStorageRedundancy value.
    • withBackupStorageRedundancy

      public PeriodicModeProperties withBackupStorageRedundancy(BackupStorageRedundancy backupStorageRedundancy)
      Set the backupStorageRedundancy property: Enum to indicate type of backup residency.
      Parameters:
      backupStorageRedundancy - the backupStorageRedundancy value to set.
      Returns:
      the PeriodicModeProperties 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<PeriodicModeProperties>
      Throws:
      IOException
    • fromJson

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