@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.852Z") @Stability(value=Stable) public class BackupVault extends Resource implements IBackupVault
Example:
IBackupVault importedVault = BackupVault.fromBackupVaultName(this, "Vault", "myVaultName");
Role role = Role.Builder.create(this, "Access Role").assumedBy(new ServicePrincipal("lambda.amazonaws.com")).build();
importedVault.grant(role, "backup:StartBackupJob");
| Modifier and Type | Class and Description |
|---|---|
static class |
BackupVault.Builder
A fluent builder for
BackupVault. |
software.amazon.jsii.JsiiObject.InitializationModeIBackupVault.Jsii$Default, IBackupVault.Jsii$Proxy| Modifier | Constructor and Description |
|---|---|
|
BackupVault(software.constructs.Construct scope,
String id) |
|
BackupVault(software.constructs.Construct scope,
String id,
BackupVaultProps props) |
protected |
BackupVault(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
BackupVault(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
void |
addToAccessPolicy(PolicyStatement statement)
Adds a statement to the vault access policy.
|
void |
blockRecoveryPointDeletion()
Adds a statement to the vault access policy that prevents anyone from deleting a recovery point.
|
static IBackupVault |
fromBackupVaultArn(software.constructs.Construct scope,
String id,
String backupVaultArn)
Import an existing backup vault by arn.
|
static IBackupVault |
fromBackupVaultName(software.constructs.Construct scope,
String id,
String backupVaultName)
Import an existing backup vault by name.
|
String |
getBackupVaultArn()
The ARN of the backup vault.
|
String |
getBackupVaultName()
The name of a logical container where backups are stored.
|
Grant |
grant(IGrantable grantee,
String... actions)
Grant the actions defined in actions to the given grantee on this Backup Vault resource.
|
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isOwnedResource, isResourcejsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitapplyRemovalPolicy, getEnv, getStackprotected BackupVault(software.amazon.jsii.JsiiObjectRef objRef)
protected BackupVault(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public BackupVault(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@Nullable
BackupVaultProps props)
scope - This parameter is required.id - This parameter is required.props - @Stability(value=Stable)
public BackupVault(@NotNull
software.constructs.Construct scope,
@NotNull
String id)
scope - This parameter is required.id - This parameter is required.@Stability(value=Stable) @NotNull public static IBackupVault fromBackupVaultArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String backupVaultArn)
scope - This parameter is required.id - This parameter is required.backupVaultArn - This parameter is required.@Stability(value=Stable) @NotNull public static IBackupVault fromBackupVaultName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String backupVaultName)
scope - This parameter is required.id - This parameter is required.backupVaultName - This parameter is required.@Stability(value=Stable)
public void addToAccessPolicy(@NotNull
PolicyStatement statement)
statement - This parameter is required.@Stability(value=Stable) public void blockRecoveryPointDeletion()
@Stability(value=Stable) @NotNull public Grant grant(@NotNull IGrantable grantee, @NotNull String... actions)
grant in interface IBackupVaultgrantee - Principal to grant right to. This parameter is required.actions - The actions to grant. This parameter is required.@Stability(value=Stable) @NotNull public String getBackupVaultArn()
getBackupVaultArn in interface IBackupVault@Stability(value=Stable) @NotNull public String getBackupVaultName()
getBackupVaultName in interface IBackupVaultCopyright © 2022. All rights reserved.