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

export interface FilterArgs extends core.SchemaArgs {
  name: string | core.StringOut;

  values: core.Array<string> | core.ArrayOut<core.StringOut>;
}

export class Filter extends core.Schema<FilterArgs> {
  @core.attr(String)
  public name!: string | core.StringOut;

  @core.attr(String, { kind: "array" })
  public values!: core.Array<string> | core.ArrayOut<core.StringOut>;
}

export interface DsEndpointArgs {
  filter?: core.Array<Filter> | core.ArrayOut<Filter>;

  resolverEndpointId?: string | core.StringOut;
}

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

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

  @core.attr(Filter, { kind: "array" })
  public filter?: core.Array<Filter> | core.ArrayOut<Filter>;

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

  @core.attr(String, { computed: true, kind: "array" })
  public ipAddresses!: core.Array<string> | core.ArrayOut<core.StringOut>;

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

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

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

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

  constructor(name: string, args?: DsEndpointArgs) {
    super(name, "aws_route53_resolver_endpoint", args);
  }

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