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

export interface RegularExpressionArgs extends core.SchemaArgs {
  regexString: string | core.StringOut;
}

export class RegularExpression extends core.Schema<RegularExpressionArgs> {
  @core.attr(String, { computed: true })
  public regexString!: string | core.StringOut;
}

export interface DsV2RegexPatternSetArgs {
  name: string | core.StringOut;

  scope: string | core.StringOut;
}

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

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

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

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

  @core.attr(RegularExpression, { computed: true, kind: "array" })
  public regularExpression!:
    | core.Array<RegularExpression>
    | core.ArrayOut<RegularExpression>;

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

  constructor(name: string, args?: DsV2RegexPatternSetArgs) {
    super(name, "aws_wafv2_regex_pattern_set", args);
  }

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