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

export interface DestinationArgs extends core.SchemaArgs {
  availabilityZoneName?: string | core.StringOut;

  fileSystemId: string | core.StringOut;

  kmsKeyId?: string | core.StringOut;

  region?: string | core.StringOut;

  status: string | core.StringOut;
}

export class Destination extends core.Schema<DestinationArgs> {
  @core.attr(String)
  public availabilityZoneName?: string | core.StringOut;

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

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

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

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

export interface ReplicationConfigurationArgs extends core.ResourceArgs {
  destination: Destination;

  sourceFileSystemId: string | core.StringOut;
}

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

  @core.attr(Destination)
  public destination!: Destination;

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

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

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

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

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

  constructor(name: string, args?: ReplicationConfigurationArgs) {
    super(name, "aws_efs_replication_configuration", args);
  }

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