import * as core from "@terrascript/core";

export interface TableReplicaArgs extends core.ResourceArgs {
  globalTableArn: string | core.StringOut;

  kmsKeyArn?: string | core.StringOut;

  pointInTimeRecovery?: boolean | core.BooleanOut;

  tableClassOverride?: string | core.StringOut;

  tags?: core.Map<string, string> | core.MapOut<core.StringOut>;

  tagsAll?: core.Map<string, string> | core.MapOut<core.StringOut>;
}

export class TableReplica extends core.Resource<TableReplicaArgs> {
  @core.attr(String, { computed: true })
  public arn!: string | core.StringOut;

  @core.attr(String)
  public globalTableArn!: string | core.StringOut;

  @core.attr(String, { computed: true })
  public id!: string | core.StringOut;

  @core.attr(String, { computed: true })
  public kmsKeyArn?: string | core.StringOut;

  @core.attr(Boolean)
  public pointInTimeRecovery?: boolean | core.BooleanOut;

  @core.attr(String)
  public tableClassOverride?: string | core.StringOut;

  @core.attr(String, { kind: "map" })
  public tags?: core.Map<string, string> | core.MapOut<core.StringOut>;

  @core.attr(String, { computed: true, kind: "map" })
  public tagsAll?: core.Map<string, string> | core.MapOut<core.StringOut>;

  constructor(name: string, args?: TableReplicaArgs) {
    super(name, "aws_dynamodb_table_replica", args);
  }

  public override getNamespace(): string {
    return "aws_dynamodb";
  }
}
