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

export interface AssociationsArgs extends core.SchemaArgs {
  gatewayId: string | core.StringOut;

  main: boolean | core.BooleanOut;

  routeTableAssociationId: string | core.StringOut;

  routeTableId: string | core.StringOut;

  subnetId: string | core.StringOut;
}

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

  @core.attr(Boolean, { computed: true })
  public main!: boolean | core.BooleanOut;

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

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

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

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 RoutesArgs extends core.SchemaArgs {
  carrierGatewayId: string | core.StringOut;

  cidrBlock: string | core.StringOut;

  coreNetworkArn: string | core.StringOut;

  destinationPrefixListId: string | core.StringOut;

  egressOnlyGatewayId: string | core.StringOut;

  gatewayId: string | core.StringOut;

  instanceId: string | core.StringOut;

  ipv6CidrBlock: string | core.StringOut;

  localGatewayId: string | core.StringOut;

  natGatewayId: string | core.StringOut;

  networkInterfaceId: string | core.StringOut;

  transitGatewayId: string | core.StringOut;

  vpcEndpointId: string | core.StringOut;

  vpcPeeringConnectionId: string | core.StringOut;
}

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

  gatewayId?: string | core.StringOut;

  routeTableId?: string | core.StringOut;

  subnetId?: string | core.StringOut;

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

  vpcId?: string | core.StringOut;
}

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

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

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

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

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

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

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

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

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

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

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

  constructor(name: string, args?: DsRouteTableArgs) {
    super(name, "aws_route_table", args);
  }

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