Interface TableAttributes

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Implementing Classes:
TableAttributes.Jsii$Proxy

@Generated(value="jsii-pacmak/1.97.0 (build 729de35)", date="2024-04-18T17:54:15.421Z") @Stability(Stable) public interface TableAttributes extends software.amazon.jsii.JsiiSerializable
Reference to a dynamodb table.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.dynamodb.*;
 import software.amazon.awscdk.services.kms.*;
 Key key;
 TableAttributes tableAttributes = TableAttributes.builder()
         .encryptionKey(key)
         .globalIndexes(List.of("globalIndexes"))
         .grantIndexPermissions(false)
         .localIndexes(List.of("localIndexes"))
         .tableArn("tableArn")
         .tableName("tableName")
         .tableStreamArn("tableStreamArn")
         .build();
 
  • Method Details

    • getEncryptionKey

      @Stability(Stable) @Nullable default IKey getEncryptionKey()
      KMS encryption key, if this table uses a customer-managed encryption key.

      Default: - no key

    • getGlobalIndexes

      @Stability(Stable) @Nullable default List<String> getGlobalIndexes()
      The name of the global indexes set for this Table.

      Note that you need to set either this property, or localIndexes, if you want methods like grantReadData() to grant permissions for indexes as well as the table itself.

      Default: - no global indexes

    • getGrantIndexPermissions

      @Stability(Stable) @Nullable default Boolean getGrantIndexPermissions()
      If set to true, grant methods always grant permissions for all indexes.

      If false is provided, grant methods grant the permissions only when globalIndexes or localIndexes is specified.

      Default: - false

    • getLocalIndexes

      @Stability(Stable) @Nullable default List<String> getLocalIndexes()
      The name of the local indexes set for this Table.

      Note that you need to set either this property, or globalIndexes, if you want methods like grantReadData() to grant permissions for indexes as well as the table itself.

      Default: - no local indexes

    • getTableArn

      @Stability(Stable) @Nullable default String getTableArn()
      The ARN of the dynamodb table.

      One of this, or tableName, is required.

      Default: - no table arn

    • getTableName

      @Stability(Stable) @Nullable default String getTableName()
      The table name of the dynamodb table.

      One of this, or tableArn, is required.

      Default: - no table name

    • getTableStreamArn

      @Stability(Stable) @Nullable default String getTableStreamArn()
      The ARN of the table's stream.

      Default: - no table stream

    • builder

      @Stability(Stable) static TableAttributes.Builder builder()
      Returns:
      a TableAttributes.Builder of TableAttributes