UNPKG

@cdktf/provider-aws

Version:

Prebuilt aws Provider for Terraform CDK (cdktf)

1,190 lines 228 kB
"use strict"; var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m; Object.defineProperty(exports, "__esModule", { value: true }); exports.AppsyncDatasource = exports.AppsyncDatasourceRelationalDatabaseConfigOutputReference = exports.AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigOutputReference = exports.AppsyncDatasourceOpensearchserviceConfigOutputReference = exports.AppsyncDatasourceLambdaConfigOutputReference = exports.AppsyncDatasourceHttpConfigOutputReference = exports.AppsyncDatasourceHttpConfigAuthorizationConfigOutputReference = exports.AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigOutputReference = exports.AppsyncDatasourceEventBridgeConfigOutputReference = exports.AppsyncDatasourceElasticsearchConfigOutputReference = exports.AppsyncDatasourceDynamodbConfigOutputReference = exports.AppsyncDatasourceDynamodbConfigDeltaSyncConfigOutputReference = void 0; exports.appsyncDatasourceDynamodbConfigDeltaSyncConfigToTerraform = appsyncDatasourceDynamodbConfigDeltaSyncConfigToTerraform; exports.appsyncDatasourceDynamodbConfigDeltaSyncConfigToHclTerraform = appsyncDatasourceDynamodbConfigDeltaSyncConfigToHclTerraform; exports.appsyncDatasourceDynamodbConfigToTerraform = appsyncDatasourceDynamodbConfigToTerraform; exports.appsyncDatasourceDynamodbConfigToHclTerraform = appsyncDatasourceDynamodbConfigToHclTerraform; exports.appsyncDatasourceElasticsearchConfigToTerraform = appsyncDatasourceElasticsearchConfigToTerraform; exports.appsyncDatasourceElasticsearchConfigToHclTerraform = appsyncDatasourceElasticsearchConfigToHclTerraform; exports.appsyncDatasourceEventBridgeConfigToTerraform = appsyncDatasourceEventBridgeConfigToTerraform; exports.appsyncDatasourceEventBridgeConfigToHclTerraform = appsyncDatasourceEventBridgeConfigToHclTerraform; exports.appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToTerraform = appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToTerraform; exports.appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToHclTerraform = appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToHclTerraform; exports.appsyncDatasourceHttpConfigAuthorizationConfigToTerraform = appsyncDatasourceHttpConfigAuthorizationConfigToTerraform; exports.appsyncDatasourceHttpConfigAuthorizationConfigToHclTerraform = appsyncDatasourceHttpConfigAuthorizationConfigToHclTerraform; exports.appsyncDatasourceHttpConfigToTerraform = appsyncDatasourceHttpConfigToTerraform; exports.appsyncDatasourceHttpConfigToHclTerraform = appsyncDatasourceHttpConfigToHclTerraform; exports.appsyncDatasourceLambdaConfigToTerraform = appsyncDatasourceLambdaConfigToTerraform; exports.appsyncDatasourceLambdaConfigToHclTerraform = appsyncDatasourceLambdaConfigToHclTerraform; exports.appsyncDatasourceOpensearchserviceConfigToTerraform = appsyncDatasourceOpensearchserviceConfigToTerraform; exports.appsyncDatasourceOpensearchserviceConfigToHclTerraform = appsyncDatasourceOpensearchserviceConfigToHclTerraform; exports.appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToTerraform = appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToTerraform; exports.appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToHclTerraform = appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToHclTerraform; exports.appsyncDatasourceRelationalDatabaseConfigToTerraform = appsyncDatasourceRelationalDatabaseConfigToTerraform; exports.appsyncDatasourceRelationalDatabaseConfigToHclTerraform = appsyncDatasourceRelationalDatabaseConfigToHclTerraform; const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); const cdktf = require("cdktf"); function appsyncDatasourceDynamodbConfigDeltaSyncConfigToTerraform(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 { base_table_ttl: cdktf.numberToTerraform(struct.baseTableTtl), delta_sync_table_name: cdktf.stringToTerraform(struct.deltaSyncTableName), delta_sync_table_ttl: cdktf.numberToTerraform(struct.deltaSyncTableTtl), }; } function appsyncDatasourceDynamodbConfigDeltaSyncConfigToHclTerraform(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"); } const attrs = { base_table_ttl: { value: cdktf.numberToHclTerraform(struct.baseTableTtl), isBlock: false, type: "simple", storageClassType: "number", }, delta_sync_table_name: { value: cdktf.stringToHclTerraform(struct.deltaSyncTableName), isBlock: false, type: "simple", storageClassType: "string", }, delta_sync_table_ttl: { value: cdktf.numberToHclTerraform(struct.deltaSyncTableTtl), isBlock: false, type: "simple", storageClassType: "number", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceDynamodbConfigDeltaSyncConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._baseTableTtl !== undefined) { hasAnyValues = true; internalValueResult.baseTableTtl = this._baseTableTtl; } if (this._deltaSyncTableName !== undefined) { hasAnyValues = true; internalValueResult.deltaSyncTableName = this._deltaSyncTableName; } if (this._deltaSyncTableTtl !== undefined) { hasAnyValues = true; internalValueResult.deltaSyncTableTtl = this._deltaSyncTableTtl; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._baseTableTtl = undefined; this._deltaSyncTableName = undefined; this._deltaSyncTableTtl = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._baseTableTtl = value.baseTableTtl; this._deltaSyncTableName = value.deltaSyncTableName; this._deltaSyncTableTtl = value.deltaSyncTableTtl; } } get baseTableTtl() { return this.getNumberAttribute('base_table_ttl'); } set baseTableTtl(value) { this._baseTableTtl = value; } resetBaseTableTtl() { this._baseTableTtl = undefined; } // Temporarily expose input value. Use with caution. get baseTableTtlInput() { return this._baseTableTtl; } get deltaSyncTableName() { return this.getStringAttribute('delta_sync_table_name'); } set deltaSyncTableName(value) { this._deltaSyncTableName = value; } // Temporarily expose input value. Use with caution. get deltaSyncTableNameInput() { return this._deltaSyncTableName; } get deltaSyncTableTtl() { return this.getNumberAttribute('delta_sync_table_ttl'); } set deltaSyncTableTtl(value) { this._deltaSyncTableTtl = value; } resetDeltaSyncTableTtl() { this._deltaSyncTableTtl = undefined; } // Temporarily expose input value. Use with caution. get deltaSyncTableTtlInput() { return this._deltaSyncTableTtl; } } exports.AppsyncDatasourceDynamodbConfigDeltaSyncConfigOutputReference = AppsyncDatasourceDynamodbConfigDeltaSyncConfigOutputReference; _a = JSII_RTTI_SYMBOL_1; AppsyncDatasourceDynamodbConfigDeltaSyncConfigOutputReference[_a] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceDynamodbConfigDeltaSyncConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceDynamodbConfigToTerraform(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 { region: cdktf.stringToTerraform(struct.region), table_name: cdktf.stringToTerraform(struct.tableName), use_caller_credentials: cdktf.booleanToTerraform(struct.useCallerCredentials), versioned: cdktf.booleanToTerraform(struct.versioned), delta_sync_config: appsyncDatasourceDynamodbConfigDeltaSyncConfigToTerraform(struct.deltaSyncConfig), }; } function appsyncDatasourceDynamodbConfigToHclTerraform(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"); } const attrs = { region: { value: cdktf.stringToHclTerraform(struct.region), isBlock: false, type: "simple", storageClassType: "string", }, table_name: { value: cdktf.stringToHclTerraform(struct.tableName), isBlock: false, type: "simple", storageClassType: "string", }, use_caller_credentials: { value: cdktf.booleanToHclTerraform(struct.useCallerCredentials), isBlock: false, type: "simple", storageClassType: "boolean", }, versioned: { value: cdktf.booleanToHclTerraform(struct.versioned), isBlock: false, type: "simple", storageClassType: "boolean", }, delta_sync_config: { value: appsyncDatasourceDynamodbConfigDeltaSyncConfigToHclTerraform(struct.deltaSyncConfig), isBlock: true, type: "list", storageClassType: "AppsyncDatasourceDynamodbConfigDeltaSyncConfigList", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceDynamodbConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; // delta_sync_config - computed: false, optional: true, required: false this._deltaSyncConfig = new AppsyncDatasourceDynamodbConfigDeltaSyncConfigOutputReference(this, "delta_sync_config"); } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._region !== undefined) { hasAnyValues = true; internalValueResult.region = this._region; } if (this._tableName !== undefined) { hasAnyValues = true; internalValueResult.tableName = this._tableName; } if (this._useCallerCredentials !== undefined) { hasAnyValues = true; internalValueResult.useCallerCredentials = this._useCallerCredentials; } if (this._versioned !== undefined) { hasAnyValues = true; internalValueResult.versioned = this._versioned; } if (this._deltaSyncConfig?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.deltaSyncConfig = this._deltaSyncConfig?.internalValue; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._region = undefined; this._tableName = undefined; this._useCallerCredentials = undefined; this._versioned = undefined; this._deltaSyncConfig.internalValue = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._region = value.region; this._tableName = value.tableName; this._useCallerCredentials = value.useCallerCredentials; this._versioned = value.versioned; this._deltaSyncConfig.internalValue = value.deltaSyncConfig; } } get region() { return this.getStringAttribute('region'); } set region(value) { this._region = value; } resetRegion() { this._region = undefined; } // Temporarily expose input value. Use with caution. get regionInput() { return this._region; } get tableName() { return this.getStringAttribute('table_name'); } set tableName(value) { this._tableName = value; } // Temporarily expose input value. Use with caution. get tableNameInput() { return this._tableName; } get useCallerCredentials() { return this.getBooleanAttribute('use_caller_credentials'); } set useCallerCredentials(value) { this._useCallerCredentials = value; } resetUseCallerCredentials() { this._useCallerCredentials = undefined; } // Temporarily expose input value. Use with caution. get useCallerCredentialsInput() { return this._useCallerCredentials; } get versioned() { return this.getBooleanAttribute('versioned'); } set versioned(value) { this._versioned = value; } resetVersioned() { this._versioned = undefined; } // Temporarily expose input value. Use with caution. get versionedInput() { return this._versioned; } get deltaSyncConfig() { return this._deltaSyncConfig; } putDeltaSyncConfig(value) { this._deltaSyncConfig.internalValue = value; } resetDeltaSyncConfig() { this._deltaSyncConfig.internalValue = undefined; } // Temporarily expose input value. Use with caution. get deltaSyncConfigInput() { return this._deltaSyncConfig.internalValue; } } exports.AppsyncDatasourceDynamodbConfigOutputReference = AppsyncDatasourceDynamodbConfigOutputReference; _b = JSII_RTTI_SYMBOL_1; AppsyncDatasourceDynamodbConfigOutputReference[_b] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceDynamodbConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceElasticsearchConfigToTerraform(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 { endpoint: cdktf.stringToTerraform(struct.endpoint), region: cdktf.stringToTerraform(struct.region), }; } function appsyncDatasourceElasticsearchConfigToHclTerraform(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"); } const attrs = { endpoint: { value: cdktf.stringToHclTerraform(struct.endpoint), isBlock: false, type: "simple", storageClassType: "string", }, region: { value: cdktf.stringToHclTerraform(struct.region), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceElasticsearchConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._endpoint !== undefined) { hasAnyValues = true; internalValueResult.endpoint = this._endpoint; } if (this._region !== undefined) { hasAnyValues = true; internalValueResult.region = this._region; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._endpoint = undefined; this._region = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._endpoint = value.endpoint; this._region = value.region; } } get endpoint() { return this.getStringAttribute('endpoint'); } set endpoint(value) { this._endpoint = value; } // Temporarily expose input value. Use with caution. get endpointInput() { return this._endpoint; } get region() { return this.getStringAttribute('region'); } set region(value) { this._region = value; } resetRegion() { this._region = undefined; } // Temporarily expose input value. Use with caution. get regionInput() { return this._region; } } exports.AppsyncDatasourceElasticsearchConfigOutputReference = AppsyncDatasourceElasticsearchConfigOutputReference; _c = JSII_RTTI_SYMBOL_1; AppsyncDatasourceElasticsearchConfigOutputReference[_c] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceElasticsearchConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceEventBridgeConfigToTerraform(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 { event_bus_arn: cdktf.stringToTerraform(struct.eventBusArn), }; } function appsyncDatasourceEventBridgeConfigToHclTerraform(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"); } const attrs = { event_bus_arn: { value: cdktf.stringToHclTerraform(struct.eventBusArn), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceEventBridgeConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._eventBusArn !== undefined) { hasAnyValues = true; internalValueResult.eventBusArn = this._eventBusArn; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._eventBusArn = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._eventBusArn = value.eventBusArn; } } get eventBusArn() { return this.getStringAttribute('event_bus_arn'); } set eventBusArn(value) { this._eventBusArn = value; } // Temporarily expose input value. Use with caution. get eventBusArnInput() { return this._eventBusArn; } } exports.AppsyncDatasourceEventBridgeConfigOutputReference = AppsyncDatasourceEventBridgeConfigOutputReference; _d = JSII_RTTI_SYMBOL_1; AppsyncDatasourceEventBridgeConfigOutputReference[_d] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceEventBridgeConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToTerraform(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 { signing_region: cdktf.stringToTerraform(struct.signingRegion), signing_service_name: cdktf.stringToTerraform(struct.signingServiceName), }; } function appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToHclTerraform(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"); } const attrs = { signing_region: { value: cdktf.stringToHclTerraform(struct.signingRegion), isBlock: false, type: "simple", storageClassType: "string", }, signing_service_name: { value: cdktf.stringToHclTerraform(struct.signingServiceName), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._signingRegion !== undefined) { hasAnyValues = true; internalValueResult.signingRegion = this._signingRegion; } if (this._signingServiceName !== undefined) { hasAnyValues = true; internalValueResult.signingServiceName = this._signingServiceName; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._signingRegion = undefined; this._signingServiceName = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._signingRegion = value.signingRegion; this._signingServiceName = value.signingServiceName; } } get signingRegion() { return this.getStringAttribute('signing_region'); } set signingRegion(value) { this._signingRegion = value; } resetSigningRegion() { this._signingRegion = undefined; } // Temporarily expose input value. Use with caution. get signingRegionInput() { return this._signingRegion; } get signingServiceName() { return this.getStringAttribute('signing_service_name'); } set signingServiceName(value) { this._signingServiceName = value; } resetSigningServiceName() { this._signingServiceName = undefined; } // Temporarily expose input value. Use with caution. get signingServiceNameInput() { return this._signingServiceName; } } exports.AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigOutputReference = AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigOutputReference; _e = JSII_RTTI_SYMBOL_1; AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigOutputReference[_e] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceHttpConfigAuthorizationConfigToTerraform(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 { authorization_type: cdktf.stringToTerraform(struct.authorizationType), aws_iam_config: appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToTerraform(struct.awsIamConfig), }; } function appsyncDatasourceHttpConfigAuthorizationConfigToHclTerraform(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"); } const attrs = { authorization_type: { value: cdktf.stringToHclTerraform(struct.authorizationType), isBlock: false, type: "simple", storageClassType: "string", }, aws_iam_config: { value: appsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigToHclTerraform(struct.awsIamConfig), isBlock: true, type: "list", storageClassType: "AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigList", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceHttpConfigAuthorizationConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; // aws_iam_config - computed: false, optional: true, required: false this._awsIamConfig = new AppsyncDatasourceHttpConfigAuthorizationConfigAwsIamConfigOutputReference(this, "aws_iam_config"); } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._authorizationType !== undefined) { hasAnyValues = true; internalValueResult.authorizationType = this._authorizationType; } if (this._awsIamConfig?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.awsIamConfig = this._awsIamConfig?.internalValue; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._authorizationType = undefined; this._awsIamConfig.internalValue = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._authorizationType = value.authorizationType; this._awsIamConfig.internalValue = value.awsIamConfig; } } get authorizationType() { return this.getStringAttribute('authorization_type'); } set authorizationType(value) { this._authorizationType = value; } resetAuthorizationType() { this._authorizationType = undefined; } // Temporarily expose input value. Use with caution. get authorizationTypeInput() { return this._authorizationType; } get awsIamConfig() { return this._awsIamConfig; } putAwsIamConfig(value) { this._awsIamConfig.internalValue = value; } resetAwsIamConfig() { this._awsIamConfig.internalValue = undefined; } // Temporarily expose input value. Use with caution. get awsIamConfigInput() { return this._awsIamConfig.internalValue; } } exports.AppsyncDatasourceHttpConfigAuthorizationConfigOutputReference = AppsyncDatasourceHttpConfigAuthorizationConfigOutputReference; _f = JSII_RTTI_SYMBOL_1; AppsyncDatasourceHttpConfigAuthorizationConfigOutputReference[_f] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceHttpConfigAuthorizationConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceHttpConfigToTerraform(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 { endpoint: cdktf.stringToTerraform(struct.endpoint), authorization_config: appsyncDatasourceHttpConfigAuthorizationConfigToTerraform(struct.authorizationConfig), }; } function appsyncDatasourceHttpConfigToHclTerraform(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"); } const attrs = { endpoint: { value: cdktf.stringToHclTerraform(struct.endpoint), isBlock: false, type: "simple", storageClassType: "string", }, authorization_config: { value: appsyncDatasourceHttpConfigAuthorizationConfigToHclTerraform(struct.authorizationConfig), isBlock: true, type: "list", storageClassType: "AppsyncDatasourceHttpConfigAuthorizationConfigList", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceHttpConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; // authorization_config - computed: false, optional: true, required: false this._authorizationConfig = new AppsyncDatasourceHttpConfigAuthorizationConfigOutputReference(this, "authorization_config"); } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._endpoint !== undefined) { hasAnyValues = true; internalValueResult.endpoint = this._endpoint; } if (this._authorizationConfig?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.authorizationConfig = this._authorizationConfig?.internalValue; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._endpoint = undefined; this._authorizationConfig.internalValue = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._endpoint = value.endpoint; this._authorizationConfig.internalValue = value.authorizationConfig; } } get endpoint() { return this.getStringAttribute('endpoint'); } set endpoint(value) { this._endpoint = value; } // Temporarily expose input value. Use with caution. get endpointInput() { return this._endpoint; } get authorizationConfig() { return this._authorizationConfig; } putAuthorizationConfig(value) { this._authorizationConfig.internalValue = value; } resetAuthorizationConfig() { this._authorizationConfig.internalValue = undefined; } // Temporarily expose input value. Use with caution. get authorizationConfigInput() { return this._authorizationConfig.internalValue; } } exports.AppsyncDatasourceHttpConfigOutputReference = AppsyncDatasourceHttpConfigOutputReference; _g = JSII_RTTI_SYMBOL_1; AppsyncDatasourceHttpConfigOutputReference[_g] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceHttpConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceLambdaConfigToTerraform(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 { function_arn: cdktf.stringToTerraform(struct.functionArn), }; } function appsyncDatasourceLambdaConfigToHclTerraform(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"); } const attrs = { function_arn: { value: cdktf.stringToHclTerraform(struct.functionArn), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceLambdaConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._functionArn !== undefined) { hasAnyValues = true; internalValueResult.functionArn = this._functionArn; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._functionArn = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._functionArn = value.functionArn; } } get functionArn() { return this.getStringAttribute('function_arn'); } set functionArn(value) { this._functionArn = value; } // Temporarily expose input value. Use with caution. get functionArnInput() { return this._functionArn; } } exports.AppsyncDatasourceLambdaConfigOutputReference = AppsyncDatasourceLambdaConfigOutputReference; _h = JSII_RTTI_SYMBOL_1; AppsyncDatasourceLambdaConfigOutputReference[_h] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceLambdaConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceOpensearchserviceConfigToTerraform(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 { endpoint: cdktf.stringToTerraform(struct.endpoint), region: cdktf.stringToTerraform(struct.region), }; } function appsyncDatasourceOpensearchserviceConfigToHclTerraform(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"); } const attrs = { endpoint: { value: cdktf.stringToHclTerraform(struct.endpoint), isBlock: false, type: "simple", storageClassType: "string", }, region: { value: cdktf.stringToHclTerraform(struct.region), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceOpensearchserviceConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._endpoint !== undefined) { hasAnyValues = true; internalValueResult.endpoint = this._endpoint; } if (this._region !== undefined) { hasAnyValues = true; internalValueResult.region = this._region; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._endpoint = undefined; this._region = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._endpoint = value.endpoint; this._region = value.region; } } get endpoint() { return this.getStringAttribute('endpoint'); } set endpoint(value) { this._endpoint = value; } // Temporarily expose input value. Use with caution. get endpointInput() { return this._endpoint; } get region() { return this.getStringAttribute('region'); } set region(value) { this._region = value; } resetRegion() { this._region = undefined; } // Temporarily expose input value. Use with caution. get regionInput() { return this._region; } } exports.AppsyncDatasourceOpensearchserviceConfigOutputReference = AppsyncDatasourceOpensearchserviceConfigOutputReference; _j = JSII_RTTI_SYMBOL_1; AppsyncDatasourceOpensearchserviceConfigOutputReference[_j] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceOpensearchserviceConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToTerraform(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 { aws_secret_store_arn: cdktf.stringToTerraform(struct.awsSecretStoreArn), database_name: cdktf.stringToTerraform(struct.databaseName), db_cluster_identifier: cdktf.stringToTerraform(struct.dbClusterIdentifier), region: cdktf.stringToTerraform(struct.region), schema: cdktf.stringToTerraform(struct.schema), }; } function appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToHclTerraform(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"); } const attrs = { aws_secret_store_arn: { value: cdktf.stringToHclTerraform(struct.awsSecretStoreArn), isBlock: false, type: "simple", storageClassType: "string", }, database_name: { value: cdktf.stringToHclTerraform(struct.databaseName), isBlock: false, type: "simple", storageClassType: "string", }, db_cluster_identifier: { value: cdktf.stringToHclTerraform(struct.dbClusterIdentifier), isBlock: false, type: "simple", storageClassType: "string", }, region: { value: cdktf.stringToHclTerraform(struct.region), isBlock: false, type: "simple", storageClassType: "string", }, schema: { value: cdktf.stringToHclTerraform(struct.schema), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._awsSecretStoreArn !== undefined) { hasAnyValues = true; internalValueResult.awsSecretStoreArn = this._awsSecretStoreArn; } if (this._databaseName !== undefined) { hasAnyValues = true; internalValueResult.databaseName = this._databaseName; } if (this._dbClusterIdentifier !== undefined) { hasAnyValues = true; internalValueResult.dbClusterIdentifier = this._dbClusterIdentifier; } if (this._region !== undefined) { hasAnyValues = true; internalValueResult.region = this._region; } if (this._schema !== undefined) { hasAnyValues = true; internalValueResult.schema = this._schema; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._awsSecretStoreArn = undefined; this._databaseName = undefined; this._dbClusterIdentifier = undefined; this._region = undefined; this._schema = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._awsSecretStoreArn = value.awsSecretStoreArn; this._databaseName = value.databaseName; this._dbClusterIdentifier = value.dbClusterIdentifier; this._region = value.region; this._schema = value.schema; } } get awsSecretStoreArn() { return this.getStringAttribute('aws_secret_store_arn'); } set awsSecretStoreArn(value) { this._awsSecretStoreArn = value; } // Temporarily expose input value. Use with caution. get awsSecretStoreArnInput() { return this._awsSecretStoreArn; } get databaseName() { return this.getStringAttribute('database_name'); } set databaseName(value) { this._databaseName = value; } resetDatabaseName() { this._databaseName = undefined; } // Temporarily expose input value. Use with caution. get databaseNameInput() { return this._databaseName; } get dbClusterIdentifier() { return this.getStringAttribute('db_cluster_identifier'); } set dbClusterIdentifier(value) { this._dbClusterIdentifier = value; } // Temporarily expose input value. Use with caution. get dbClusterIdentifierInput() { return this._dbClusterIdentifier; } get region() { return this.getStringAttribute('region'); } set region(value) { this._region = value; } resetRegion() { this._region = undefined; } // Temporarily expose input value. Use with caution. get regionInput() { return this._region; } get schema() { return this.getStringAttribute('schema'); } set schema(value) { this._schema = value; } resetSchema() { this._schema = undefined; } // Temporarily expose input value. Use with caution. get schemaInput() { return this._schema; } } exports.AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigOutputReference = AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigOutputReference; _k = JSII_RTTI_SYMBOL_1; AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigOutputReference[_k] = { fqn: "@cdktf/provider-aws.appsyncDatasource.AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigOutputReference", version: "21.22.1" }; function appsyncDatasourceRelationalDatabaseConfigToTerraform(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 { source_type: cdktf.stringToTerraform(struct.sourceType), http_endpoint_config: appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToTerraform(struct.httpEndpointConfig), }; } function appsyncDatasourceRelationalDatabaseConfigToHclTerraform(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"); } const attrs = { source_type: { value: cdktf.stringToHclTerraform(struct.sourceType), isBlock: false, type: "simple", storageClassType: "string", }, http_endpoint_config: { value: appsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigToHclTerraform(struct.httpEndpointConfig), isBlock: true, type: "list", storageClassType: "AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigList", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class AppsyncDatasourceRelationalDatabaseConfigOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing */ constructor(terraformResource, terraformAttribute) { super(terraformResource, terraformAttribute, false, 0); this.isEmptyObject = false; // http_endpoint_config - computed: false, optional: true, required: false this._httpEndpointConfig = new AppsyncDatasourceRelationalDatabaseConfigHttpEndpointConfigOutputReference(this, "http_endpoint_config"); } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._sourceType !== undefined) { hasAnyValues = true; internalValueResult.so