Class Backup

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

public final class Backup extends Object implements com.azure.json.JsonSerializable<Backup>
Backup properties of a server.
  • Constructor Details

    • Backup

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

    • backupRetentionDays

      public Integer backupRetentionDays()
      Get the backupRetentionDays property: Backup retention days for the server.
      Returns:
      the backupRetentionDays value.
    • withBackupRetentionDays

      public Backup withBackupRetentionDays(Integer backupRetentionDays)
      Set the backupRetentionDays property: Backup retention days for the server.
      Parameters:
      backupRetentionDays - the backupRetentionDays value to set.
      Returns:
      the Backup object itself.
    • geoRedundantBackup

      public GeographicallyRedundantBackup geoRedundantBackup()
      Get the geoRedundantBackup property: Indicates if the server is configured to create geographically redundant backups.
      Returns:
      the geoRedundantBackup value.
    • withGeoRedundantBackup

      public Backup withGeoRedundantBackup(GeographicallyRedundantBackup geoRedundantBackup)
      Set the geoRedundantBackup property: Indicates if the server is configured to create geographically redundant backups.
      Parameters:
      geoRedundantBackup - the geoRedundantBackup value to set.
      Returns:
      the Backup object itself.
    • earliestRestoreDate

      public OffsetDateTime earliestRestoreDate()
      Get the earliestRestoreDate property: Earliest restore point time (ISO8601 format) for a server.
      Returns:
      the earliestRestoreDate value.
    • 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<Backup>
      Throws:
      IOException
    • fromJson

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