ManagedDatabaseInner Class

public final class ManagedDatabaseInner
extends Resource

A managed database resource.

Constructor Summary

Constructor Description
ManagedDatabaseInner()

Creates an instance of ManagedDatabaseInner class.

Method Summary

Modifier and Type Method and Description
Boolean autoCompleteRestore()

Get the autoCompleteRestore property: Whether to auto complete restore of this managed database.

CatalogCollationType catalogCollation()

Get the catalogCollation property: Collation of the metadata catalog.

String collation()

Get the collation property: Collation of the managed database.

ManagedDatabaseCreateMode createMode()

Get the createMode property: Managed database create mode.

OffsetDateTime creationDate()

Get the creationDate property: Creation date of the database.

String defaultSecondaryLocation()

Get the defaultSecondaryLocation property: Geo paired region.

OffsetDateTime earliestRestorePoint()

Get the earliestRestorePoint property: Earliest restore point in time for point in time restore.

String failoverGroupId()

Get the failoverGroupId property: Instance Failover Group resource identifier that this managed database belongs to.

static ManagedDatabaseInner fromJson(JsonReader jsonReader)

Reads an instance of ManagedDatabaseInner from the JsonReader.

String id()

Get the id property: Fully qualified resource Id for the resource.

String lastBackupName()

Get the lastBackupName property: Last backup file name for restore of this managed database.

String longTermRetentionBackupResourceId()

Get the longTermRetentionBackupResourceId property: The name of the Long Term Retention backup to be used for restore of this managed database.

String name()

Get the name property: The name of the resource.

String recoverableDatabaseId()

Get the recoverableDatabaseId property: The resource identifier of the recoverable database associated with create operation of this database.

String restorableDroppedDatabaseId()

Get the restorableDroppedDatabaseId property: The restorable dropped database resource id to restore when creating this database.

OffsetDateTime restorePointInTime()

Get the restorePointInTime property: Conditional.

String sourceDatabaseId()

Get the sourceDatabaseId property: The resource identifier of the source database associated with create operation of this database.

ManagedDatabaseStatus status()

Get the status property: Status of the database.

String storageContainerSasToken()

Get the storageContainerSasToken property: Conditional.

String storageContainerUri()

Get the storageContainerUri property: Conditional.

JsonWriter toJson(JsonWriter jsonWriter)
String type()

Get the type property: The type of the resource.

void validate()

Validates the instance.

ManagedDatabaseInner withAutoCompleteRestore(Boolean autoCompleteRestore)

Set the autoCompleteRestore property: Whether to auto complete restore of this managed database.

ManagedDatabaseInner withCatalogCollation(CatalogCollationType catalogCollation)

Set the catalogCollation property: Collation of the metadata catalog.

ManagedDatabaseInner withCollation(String collation)

Set the collation property: Collation of the managed database.

ManagedDatabaseInner withCreateMode(ManagedDatabaseCreateMode createMode)

Set the createMode property: Managed database create mode.

ManagedDatabaseInner withLastBackupName(String lastBackupName)

Set the lastBackupName property: Last backup file name for restore of this managed database.

ManagedDatabaseInner withLocation(String location)
ManagedDatabaseInner withLongTermRetentionBackupResourceId(String longTermRetentionBackupResourceId)

Set the longTermRetentionBackupResourceId property: The name of the Long Term Retention backup to be used for restore of this managed database.

ManagedDatabaseInner withRecoverableDatabaseId(String recoverableDatabaseId)

Set the recoverableDatabaseId property: The resource identifier of the recoverable database associated with create operation of this database.

ManagedDatabaseInner withRestorableDroppedDatabaseId(String restorableDroppedDatabaseId)

Set the restorableDroppedDatabaseId property: The restorable dropped database resource id to restore when creating this database.

ManagedDatabaseInner withRestorePointInTime(OffsetDateTime restorePointInTime)

Set the restorePointInTime property: Conditional.

ManagedDatabaseInner withSourceDatabaseId(String sourceDatabaseId)

Set the sourceDatabaseId property: The resource identifier of the source database associated with create operation of this database.

ManagedDatabaseInner withStorageContainerSasToken(String storageContainerSasToken)

Set the storageContainerSasToken property: Conditional.

ManagedDatabaseInner withStorageContainerUri(String storageContainerUri)

Set the storageContainerUri property: Conditional.

ManagedDatabaseInner withTags(Map<String,String> tags)

Methods inherited from ProxyResource

Methods inherited from Resource

Methods inherited from java.lang.Object

Constructor Details

ManagedDatabaseInner

public ManagedDatabaseInner()

Creates an instance of ManagedDatabaseInner class.

Method Details

autoCompleteRestore

public Boolean autoCompleteRestore()

Get the autoCompleteRestore property: Whether to auto complete restore of this managed database.

Returns:

the autoCompleteRestore value.

catalogCollation

public CatalogCollationType catalogCollation()

Get the catalogCollation property: Collation of the metadata catalog.

Returns:

the catalogCollation value.

collation

public String collation()

Get the collation property: Collation of the managed database.

Returns:

the collation value.

createMode

public ManagedDatabaseCreateMode createMode()

Get the createMode property: Managed database create mode. PointInTimeRestore: Create a database by restoring a point in time backup of an existing database. SourceDatabaseName, SourceManagedInstanceName and PointInTime must be specified. RestoreExternalBackup: Create a database by restoring from external backup files. Collation, StorageContainerUri and StorageContainerSasToken must be specified. Recovery: Creates a database by restoring a geo-replicated backup. RecoverableDatabaseId must be specified as the recoverable database resource ID to restore. RestoreLongTermRetentionBackup: Create a database by restoring from a long term retention backup (longTermRetentionBackupResourceId required).

Returns:

the createMode value.

creationDate

public OffsetDateTime creationDate()

Get the creationDate property: Creation date of the database.

Returns:

the creationDate value.

defaultSecondaryLocation

public String defaultSecondaryLocation()

Get the defaultSecondaryLocation property: Geo paired region.

Returns:

the defaultSecondaryLocation value.

earliestRestorePoint

public OffsetDateTime earliestRestorePoint()

Get the earliestRestorePoint property: Earliest restore point in time for point in time restore.

Returns:

the earliestRestorePoint value.

failoverGroupId

public String failoverGroupId()

Get the failoverGroupId property: Instance Failover Group resource identifier that this managed database belongs to.

Returns:

the failoverGroupId value.

fromJson

public static ManagedDatabaseInner fromJson(JsonReader jsonReader)

Reads an instance of ManagedDatabaseInner from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of ManagedDatabaseInner if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

id

public String id()

Get the id property: Fully qualified resource Id for the resource.

Overrides:

ManagedDatabaseInner.id()

Returns:

the id value.

lastBackupName

public String lastBackupName()

Get the lastBackupName property: Last backup file name for restore of this managed database.

Returns:

the lastBackupName value.

longTermRetentionBackupResourceId

public String longTermRetentionBackupResourceId()

Get the longTermRetentionBackupResourceId property: The name of the Long Term Retention backup to be used for restore of this managed database.

Returns:

the longTermRetentionBackupResourceId value.

name

public String name()

Get the name property: The name of the resource.

Overrides:

ManagedDatabaseInner.name()

Returns:

the name value.

recoverableDatabaseId

public String recoverableDatabaseId()

Get the recoverableDatabaseId property: The resource identifier of the recoverable database associated with create operation of this database.

Returns:

the recoverableDatabaseId value.

restorableDroppedDatabaseId

public String restorableDroppedDatabaseId()

Get the restorableDroppedDatabaseId property: The restorable dropped database resource id to restore when creating this database.

Returns:

the restorableDroppedDatabaseId value.

restorePointInTime

public OffsetDateTime restorePointInTime()

Get the restorePointInTime property: Conditional. If createMode is PointInTimeRestore, this value is required. Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database.

Returns:

the restorePointInTime value.

sourceDatabaseId

public String sourceDatabaseId()

Get the sourceDatabaseId property: The resource identifier of the source database associated with create operation of this database.

Returns:

the sourceDatabaseId value.

status

public ManagedDatabaseStatus status()

Get the status property: Status of the database.

Returns:

the status value.

storageContainerSasToken

public String storageContainerSasToken()

Get the storageContainerSasToken property: Conditional. If createMode is RestoreExternalBackup, this value is required. Specifies the storage container sas token.

Returns:

the storageContainerSasToken value.

storageContainerUri

public String storageContainerUri()

Get the storageContainerUri property: Conditional. If createMode is RestoreExternalBackup, this value is required. Specifies the uri of the storage container where backups for this restore are stored.

Returns:

the storageContainerUri value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Overrides:

ManagedDatabaseInner.toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public String type()

Get the type property: The type of the resource.

Overrides:

ManagedDatabaseInner.type()

Returns:

the type value.

validate

public void validate()

Validates the instance.

withAutoCompleteRestore

public ManagedDatabaseInner withAutoCompleteRestore(Boolean autoCompleteRestore)

Set the autoCompleteRestore property: Whether to auto complete restore of this managed database.

Parameters:

autoCompleteRestore - the autoCompleteRestore value to set.

Returns:

the ManagedDatabaseInner object itself.

withCatalogCollation

public ManagedDatabaseInner withCatalogCollation(CatalogCollationType catalogCollation)

Set the catalogCollation property: Collation of the metadata catalog.

Parameters:

catalogCollation - the catalogCollation value to set.

Returns:

the ManagedDatabaseInner object itself.

withCollation

public ManagedDatabaseInner withCollation(String collation)

Set the collation property: Collation of the managed database.

Parameters:

collation - the collation value to set.

Returns:

the ManagedDatabaseInner object itself.

withCreateMode

public ManagedDatabaseInner withCreateMode(ManagedDatabaseCreateMode createMode)

Set the createMode property: Managed database create mode. PointInTimeRestore: Create a database by restoring a point in time backup of an existing database. SourceDatabaseName, SourceManagedInstanceName and PointInTime must be specified. RestoreExternalBackup: Create a database by restoring from external backup files. Collation, StorageContainerUri and StorageContainerSasToken must be specified. Recovery: Creates a database by restoring a geo-replicated backup. RecoverableDatabaseId must be specified as the recoverable database resource ID to restore. RestoreLongTermRetentionBackup: Create a database by restoring from a long term retention backup (longTermRetentionBackupResourceId required).

Parameters:

createMode - the createMode value to set.

Returns:

the ManagedDatabaseInner object itself.

withLastBackupName

public ManagedDatabaseInner withLastBackupName(String lastBackupName)

Set the lastBackupName property: Last backup file name for restore of this managed database.

Parameters:

lastBackupName - the lastBackupName value to set.

Returns:

the ManagedDatabaseInner object itself.

withLocation

public ManagedDatabaseInner withLocation(String location)

Overrides:

ManagedDatabaseInner.withLocation(String location)

Parameters:

location

withLongTermRetentionBackupResourceId

public ManagedDatabaseInner withLongTermRetentionBackupResourceId(String longTermRetentionBackupResourceId)

Set the longTermRetentionBackupResourceId property: The name of the Long Term Retention backup to be used for restore of this managed database.

Parameters:

longTermRetentionBackupResourceId - the longTermRetentionBackupResourceId value to set.

Returns:

the ManagedDatabaseInner object itself.

withRecoverableDatabaseId

public ManagedDatabaseInner withRecoverableDatabaseId(String recoverableDatabaseId)

Set the recoverableDatabaseId property: The resource identifier of the recoverable database associated with create operation of this database.

Parameters:

recoverableDatabaseId - the recoverableDatabaseId value to set.

Returns:

the ManagedDatabaseInner object itself.

withRestorableDroppedDatabaseId

public ManagedDatabaseInner withRestorableDroppedDatabaseId(String restorableDroppedDatabaseId)

Set the restorableDroppedDatabaseId property: The restorable dropped database resource id to restore when creating this database.

Parameters:

restorableDroppedDatabaseId - the restorableDroppedDatabaseId value to set.

Returns:

the ManagedDatabaseInner object itself.

withRestorePointInTime

public ManagedDatabaseInner withRestorePointInTime(OffsetDateTime restorePointInTime)

Set the restorePointInTime property: Conditional. If createMode is PointInTimeRestore, this value is required. Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database.

Parameters:

restorePointInTime - the restorePointInTime value to set.

Returns:

the ManagedDatabaseInner object itself.

withSourceDatabaseId

public ManagedDatabaseInner withSourceDatabaseId(String sourceDatabaseId)

Set the sourceDatabaseId property: The resource identifier of the source database associated with create operation of this database.

Parameters:

sourceDatabaseId - the sourceDatabaseId value to set.

Returns:

the ManagedDatabaseInner object itself.

withStorageContainerSasToken

public ManagedDatabaseInner withStorageContainerSasToken(String storageContainerSasToken)

Set the storageContainerSasToken property: Conditional. If createMode is RestoreExternalBackup, this value is required. Specifies the storage container sas token.

Parameters:

storageContainerSasToken - the storageContainerSasToken value to set.

Returns:

the ManagedDatabaseInner object itself.

withStorageContainerUri

public ManagedDatabaseInner withStorageContainerUri(String storageContainerUri)

Set the storageContainerUri property: Conditional. If createMode is RestoreExternalBackup, this value is required. Specifies the uri of the storage container where backups for this restore are stored.

Parameters:

storageContainerUri - the storageContainerUri value to set.

Returns:

the ManagedDatabaseInner object itself.

withTags

public ManagedDatabaseInner withTags(Map tags)

Overrides:

ManagedDatabaseInner.withTags(Map<String,String> tags)

Parameters:

tags

Applies to