Class TableBucket
- All Implemented Interfaces:
IResource,ITableBucket,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
This bucket may not yet have all features that exposed by the underlying CfnTableBucket.
Example:
TableBucket sampleTableBucket = TableBucket.Builder.create(scope, "ExampleTableBucket")
.tableBucketName("example-bucket")
// Optional fields:
.unreferencedFileRemoval(UnreferencedFileRemoval.builder()
.noncurrentDays(123)
.status(UnreferencedFileRemovalStatus.ENABLED)
.unreferencedDays(123)
.build())
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class(experimental) A fluent builder forTableBucket.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IResource
IResource.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.services.s3tables.alpha.ITableBucket
ITableBucket.Jsii$Default, ITableBucket.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String(experimental) Uniquely identifies this class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedTableBucket(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedTableBucket(software.amazon.jsii.JsiiObjectRef objRef) TableBucket(software.constructs.Construct scope, String id, TableBucketProps props) -
Method Summary
Modifier and TypeMethodDescriptionaddToResourcePolicy(PolicyStatement statement) (experimental) Adds a statement to the resource policy for a principal (i.e.static ITableBucketfromTableBucketArn(software.constructs.Construct scope, String id, String tableBucketArn) (experimental) Defines a TableBucket construct from an external table bucket ARN.static ITableBucketfromTableBucketAttributes(software.constructs.Construct scope, String id, TableBucketAttributes attrs) (experimental) Defines a TableBucket construct that represents an external table bucket.protected Boolean(experimental) Indicates if a table bucket resource policy should automatically created upon the first call toaddToResourcePolicy.(experimental) Optional KMS encryption key associated with this table bucket.(experimental) The unique Amazon Resource Name (arn) of this table bucket.(experimental) The name of this table bucket.(experimental) The resource policy for this tableBucket.grantRead(IGrantable identity, String tableId) (experimental) Grant read permissions for this table bucket and its tables to an IAM principal (Role/Group/User).grantReadWrite(IGrantable identity, String tableId) (experimental) Grant read and write permissions for this table bucket and its tables to an IAM principal (Role/Group/User).grantWrite(IGrantable identity, String tableId) (experimental) Grant write permissions for this table bucket and its tables to an IAM principal (Role/Group/User).protected voidsetAutoCreatePolicy(Boolean value) (experimental) Indicates if a table bucket resource policy should automatically created upon the first call toaddToResourcePolicy.static void(experimental) Throws an exception if the given table bucket name is not valid.static voidvalidateTableBucketName(String bucketName) (experimental) Throws an exception if the given table bucket name is not valid.static void(experimental) Throws an exception if the given unreferencedFileRemovalProperty is not valid.static voidvalidateUnreferencedFileRemoval(UnreferencedFileRemoval unreferencedFileRemoval) (experimental) Throws an exception if the given unreferencedFileRemovalProperty is not valid.Methods inherited from class software.amazon.awscdk.Resource
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isOwnedResource, isResourceMethods inherited from class software.constructs.Construct
getNode, isConstruct, toStringMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.IResource
applyRemovalPolicy, getEnv, getStackMethods inherited from interface software.amazon.awscdk.services.s3tables.alpha.ITableBucket
getAccount, getRegionMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
PROPERTY_INJECTION_ID
(experimental) Uniquely identifies this class.
-
-
Constructor Details
-
TableBucket
protected TableBucket(software.amazon.jsii.JsiiObjectRef objRef) -
TableBucket
protected TableBucket(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
TableBucket
@Stability(Experimental) public TableBucket(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull TableBucketProps props) - Parameters:
scope- This parameter is required.id- This parameter is required.props- This parameter is required.
-
-
Method Details
-
fromTableBucketArn
@Stability(Experimental) @NotNull public static ITableBucket fromTableBucketArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String tableBucketArn) (experimental) Defines a TableBucket construct from an external table bucket ARN.- Parameters:
scope- The parent creating construct (usuallythis). This parameter is required.id- The construct's name. This parameter is required.tableBucketArn- Amazon Resource Name (arn) of the table bucket. This parameter is required.
-
fromTableBucketAttributes
@Stability(Experimental) @NotNull public static ITableBucket fromTableBucketAttributes(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull TableBucketAttributes attrs) (experimental) Defines a TableBucket construct that represents an external table bucket.- Parameters:
scope- The parent creating construct (usuallythis). This parameter is required.id- The construct's name. This parameter is required.attrs- ATableBucketAttributesobject. This parameter is required.
-
validateTableBucketName
(experimental) Throws an exception if the given table bucket name is not valid.- Parameters:
bucketName- name of the bucket.
-
validateTableBucketName
@Stability(Experimental) public static void validateTableBucketName()(experimental) Throws an exception if the given table bucket name is not valid. -
validateUnreferencedFileRemoval
@Stability(Experimental) public static void validateUnreferencedFileRemoval(@Nullable UnreferencedFileRemoval unreferencedFileRemoval) (experimental) Throws an exception if the given unreferencedFileRemovalProperty is not valid.- Parameters:
unreferencedFileRemoval- configuration for the table bucket.
-
validateUnreferencedFileRemoval
@Stability(Experimental) public static void validateUnreferencedFileRemoval()(experimental) Throws an exception if the given unreferencedFileRemovalProperty is not valid. -
addToResourcePolicy
@Stability(Experimental) @NotNull public AddToResourcePolicyResult addToResourcePolicy(@NotNull PolicyStatement statement) (experimental) Adds a statement to the resource policy for a principal (i.e. account/role/service) to perform actions on this table bucket and/or its contents. UsetableBucketArnandarnForObjects(keys)to obtain ARNs for this bucket or objects.Note that the policy statement may or may not be added to the policy. For example, when an
ITableBucketis created from an existing table bucket, it's not possible to tell whether the bucket already has a policy attached, let alone to re-use that policy to add more statements to it. So it's safest to do nothing in these cases.- Specified by:
addToResourcePolicyin interfaceITableBucket- Parameters:
statement- the policy statement to be added to the bucket's policy. This parameter is required.- Returns:
- metadata about the execution of this method. If the policy
was not added, the value of
statementAddedwill befalse. You should always check this value to make sure that the operation was actually carried out. Otherwise, synthesis and deploy will terminate silently, which may be confusing.
-
grantRead
@Stability(Experimental) @NotNull public Grant grantRead(@NotNull IGrantable identity, @NotNull String tableId) (experimental) Grant read permissions for this table bucket and its tables to an IAM principal (Role/Group/User).If encryption is used, permission to use the key to decrypt the contents of the bucket will also be granted to the same principal.
- Specified by:
grantReadin interfaceITableBucket- Parameters:
identity- This parameter is required.tableId- This parameter is required.
-
grantReadWrite
@Stability(Experimental) @NotNull public Grant grantReadWrite(@NotNull IGrantable identity, @NotNull String tableId) (experimental) Grant read and write permissions for this table bucket and its tables to an IAM principal (Role/Group/User).If encryption is used, permission to use the key to encrypt/decrypt the contents of the bucket will also be granted to the same principal.
- Specified by:
grantReadWritein interfaceITableBucket- Parameters:
identity- This parameter is required.tableId- This parameter is required.
-
grantWrite
@Stability(Experimental) @NotNull public Grant grantWrite(@NotNull IGrantable identity, @NotNull String tableId) (experimental) Grant write permissions for this table bucket and its tables to an IAM principal (Role/Group/User).If encryption is used, permission to use the key to encrypt the contents of the bucket will also be granted to the same principal.
- Specified by:
grantWritein interfaceITableBucket- Parameters:
identity- This parameter is required.tableId- This parameter is required.
-
getTableBucketArn
(experimental) The unique Amazon Resource Name (arn) of this table bucket.- Specified by:
getTableBucketArnin interfaceITableBucket
-
getTableBucketName
(experimental) The name of this table bucket.- Specified by:
getTableBucketNamein interfaceITableBucket
-
getEncryptionKey
(experimental) Optional KMS encryption key associated with this table bucket.- Specified by:
getEncryptionKeyin interfaceITableBucket
-
getTableBucketPolicy
(experimental) The resource policy for this tableBucket. -
getAutoCreatePolicy
(experimental) Indicates if a table bucket resource policy should automatically created upon the first call toaddToResourcePolicy. -
setAutoCreatePolicy
(experimental) Indicates if a table bucket resource policy should automatically created upon the first call toaddToResourcePolicy.
-