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

export interface QueryArgProfilesItemsArgs extends core.SchemaArgs {
  profileId: string | core.StringOut;

  queryArg: string | core.StringOut;
}

export class QueryArgProfilesItems extends core.Schema<QueryArgProfilesItemsArgs> {
  @core.attr(String)
  public profileId!: string | core.StringOut;

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

export interface QueryArgProfilesArgs extends core.SchemaArgs {
  items?:
    | core.Array<QueryArgProfilesItems>
    | core.ArrayOut<QueryArgProfilesItems>;
}

export class QueryArgProfiles extends core.Schema<QueryArgProfilesArgs> {
  @core.attr(QueryArgProfilesItems, { kind: "array" })
  public items?:
    | core.Array<QueryArgProfilesItems>
    | core.ArrayOut<QueryArgProfilesItems>;
}

export interface QueryArgProfileConfigArgs extends core.SchemaArgs {
  forwardWhenQueryArgProfileIsUnknown: boolean | core.BooleanOut;

  queryArgProfiles?: QueryArgProfiles;
}

export class QueryArgProfileConfig extends core.Schema<QueryArgProfileConfigArgs> {
  @core.attr(Boolean)
  public forwardWhenQueryArgProfileIsUnknown!: boolean | core.BooleanOut;

  @core.attr(QueryArgProfiles)
  public queryArgProfiles?: QueryArgProfiles;
}

export interface ContentTypeProfilesItemsArgs extends core.SchemaArgs {
  contentType: string | core.StringOut;

  format: string | core.StringOut;

  profileId?: string | core.StringOut;
}

export class ContentTypeProfilesItems extends core.Schema<ContentTypeProfilesItemsArgs> {
  @core.attr(String)
  public contentType!: string | core.StringOut;

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

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

export interface ContentTypeProfilesArgs extends core.SchemaArgs {
  items:
    | core.Array<ContentTypeProfilesItems>
    | core.ArrayOut<ContentTypeProfilesItems>;
}

export class ContentTypeProfiles extends core.Schema<ContentTypeProfilesArgs> {
  @core.attr(ContentTypeProfilesItems, { kind: "array" })
  public items!:
    | core.Array<ContentTypeProfilesItems>
    | core.ArrayOut<ContentTypeProfilesItems>;
}

export interface ContentTypeProfileConfigArgs extends core.SchemaArgs {
  contentTypeProfiles: ContentTypeProfiles;

  forwardWhenContentTypeIsUnknown: boolean | core.BooleanOut;
}

export class ContentTypeProfileConfig extends core.Schema<ContentTypeProfileConfigArgs> {
  @core.attr(ContentTypeProfiles)
  public contentTypeProfiles!: ContentTypeProfiles;

  @core.attr(Boolean)
  public forwardWhenContentTypeIsUnknown!: boolean | core.BooleanOut;
}

export interface FieldLevelEncryptionConfigArgs extends core.ResourceArgs {
  comment?: string | core.StringOut;

  contentTypeProfileConfig: ContentTypeProfileConfig;

  queryArgProfileConfig: QueryArgProfileConfig;
}

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

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

  @core.attr(ContentTypeProfileConfig)
  public contentTypeProfileConfig!: ContentTypeProfileConfig;

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

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

  @core.attr(QueryArgProfileConfig)
  public queryArgProfileConfig!: QueryArgProfileConfig;

  constructor(name: string, args?: FieldLevelEncryptionConfigArgs) {
    super(name, "aws_cloudfront_field_level_encryption_config", args);
  }

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