Class GenericProtectedItem
- java.lang.Object
-
- com.azure.resourcemanager.recoveryservicesbackup.models.ProtectedItem
-
- com.azure.resourcemanager.recoveryservicesbackup.models.GenericProtectedItem
-
public final class GenericProtectedItem extends ProtectedItem
Base class for backup items.
-
-
Constructor Summary
Constructors Constructor Description GenericProtectedItem()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
fabricName()
Get the fabricName property: Name of this backup item's fabric.String
friendlyName()
Get the friendlyName property: Friendly name of the container.String
policyState()
Get the policyState property: Indicates consistency of policy object and policy applied to this backup item.Long
protectedItemId()
Get the protectedItemId property: Data Plane Service ID of the protected item.ProtectionState
protectionState()
Get the protectionState property: Backup state of this backup item.Map<String,String>
sourceAssociations()
Get the sourceAssociations property: Loosely coupled (type, value) associations (example - parent of a protected item).void
validate()
Validates the instance.GenericProtectedItem
withBackupManagementType(BackupManagementType backupManagementType)
Set the backupManagementType property: Type of backup management for the backed up item.GenericProtectedItem
withBackupSetName(String backupSetName)
Set the backupSetName property: Name of the backup set the backup item belongs to.GenericProtectedItem
withContainerName(String containerName)
Set the containerName property: Unique name of container.GenericProtectedItem
withCreateMode(CreateMode createMode)
Set the createMode property: Create mode to indicate recovery of existing soft deleted data source or creation of new data source.GenericProtectedItem
withDeferredDeleteTimeInUtc(OffsetDateTime deferredDeleteTimeInUtc)
Set the deferredDeleteTimeInUtc property: Time for deferred deletion in UTC.GenericProtectedItem
withDeferredDeleteTimeRemaining(String deferredDeleteTimeRemaining)
Set the deferredDeleteTimeRemaining property: Time remaining before the DS marked for deferred delete is permanently deleted.GenericProtectedItem
withFabricName(String fabricName)
Set the fabricName property: Name of this backup item's fabric.GenericProtectedItem
withFriendlyName(String friendlyName)
Set the friendlyName property: Friendly name of the container.GenericProtectedItem
withIsArchiveEnabled(Boolean isArchiveEnabled)
Set the isArchiveEnabled property: Flag to identify whether datasource is protected in archive.GenericProtectedItem
withIsDeferredDeleteScheduleUpcoming(Boolean isDeferredDeleteScheduleUpcoming)
Set the isDeferredDeleteScheduleUpcoming property: Flag to identify whether the deferred deleted DS is to be purged soon.GenericProtectedItem
withIsRehydrate(Boolean isRehydrate)
Set the isRehydrate property: Flag to identify that deferred deleted DS is to be moved into Pause state.GenericProtectedItem
withIsScheduledForDeferredDelete(Boolean isScheduledForDeferredDelete)
Set the isScheduledForDeferredDelete property: Flag to identify whether the DS is scheduled for deferred delete.GenericProtectedItem
withLastRecoveryPoint(OffsetDateTime lastRecoveryPoint)
Set the lastRecoveryPoint property: Timestamp when the last (latest) backup copy was created for this backup item.GenericProtectedItem
withPolicyId(String policyId)
Set the policyId property: ID of the backup policy with which this item is backed up.GenericProtectedItem
withPolicyName(String policyName)
Set the policyName property: Name of the policy used for protection.GenericProtectedItem
withPolicyState(String policyState)
Set the policyState property: Indicates consistency of policy object and policy applied to this backup item.GenericProtectedItem
withProtectedItemId(Long protectedItemId)
Set the protectedItemId property: Data Plane Service ID of the protected item.GenericProtectedItem
withProtectionState(ProtectionState protectionState)
Set the protectionState property: Backup state of this backup item.GenericProtectedItem
withResourceGuardOperationRequests(List<String> resourceGuardOperationRequests)
Set the resourceGuardOperationRequests property: ResourceGuardOperationRequests on which LAC check will be performed.GenericProtectedItem
withSourceAssociations(Map<String,String> sourceAssociations)
Set the sourceAssociations property: Loosely coupled (type, value) associations (example - parent of a protected item).GenericProtectedItem
withSourceResourceId(String sourceResourceId)
Set the sourceResourceId property: ARM ID of the resource to be backed up.GenericProtectedItem
withWorkloadType(DataSourceType workloadType)
Set the workloadType property: Type of workload this item represents.-
Methods inherited from class com.azure.resourcemanager.recoveryservicesbackup.models.ProtectedItem
backupManagementType, backupSetName, containerName, createMode, deferredDeleteTimeInUtc, deferredDeleteTimeRemaining, isArchiveEnabled, isDeferredDeleteScheduleUpcoming, isRehydrate, isScheduledForDeferredDelete, lastRecoveryPoint, policyId, policyName, resourceGuardOperationRequests, sourceResourceId, workloadType
-
-
-
-
Method Detail
-
friendlyName
public String friendlyName()
Get the friendlyName property: Friendly name of the container.- Returns:
- the friendlyName value.
-
withFriendlyName
public GenericProtectedItem withFriendlyName(String friendlyName)
Set the friendlyName property: Friendly name of the container.- Parameters:
friendlyName
- the friendlyName value to set.- Returns:
- the GenericProtectedItem object itself.
-
policyState
public String policyState()
Get the policyState property: Indicates consistency of policy object and policy applied to this backup item.- Returns:
- the policyState value.
-
withPolicyState
public GenericProtectedItem withPolicyState(String policyState)
Set the policyState property: Indicates consistency of policy object and policy applied to this backup item.- Parameters:
policyState
- the policyState value to set.- Returns:
- the GenericProtectedItem object itself.
-
protectionState
public ProtectionState protectionState()
Get the protectionState property: Backup state of this backup item.- Returns:
- the protectionState value.
-
withProtectionState
public GenericProtectedItem withProtectionState(ProtectionState protectionState)
Set the protectionState property: Backup state of this backup item.- Parameters:
protectionState
- the protectionState value to set.- Returns:
- the GenericProtectedItem object itself.
-
protectedItemId
public Long protectedItemId()
Get the protectedItemId property: Data Plane Service ID of the protected item.- Returns:
- the protectedItemId value.
-
withProtectedItemId
public GenericProtectedItem withProtectedItemId(Long protectedItemId)
Set the protectedItemId property: Data Plane Service ID of the protected item.- Parameters:
protectedItemId
- the protectedItemId value to set.- Returns:
- the GenericProtectedItem object itself.
-
sourceAssociations
public Map<String,String> sourceAssociations()
Get the sourceAssociations property: Loosely coupled (type, value) associations (example - parent of a protected item).- Returns:
- the sourceAssociations value.
-
withSourceAssociations
public GenericProtectedItem withSourceAssociations(Map<String,String> sourceAssociations)
Set the sourceAssociations property: Loosely coupled (type, value) associations (example - parent of a protected item).- Parameters:
sourceAssociations
- the sourceAssociations value to set.- Returns:
- the GenericProtectedItem object itself.
-
fabricName
public String fabricName()
Get the fabricName property: Name of this backup item's fabric.- Returns:
- the fabricName value.
-
withFabricName
public GenericProtectedItem withFabricName(String fabricName)
Set the fabricName property: Name of this backup item's fabric.- Parameters:
fabricName
- the fabricName value to set.- Returns:
- the GenericProtectedItem object itself.
-
withBackupManagementType
public GenericProtectedItem withBackupManagementType(BackupManagementType backupManagementType)
Set the backupManagementType property: Type of backup management for the backed up item.- Overrides:
withBackupManagementType
in classProtectedItem
- Parameters:
backupManagementType
- the backupManagementType value to set.- Returns:
- the ProtectedItem object itself.
-
withWorkloadType
public GenericProtectedItem withWorkloadType(DataSourceType workloadType)
Set the workloadType property: Type of workload this item represents.- Overrides:
withWorkloadType
in classProtectedItem
- Parameters:
workloadType
- the workloadType value to set.- Returns:
- the ProtectedItem object itself.
-
withContainerName
public GenericProtectedItem withContainerName(String containerName)
Set the containerName property: Unique name of container.- Overrides:
withContainerName
in classProtectedItem
- Parameters:
containerName
- the containerName value to set.- Returns:
- the ProtectedItem object itself.
-
withSourceResourceId
public GenericProtectedItem withSourceResourceId(String sourceResourceId)
Set the sourceResourceId property: ARM ID of the resource to be backed up.- Overrides:
withSourceResourceId
in classProtectedItem
- Parameters:
sourceResourceId
- the sourceResourceId value to set.- Returns:
- the ProtectedItem object itself.
-
withPolicyId
public GenericProtectedItem withPolicyId(String policyId)
Set the policyId property: ID of the backup policy with which this item is backed up.- Overrides:
withPolicyId
in classProtectedItem
- Parameters:
policyId
- the policyId value to set.- Returns:
- the ProtectedItem object itself.
-
withLastRecoveryPoint
public GenericProtectedItem withLastRecoveryPoint(OffsetDateTime lastRecoveryPoint)
Set the lastRecoveryPoint property: Timestamp when the last (latest) backup copy was created for this backup item.- Overrides:
withLastRecoveryPoint
in classProtectedItem
- Parameters:
lastRecoveryPoint
- the lastRecoveryPoint value to set.- Returns:
- the ProtectedItem object itself.
-
withBackupSetName
public GenericProtectedItem withBackupSetName(String backupSetName)
Set the backupSetName property: Name of the backup set the backup item belongs to.- Overrides:
withBackupSetName
in classProtectedItem
- Parameters:
backupSetName
- the backupSetName value to set.- Returns:
- the ProtectedItem object itself.
-
withCreateMode
public GenericProtectedItem withCreateMode(CreateMode createMode)
Set the createMode property: Create mode to indicate recovery of existing soft deleted data source or creation of new data source.- Overrides:
withCreateMode
in classProtectedItem
- Parameters:
createMode
- the createMode value to set.- Returns:
- the ProtectedItem object itself.
-
withDeferredDeleteTimeInUtc
public GenericProtectedItem withDeferredDeleteTimeInUtc(OffsetDateTime deferredDeleteTimeInUtc)
Set the deferredDeleteTimeInUtc property: Time for deferred deletion in UTC.- Overrides:
withDeferredDeleteTimeInUtc
in classProtectedItem
- Parameters:
deferredDeleteTimeInUtc
- the deferredDeleteTimeInUtc value to set.- Returns:
- the ProtectedItem object itself.
-
withIsScheduledForDeferredDelete
public GenericProtectedItem withIsScheduledForDeferredDelete(Boolean isScheduledForDeferredDelete)
Set the isScheduledForDeferredDelete property: Flag to identify whether the DS is scheduled for deferred delete.- Overrides:
withIsScheduledForDeferredDelete
in classProtectedItem
- Parameters:
isScheduledForDeferredDelete
- the isScheduledForDeferredDelete value to set.- Returns:
- the ProtectedItem object itself.
-
withDeferredDeleteTimeRemaining
public GenericProtectedItem withDeferredDeleteTimeRemaining(String deferredDeleteTimeRemaining)
Set the deferredDeleteTimeRemaining property: Time remaining before the DS marked for deferred delete is permanently deleted.- Overrides:
withDeferredDeleteTimeRemaining
in classProtectedItem
- Parameters:
deferredDeleteTimeRemaining
- the deferredDeleteTimeRemaining value to set.- Returns:
- the ProtectedItem object itself.
-
withIsDeferredDeleteScheduleUpcoming
public GenericProtectedItem withIsDeferredDeleteScheduleUpcoming(Boolean isDeferredDeleteScheduleUpcoming)
Set the isDeferredDeleteScheduleUpcoming property: Flag to identify whether the deferred deleted DS is to be purged soon.- Overrides:
withIsDeferredDeleteScheduleUpcoming
in classProtectedItem
- Parameters:
isDeferredDeleteScheduleUpcoming
- the isDeferredDeleteScheduleUpcoming value to set.- Returns:
- the ProtectedItem object itself.
-
withIsRehydrate
public GenericProtectedItem withIsRehydrate(Boolean isRehydrate)
Set the isRehydrate property: Flag to identify that deferred deleted DS is to be moved into Pause state.- Overrides:
withIsRehydrate
in classProtectedItem
- Parameters:
isRehydrate
- the isRehydrate value to set.- Returns:
- the ProtectedItem object itself.
-
withResourceGuardOperationRequests
public GenericProtectedItem withResourceGuardOperationRequests(List<String> resourceGuardOperationRequests)
Set the resourceGuardOperationRequests property: ResourceGuardOperationRequests on which LAC check will be performed.- Overrides:
withResourceGuardOperationRequests
in classProtectedItem
- Parameters:
resourceGuardOperationRequests
- the resourceGuardOperationRequests value to set.- Returns:
- the ProtectedItem object itself.
-
withIsArchiveEnabled
public GenericProtectedItem withIsArchiveEnabled(Boolean isArchiveEnabled)
Set the isArchiveEnabled property: Flag to identify whether datasource is protected in archive.- Overrides:
withIsArchiveEnabled
in classProtectedItem
- Parameters:
isArchiveEnabled
- the isArchiveEnabled value to set.- Returns:
- the ProtectedItem object itself.
-
withPolicyName
public GenericProtectedItem withPolicyName(String policyName)
Set the policyName property: Name of the policy used for protection.- Overrides:
withPolicyName
in classProtectedItem
- Parameters:
policyName
- the policyName value to set.- Returns:
- the ProtectedItem object itself.
-
validate
public void validate()
Validates the instance.- Overrides:
validate
in classProtectedItem
- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-
-