UNPKG

@cdktf/provider-databricks

Version:

Prebuilt databricks Provider for Terraform CDK (cdktf)

943 lines 145 kB
"use strict"; var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k; Object.defineProperty(exports, "__esModule", { value: true }); exports.DataDatabricksAccountNetworkPolicies = exports.DataDatabricksAccountNetworkPoliciesItemsList = exports.DataDatabricksAccountNetworkPoliciesItemsOutputReference = exports.DataDatabricksAccountNetworkPoliciesItemsEgressOutputReference = exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessOutputReference = exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementOutputReference = exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList = exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsOutputReference = exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList = exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsOutputReference = void 0; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToHclTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToHclTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToHclTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToHclTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToHclTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToHclTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToHclTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToHclTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressToTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressToTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsEgressToHclTerraform = dataDatabricksAccountNetworkPoliciesItemsEgressToHclTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsToTerraform = dataDatabricksAccountNetworkPoliciesItemsToTerraform; exports.dataDatabricksAccountNetworkPoliciesItemsToHclTerraform = dataDatabricksAccountNetworkPoliciesItemsToHclTerraform; const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); const cdktf = require("cdktf"); function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToTerraform(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 { destination: cdktf.stringToTerraform(struct.destination), internet_destination_type: cdktf.stringToTerraform(struct.internetDestinationType), }; } function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToHclTerraform(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 = { destination: { value: cdktf.stringToHclTerraform(struct.destination), isBlock: false, type: "simple", storageClassType: "string", }, internet_destination_type: { value: cdktf.stringToHclTerraform(struct.internetDestinationType), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param complexObjectIndex the index of this item in the list * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) { super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex); this.isEmptyObject = false; } get internalValue() { if (this.resolvableValue) { return this.resolvableValue; } let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._destination !== undefined) { hasAnyValues = true; internalValueResult.destination = this._destination; } if (this._internetDestinationType !== undefined) { hasAnyValues = true; internalValueResult.internetDestinationType = this._internetDestinationType; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._destination = undefined; this._internetDestinationType = undefined; } else if (cdktf.Tokenization.isResolvable(value)) { this.isEmptyObject = false; this.resolvableValue = value; } else { this.isEmptyObject = Object.keys(value).length === 0; this.resolvableValue = undefined; this._destination = value.destination; this._internetDestinationType = value.internetDestinationType; } } get destination() { return this.getStringAttribute('destination'); } set destination(value) { this._destination = value; } resetDestination() { this._destination = undefined; } // Temporarily expose input value. Use with caution. get destinationInput() { return this._destination; } get internetDestinationType() { return this.getStringAttribute('internet_destination_type'); } set internetDestinationType(value) { this._internetDestinationType = value; } resetInternetDestinationType() { this._internetDestinationType = undefined; } // Temporarily expose input value. Use with caution. get internetDestinationTypeInput() { return this._internetDestinationType; } } exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsOutputReference = DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsOutputReference; _a = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsOutputReference[_a] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsOutputReference", version: "15.3.1" }; class DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList extends cdktf.ComplexList { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, wrapsSet) { super(terraformResource, terraformAttribute, wrapsSet); this.terraformResource = terraformResource; this.terraformAttribute = terraformAttribute; this.wrapsSet = wrapsSet; } /** * @param index the index of the item to return */ get(index) { return new DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList = DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList; _b = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList[_b] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList", version: "15.3.1" }; function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToTerraform(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 { azure_storage_account: cdktf.stringToTerraform(struct.azureStorageAccount), azure_storage_service: cdktf.stringToTerraform(struct.azureStorageService), bucket_name: cdktf.stringToTerraform(struct.bucketName), region: cdktf.stringToTerraform(struct.region), storage_destination_type: cdktf.stringToTerraform(struct.storageDestinationType), }; } function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToHclTerraform(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 = { azure_storage_account: { value: cdktf.stringToHclTerraform(struct.azureStorageAccount), isBlock: false, type: "simple", storageClassType: "string", }, azure_storage_service: { value: cdktf.stringToHclTerraform(struct.azureStorageService), isBlock: false, type: "simple", storageClassType: "string", }, bucket_name: { value: cdktf.stringToHclTerraform(struct.bucketName), isBlock: false, type: "simple", storageClassType: "string", }, region: { value: cdktf.stringToHclTerraform(struct.region), isBlock: false, type: "simple", storageClassType: "string", }, storage_destination_type: { value: cdktf.stringToHclTerraform(struct.storageDestinationType), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param complexObjectIndex the index of this item in the list * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) { super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex); this.isEmptyObject = false; } get internalValue() { if (this.resolvableValue) { return this.resolvableValue; } let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._azureStorageAccount !== undefined) { hasAnyValues = true; internalValueResult.azureStorageAccount = this._azureStorageAccount; } if (this._azureStorageService !== undefined) { hasAnyValues = true; internalValueResult.azureStorageService = this._azureStorageService; } if (this._bucketName !== undefined) { hasAnyValues = true; internalValueResult.bucketName = this._bucketName; } if (this._region !== undefined) { hasAnyValues = true; internalValueResult.region = this._region; } if (this._storageDestinationType !== undefined) { hasAnyValues = true; internalValueResult.storageDestinationType = this._storageDestinationType; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._azureStorageAccount = undefined; this._azureStorageService = undefined; this._bucketName = undefined; this._region = undefined; this._storageDestinationType = undefined; } else if (cdktf.Tokenization.isResolvable(value)) { this.isEmptyObject = false; this.resolvableValue = value; } else { this.isEmptyObject = Object.keys(value).length === 0; this.resolvableValue = undefined; this._azureStorageAccount = value.azureStorageAccount; this._azureStorageService = value.azureStorageService; this._bucketName = value.bucketName; this._region = value.region; this._storageDestinationType = value.storageDestinationType; } } get azureStorageAccount() { return this.getStringAttribute('azure_storage_account'); } set azureStorageAccount(value) { this._azureStorageAccount = value; } resetAzureStorageAccount() { this._azureStorageAccount = undefined; } // Temporarily expose input value. Use with caution. get azureStorageAccountInput() { return this._azureStorageAccount; } get azureStorageService() { return this.getStringAttribute('azure_storage_service'); } set azureStorageService(value) { this._azureStorageService = value; } resetAzureStorageService() { this._azureStorageService = undefined; } // Temporarily expose input value. Use with caution. get azureStorageServiceInput() { return this._azureStorageService; } get bucketName() { return this.getStringAttribute('bucket_name'); } set bucketName(value) { this._bucketName = value; } resetBucketName() { this._bucketName = undefined; } // Temporarily expose input value. Use with caution. get bucketNameInput() { return this._bucketName; } 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 storageDestinationType() { return this.getStringAttribute('storage_destination_type'); } set storageDestinationType(value) { this._storageDestinationType = value; } resetStorageDestinationType() { this._storageDestinationType = undefined; } // Temporarily expose input value. Use with caution. get storageDestinationTypeInput() { return this._storageDestinationType; } } exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsOutputReference = DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsOutputReference; _c = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsOutputReference[_c] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsOutputReference", version: "15.3.1" }; class DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList extends cdktf.ComplexList { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, wrapsSet) { super(terraformResource, terraformAttribute, wrapsSet); this.terraformResource = terraformResource; this.terraformAttribute = terraformAttribute; this.wrapsSet = wrapsSet; } /** * @param index the index of the item to return */ get(index) { return new DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList = DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList; _d = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList[_d] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList", version: "15.3.1" }; function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToTerraform(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 { dry_run_mode_product_filter: cdktf.listMapper(cdktf.stringToTerraform, false)(struct.dryRunModeProductFilter), enforcement_mode: cdktf.stringToTerraform(struct.enforcementMode), }; } function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToHclTerraform(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 = { dry_run_mode_product_filter: { value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(struct.dryRunModeProductFilter), isBlock: false, type: "list", storageClassType: "stringList", }, enforcement_mode: { value: cdktf.stringToHclTerraform(struct.enforcementMode), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementOutputReference 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); this.isEmptyObject = false; } get internalValue() { if (this.resolvableValue) { return this.resolvableValue; } let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._dryRunModeProductFilter !== undefined) { hasAnyValues = true; internalValueResult.dryRunModeProductFilter = this._dryRunModeProductFilter; } if (this._enforcementMode !== undefined) { hasAnyValues = true; internalValueResult.enforcementMode = this._enforcementMode; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._dryRunModeProductFilter = undefined; this._enforcementMode = undefined; } else if (cdktf.Tokenization.isResolvable(value)) { this.isEmptyObject = false; this.resolvableValue = value; } else { this.isEmptyObject = Object.keys(value).length === 0; this.resolvableValue = undefined; this._dryRunModeProductFilter = value.dryRunModeProductFilter; this._enforcementMode = value.enforcementMode; } } get dryRunModeProductFilter() { return this.getListAttribute('dry_run_mode_product_filter'); } set dryRunModeProductFilter(value) { this._dryRunModeProductFilter = value; } resetDryRunModeProductFilter() { this._dryRunModeProductFilter = undefined; } // Temporarily expose input value. Use with caution. get dryRunModeProductFilterInput() { return this._dryRunModeProductFilter; } get enforcementMode() { return this.getStringAttribute('enforcement_mode'); } set enforcementMode(value) { this._enforcementMode = value; } resetEnforcementMode() { this._enforcementMode = undefined; } // Temporarily expose input value. Use with caution. get enforcementModeInput() { return this._enforcementMode; } } exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementOutputReference = DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementOutputReference; _e = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementOutputReference[_e] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementOutputReference", version: "15.3.1" }; function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToTerraform(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 { allowed_internet_destinations: cdktf.listMapper(dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToTerraform, false)(struct.allowedInternetDestinations), allowed_storage_destinations: cdktf.listMapper(dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToTerraform, false)(struct.allowedStorageDestinations), policy_enforcement: dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToTerraform(struct.policyEnforcement), restriction_mode: cdktf.stringToTerraform(struct.restrictionMode), }; } function dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToHclTerraform(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 = { allowed_internet_destinations: { value: cdktf.listMapperHcl(dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsToHclTerraform, false)(struct.allowedInternetDestinations), isBlock: true, type: "list", storageClassType: "DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList", }, allowed_storage_destinations: { value: cdktf.listMapperHcl(dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsToHclTerraform, false)(struct.allowedStorageDestinations), isBlock: true, type: "list", storageClassType: "DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList", }, policy_enforcement: { value: dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementToHclTerraform(struct.policyEnforcement), isBlock: true, type: "struct", storageClassType: "DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcement", }, restriction_mode: { value: cdktf.stringToHclTerraform(struct.restrictionMode), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessOutputReference 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); this.isEmptyObject = false; // allowed_internet_destinations - computed: true, optional: true, required: false this._allowedInternetDestinations = new DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedInternetDestinationsList(this, "allowed_internet_destinations", false); // allowed_storage_destinations - computed: true, optional: true, required: false this._allowedStorageDestinations = new DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessAllowedStorageDestinationsList(this, "allowed_storage_destinations", false); // policy_enforcement - computed: true, optional: true, required: false this._policyEnforcement = new DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessPolicyEnforcementOutputReference(this, "policy_enforcement"); } get internalValue() { if (this.resolvableValue) { return this.resolvableValue; } let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._allowedInternetDestinations?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.allowedInternetDestinations = this._allowedInternetDestinations?.internalValue; } if (this._allowedStorageDestinations?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.allowedStorageDestinations = this._allowedStorageDestinations?.internalValue; } if (this._policyEnforcement?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.policyEnforcement = this._policyEnforcement?.internalValue; } if (this._restrictionMode !== undefined) { hasAnyValues = true; internalValueResult.restrictionMode = this._restrictionMode; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._allowedInternetDestinations.internalValue = undefined; this._allowedStorageDestinations.internalValue = undefined; this._policyEnforcement.internalValue = undefined; this._restrictionMode = undefined; } else if (cdktf.Tokenization.isResolvable(value)) { this.isEmptyObject = false; this.resolvableValue = value; } else { this.isEmptyObject = Object.keys(value).length === 0; this.resolvableValue = undefined; this._allowedInternetDestinations.internalValue = value.allowedInternetDestinations; this._allowedStorageDestinations.internalValue = value.allowedStorageDestinations; this._policyEnforcement.internalValue = value.policyEnforcement; this._restrictionMode = value.restrictionMode; } } get allowedInternetDestinations() { return this._allowedInternetDestinations; } putAllowedInternetDestinations(value) { this._allowedInternetDestinations.internalValue = value; } resetAllowedInternetDestinations() { this._allowedInternetDestinations.internalValue = undefined; } // Temporarily expose input value. Use with caution. get allowedInternetDestinationsInput() { return this._allowedInternetDestinations.internalValue; } get allowedStorageDestinations() { return this._allowedStorageDestinations; } putAllowedStorageDestinations(value) { this._allowedStorageDestinations.internalValue = value; } resetAllowedStorageDestinations() { this._allowedStorageDestinations.internalValue = undefined; } // Temporarily expose input value. Use with caution. get allowedStorageDestinationsInput() { return this._allowedStorageDestinations.internalValue; } get policyEnforcement() { return this._policyEnforcement; } putPolicyEnforcement(value) { this._policyEnforcement.internalValue = value; } resetPolicyEnforcement() { this._policyEnforcement.internalValue = undefined; } // Temporarily expose input value. Use with caution. get policyEnforcementInput() { return this._policyEnforcement.internalValue; } get restrictionMode() { return this.getStringAttribute('restriction_mode'); } set restrictionMode(value) { this._restrictionMode = value; } // Temporarily expose input value. Use with caution. get restrictionModeInput() { return this._restrictionMode; } } exports.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessOutputReference = DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessOutputReference; _f = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessOutputReference[_f] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessOutputReference", version: "15.3.1" }; function dataDatabricksAccountNetworkPoliciesItemsEgressToTerraform(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 { network_access: dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToTerraform(struct.networkAccess), }; } function dataDatabricksAccountNetworkPoliciesItemsEgressToHclTerraform(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 = { network_access: { value: dataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessToHclTerraform(struct.networkAccess), isBlock: true, type: "struct", storageClassType: "DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccess", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksAccountNetworkPoliciesItemsEgressOutputReference 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); this.isEmptyObject = false; // network_access - computed: true, optional: true, required: false this._networkAccess = new DataDatabricksAccountNetworkPoliciesItemsEgressNetworkAccessOutputReference(this, "network_access"); } get internalValue() { if (this.resolvableValue) { return this.resolvableValue; } let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._networkAccess?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.networkAccess = this._networkAccess?.internalValue; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._networkAccess.internalValue = undefined; } else if (cdktf.Tokenization.isResolvable(value)) { this.isEmptyObject = false; this.resolvableValue = value; } else { this.isEmptyObject = Object.keys(value).length === 0; this.resolvableValue = undefined; this._networkAccess.internalValue = value.networkAccess; } } get networkAccess() { return this._networkAccess; } putNetworkAccess(value) { this._networkAccess.internalValue = value; } resetNetworkAccess() { this._networkAccess.internalValue = undefined; } // Temporarily expose input value. Use with caution. get networkAccessInput() { return this._networkAccess.internalValue; } } exports.DataDatabricksAccountNetworkPoliciesItemsEgressOutputReference = DataDatabricksAccountNetworkPoliciesItemsEgressOutputReference; _g = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsEgressOutputReference[_g] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsEgressOutputReference", version: "15.3.1" }; function dataDatabricksAccountNetworkPoliciesItemsToTerraform(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 { account_id: cdktf.stringToTerraform(struct.accountId), egress: dataDatabricksAccountNetworkPoliciesItemsEgressToTerraform(struct.egress), network_policy_id: cdktf.stringToTerraform(struct.networkPolicyId), }; } function dataDatabricksAccountNetworkPoliciesItemsToHclTerraform(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 = { account_id: { value: cdktf.stringToHclTerraform(struct.accountId), isBlock: false, type: "simple", storageClassType: "string", }, egress: { value: dataDatabricksAccountNetworkPoliciesItemsEgressToHclTerraform(struct.egress), isBlock: true, type: "struct", storageClassType: "DataDatabricksAccountNetworkPoliciesItemsEgress", }, network_policy_id: { value: cdktf.stringToHclTerraform(struct.networkPolicyId), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksAccountNetworkPoliciesItemsOutputReference extends cdktf.ComplexObject { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param complexObjectIndex the index of this item in the list * @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) { super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex); this.isEmptyObject = false; // egress - computed: true, optional: true, required: false this._egress = new DataDatabricksAccountNetworkPoliciesItemsEgressOutputReference(this, "egress"); } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._accountId !== undefined) { hasAnyValues = true; internalValueResult.accountId = this._accountId; } if (this._egress?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.egress = this._egress?.internalValue; } if (this._networkPolicyId !== undefined) { hasAnyValues = true; internalValueResult.networkPolicyId = this._networkPolicyId; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._accountId = undefined; this._egress.internalValue = undefined; this._networkPolicyId = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._accountId = value.accountId; this._egress.internalValue = value.egress; this._networkPolicyId = value.networkPolicyId; } } get accountId() { return this.getStringAttribute('account_id'); } set accountId(value) { this._accountId = value; } resetAccountId() { this._accountId = undefined; } // Temporarily expose input value. Use with caution. get accountIdInput() { return this._accountId; } get egress() { return this._egress; } putEgress(value) { this._egress.internalValue = value; } resetEgress() { this._egress.internalValue = undefined; } // Temporarily expose input value. Use with caution. get egressInput() { return this._egress.internalValue; } get networkPolicyId() { return this.getStringAttribute('network_policy_id'); } set networkPolicyId(value) { this._networkPolicyId = value; } resetNetworkPolicyId() { this._networkPolicyId = undefined; } // Temporarily expose input value. Use with caution. get networkPolicyIdInput() { return this._networkPolicyId; } } exports.DataDatabricksAccountNetworkPoliciesItemsOutputReference = DataDatabricksAccountNetworkPoliciesItemsOutputReference; _h = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsOutputReference[_h] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsOutputReference", version: "15.3.1" }; class DataDatabricksAccountNetworkPoliciesItemsList extends cdktf.ComplexList { /** * @param terraformResource The parent resource * @param terraformAttribute The attribute on the parent resource this class is referencing * @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index) */ constructor(terraformResource, terraformAttribute, wrapsSet) { super(terraformResource, terraformAttribute, wrapsSet); this.terraformResource = terraformResource; this.terraformAttribute = terraformAttribute; this.wrapsSet = wrapsSet; } /** * @param index the index of the item to return */ get(index) { return new DataDatabricksAccountNetworkPoliciesItemsOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.DataDatabricksAccountNetworkPoliciesItemsList = DataDatabricksAccountNetworkPoliciesItemsList; _j = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPoliciesItemsList[_j] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPoliciesItemsList", version: "15.3.1" }; /** * Represents a {@link https://registry.terraform.io/providers/databricks/databricks/1.86.0/docs/data-sources/account_network_policies databricks_account_network_policies} */ class DataDatabricksAccountNetworkPolicies extends cdktf.TerraformDataSource { // ============== // STATIC Methods // ============== /** * Generates CDKTF code for importing a DataDatabricksAccountNetworkPolicies resource upon running "cdktf plan <stack-name>" * @param scope The scope in which to define this construct * @param importToId The construct id used in the generated config for the DataDatabricksAccountNetworkPolicies to import * @param importFromId The id of the existing DataDatabricksAccountNetworkPolicies that should be imported. Refer to the {@link https://registry.terraform.io/providers/databricks/databricks/1.86.0/docs/data-sources/account_network_policies#import import section} in the documentation of this resource for the id to use * @param provider? Optional instance of the provider where the DataDatabricksAccountNetworkPolicies to import is found */ static generateConfigForImport(scope, importToId, importFromId, provider) { return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "databricks_account_network_policies", importId: importFromId, provider }); } // =========== // INITIALIZER // =========== /** * Create a new {@link https://registry.terraform.io/providers/databricks/databricks/1.86.0/docs/data-sources/account_network_policies databricks_account_network_policies} Data Source * * @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 DataDatabricksAccountNetworkPoliciesConfig = {} */ constructor(scope, id, config = {}) { super(scope, id, { terraformResourceType: 'databricks_account_network_policies', terraformGeneratorMetadata: { providerName: 'databricks', providerVersion: '1.86.0', providerVersionConstraint: '~> 1.0' }, provider: config.provider, dependsOn: config.dependsOn, count: config.count, lifecycle: config.lifecycle, provisioners: config.provisioners, connection: config.connection, forEach: config.forEach }); // ========== // ATTRIBUTES // ========== // items - computed: true, optional: false, required: false this._items = new DataDatabricksAccountNetworkPoliciesItemsList(this, "items", false); } get items() { return this._items; } // ========= // SYNTHESIS // ========= synthesizeAttributes() { return {}; } synthesizeHclAttributes() { const attrs = {}; return attrs; } } exports.DataDatabricksAccountNetworkPolicies = DataDatabricksAccountNetworkPolicies; _k = JSII_RTTI_SYMBOL_1; DataDatabricksAccountNetworkPolicies[_k] = { fqn: "@cdktf/provider-databricks.dataDatabricksAccountNetworkPolicies.DataDatabricksAccountNetworkPolicies", version: "15.3.1" }; // ================= // STATIC PROPERTIES // ================= DataDatabricksAccountNetworkPolicies.tfResourceType = "databricks_account_network_policies"; //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvZGF0YS1kYXRhYnJpY2tzLWFjY291bnQtbmV0d29yay1wb2xpY2llcy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7O0FBMEJBLGdOQVNDO0FBR0Qsc05Bc0JDO0FBK0hELDhNQVlDO0FBR0Qsb05Bd0NDO0FBcUxELDRMQVNDO0FBR0Qsa01Bc0JDO0FBcUdELDBKQVdDO0FBR0QsZ0tBa0NDO0FBa0lELGdJQVFDO0FBR0Qsc0lBZ0JDO0FBMkVELG9IQVVDO0FBR0QsMEhBNEJDOztBQXQyQkQsK0JBQStCO0FBaUIvQixTQUFnQixrR0FBa0csQ0FBQyxNQUFvSDtJQUNyTyxJQUFJLENBQUMsS0FBSyxDQUFDLFVBQVUsQ0FBQyxNQUFNLENBQUMsSUFBSSxLQUFLLENBQUMsWUFBWSxDQUFDLFlBQVksQ0FBQyxNQUFNLENBQUMsRUFBRSxDQUFDO1FBQUMsT0FBTyxNQUFNLENBQUM7SUFBQyxDQUFDO0lBQzVGLElBQUksS0FBSyxDQUFDLGdCQUFnQixDQUFDLE1BQU0sQ0FBQyxFQUFFLENBQUM7UUFDbkMsTUFBTSxJQUFJLEtBQUssQ0FBQyxvSEFBb0gsQ0FBQyxDQUFDO0lBQ3hJLENBQUM7SUFDRCxPQUFPO1FBQ0wsV0FBVyxFQUFFLEtBQUssQ0FBQyxpQkFBaUIsQ0FBQyxNQUFPLENBQUMsV0FBVyxDQUFDO1FBQ3p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