java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, ITaggable, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.101.0 (build b95fe5d)", date="2024-07-12T19:33:58.375Z") @Stability(Stable) public class CfnTable extends CfnResource implements IInspectable, ITaggable
You can use the AWS::Cassandra::Table resource to create a new table in Amazon Keyspaces (for Apache Cassandra).

For more information, see Create a keyspace and a table in the Amazon Keyspaces Developer Guide .

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.cassandra.*;
 CfnTable cfnTable = CfnTable.Builder.create(this, "MyCfnTable")
         .keyspaceName("keyspaceName")
         .partitionKeyColumns(List.of(ColumnProperty.builder()
                 .columnName("columnName")
                 .columnType("columnType")
                 .build()))
         // the properties below are optional
         .autoScalingSpecifications(AutoScalingSpecificationProperty.builder()
                 .readCapacityAutoScaling(AutoScalingSettingProperty.builder()
                         .autoScalingDisabled(false)
                         .maximumUnits(123)
                         .minimumUnits(123)
                         .scalingPolicy(ScalingPolicyProperty.builder()
                                 .targetTrackingScalingPolicyConfiguration(TargetTrackingScalingPolicyConfigurationProperty.builder()
                                         .targetValue(123)
                                         // the properties below are optional
                                         .disableScaleIn(false)
                                         .scaleInCooldown(123)
                                         .scaleOutCooldown(123)
                                         .build())
                                 .build())
                         .build())
                 .writeCapacityAutoScaling(AutoScalingSettingProperty.builder()
                         .autoScalingDisabled(false)
                         .maximumUnits(123)
                         .minimumUnits(123)
                         .scalingPolicy(ScalingPolicyProperty.builder()
                                 .targetTrackingScalingPolicyConfiguration(TargetTrackingScalingPolicyConfigurationProperty.builder()
                                         .targetValue(123)
                                         // the properties below are optional
                                         .disableScaleIn(false)
                                         .scaleInCooldown(123)
                                         .scaleOutCooldown(123)
                                         .build())
                                 .build())
                         .build())
                 .build())
         .billingMode(BillingModeProperty.builder()
                 .mode("mode")
                 // the properties below are optional
                 .provisionedThroughput(ProvisionedThroughputProperty.builder()
                         .readCapacityUnits(123)
                         .writeCapacityUnits(123)
                         .build())
                 .build())
         .clientSideTimestampsEnabled(false)
         .clusteringKeyColumns(List.of(ClusteringKeyColumnProperty.builder()
                 .column(ColumnProperty.builder()
                         .columnName("columnName")
                         .columnType("columnType")
                         .build())
                 // the properties below are optional
                 .orderBy("orderBy")
                 .build()))
         .defaultTimeToLive(123)
         .encryptionSpecification(EncryptionSpecificationProperty.builder()
                 .encryptionType("encryptionType")
                 // the properties below are optional
                 .kmsKeyIdentifier("kmsKeyIdentifier")
                 .build())
         .pointInTimeRecoveryEnabled(false)
         .regularColumns(List.of(ColumnProperty.builder()
                 .columnName("columnName")
                 .columnType("columnType")
                 .build()))
         .replicaSpecifications(List.of(ReplicaSpecificationProperty.builder()
                 .region("region")
                 // the properties below are optional
                 .readCapacityAutoScaling(AutoScalingSettingProperty.builder()
                         .autoScalingDisabled(false)
                         .maximumUnits(123)
                         .minimumUnits(123)
                         .scalingPolicy(ScalingPolicyProperty.builder()
                                 .targetTrackingScalingPolicyConfiguration(TargetTrackingScalingPolicyConfigurationProperty.builder()
                                         .targetValue(123)
                                         // the properties below are optional
                                         .disableScaleIn(false)
                                         .scaleInCooldown(123)
                                         .scaleOutCooldown(123)
                                         .build())
                                 .build())
                         .build())
                 .readCapacityUnits(123)
                 .build()))
         .tableName("tableName")
         .tags(List.of(CfnTag.builder()
                 .key("key")
                 .value("value")
                 .build()))
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnTable

      protected CfnTable(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnTable

      protected CfnTable(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnTable

      @Stability(Stable) public CfnTable(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnTableProps props)
      Parameters:
      scope - Scope in which this resource is defined. This parameter is required.
      id - Construct identifier for this resource (unique in its scope). This parameter is required.
      props - Resource properties. This parameter is required.
  • Method Details

    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector - tree inspector to collect and process attributes. This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getTags

      @Stability(Stable) @NotNull public TagManager getTags()
      Tag Manager which manages the tags for this resource.
      Specified by:
      getTags in interface ITaggable
    • getKeyspaceName

      @Stability(Stable) @NotNull public String getKeyspaceName()
      The name of the keyspace to create the table in.
    • setKeyspaceName

      @Stability(Stable) public void setKeyspaceName(@NotNull String value)
      The name of the keyspace to create the table in.
    • getPartitionKeyColumns

      @Stability(Stable) @NotNull public Object getPartitionKeyColumns()
      One or more columns that uniquely identify every row in the table.
    • setPartitionKeyColumns

      @Stability(Stable) public void setPartitionKeyColumns(@NotNull IResolvable value)
      One or more columns that uniquely identify every row in the table.
    • setPartitionKeyColumns

      @Stability(Stable) public void setPartitionKeyColumns(@NotNull List<Object> value)
      One or more columns that uniquely identify every row in the table.
    • getAutoScalingSpecifications

      @Stability(Stable) @Nullable public Object getAutoScalingSpecifications()
      The optional auto scaling capacity settings for a table in provisioned capacity mode.
    • setAutoScalingSpecifications

      @Stability(Stable) public void setAutoScalingSpecifications(@Nullable IResolvable value)
      The optional auto scaling capacity settings for a table in provisioned capacity mode.
    • setAutoScalingSpecifications

      @Stability(Stable) public void setAutoScalingSpecifications(@Nullable CfnTable.AutoScalingSpecificationProperty value)
      The optional auto scaling capacity settings for a table in provisioned capacity mode.
    • getBillingMode

      @Stability(Stable) @Nullable public Object getBillingMode()
      The billing mode for the table, which determines how you'll be charged for reads and writes:.
    • setBillingMode

      @Stability(Stable) public void setBillingMode(@Nullable IResolvable value)
      The billing mode for the table, which determines how you'll be charged for reads and writes:.
    • setBillingMode

      @Stability(Stable) public void setBillingMode(@Nullable CfnTable.BillingModeProperty value)
      The billing mode for the table, which determines how you'll be charged for reads and writes:.
    • getClientSideTimestampsEnabled

      @Stability(Stable) @Nullable public Object getClientSideTimestampsEnabled()
      Enables client-side timestamps for the table.
    • setClientSideTimestampsEnabled

      @Stability(Stable) public void setClientSideTimestampsEnabled(@Nullable Boolean value)
      Enables client-side timestamps for the table.
    • setClientSideTimestampsEnabled

      @Stability(Stable) public void setClientSideTimestampsEnabled(@Nullable IResolvable value)
      Enables client-side timestamps for the table.
    • getClusteringKeyColumns

      @Stability(Stable) @Nullable public Object getClusteringKeyColumns()
      One or more columns that determine how the table data is sorted.
    • setClusteringKeyColumns

      @Stability(Stable) public void setClusteringKeyColumns(@Nullable IResolvable value)
      One or more columns that determine how the table data is sorted.
    • setClusteringKeyColumns

      @Stability(Stable) public void setClusteringKeyColumns(@Nullable List<Object> value)
      One or more columns that determine how the table data is sorted.
    • getDefaultTimeToLive

      @Stability(Stable) @Nullable public Number getDefaultTimeToLive()
      The default Time To Live (TTL) value for all rows in a table in seconds.
    • setDefaultTimeToLive

      @Stability(Stable) public void setDefaultTimeToLive(@Nullable Number value)
      The default Time To Live (TTL) value for all rows in a table in seconds.
    • getEncryptionSpecification

      @Stability(Stable) @Nullable public Object getEncryptionSpecification()
      The encryption at rest options for the table.
    • setEncryptionSpecification

      @Stability(Stable) public void setEncryptionSpecification(@Nullable IResolvable value)
      The encryption at rest options for the table.
    • setEncryptionSpecification

      @Stability(Stable) public void setEncryptionSpecification(@Nullable CfnTable.EncryptionSpecificationProperty value)
      The encryption at rest options for the table.
    • getPointInTimeRecoveryEnabled

      @Stability(Stable) @Nullable public Object getPointInTimeRecoveryEnabled()
      Specifies if point-in-time recovery is enabled or disabled for the table.
    • setPointInTimeRecoveryEnabled

      @Stability(Stable) public void setPointInTimeRecoveryEnabled(@Nullable Boolean value)
      Specifies if point-in-time recovery is enabled or disabled for the table.
    • setPointInTimeRecoveryEnabled

      @Stability(Stable) public void setPointInTimeRecoveryEnabled(@Nullable IResolvable value)
      Specifies if point-in-time recovery is enabled or disabled for the table.
    • getRegularColumns

      @Stability(Stable) @Nullable public Object getRegularColumns()
      One or more columns that are not part of the primary key - that is, columns that are not defined as partition key columns or clustering key columns.
    • setRegularColumns

      @Stability(Stable) public void setRegularColumns(@Nullable IResolvable value)
      One or more columns that are not part of the primary key - that is, columns that are not defined as partition key columns or clustering key columns.
    • setRegularColumns

      @Stability(Stable) public void setRegularColumns(@Nullable List<Object> value)
      One or more columns that are not part of the primary key - that is, columns that are not defined as partition key columns or clustering key columns.
    • getReplicaSpecifications

      @Stability(Stable) @Nullable public Object getReplicaSpecifications()
      The AWS Region specific settings of a multi-Region table.
    • setReplicaSpecifications

      @Stability(Stable) public void setReplicaSpecifications(@Nullable IResolvable value)
      The AWS Region specific settings of a multi-Region table.
    • setReplicaSpecifications

      @Stability(Stable) public void setReplicaSpecifications(@Nullable List<Object> value)
      The AWS Region specific settings of a multi-Region table.
    • getTableName

      @Stability(Stable) @Nullable public String getTableName()
      The name of the table to be created.
    • setTableName

      @Stability(Stable) public void setTableName(@Nullable String value)
      The name of the table to be created.
    • getTagsRaw

      @Stability(Stable) @Nullable public List<CfnTag> getTagsRaw()
      An array of key-value pairs to apply to this resource.
    • setTagsRaw

      @Stability(Stable) public void setTagsRaw(@Nullable List<CfnTag> value)
      An array of key-value pairs to apply to this resource.