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

export interface DiskIopsConfigurationArgs extends core.SchemaArgs {
  iops?: number | core.NumberOut;

  mode?: string | core.StringOut;
}

export class DiskIopsConfiguration extends core.Schema<DiskIopsConfigurationArgs> {
  @core.attr(Number, { computed: true })
  public iops?: number | core.NumberOut;

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

export interface UserAndGroupQuotasArgs extends core.SchemaArgs {
  id: number | core.NumberOut;

  storageCapacityQuotaGib: number | core.NumberOut;

  type: string | core.StringOut;
}

export class UserAndGroupQuotas extends core.Schema<UserAndGroupQuotasArgs> {
  @core.attr(Number)
  public id!: number | core.NumberOut;

  @core.attr(Number)
  public storageCapacityQuotaGib!: number | core.NumberOut;

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

export interface ClientConfigurationsArgs extends core.SchemaArgs {
  clients: string | core.StringOut;

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

export class ClientConfigurations extends core.Schema<ClientConfigurationsArgs> {
  @core.attr(String)
  public clients!: string | core.StringOut;

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

export interface NfsExportsArgs extends core.SchemaArgs {
  clientConfigurations:
    | core.Array<ClientConfigurations>
    | core.ArrayOut<ClientConfigurations>;
}

export class NfsExports extends core.Schema<NfsExportsArgs> {
  @core.attr(ClientConfigurations, { kind: "array" })
  public clientConfigurations!:
    | core.Array<ClientConfigurations>
    | core.ArrayOut<ClientConfigurations>;
}

export interface RootVolumeConfigurationArgs extends core.SchemaArgs {
  copyTagsToSnapshots?: boolean | core.BooleanOut;

  dataCompressionType?: string | core.StringOut;

  nfsExports?: NfsExports;

  readOnly?: boolean | core.BooleanOut;

  recordSizeKib?: number | core.NumberOut;

  userAndGroupQuotas?:
    | core.Array<UserAndGroupQuotas>
    | core.ArrayOut<UserAndGroupQuotas>;
}

export class RootVolumeConfiguration extends core.Schema<RootVolumeConfigurationArgs> {
  @core.attr(Boolean)
  public copyTagsToSnapshots?: boolean | core.BooleanOut;

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

  @core.attr(NfsExports)
  public nfsExports?: NfsExports;

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

  @core.attr(Number)
  public recordSizeKib?: number | core.NumberOut;

  @core.attr(UserAndGroupQuotas, { computed: true, kind: "array" })
  public userAndGroupQuotas?:
    | core.Array<UserAndGroupQuotas>
    | core.ArrayOut<UserAndGroupQuotas>;
}

export interface OpenzfsFileSystemArgs extends core.ResourceArgs {
  automaticBackupRetentionDays?: number | core.NumberOut;

  backupId?: string | core.StringOut;

  copyTagsToBackups?: boolean | core.BooleanOut;

  copyTagsToVolumes?: boolean | core.BooleanOut;

  dailyAutomaticBackupStartTime?: string | core.StringOut;

  deploymentType: string | core.StringOut;

  diskIopsConfiguration?: DiskIopsConfiguration;

  kmsKeyId?: string | core.StringOut;

  rootVolumeConfiguration?: RootVolumeConfiguration;

  securityGroupIds?: core.Array<string> | core.ArrayOut<core.StringOut>;

  storageCapacity?: number | core.NumberOut;

  storageType?: string | core.StringOut;

  subnetIds: core.Array<string> | core.ArrayOut<core.StringOut>;

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

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

  throughputCapacity: number | core.NumberOut;

  weeklyMaintenanceStartTime?: string | core.StringOut;
}

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

  @core.attr(Number)
  public automaticBackupRetentionDays?: number | core.NumberOut;

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

  @core.attr(Boolean)
  public copyTagsToBackups?: boolean | core.BooleanOut;

  @core.attr(Boolean)
  public copyTagsToVolumes?: boolean | core.BooleanOut;

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

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

  @core.attr(DiskIopsConfiguration, { computed: true })
  public diskIopsConfiguration?: DiskIopsConfiguration;

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

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

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

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

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

  @core.attr(RootVolumeConfiguration, { computed: true })
  public rootVolumeConfiguration?: RootVolumeConfiguration;

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

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

  @core.attr(Number)
  public storageCapacity?: number | core.NumberOut;

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

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

  @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>;

  @core.attr(Number)
  public throughputCapacity!: number | core.NumberOut;

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

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

  constructor(name: string, args?: OpenzfsFileSystemArgs) {
    super(name, "aws_fsx_openzfs_file_system", args);
  }

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