Interface Attribute
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
Attribute.Jsii$Proxy
@Generated(value="jsii-pacmak/1.127.0 (build 2117ad5)",
date="2026-04-02T09:31:39.016Z")
@Stability(Stable)
public interface Attribute
extends software.amazon.jsii.JsiiSerializable
Represents an attribute for describing the key schema for the table and indexes.
Example:
import software.amazon.awscdk.*;
App app = new App();
// Source table in Account A
Stack sourceStack = Stack.Builder.create(app, "SourceStack")
.env(Environment.builder().region("us-east-1").account("111111111111").build())
.build();
// Region us-west-2
TableV2 sourceTable = TableV2.Builder.create(sourceStack, "SourceTable")
.tableName("MyMultiAccountTable")
.partitionKey(Attribute.builder().name("pk").type(AttributeType.STRING).build())
.globalTableSettingsReplicationMode(GlobalTableSettingsReplicationMode.ALL)
.build();
// After replica is deployed, update source stack with the ARN
sourceTable.grants.multiAccountReplicationTo("arn:aws:dynamodb:us-east-1:222222222222:table/MyMultiAccountTable");
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic Attribute.Builderbuilder()getName()The name of an attribute.getType()The data type of an attribute.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getName
The name of an attribute. -
getType
The data type of an attribute. -
builder
- Returns:
- a
Attribute.BuilderofAttribute
-