// generated from terraform resource schema
import * as cdktf from 'cdktf';
export class StoragegatewayGatewayGatewayNetworkInterface extends cdktf.ComplexComputedList {
    // ipv4_address - computed: true, optional: false, required: false
    get ipv4Address() {
        return this.getStringAttribute('ipv4_address');
    }
}
export function storagegatewayGatewaySmbActiveDirectorySettingsToTerraform(struct) {
    if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
        return struct;
    }
    if (cdktf.isComplexElement(struct)) {
        throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
    }
    return {
        domain_controllers: cdktf.listMapper(cdktf.stringToTerraform)(struct.domainControllers),
        domain_name: cdktf.stringToTerraform(struct.domainName),
        organizational_unit: cdktf.stringToTerraform(struct.organizationalUnit),
        password: cdktf.stringToTerraform(struct.password),
        timeout_in_seconds: cdktf.numberToTerraform(struct.timeoutInSeconds),
        username: cdktf.stringToTerraform(struct.username),
    };
}
export class StoragegatewayGatewaySmbActiveDirectorySettingsOutputReference extends cdktf.ComplexObject {
    isEmptyObject = false;
    /**
    * @param terraformResource The parent resource
    * @param terraformAttribute The attribute on the parent resource this class is referencing
    * @param isSingleItem True if this is a block, false if it's a list
    */
    constructor(terraformResource, terraformAttribute, isSingleItem) {
        super(terraformResource, terraformAttribute, isSingleItem);
    }
    get internalValue() {
        let hasAnyValues = this.isEmptyObject;
        const internalValueResult = {};
        if (this._domainControllers !== undefined) {
            hasAnyValues = true;
            internalValueResult.domainControllers = this._domainControllers;
        }
        if (this._domainName !== undefined) {
            hasAnyValues = true;
            internalValueResult.domainName = this._domainName;
        }
        if (this._organizationalUnit !== undefined) {
            hasAnyValues = true;
            internalValueResult.organizationalUnit = this._organizationalUnit;
        }
        if (this._password !== undefined) {
            hasAnyValues = true;
            internalValueResult.password = this._password;
        }
        if (this._timeoutInSeconds !== undefined) {
            hasAnyValues = true;
            internalValueResult.timeoutInSeconds = this._timeoutInSeconds;
        }
        if (this._username !== undefined) {
            hasAnyValues = true;
            internalValueResult.username = this._username;
        }
        return hasAnyValues ? internalValueResult : undefined;
    }
    set internalValue(value) {
        if (value === undefined) {
            this.isEmptyObject = false;
            this._domainControllers = undefined;
            this._domainName = undefined;
            this._organizationalUnit = undefined;
            this._password = undefined;
            this._timeoutInSeconds = undefined;
            this._username = undefined;
        }
        else {
            this.isEmptyObject = Object.keys(value).length === 0;
            this._domainControllers = value.domainControllers;
            this._domainName = value.domainName;
            this._organizationalUnit = value.organizationalUnit;
            this._password = value.password;
            this._timeoutInSeconds = value.timeoutInSeconds;
            this._username = value.username;
        }
    }
    // active_directory_status - computed: true, optional: false, required: false
    get activeDirectoryStatus() {
        return this.getStringAttribute('active_directory_status');
    }
    // domain_controllers - computed: false, optional: true, required: false
    _domainControllers;
    get domainControllers() {
        return cdktf.Fn.tolist(this.getListAttribute('domain_controllers'));
    }
    set domainControllers(value) {
        this._domainControllers = value;
    }
    resetDomainControllers() {
        this._domainControllers = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get domainControllersInput() {
        return this._domainControllers;
    }
    // domain_name - computed: false, optional: false, required: true
    _domainName;
    get domainName() {
        return this.getStringAttribute('domain_name');
    }
    set domainName(value) {
        this._domainName = value;
    }
    // Temporarily expose input value. Use with caution.
    get domainNameInput() {
        return this._domainName;
    }
    // organizational_unit - computed: false, optional: true, required: false
    _organizationalUnit;
    get organizationalUnit() {
        return this.getStringAttribute('organizational_unit');
    }
    set organizationalUnit(value) {
        this._organizationalUnit = value;
    }
    resetOrganizationalUnit() {
        this._organizationalUnit = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get organizationalUnitInput() {
        return this._organizationalUnit;
    }
    // password - computed: false, optional: false, required: true
    _password;
    get password() {
        return this.getStringAttribute('password');
    }
    set password(value) {
        this._password = value;
    }
    // Temporarily expose input value. Use with caution.
    get passwordInput() {
        return this._password;
    }
    // timeout_in_seconds - computed: false, optional: true, required: false
    _timeoutInSeconds;
    get timeoutInSeconds() {
        return this.getNumberAttribute('timeout_in_seconds');
    }
    set timeoutInSeconds(value) {
        this._timeoutInSeconds = value;
    }
    resetTimeoutInSeconds() {
        this._timeoutInSeconds = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get timeoutInSecondsInput() {
        return this._timeoutInSeconds;
    }
    // username - computed: false, optional: false, required: true
    _username;
    get username() {
        return this.getStringAttribute('username');
    }
    set username(value) {
        this._username = value;
    }
    // Temporarily expose input value. Use with caution.
    get usernameInput() {
        return this._username;
    }
}
export function storagegatewayGatewayTimeoutsToTerraform(struct) {
    if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
        return struct;
    }
    if (cdktf.isComplexElement(struct)) {
        throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
    }
    return {
        create: cdktf.stringToTerraform(struct.create),
    };
}
export class StoragegatewayGatewayTimeoutsOutputReference extends cdktf.ComplexObject {
    isEmptyObject = false;
    /**
    * @param terraformResource The parent resource
    * @param terraformAttribute The attribute on the parent resource this class is referencing
    * @param isSingleItem True if this is a block, false if it's a list
    */
    constructor(terraformResource, terraformAttribute, isSingleItem) {
        super(terraformResource, terraformAttribute, isSingleItem);
    }
    get internalValue() {
        let hasAnyValues = this.isEmptyObject;
        const internalValueResult = {};
        if (this._create !== undefined) {
            hasAnyValues = true;
            internalValueResult.create = this._create;
        }
        return hasAnyValues ? internalValueResult : undefined;
    }
    set internalValue(value) {
        if (value === undefined) {
            this.isEmptyObject = false;
            this._create = undefined;
        }
        else {
            this.isEmptyObject = Object.keys(value).length === 0;
            this._create = value.create;
        }
    }
    // create - computed: false, optional: true, required: false
    _create;
    get create() {
        return this.getStringAttribute('create');
    }
    set create(value) {
        this._create = value;
    }
    resetCreate() {
        this._create = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get createInput() {
        return this._create;
    }
}
/**
* Represents a {@link https://www.terraform.io/docs/providers/aws/r/storagegateway_gateway aws_storagegateway_gateway}
*/
export class StoragegatewayGateway extends cdktf.TerraformResource {
    // =================
    // STATIC PROPERTIES
    // =================
    static tfResourceType = "aws_storagegateway_gateway";
    // ===========
    // INITIALIZER
    // ===========
    /**
    * Create a new {@link https://www.terraform.io/docs/providers/aws/r/storagegateway_gateway aws_storagegateway_gateway} Resource
    *
    * @param scope The scope in which to define this construct
    * @param id The scoped construct ID. Must be unique amongst siblings in the same scope
    * @param options StoragegatewayGatewayConfig
    */
    constructor(scope, id, config) {
        super(scope, id, {
            terraformResourceType: 'aws_storagegateway_gateway',
            terraformGeneratorMetadata: {
                providerName: 'aws'
            },
            provider: config.provider,
            dependsOn: config.dependsOn,
            count: config.count,
            lifecycle: config.lifecycle
        });
        this._activationKey = config.activationKey;
        this._averageDownloadRateLimitInBitsPerSec = config.averageDownloadRateLimitInBitsPerSec;
        this._averageUploadRateLimitInBitsPerSec = config.averageUploadRateLimitInBitsPerSec;
        this._cloudwatchLogGroupArn = config.cloudwatchLogGroupArn;
        this._gatewayIpAddress = config.gatewayIpAddress;
        this._gatewayName = config.gatewayName;
        this._gatewayTimezone = config.gatewayTimezone;
        this._gatewayType = config.gatewayType;
        this._gatewayVpcEndpoint = config.gatewayVpcEndpoint;
        this._mediumChangerType = config.mediumChangerType;
        this._smbFileShareVisibility = config.smbFileShareVisibility;
        this._smbGuestPassword = config.smbGuestPassword;
        this._smbSecurityStrategy = config.smbSecurityStrategy;
        this._tags = config.tags;
        this._tagsAll = config.tagsAll;
        this._tapeDriveType = config.tapeDriveType;
        this._smbActiveDirectorySettings.internalValue = config.smbActiveDirectorySettings;
        this._timeouts.internalValue = config.timeouts;
    }
    // ==========
    // ATTRIBUTES
    // ==========
    // activation_key - computed: true, optional: true, required: false
    _activationKey;
    get activationKey() {
        return this.getStringAttribute('activation_key');
    }
    set activationKey(value) {
        this._activationKey = value;
    }
    resetActivationKey() {
        this._activationKey = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get activationKeyInput() {
        return this._activationKey;
    }
    // arn - computed: true, optional: false, required: false
    get arn() {
        return this.getStringAttribute('arn');
    }
    // average_download_rate_limit_in_bits_per_sec - computed: false, optional: true, required: false
    _averageDownloadRateLimitInBitsPerSec;
    get averageDownloadRateLimitInBitsPerSec() {
        return this.getNumberAttribute('average_download_rate_limit_in_bits_per_sec');
    }
    set averageDownloadRateLimitInBitsPerSec(value) {
        this._averageDownloadRateLimitInBitsPerSec = value;
    }
    resetAverageDownloadRateLimitInBitsPerSec() {
        this._averageDownloadRateLimitInBitsPerSec = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get averageDownloadRateLimitInBitsPerSecInput() {
        return this._averageDownloadRateLimitInBitsPerSec;
    }
    // average_upload_rate_limit_in_bits_per_sec - computed: false, optional: true, required: false
    _averageUploadRateLimitInBitsPerSec;
    get averageUploadRateLimitInBitsPerSec() {
        return this.getNumberAttribute('average_upload_rate_limit_in_bits_per_sec');
    }
    set averageUploadRateLimitInBitsPerSec(value) {
        this._averageUploadRateLimitInBitsPerSec = value;
    }
    resetAverageUploadRateLimitInBitsPerSec() {
        this._averageUploadRateLimitInBitsPerSec = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get averageUploadRateLimitInBitsPerSecInput() {
        return this._averageUploadRateLimitInBitsPerSec;
    }
    // cloudwatch_log_group_arn - computed: false, optional: true, required: false
    _cloudwatchLogGroupArn;
    get cloudwatchLogGroupArn() {
        return this.getStringAttribute('cloudwatch_log_group_arn');
    }
    set cloudwatchLogGroupArn(value) {
        this._cloudwatchLogGroupArn = value;
    }
    resetCloudwatchLogGroupArn() {
        this._cloudwatchLogGroupArn = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get cloudwatchLogGroupArnInput() {
        return this._cloudwatchLogGroupArn;
    }
    // ec2_instance_id - computed: true, optional: false, required: false
    get ec2InstanceId() {
        return this.getStringAttribute('ec2_instance_id');
    }
    // endpoint_type - computed: true, optional: false, required: false
    get endpointType() {
        return this.getStringAttribute('endpoint_type');
    }
    // gateway_id - computed: true, optional: false, required: false
    get gatewayId() {
        return this.getStringAttribute('gateway_id');
    }
    // gateway_ip_address - computed: true, optional: true, required: false
    _gatewayIpAddress;
    get gatewayIpAddress() {
        return this.getStringAttribute('gateway_ip_address');
    }
    set gatewayIpAddress(value) {
        this._gatewayIpAddress = value;
    }
    resetGatewayIpAddress() {
        this._gatewayIpAddress = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get gatewayIpAddressInput() {
        return this._gatewayIpAddress;
    }
    // gateway_name - computed: false, optional: false, required: true
    _gatewayName;
    get gatewayName() {
        return this.getStringAttribute('gateway_name');
    }
    set gatewayName(value) {
        this._gatewayName = value;
    }
    // Temporarily expose input value. Use with caution.
    get gatewayNameInput() {
        return this._gatewayName;
    }
    // gateway_network_interface - computed: true, optional: false, required: false
    gatewayNetworkInterface(index) {
        return new StoragegatewayGatewayGatewayNetworkInterface(this, 'gateway_network_interface', index, false);
    }
    // gateway_timezone - computed: false, optional: false, required: true
    _gatewayTimezone;
    get gatewayTimezone() {
        return this.getStringAttribute('gateway_timezone');
    }
    set gatewayTimezone(value) {
        this._gatewayTimezone = value;
    }
    // Temporarily expose input value. Use with caution.
    get gatewayTimezoneInput() {
        return this._gatewayTimezone;
    }
    // gateway_type - computed: false, optional: true, required: false
    _gatewayType;
    get gatewayType() {
        return this.getStringAttribute('gateway_type');
    }
    set gatewayType(value) {
        this._gatewayType = value;
    }
    resetGatewayType() {
        this._gatewayType = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get gatewayTypeInput() {
        return this._gatewayType;
    }
    // gateway_vpc_endpoint - computed: false, optional: true, required: false
    _gatewayVpcEndpoint;
    get gatewayVpcEndpoint() {
        return this.getStringAttribute('gateway_vpc_endpoint');
    }
    set gatewayVpcEndpoint(value) {
        this._gatewayVpcEndpoint = value;
    }
    resetGatewayVpcEndpoint() {
        this._gatewayVpcEndpoint = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get gatewayVpcEndpointInput() {
        return this._gatewayVpcEndpoint;
    }
    // host_environment - computed: true, optional: false, required: false
    get hostEnvironment() {
        return this.getStringAttribute('host_environment');
    }
    // id - computed: true, optional: true, required: false
    get id() {
        return this.getStringAttribute('id');
    }
    // medium_changer_type - computed: false, optional: true, required: false
    _mediumChangerType;
    get mediumChangerType() {
        return this.getStringAttribute('medium_changer_type');
    }
    set mediumChangerType(value) {
        this._mediumChangerType = value;
    }
    resetMediumChangerType() {
        this._mediumChangerType = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get mediumChangerTypeInput() {
        return this._mediumChangerType;
    }
    // smb_file_share_visibility - computed: false, optional: true, required: false
    _smbFileShareVisibility;
    get smbFileShareVisibility() {
        return this.getBooleanAttribute('smb_file_share_visibility');
    }
    set smbFileShareVisibility(value) {
        this._smbFileShareVisibility = value;
    }
    resetSmbFileShareVisibility() {
        this._smbFileShareVisibility = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get smbFileShareVisibilityInput() {
        return this._smbFileShareVisibility;
    }
    // smb_guest_password - computed: false, optional: true, required: false
    _smbGuestPassword;
    get smbGuestPassword() {
        return this.getStringAttribute('smb_guest_password');
    }
    set smbGuestPassword(value) {
        this._smbGuestPassword = value;
    }
    resetSmbGuestPassword() {
        this._smbGuestPassword = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get smbGuestPasswordInput() {
        return this._smbGuestPassword;
    }
    // smb_security_strategy - computed: true, optional: true, required: false
    _smbSecurityStrategy;
    get smbSecurityStrategy() {
        return this.getStringAttribute('smb_security_strategy');
    }
    set smbSecurityStrategy(value) {
        this._smbSecurityStrategy = value;
    }
    resetSmbSecurityStrategy() {
        this._smbSecurityStrategy = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get smbSecurityStrategyInput() {
        return this._smbSecurityStrategy;
    }
    // tags - computed: false, optional: true, required: false
    _tags;
    get tags() {
        return this.getStringMapAttribute('tags');
    }
    set tags(value) {
        this._tags = value;
    }
    resetTags() {
        this._tags = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get tagsInput() {
        return this._tags;
    }
    // tags_all - computed: true, optional: true, required: false
    _tagsAll;
    get tagsAll() {
        return this.getStringMapAttribute('tags_all');
    }
    set tagsAll(value) {
        this._tagsAll = value;
    }
    resetTagsAll() {
        this._tagsAll = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get tagsAllInput() {
        return this._tagsAll;
    }
    // tape_drive_type - computed: false, optional: true, required: false
    _tapeDriveType;
    get tapeDriveType() {
        return this.getStringAttribute('tape_drive_type');
    }
    set tapeDriveType(value) {
        this._tapeDriveType = value;
    }
    resetTapeDriveType() {
        this._tapeDriveType = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get tapeDriveTypeInput() {
        return this._tapeDriveType;
    }
    // smb_active_directory_settings - computed: false, optional: true, required: false
    _smbActiveDirectorySettings = new StoragegatewayGatewaySmbActiveDirectorySettingsOutputReference(this, "smb_active_directory_settings", true);
    get smbActiveDirectorySettings() {
        return this._smbActiveDirectorySettings;
    }
    putSmbActiveDirectorySettings(value) {
        this._smbActiveDirectorySettings.internalValue = value;
    }
    resetSmbActiveDirectorySettings() {
        this._smbActiveDirectorySettings.internalValue = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get smbActiveDirectorySettingsInput() {
        return this._smbActiveDirectorySettings.internalValue;
    }
    // timeouts - computed: false, optional: true, required: false
    _timeouts = new StoragegatewayGatewayTimeoutsOutputReference(this, "timeouts", true);
    get timeouts() {
        return this._timeouts;
    }
    putTimeouts(value) {
        this._timeouts.internalValue = value;
    }
    resetTimeouts() {
        this._timeouts.internalValue = undefined;
    }
    // Temporarily expose input value. Use with caution.
    get timeoutsInput() {
        return this._timeouts.internalValue;
    }
    // =========
    // SYNTHESIS
    // =========
    synthesizeAttributes() {
        return {
            activation_key: cdktf.stringToTerraform(this._activationKey),
            average_download_rate_limit_in_bits_per_sec: cdktf.numberToTerraform(this._averageDownloadRateLimitInBitsPerSec),
            average_upload_rate_limit_in_bits_per_sec: cdktf.numberToTerraform(this._averageUploadRateLimitInBitsPerSec),
            cloudwatch_log_group_arn: cdktf.stringToTerraform(this._cloudwatchLogGroupArn),
            gateway_ip_address: cdktf.stringToTerraform(this._gatewayIpAddress),
            gateway_name: cdktf.stringToTerraform(this._gatewayName),
            gateway_timezone: cdktf.stringToTerraform(this._gatewayTimezone),
            gateway_type: cdktf.stringToTerraform(this._gatewayType),
            gateway_vpc_endpoint: cdktf.stringToTerraform(this._gatewayVpcEndpoint),
            medium_changer_type: cdktf.stringToTerraform(this._mediumChangerType),
            smb_file_share_visibility: cdktf.booleanToTerraform(this._smbFileShareVisibility),
            smb_guest_password: cdktf.stringToTerraform(this._smbGuestPassword),
            smb_security_strategy: cdktf.stringToTerraform(this._smbSecurityStrategy),
            tags: cdktf.hashMapper(cdktf.stringToTerraform)(this._tags),
            tags_all: cdktf.hashMapper(cdktf.stringToTerraform)(this._tagsAll),
            tape_drive_type: cdktf.stringToTerraform(this._tapeDriveType),
            smb_active_directory_settings: storagegatewayGatewaySmbActiveDirectorySettingsToTerraform(this._smbActiveDirectorySettings.internalValue),
            timeouts: storagegatewayGatewayTimeoutsToTerraform(this._timeouts.internalValue),
        };
    }
}
//# sourceMappingURL=storagegateway-gateway.js.map