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

export interface RoutingStrategyArgs extends core.SchemaArgs {
  fleetId?: string | core.StringOut;

  message?: string | core.StringOut;

  type: string | core.StringOut;
}

export class RoutingStrategy extends core.Schema<RoutingStrategyArgs> {
  @core.attr(String)
  public fleetId?: string | core.StringOut;

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

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

export interface AliasArgs extends core.ResourceArgs {
  description?: string | core.StringOut;

  name: string | core.StringOut;

  routingStrategy: RoutingStrategy;

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

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

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

  @core.attr(String)
  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(RoutingStrategy)
  public routingStrategy!: RoutingStrategy;

  @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?: AliasArgs) {
    super(name, "aws_gamelift_alias", args);
  }

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