Skip to content
v2.278.0

Experimental

@aws-cdk/aws-s3tables-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

TablePolicyProps Struct ​

Parameters for constructing a TablePolicy.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as s3tables_alpha from '@aws-cdk/aws-s3tables-alpha';
import * as cdk from 'aws-cdk-lib';
import { aws_iam as iam } from 'aws-cdk-lib';

declare const policyDocument: iam.PolicyDocument;
declare const table: s3tables_alpha.Table;
const tablePolicyProps: s3tables_alpha.TablePolicyProps = {
  table: table,

  // the properties below are optional
  removalPolicy: cdk.RemovalPolicy.DESTROY,
  resourcePolicy: policyDocument,
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk.aws_s3tables_alpha as s3tables_alpha
import aws_cdk as cdk
from aws_cdk import aws_iam as iam

# policy_document: iam.PolicyDocument
# table: s3tables_alpha.Table

table_policy_props = s3tables_alpha.TablePolicyProps(
    table=table,

    # the properties below are optional
    removal_policy=cdk.RemovalPolicy.DESTROY,
    resource_policy=policy_document
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.s3tables.alpha.*;
import software.amazon.awscdk.*;
import software.amazon.awscdk.services.iam.*;

PolicyDocument policyDocument;
Table table;

TablePolicyProps tablePolicyProps = TablePolicyProps.builder()
        .table(table)

        // the properties below are optional
        .removalPolicy(RemovalPolicy.DESTROY)
        .resourcePolicy(policyDocument)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.S3Tables.Alpha
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.S3Tables.Alpha;
using Amazon.CDK;
using Amazon.CDK.AWS.IAM;

PolicyDocument policyDocument;
Table table;

var tablePolicyProps = new TablePolicyProps {
    Table = table,

    // the properties below are optional
    RemovalPolicy = RemovalPolicy.DESTROY,
    ResourcePolicy = policyDocument
};
go
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import s3tables_alpha "github.com/aws-samples/dummy/awscdkawss3tablesalpha"
import cdk "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"

var policyDocument PolicyDocument
var table Table

tablePolicyProps := &TablePolicyProps{
	Table: table,

	// the properties below are optional
	RemovalPolicy: cdk.RemovalPolicy_DESTROY,
	ResourcePolicy: policyDocument,
}

Properties ​

removalPolicyoptionalRemovalPolicyremoval_policyoptionalRemovalPolicyremovalPolicyoptionalRemovalPolicyRemovalPolicyoptionalRemovalPolicyRemovalPolicyoptionalRemovalPolicy = RemovalPolicy.DESTROY. #
Policy to apply when the policy is removed from this stack.
resourcePolicyoptionalPolicyDocumentresource_policyoptionalPolicyDocumentresourcePolicyoptionalPolicyDocumentResourcePolicyoptionalPolicyDocumentResourcePolicyoptionalPolicyDocument #
The policy document for the table's resource policy.

Default: undefined An empty iam.PolicyDocument will be initialized

tableITabletableITabletableITableTableITableTableITable required #
The associated table.