UNPKG

@cdktf/provider-databricks

Version:

Prebuilt databricks Provider for Terraform CDK (cdktf)

1,300 lines 175 kB
"use strict"; var _a, _b, _c, _d, _e, _f, _g, _h; Object.defineProperty(exports, "__esModule", { value: true }); exports.DataDatabricksSqlWarehouse = exports.DataDatabricksSqlWarehouseTagsOutputReference = exports.DataDatabricksSqlWarehouseTagsCustomTagsList = exports.DataDatabricksSqlWarehouseTagsCustomTagsOutputReference = exports.DataDatabricksSqlWarehouseOdbcParamsOutputReference = exports.DataDatabricksSqlWarehouseHealthOutputReference = exports.DataDatabricksSqlWarehouseHealthFailureReasonOutputReference = exports.DataDatabricksSqlWarehouseChannelOutputReference = void 0; exports.dataDatabricksSqlWarehouseChannelToTerraform = dataDatabricksSqlWarehouseChannelToTerraform; exports.dataDatabricksSqlWarehouseChannelToHclTerraform = dataDatabricksSqlWarehouseChannelToHclTerraform; exports.dataDatabricksSqlWarehouseHealthFailureReasonToTerraform = dataDatabricksSqlWarehouseHealthFailureReasonToTerraform; exports.dataDatabricksSqlWarehouseHealthFailureReasonToHclTerraform = dataDatabricksSqlWarehouseHealthFailureReasonToHclTerraform; exports.dataDatabricksSqlWarehouseHealthToTerraform = dataDatabricksSqlWarehouseHealthToTerraform; exports.dataDatabricksSqlWarehouseHealthToHclTerraform = dataDatabricksSqlWarehouseHealthToHclTerraform; exports.dataDatabricksSqlWarehouseOdbcParamsToTerraform = dataDatabricksSqlWarehouseOdbcParamsToTerraform; exports.dataDatabricksSqlWarehouseOdbcParamsToHclTerraform = dataDatabricksSqlWarehouseOdbcParamsToHclTerraform; exports.dataDatabricksSqlWarehouseTagsCustomTagsToTerraform = dataDatabricksSqlWarehouseTagsCustomTagsToTerraform; exports.dataDatabricksSqlWarehouseTagsCustomTagsToHclTerraform = dataDatabricksSqlWarehouseTagsCustomTagsToHclTerraform; exports.dataDatabricksSqlWarehouseTagsToTerraform = dataDatabricksSqlWarehouseTagsToTerraform; exports.dataDatabricksSqlWarehouseTagsToHclTerraform = dataDatabricksSqlWarehouseTagsToHclTerraform; const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); const cdktf = require("cdktf"); function dataDatabricksSqlWarehouseChannelToTerraform(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 { dbsql_version: cdktf.stringToTerraform(struct.dbsqlVersion), name: cdktf.stringToTerraform(struct.name), }; } function dataDatabricksSqlWarehouseChannelToHclTerraform(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 = { dbsql_version: { value: cdktf.stringToHclTerraform(struct.dbsqlVersion), isBlock: false, type: "simple", storageClassType: "string", }, name: { value: cdktf.stringToHclTerraform(struct.name), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksSqlWarehouseChannelOutputReference 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._dbsqlVersion !== undefined) { hasAnyValues = true; internalValueResult.dbsqlVersion = this._dbsqlVersion; } if (this._name !== undefined) { hasAnyValues = true; internalValueResult.name = this._name; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._dbsqlVersion = undefined; this._name = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._dbsqlVersion = value.dbsqlVersion; this._name = value.name; } } get dbsqlVersion() { return this.getStringAttribute('dbsql_version'); } set dbsqlVersion(value) { this._dbsqlVersion = value; } resetDbsqlVersion() { this._dbsqlVersion = undefined; } // Temporarily expose input value. Use with caution. get dbsqlVersionInput() { return this._dbsqlVersion; } get name() { return this.getStringAttribute('name'); } set name(value) { this._name = value; } resetName() { this._name = undefined; } // Temporarily expose input value. Use with caution. get nameInput() { return this._name; } } exports.DataDatabricksSqlWarehouseChannelOutputReference = DataDatabricksSqlWarehouseChannelOutputReference; _a = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouseChannelOutputReference[_a] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouseChannelOutputReference", version: "15.3.1" }; function dataDatabricksSqlWarehouseHealthFailureReasonToTerraform(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 { code: cdktf.stringToTerraform(struct.code), parameters: cdktf.hashMapper(cdktf.stringToTerraform)(struct.parameters), type: cdktf.stringToTerraform(struct.type), }; } function dataDatabricksSqlWarehouseHealthFailureReasonToHclTerraform(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 = { code: { value: cdktf.stringToHclTerraform(struct.code), isBlock: false, type: "simple", storageClassType: "string", }, parameters: { value: cdktf.hashMapperHcl(cdktf.stringToHclTerraform)(struct.parameters), isBlock: false, type: "map", storageClassType: "stringMap", }, type: { value: cdktf.stringToHclTerraform(struct.type), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksSqlWarehouseHealthFailureReasonOutputReference 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._code !== undefined) { hasAnyValues = true; internalValueResult.code = this._code; } if (this._parameters !== undefined) { hasAnyValues = true; internalValueResult.parameters = this._parameters; } if (this._type !== undefined) { hasAnyValues = true; internalValueResult.type = this._type; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._code = undefined; this._parameters = undefined; this._type = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._code = value.code; this._parameters = value.parameters; this._type = value.type; } } get code() { return this.getStringAttribute('code'); } set code(value) { this._code = value; } resetCode() { this._code = undefined; } // Temporarily expose input value. Use with caution. get codeInput() { return this._code; } get parameters() { return this.getStringMapAttribute('parameters'); } set parameters(value) { this._parameters = value; } resetParameters() { this._parameters = undefined; } // Temporarily expose input value. Use with caution. get parametersInput() { return this._parameters; } get type() { return this.getStringAttribute('type'); } set type(value) { this._type = value; } resetType() { this._type = undefined; } // Temporarily expose input value. Use with caution. get typeInput() { return this._type; } } exports.DataDatabricksSqlWarehouseHealthFailureReasonOutputReference = DataDatabricksSqlWarehouseHealthFailureReasonOutputReference; _b = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouseHealthFailureReasonOutputReference[_b] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouseHealthFailureReasonOutputReference", version: "15.3.1" }; function dataDatabricksSqlWarehouseHealthToTerraform(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 { details: cdktf.stringToTerraform(struct.details), message: cdktf.stringToTerraform(struct.message), status: cdktf.stringToTerraform(struct.status), summary: cdktf.stringToTerraform(struct.summary), failure_reason: dataDatabricksSqlWarehouseHealthFailureReasonToTerraform(struct.failureReason), }; } function dataDatabricksSqlWarehouseHealthToHclTerraform(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 = { details: { value: cdktf.stringToHclTerraform(struct.details), isBlock: false, type: "simple", storageClassType: "string", }, message: { value: cdktf.stringToHclTerraform(struct.message), isBlock: false, type: "simple", storageClassType: "string", }, status: { value: cdktf.stringToHclTerraform(struct.status), isBlock: false, type: "simple", storageClassType: "string", }, summary: { value: cdktf.stringToHclTerraform(struct.summary), isBlock: false, type: "simple", storageClassType: "string", }, failure_reason: { value: dataDatabricksSqlWarehouseHealthFailureReasonToHclTerraform(struct.failureReason), isBlock: true, type: "list", storageClassType: "DataDatabricksSqlWarehouseHealthFailureReasonList", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksSqlWarehouseHealthOutputReference 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; // failure_reason - computed: false, optional: true, required: false this._failureReason = new DataDatabricksSqlWarehouseHealthFailureReasonOutputReference(this, "failure_reason"); } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._details !== undefined) { hasAnyValues = true; internalValueResult.details = this._details; } if (this._message !== undefined) { hasAnyValues = true; internalValueResult.message = this._message; } if (this._status !== undefined) { hasAnyValues = true; internalValueResult.status = this._status; } if (this._summary !== undefined) { hasAnyValues = true; internalValueResult.summary = this._summary; } if (this._failureReason?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.failureReason = this._failureReason?.internalValue; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._details = undefined; this._message = undefined; this._status = undefined; this._summary = undefined; this._failureReason.internalValue = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._details = value.details; this._message = value.message; this._status = value.status; this._summary = value.summary; this._failureReason.internalValue = value.failureReason; } } get details() { return this.getStringAttribute('details'); } set details(value) { this._details = value; } resetDetails() { this._details = undefined; } // Temporarily expose input value. Use with caution. get detailsInput() { return this._details; } get message() { return this.getStringAttribute('message'); } set message(value) { this._message = value; } resetMessage() { this._message = undefined; } // Temporarily expose input value. Use with caution. get messageInput() { return this._message; } get status() { return this.getStringAttribute('status'); } set status(value) { this._status = value; } resetStatus() { this._status = undefined; } // Temporarily expose input value. Use with caution. get statusInput() { return this._status; } get summary() { return this.getStringAttribute('summary'); } set summary(value) { this._summary = value; } resetSummary() { this._summary = undefined; } // Temporarily expose input value. Use with caution. get summaryInput() { return this._summary; } get failureReason() { return this._failureReason; } putFailureReason(value) { this._failureReason.internalValue = value; } resetFailureReason() { this._failureReason.internalValue = undefined; } // Temporarily expose input value. Use with caution. get failureReasonInput() { return this._failureReason.internalValue; } } exports.DataDatabricksSqlWarehouseHealthOutputReference = DataDatabricksSqlWarehouseHealthOutputReference; _c = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouseHealthOutputReference[_c] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouseHealthOutputReference", version: "15.3.1" }; function dataDatabricksSqlWarehouseOdbcParamsToTerraform(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 { hostname: cdktf.stringToTerraform(struct.hostname), path: cdktf.stringToTerraform(struct.path), port: cdktf.numberToTerraform(struct.port), protocol: cdktf.stringToTerraform(struct.protocol), }; } function dataDatabricksSqlWarehouseOdbcParamsToHclTerraform(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 = { hostname: { value: cdktf.stringToHclTerraform(struct.hostname), isBlock: false, type: "simple", storageClassType: "string", }, path: { value: cdktf.stringToHclTerraform(struct.path), isBlock: false, type: "simple", storageClassType: "string", }, port: { value: cdktf.numberToHclTerraform(struct.port), isBlock: false, type: "simple", storageClassType: "number", }, protocol: { value: cdktf.stringToHclTerraform(struct.protocol), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksSqlWarehouseOdbcParamsOutputReference 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._hostname !== undefined) { hasAnyValues = true; internalValueResult.hostname = this._hostname; } if (this._path !== undefined) { hasAnyValues = true; internalValueResult.path = this._path; } if (this._port !== undefined) { hasAnyValues = true; internalValueResult.port = this._port; } if (this._protocol !== undefined) { hasAnyValues = true; internalValueResult.protocol = this._protocol; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._hostname = undefined; this._path = undefined; this._port = undefined; this._protocol = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._hostname = value.hostname; this._path = value.path; this._port = value.port; this._protocol = value.protocol; } } get hostname() { return this.getStringAttribute('hostname'); } set hostname(value) { this._hostname = value; } resetHostname() { this._hostname = undefined; } // Temporarily expose input value. Use with caution. get hostnameInput() { return this._hostname; } get path() { return this.getStringAttribute('path'); } set path(value) { this._path = value; } resetPath() { this._path = undefined; } // Temporarily expose input value. Use with caution. get pathInput() { return this._path; } get port() { return this.getNumberAttribute('port'); } set port(value) { this._port = value; } resetPort() { this._port = undefined; } // Temporarily expose input value. Use with caution. get portInput() { return this._port; } get protocol() { return this.getStringAttribute('protocol'); } set protocol(value) { this._protocol = value; } resetProtocol() { this._protocol = undefined; } // Temporarily expose input value. Use with caution. get protocolInput() { return this._protocol; } } exports.DataDatabricksSqlWarehouseOdbcParamsOutputReference = DataDatabricksSqlWarehouseOdbcParamsOutputReference; _d = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouseOdbcParamsOutputReference[_d] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouseOdbcParamsOutputReference", version: "15.3.1" }; function dataDatabricksSqlWarehouseTagsCustomTagsToTerraform(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 { key: cdktf.stringToTerraform(struct.key), value: cdktf.stringToTerraform(struct.value), }; } function dataDatabricksSqlWarehouseTagsCustomTagsToHclTerraform(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 = { key: { value: cdktf.stringToHclTerraform(struct.key), isBlock: false, type: "simple", storageClassType: "string", }, value: { value: cdktf.stringToHclTerraform(struct.value), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksSqlWarehouseTagsCustomTagsOutputReference 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._key !== undefined) { hasAnyValues = true; internalValueResult.key = this._key; } if (this._value !== undefined) { hasAnyValues = true; internalValueResult.value = this._value; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._key = undefined; this._value = 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._key = value.key; this._value = value.value; } } get key() { return this.getStringAttribute('key'); } set key(value) { this._key = value; } resetKey() { this._key = undefined; } // Temporarily expose input value. Use with caution. get keyInput() { return this._key; } get value() { return this.getStringAttribute('value'); } set value(value) { this._value = value; } resetValue() { this._value = undefined; } // Temporarily expose input value. Use with caution. get valueInput() { return this._value; } } exports.DataDatabricksSqlWarehouseTagsCustomTagsOutputReference = DataDatabricksSqlWarehouseTagsCustomTagsOutputReference; _e = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouseTagsCustomTagsOutputReference[_e] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouseTagsCustomTagsOutputReference", version: "15.3.1" }; class DataDatabricksSqlWarehouseTagsCustomTagsList 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 DataDatabricksSqlWarehouseTagsCustomTagsOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.DataDatabricksSqlWarehouseTagsCustomTagsList = DataDatabricksSqlWarehouseTagsCustomTagsList; _f = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouseTagsCustomTagsList[_f] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouseTagsCustomTagsList", version: "15.3.1" }; function dataDatabricksSqlWarehouseTagsToTerraform(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 { custom_tags: cdktf.listMapper(dataDatabricksSqlWarehouseTagsCustomTagsToTerraform, true)(struct.customTags), }; } function dataDatabricksSqlWarehouseTagsToHclTerraform(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 = { custom_tags: { value: cdktf.listMapperHcl(dataDatabricksSqlWarehouseTagsCustomTagsToHclTerraform, true)(struct.customTags), isBlock: true, type: "list", storageClassType: "DataDatabricksSqlWarehouseTagsCustomTagsList", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } class DataDatabricksSqlWarehouseTagsOutputReference 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; // custom_tags - computed: false, optional: true, required: false this._customTags = new DataDatabricksSqlWarehouseTagsCustomTagsList(this, "custom_tags", false); } get internalValue() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; if (this._customTags?.internalValue !== undefined) { hasAnyValues = true; internalValueResult.customTags = this._customTags?.internalValue; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._customTags.internalValue = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._customTags.internalValue = value.customTags; } } get customTags() { return this._customTags; } putCustomTags(value) { this._customTags.internalValue = value; } resetCustomTags() { this._customTags.internalValue = undefined; } // Temporarily expose input value. Use with caution. get customTagsInput() { return this._customTags.internalValue; } } exports.DataDatabricksSqlWarehouseTagsOutputReference = DataDatabricksSqlWarehouseTagsOutputReference; _g = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouseTagsOutputReference[_g] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouseTagsOutputReference", version: "15.3.1" }; /** * Represents a {@link https://registry.terraform.io/providers/databricks/databricks/1.86.0/docs/data-sources/sql_warehouse databricks_sql_warehouse} */ class DataDatabricksSqlWarehouse extends cdktf.TerraformDataSource { // ============== // STATIC Methods // ============== /** * Generates CDKTF code for importing a DataDatabricksSqlWarehouse 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 DataDatabricksSqlWarehouse to import * @param importFromId The id of the existing DataDatabricksSqlWarehouse that should be imported. Refer to the {@link https://registry.terraform.io/providers/databricks/databricks/1.86.0/docs/data-sources/sql_warehouse#import import section} in the documentation of this resource for the id to use * @param provider? Optional instance of the provider where the DataDatabricksSqlWarehouse to import is found */ static generateConfigForImport(scope, importToId, importFromId, provider) { return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "databricks_sql_warehouse", importId: importFromId, provider }); } // =========== // INITIALIZER // =========== /** * Create a new {@link https://registry.terraform.io/providers/databricks/databricks/1.86.0/docs/data-sources/sql_warehouse databricks_sql_warehouse} 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 DataDatabricksSqlWarehouseConfig = {} */ constructor(scope, id, config = {}) { super(scope, id, { terraformResourceType: 'databricks_sql_warehouse', 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 }); // channel - computed: false, optional: true, required: false this._channel = new DataDatabricksSqlWarehouseChannelOutputReference(this, "channel"); // health - computed: false, optional: true, required: false this._health = new DataDatabricksSqlWarehouseHealthOutputReference(this, "health"); // odbc_params - computed: false, optional: true, required: false this._odbcParams = new DataDatabricksSqlWarehouseOdbcParamsOutputReference(this, "odbc_params"); // tags - computed: false, optional: true, required: false this._tags = new DataDatabricksSqlWarehouseTagsOutputReference(this, "tags"); this._autoStopMins = config.autoStopMins; this._clusterSize = config.clusterSize; this._creatorName = config.creatorName; this._dataSourceId = config.dataSourceId; this._enablePhoton = config.enablePhoton; this._enableServerlessCompute = config.enableServerlessCompute; this._id = config.id; this._instanceProfileArn = config.instanceProfileArn; this._jdbcUrl = config.jdbcUrl; this._maxNumClusters = config.maxNumClusters; this._minNumClusters = config.minNumClusters; this._name = config.name; this._numActiveSessions = config.numActiveSessions; this._numClusters = config.numClusters; this._spotInstancePolicy = config.spotInstancePolicy; this._state = config.state; this._warehouseType = config.warehouseType; this._channel.internalValue = config.channel; this._health.internalValue = config.health; this._odbcParams.internalValue = config.odbcParams; this._tags.internalValue = config.tags; } get autoStopMins() { return this.getNumberAttribute('auto_stop_mins'); } set autoStopMins(value) { this._autoStopMins = value; } resetAutoStopMins() { this._autoStopMins = undefined; } // Temporarily expose input value. Use with caution. get autoStopMinsInput() { return this._autoStopMins; } get clusterSize() { return this.getStringAttribute('cluster_size'); } set clusterSize(value) { this._clusterSize = value; } resetClusterSize() { this._clusterSize = undefined; } // Temporarily expose input value. Use with caution. get clusterSizeInput() { return this._clusterSize; } get creatorName() { return this.getStringAttribute('creator_name'); } set creatorName(value) { this._creatorName = value; } resetCreatorName() { this._creatorName = undefined; } // Temporarily expose input value. Use with caution. get creatorNameInput() { return this._creatorName; } get dataSourceId() { return this.getStringAttribute('data_source_id'); } set dataSourceId(value) { this._dataSourceId = value; } resetDataSourceId() { this._dataSourceId = undefined; } // Temporarily expose input value. Use with caution. get dataSourceIdInput() { return this._dataSourceId; } get enablePhoton() { return this.getBooleanAttribute('enable_photon'); } set enablePhoton(value) { this._enablePhoton = value; } resetEnablePhoton() { this._enablePhoton = undefined; } // Temporarily expose input value. Use with caution. get enablePhotonInput() { return this._enablePhoton; } get enableServerlessCompute() { return this.getBooleanAttribute('enable_serverless_compute'); } set enableServerlessCompute(value) { this._enableServerlessCompute = value; } resetEnableServerlessCompute() { this._enableServerlessCompute = undefined; } // Temporarily expose input value. Use with caution. get enableServerlessComputeInput() { return this._enableServerlessCompute; } get id() { return this.getStringAttribute('id'); } set id(value) { this._id = value; } resetId() { this._id = undefined; } // Temporarily expose input value. Use with caution. get idInput() { return this._id; } get instanceProfileArn() { return this.getStringAttribute('instance_profile_arn'); } set instanceProfileArn(value) { this._instanceProfileArn = value; } resetInstanceProfileArn() { this._instanceProfileArn = undefined; } // Temporarily expose input value. Use with caution. get instanceProfileArnInput() { return this._instanceProfileArn; } get jdbcUrl() { return this.getStringAttribute('jdbc_url'); } set jdbcUrl(value) { this._jdbcUrl = value; } resetJdbcUrl() { this._jdbcUrl = undefined; } // Temporarily expose input value. Use with caution. get jdbcUrlInput() { return this._jdbcUrl; } get maxNumClusters() { return this.getNumberAttribute('max_num_clusters'); } set maxNumClusters(value) { this._maxNumClusters = value; } resetMaxNumClusters() { this._maxNumClusters = undefined; } // Temporarily expose input value. Use with caution. get maxNumClustersInput() { return this._maxNumClusters; } get minNumClusters() { return this.getNumberAttribute('min_num_clusters'); } set minNumClusters(value) { this._minNumClusters = value; } resetMinNumClusters() { this._minNumClusters = undefined; } // Temporarily expose input value. Use with caution. get minNumClustersInput() { return this._minNumClusters; } get name() { return this.getStringAttribute('name'); } set name(value) { this._name = value; } resetName() { this._name = undefined; } // Temporarily expose input value. Use with caution. get nameInput() { return this._name; } get numActiveSessions() { return this.getNumberAttribute('num_active_sessions'); } set numActiveSessions(value) { this._numActiveSessions = value; } resetNumActiveSessions() { this._numActiveSessions = undefined; } // Temporarily expose input value. Use with caution. get numActiveSessionsInput() { return this._numActiveSessions; } get numClusters() { return this.getNumberAttribute('num_clusters'); } set numClusters(value) { this._numClusters = value; } resetNumClusters() { this._numClusters = undefined; } // Temporarily expose input value. Use with caution. get numClustersInput() { return this._numClusters; } get spotInstancePolicy() { return this.getStringAttribute('spot_instance_policy'); } set spotInstancePolicy(value) { this._spotInstancePolicy = value; } resetSpotInstancePolicy() { this._spotInstancePolicy = undefined; } // Temporarily expose input value. Use with caution. get spotInstancePolicyInput() { return this._spotInstancePolicy; } get state() { return this.getStringAttribute('state'); } set state(value) { this._state = value; } resetState() { this._state = undefined; } // Temporarily expose input value. Use with caution. get stateInput() { return this._state; } get warehouseType() { return this.getStringAttribute('warehouse_type'); } set warehouseType(value) { this._warehouseType = value; } resetWarehouseType() { this._warehouseType = undefined; } // Temporarily expose input value. Use with caution. get warehouseTypeInput() { return this._warehouseType; } get channel() { return this._channel; } putChannel(value) { this._channel.internalValue = value; } resetChannel() { this._channel.internalValue = undefined; } // Temporarily expose input value. Use with caution. get channelInput() { return this._channel.internalValue; } get health() { return this._health; } putHealth(value) { this._health.internalValue = value; } resetHealth() { this._health.internalValue = undefined; } // Temporarily expose input value. Use with caution. get healthInput() { return this._health.internalValue; } get odbcParams() { return this._odbcParams; } putOdbcParams(value) { this._odbcParams.internalValue = value; } resetOdbcParams() { this._odbcParams.internalValue = undefined; } // Temporarily expose input value. Use with caution. get odbcParamsInput() { return this._odbcParams.internalValue; } get tags() { return this._tags; } putTags(value) { this._tags.internalValue = value; } resetTags() { this._tags.internalValue = undefined; } // Temporarily expose input value. Use with caution. get tagsInput() { return this._tags.internalValue; } // ========= // SYNTHESIS // ========= synthesizeAttributes() { return { auto_stop_mins: cdktf.numberToTerraform(this._autoStopMins), cluster_size: cdktf.stringToTerraform(this._clusterSize), creator_name: cdktf.stringToTerraform(this._creatorName), data_source_id: cdktf.stringToTerraform(this._dataSourceId), enable_photon: cdktf.booleanToTerraform(this._enablePhoton), enable_serverless_compute: cdktf.booleanToTerraform(this._enableServerlessCompute), id: cdktf.stringToTerraform(this._id), instance_profile_arn: cdktf.stringToTerraform(this._instanceProfileArn), jdbc_url: cdktf.stringToTerraform(this._jdbcUrl), max_num_clusters: cdktf.numberToTerraform(this._maxNumClusters), min_num_clusters: cdktf.numberToTerraform(this._minNumClusters), name: cdktf.stringToTerraform(this._name), num_active_sessions: cdktf.numberToTerraform(this._numActiveSessions), num_clusters: cdktf.numberToTerraform(this._numClusters), spot_instance_policy: cdktf.stringToTerraform(this._spotInstancePolicy), state: cdktf.stringToTerraform(this._state), warehouse_type: cdktf.stringToTerraform(this._warehouseType), channel: dataDatabricksSqlWarehouseChannelToTerraform(this._channel.internalValue), health: dataDatabricksSqlWarehouseHealthToTerraform(this._health.internalValue), odbc_params: dataDatabricksSqlWarehouseOdbcParamsToTerraform(this._odbcParams.internalValue), tags: dataDatabricksSqlWarehouseTagsToTerraform(this._tags.internalValue), }; } synthesizeHclAttributes() { const attrs = { auto_stop_mins: { value: cdktf.numberToHclTerraform(this._autoStopMins), isBlock: false, type: "simple", storageClassType: "number", }, cluster_size: { value: cdktf.stringToHclTerraform(this._clusterSize), isBlock: false, type: "simple", storageClassType: "string", }, creator_name: { value: cdktf.stringToHclTerraform(this._creatorName), isBlock: false, type: "simple", storageClassType: "string", }, data_source_id: { value: cdktf.stringToHclTerraform(this._dataSourceId), isBlock: false, type: "simple", storageClassType: "string", }, enable_photon: { value: cdktf.booleanToHclTerraform(this._enablePhoton), isBlock: false, type: "simple", storageClassType: "boolean", }, enable_serverless_compute: { value: cdktf.booleanToHclTerraform(this._enableServerlessCompute), isBlock: false, type: "simple", storageClassType: "boolean", }, id: { value: cdktf.stringToHclTerraform(this._id), isBlock: false, type: "simple", storageClassType: "string", }, instance_profile_arn: { value: cdktf.stringToHclTerraform(this._instanceProfileArn), isBlock: false, type: "simple", storageClassType: "string", }, jdbc_url: { value: cdktf.stringToHclTerraform(this._jdbcUrl), isBlock: false, type: "simple", storageClassType: "string", }, max_num_clusters: { value: cdktf.numberToHclTerraform(this._maxNumClusters), isBlock: false, type: "simple", storageClassType: "number", }, min_num_clusters: { value: cdktf.numberToHclTerraform(this._minNumClusters), isBlock: false, type: "simple", storageClassType: "number", }, name: { value: cdktf.stringToHclTerraform(this._name), isBlock: false, type: "simple", storageClassType: "string", }, num_active_sessions: { value: cdktf.numberToHclTerraform(this._numActiveSessions), isBlock: false, type: "simple", storageClassType: "number", }, num_clusters: { value: cdktf.numberToHclTerraform(this._numClusters), isBlock: false, type: "simple", storageClassType: "number", }, spot_instance_policy: { value: cdktf.stringToHclTerraform(this._spotInstancePolicy), isBlock: false, type: "simple", storageClassType: "string", }, state: { value: cdktf.stringToHclTerraform(this._state), isBlock: false, type: "simple", storageClassType: "string", }, warehouse_type: { value: cdktf.stringToHclTerraform(this._warehouseType), isBlock: false, type: "simple", storageClassType: "string", }, channel: { value: dataDatabricksSqlWarehouseChannelToHclTerraform(this._channel.internalValue), isBlock: true, type: "list", storageClassType: "DataDatabricksSqlWarehouseChannelList", }, health: { value: dataDatabricksSqlWarehouseHealthToHclTerraform(this._health.internalValue), isBlock: true, type: "list", storageClassType: "DataDatabricksSqlWarehouseHealthList", }, odbc_params: { value: dataDatabricksSqlWarehouseOdbcParamsToHclTerraform(this._odbcParams.internalValue), isBlock: true, type: "list", storageClassType: "DataDatabricksSqlWarehouseOdbcParamsList", }, tags: { value: dataDatabricksSqlWarehouseTagsToHclTerraform(this._tags.internalValue), isBlock: true, type: "list", storageClassType: "DataDatabricksSqlWarehouseTagsList", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } } exports.DataDatabricksSqlWarehouse = DataDatabricksSqlWarehouse; _h = JSII_RTTI_SYMBOL_1; DataDatabricksSqlWarehouse[_h] = { fqn: "@cdktf/provider-databricks.dataDatabricksSqlWarehouse.DataDatabricksSqlWarehouse", version: "15.3.1" }; // ================= // STATIC PROPERTIES // ================= DataDatabricksSqlWarehouse.tfResourceType = "databricks_sql_warehouse"; //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvZGF0YS1kYXRhYnJpY2tzLXNxbC13YXJlaG91c2UvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7OztBQXlIQSxvR0FTQztBQUdELDBHQXNCQztBQXVGRCw0SEFVQztBQUdELGtJQTRCQztBQXVIRCxrR0FZQztBQUdELHdHQXdDQztBQTZKRCwwR0FXQztBQUdELGdIQWtDQztBQStIRCxrSEFTQztBQUdELHdIQXNCQztBQWlIRCw4RkFRQztBQUdELG9HQWdCQzs7QUExN0JELCtCQUErQjtBQWdIL0IsU0FBZ0IsNENBQTRDLENBQUMsTUFBNkY7SUFDeEosSUFBSSxDQUFDLEtBQUssQ0FBQyxVQUFVLENBQUMsTUFBTSxDQUFDLElBQUksS0FBSyxDQUFDLFlBQVksQ0FBQyxZQUFZLENBQUMsTUFBTSxDQUFDLEVBQUUsQ0FBQztRQUFDLE9BQU8sTUFBTSxDQUFDO0lBQUMsQ0FBQztJQ