UNPKG

rhizo-co-terraform-provider-oci

Version:

Prebuilt oci Provider for Terraform CDK (cdktf)

1,250 lines 198 kB
"use strict"; var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l; Object.defineProperty(exports, "__esModule", { value: true }); exports.KmsKey = exports.KmsKeyTimeoutsOutputReference = exports.kmsKeyTimeoutsToHclTerraform = exports.kmsKeyTimeoutsToTerraform = exports.KmsKeyRestoreFromObjectStoreOutputReference = exports.kmsKeyRestoreFromObjectStoreToHclTerraform = exports.kmsKeyRestoreFromObjectStoreToTerraform = exports.KmsKeyRestoreFromFileOutputReference = exports.kmsKeyRestoreFromFileToHclTerraform = exports.kmsKeyRestoreFromFileToTerraform = exports.KmsKeyKeyShapeOutputReference = exports.kmsKeyKeyShapeToHclTerraform = exports.kmsKeyKeyShapeToTerraform = exports.KmsKeyExternalKeyReferenceOutputReference = exports.kmsKeyExternalKeyReferenceToHclTerraform = exports.kmsKeyExternalKeyReferenceToTerraform = exports.KmsKeyAutoKeyRotationDetailsOutputReference = exports.kmsKeyAutoKeyRotationDetailsToHclTerraform = exports.kmsKeyAutoKeyRotationDetailsToTerraform = exports.KmsKeyReplicaDetailsList = exports.KmsKeyReplicaDetailsOutputReference = exports.kmsKeyReplicaDetailsToHclTerraform = exports.kmsKeyReplicaDetailsToTerraform = exports.KmsKeyExternalKeyReferenceDetailsList = exports.KmsKeyExternalKeyReferenceDetailsOutputReference = exports.kmsKeyExternalKeyReferenceDetailsToHclTerraform = exports.kmsKeyExternalKeyReferenceDetailsToTerraform = void 0; const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti"); const cdktf = require("cdktf"); function kmsKeyExternalKeyReferenceDetailsToTerraform(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 {}; } exports.kmsKeyExternalKeyReferenceDetailsToTerraform = kmsKeyExternalKeyReferenceDetailsToTerraform; function kmsKeyExternalKeyReferenceDetailsToHclTerraform(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 = {}; return attrs; } exports.kmsKeyExternalKeyReferenceDetailsToHclTerraform = kmsKeyExternalKeyReferenceDetailsToHclTerraform; class KmsKeyExternalKeyReferenceDetailsOutputReference 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() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; } else { this.isEmptyObject = Object.keys(value).length === 0; } } // external_key_id - computed: true, optional: false, required: false get externalKeyId() { return this.getStringAttribute('external_key_id'); } // external_key_version_id - computed: true, optional: false, required: false get externalKeyVersionId() { return this.getStringAttribute('external_key_version_id'); } } exports.KmsKeyExternalKeyReferenceDetailsOutputReference = KmsKeyExternalKeyReferenceDetailsOutputReference; _a = JSII_RTTI_SYMBOL_1; KmsKeyExternalKeyReferenceDetailsOutputReference[_a] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyExternalKeyReferenceDetailsOutputReference", version: "1.0.0" }; class KmsKeyExternalKeyReferenceDetailsList 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 KmsKeyExternalKeyReferenceDetailsOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.KmsKeyExternalKeyReferenceDetailsList = KmsKeyExternalKeyReferenceDetailsList; _b = JSII_RTTI_SYMBOL_1; KmsKeyExternalKeyReferenceDetailsList[_b] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyExternalKeyReferenceDetailsList", version: "1.0.0" }; function kmsKeyReplicaDetailsToTerraform(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 {}; } exports.kmsKeyReplicaDetailsToTerraform = kmsKeyReplicaDetailsToTerraform; function kmsKeyReplicaDetailsToHclTerraform(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 = {}; return attrs; } exports.kmsKeyReplicaDetailsToHclTerraform = kmsKeyReplicaDetailsToHclTerraform; class KmsKeyReplicaDetailsOutputReference 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() { let hasAnyValues = this.isEmptyObject; const internalValueResult = {}; return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; } else { this.isEmptyObject = Object.keys(value).length === 0; } } // replication_id - computed: true, optional: false, required: false get replicationId() { return this.getStringAttribute('replication_id'); } } exports.KmsKeyReplicaDetailsOutputReference = KmsKeyReplicaDetailsOutputReference; _c = JSII_RTTI_SYMBOL_1; KmsKeyReplicaDetailsOutputReference[_c] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyReplicaDetailsOutputReference", version: "1.0.0" }; class KmsKeyReplicaDetailsList 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 KmsKeyReplicaDetailsOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet); } } exports.KmsKeyReplicaDetailsList = KmsKeyReplicaDetailsList; _d = JSII_RTTI_SYMBOL_1; KmsKeyReplicaDetailsList[_d] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyReplicaDetailsList", version: "1.0.0" }; function kmsKeyAutoKeyRotationDetailsToTerraform(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 { last_rotation_message: cdktf.stringToTerraform(struct.lastRotationMessage), last_rotation_status: cdktf.stringToTerraform(struct.lastRotationStatus), rotation_interval_in_days: cdktf.numberToTerraform(struct.rotationIntervalInDays), time_of_last_rotation: cdktf.stringToTerraform(struct.timeOfLastRotation), time_of_next_rotation: cdktf.stringToTerraform(struct.timeOfNextRotation), time_of_schedule_start: cdktf.stringToTerraform(struct.timeOfScheduleStart), }; } exports.kmsKeyAutoKeyRotationDetailsToTerraform = kmsKeyAutoKeyRotationDetailsToTerraform; function kmsKeyAutoKeyRotationDetailsToHclTerraform(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 = { last_rotation_message: { value: cdktf.stringToHclTerraform(struct.lastRotationMessage), isBlock: false, type: "simple", storageClassType: "string", }, last_rotation_status: { value: cdktf.stringToHclTerraform(struct.lastRotationStatus), isBlock: false, type: "simple", storageClassType: "string", }, rotation_interval_in_days: { value: cdktf.numberToHclTerraform(struct.rotationIntervalInDays), isBlock: false, type: "simple", storageClassType: "number", }, time_of_last_rotation: { value: cdktf.stringToHclTerraform(struct.timeOfLastRotation), isBlock: false, type: "simple", storageClassType: "string", }, time_of_next_rotation: { value: cdktf.stringToHclTerraform(struct.timeOfNextRotation), isBlock: false, type: "simple", storageClassType: "string", }, time_of_schedule_start: { value: cdktf.stringToHclTerraform(struct.timeOfScheduleStart), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } exports.kmsKeyAutoKeyRotationDetailsToHclTerraform = kmsKeyAutoKeyRotationDetailsToHclTerraform; class KmsKeyAutoKeyRotationDetailsOutputReference 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._lastRotationMessage !== undefined) { hasAnyValues = true; internalValueResult.lastRotationMessage = this._lastRotationMessage; } if (this._lastRotationStatus !== undefined) { hasAnyValues = true; internalValueResult.lastRotationStatus = this._lastRotationStatus; } if (this._rotationIntervalInDays !== undefined) { hasAnyValues = true; internalValueResult.rotationIntervalInDays = this._rotationIntervalInDays; } if (this._timeOfLastRotation !== undefined) { hasAnyValues = true; internalValueResult.timeOfLastRotation = this._timeOfLastRotation; } if (this._timeOfNextRotation !== undefined) { hasAnyValues = true; internalValueResult.timeOfNextRotation = this._timeOfNextRotation; } if (this._timeOfScheduleStart !== undefined) { hasAnyValues = true; internalValueResult.timeOfScheduleStart = this._timeOfScheduleStart; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._lastRotationMessage = undefined; this._lastRotationStatus = undefined; this._rotationIntervalInDays = undefined; this._timeOfLastRotation = undefined; this._timeOfNextRotation = undefined; this._timeOfScheduleStart = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._lastRotationMessage = value.lastRotationMessage; this._lastRotationStatus = value.lastRotationStatus; this._rotationIntervalInDays = value.rotationIntervalInDays; this._timeOfLastRotation = value.timeOfLastRotation; this._timeOfNextRotation = value.timeOfNextRotation; this._timeOfScheduleStart = value.timeOfScheduleStart; } } get lastRotationMessage() { return this.getStringAttribute('last_rotation_message'); } set lastRotationMessage(value) { this._lastRotationMessage = value; } resetLastRotationMessage() { this._lastRotationMessage = undefined; } // Temporarily expose input value. Use with caution. get lastRotationMessageInput() { return this._lastRotationMessage; } get lastRotationStatus() { return this.getStringAttribute('last_rotation_status'); } set lastRotationStatus(value) { this._lastRotationStatus = value; } resetLastRotationStatus() { this._lastRotationStatus = undefined; } // Temporarily expose input value. Use with caution. get lastRotationStatusInput() { return this._lastRotationStatus; } get rotationIntervalInDays() { return this.getNumberAttribute('rotation_interval_in_days'); } set rotationIntervalInDays(value) { this._rotationIntervalInDays = value; } resetRotationIntervalInDays() { this._rotationIntervalInDays = undefined; } // Temporarily expose input value. Use with caution. get rotationIntervalInDaysInput() { return this._rotationIntervalInDays; } get timeOfLastRotation() { return this.getStringAttribute('time_of_last_rotation'); } set timeOfLastRotation(value) { this._timeOfLastRotation = value; } resetTimeOfLastRotation() { this._timeOfLastRotation = undefined; } // Temporarily expose input value. Use with caution. get timeOfLastRotationInput() { return this._timeOfLastRotation; } get timeOfNextRotation() { return this.getStringAttribute('time_of_next_rotation'); } set timeOfNextRotation(value) { this._timeOfNextRotation = value; } resetTimeOfNextRotation() { this._timeOfNextRotation = undefined; } // Temporarily expose input value. Use with caution. get timeOfNextRotationInput() { return this._timeOfNextRotation; } get timeOfScheduleStart() { return this.getStringAttribute('time_of_schedule_start'); } set timeOfScheduleStart(value) { this._timeOfScheduleStart = value; } resetTimeOfScheduleStart() { this._timeOfScheduleStart = undefined; } // Temporarily expose input value. Use with caution. get timeOfScheduleStartInput() { return this._timeOfScheduleStart; } } exports.KmsKeyAutoKeyRotationDetailsOutputReference = KmsKeyAutoKeyRotationDetailsOutputReference; _e = JSII_RTTI_SYMBOL_1; KmsKeyAutoKeyRotationDetailsOutputReference[_e] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyAutoKeyRotationDetailsOutputReference", version: "1.0.0" }; function kmsKeyExternalKeyReferenceToTerraform(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 { external_key_id: cdktf.stringToTerraform(struct.externalKeyId), }; } exports.kmsKeyExternalKeyReferenceToTerraform = kmsKeyExternalKeyReferenceToTerraform; function kmsKeyExternalKeyReferenceToHclTerraform(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 = { external_key_id: { value: cdktf.stringToHclTerraform(struct.externalKeyId), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } exports.kmsKeyExternalKeyReferenceToHclTerraform = kmsKeyExternalKeyReferenceToHclTerraform; class KmsKeyExternalKeyReferenceOutputReference 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._externalKeyId !== undefined) { hasAnyValues = true; internalValueResult.externalKeyId = this._externalKeyId; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._externalKeyId = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._externalKeyId = value.externalKeyId; } } get externalKeyId() { return this.getStringAttribute('external_key_id'); } set externalKeyId(value) { this._externalKeyId = value; } // Temporarily expose input value. Use with caution. get externalKeyIdInput() { return this._externalKeyId; } } exports.KmsKeyExternalKeyReferenceOutputReference = KmsKeyExternalKeyReferenceOutputReference; _f = JSII_RTTI_SYMBOL_1; KmsKeyExternalKeyReferenceOutputReference[_f] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyExternalKeyReferenceOutputReference", version: "1.0.0" }; function kmsKeyKeyShapeToTerraform(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 { algorithm: cdktf.stringToTerraform(struct.algorithm), curve_id: cdktf.stringToTerraform(struct.curveId), length: cdktf.numberToTerraform(struct.length), }; } exports.kmsKeyKeyShapeToTerraform = kmsKeyKeyShapeToTerraform; function kmsKeyKeyShapeToHclTerraform(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 = { algorithm: { value: cdktf.stringToHclTerraform(struct.algorithm), isBlock: false, type: "simple", storageClassType: "string", }, curve_id: { value: cdktf.stringToHclTerraform(struct.curveId), isBlock: false, type: "simple", storageClassType: "string", }, length: { value: cdktf.numberToHclTerraform(struct.length), isBlock: false, type: "simple", storageClassType: "number", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } exports.kmsKeyKeyShapeToHclTerraform = kmsKeyKeyShapeToHclTerraform; class KmsKeyKeyShapeOutputReference 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._algorithm !== undefined) { hasAnyValues = true; internalValueResult.algorithm = this._algorithm; } if (this._curveId !== undefined) { hasAnyValues = true; internalValueResult.curveId = this._curveId; } if (this._length !== undefined) { hasAnyValues = true; internalValueResult.length = this._length; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._algorithm = undefined; this._curveId = undefined; this._length = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._algorithm = value.algorithm; this._curveId = value.curveId; this._length = value.length; } } get algorithm() { return this.getStringAttribute('algorithm'); } set algorithm(value) { this._algorithm = value; } // Temporarily expose input value. Use with caution. get algorithmInput() { return this._algorithm; } get curveId() { return this.getStringAttribute('curve_id'); } set curveId(value) { this._curveId = value; } resetCurveId() { this._curveId = undefined; } // Temporarily expose input value. Use with caution. get curveIdInput() { return this._curveId; } get length() { return this.getNumberAttribute('length'); } set length(value) { this._length = value; } // Temporarily expose input value. Use with caution. get lengthInput() { return this._length; } } exports.KmsKeyKeyShapeOutputReference = KmsKeyKeyShapeOutputReference; _g = JSII_RTTI_SYMBOL_1; KmsKeyKeyShapeOutputReference[_g] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyKeyShapeOutputReference", version: "1.0.0" }; function kmsKeyRestoreFromFileToTerraform(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 { content_length: cdktf.stringToTerraform(struct.contentLength), content_md5: cdktf.stringToTerraform(struct.contentMd5), restore_key_from_file_details: cdktf.stringToTerraform(struct.restoreKeyFromFileDetails), }; } exports.kmsKeyRestoreFromFileToTerraform = kmsKeyRestoreFromFileToTerraform; function kmsKeyRestoreFromFileToHclTerraform(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 = { content_length: { value: cdktf.stringToHclTerraform(struct.contentLength), isBlock: false, type: "simple", storageClassType: "string", }, content_md5: { value: cdktf.stringToHclTerraform(struct.contentMd5), isBlock: false, type: "simple", storageClassType: "string", }, restore_key_from_file_details: { value: cdktf.stringToHclTerraform(struct.restoreKeyFromFileDetails), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } exports.kmsKeyRestoreFromFileToHclTerraform = kmsKeyRestoreFromFileToHclTerraform; class KmsKeyRestoreFromFileOutputReference 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._contentLength !== undefined) { hasAnyValues = true; internalValueResult.contentLength = this._contentLength; } if (this._contentMd5 !== undefined) { hasAnyValues = true; internalValueResult.contentMd5 = this._contentMd5; } if (this._restoreKeyFromFileDetails !== undefined) { hasAnyValues = true; internalValueResult.restoreKeyFromFileDetails = this._restoreKeyFromFileDetails; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._contentLength = undefined; this._contentMd5 = undefined; this._restoreKeyFromFileDetails = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._contentLength = value.contentLength; this._contentMd5 = value.contentMd5; this._restoreKeyFromFileDetails = value.restoreKeyFromFileDetails; } } get contentLength() { return this.getStringAttribute('content_length'); } set contentLength(value) { this._contentLength = value; } // Temporarily expose input value. Use with caution. get contentLengthInput() { return this._contentLength; } get contentMd5() { return this.getStringAttribute('content_md5'); } set contentMd5(value) { this._contentMd5 = value; } resetContentMd5() { this._contentMd5 = undefined; } // Temporarily expose input value. Use with caution. get contentMd5Input() { return this._contentMd5; } get restoreKeyFromFileDetails() { return this.getStringAttribute('restore_key_from_file_details'); } set restoreKeyFromFileDetails(value) { this._restoreKeyFromFileDetails = value; } // Temporarily expose input value. Use with caution. get restoreKeyFromFileDetailsInput() { return this._restoreKeyFromFileDetails; } } exports.KmsKeyRestoreFromFileOutputReference = KmsKeyRestoreFromFileOutputReference; _h = JSII_RTTI_SYMBOL_1; KmsKeyRestoreFromFileOutputReference[_h] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyRestoreFromFileOutputReference", version: "1.0.0" }; function kmsKeyRestoreFromObjectStoreToTerraform(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 { bucket: cdktf.stringToTerraform(struct.bucket), destination: cdktf.stringToTerraform(struct.destination), namespace: cdktf.stringToTerraform(struct.namespace), object: cdktf.stringToTerraform(struct.object), uri: cdktf.stringToTerraform(struct.uri), }; } exports.kmsKeyRestoreFromObjectStoreToTerraform = kmsKeyRestoreFromObjectStoreToTerraform; function kmsKeyRestoreFromObjectStoreToHclTerraform(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 = { bucket: { value: cdktf.stringToHclTerraform(struct.bucket), isBlock: false, type: "simple", storageClassType: "string", }, destination: { value: cdktf.stringToHclTerraform(struct.destination), isBlock: false, type: "simple", storageClassType: "string", }, namespace: { value: cdktf.stringToHclTerraform(struct.namespace), isBlock: false, type: "simple", storageClassType: "string", }, object: { value: cdktf.stringToHclTerraform(struct.object), isBlock: false, type: "simple", storageClassType: "string", }, uri: { value: cdktf.stringToHclTerraform(struct.uri), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } exports.kmsKeyRestoreFromObjectStoreToHclTerraform = kmsKeyRestoreFromObjectStoreToHclTerraform; class KmsKeyRestoreFromObjectStoreOutputReference 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._bucket !== undefined) { hasAnyValues = true; internalValueResult.bucket = this._bucket; } if (this._destination !== undefined) { hasAnyValues = true; internalValueResult.destination = this._destination; } if (this._namespace !== undefined) { hasAnyValues = true; internalValueResult.namespace = this._namespace; } if (this._object !== undefined) { hasAnyValues = true; internalValueResult.object = this._object; } if (this._uri !== undefined) { hasAnyValues = true; internalValueResult.uri = this._uri; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this._bucket = undefined; this._destination = undefined; this._namespace = undefined; this._object = undefined; this._uri = undefined; } else { this.isEmptyObject = Object.keys(value).length === 0; this._bucket = value.bucket; this._destination = value.destination; this._namespace = value.namespace; this._object = value.object; this._uri = value.uri; } } get bucket() { return this.getStringAttribute('bucket'); } set bucket(value) { this._bucket = value; } resetBucket() { this._bucket = undefined; } // Temporarily expose input value. Use with caution. get bucketInput() { return this._bucket; } get destination() { return this.getStringAttribute('destination'); } set destination(value) { this._destination = value; } // Temporarily expose input value. Use with caution. get destinationInput() { return this._destination; } get namespace() { return this.getStringAttribute('namespace'); } set namespace(value) { this._namespace = value; } resetNamespace() { this._namespace = undefined; } // Temporarily expose input value. Use with caution. get namespaceInput() { return this._namespace; } get object() { return this.getStringAttribute('object'); } set object(value) { this._object = value; } resetObject() { this._object = undefined; } // Temporarily expose input value. Use with caution. get objectInput() { return this._object; } get uri() { return this.getStringAttribute('uri'); } set uri(value) { this._uri = value; } resetUri() { this._uri = undefined; } // Temporarily expose input value. Use with caution. get uriInput() { return this._uri; } } exports.KmsKeyRestoreFromObjectStoreOutputReference = KmsKeyRestoreFromObjectStoreOutputReference; _j = JSII_RTTI_SYMBOL_1; KmsKeyRestoreFromObjectStoreOutputReference[_j] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyRestoreFromObjectStoreOutputReference", version: "1.0.0" }; function kmsKeyTimeoutsToTerraform(struct) { if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) { return struct; } if (cdktf.isComplexElement(struct)) { throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration"); } return { create: cdktf.stringToTerraform(struct.create), delete: cdktf.stringToTerraform(struct.delete), update: cdktf.stringToTerraform(struct.update), }; } exports.kmsKeyTimeoutsToTerraform = kmsKeyTimeoutsToTerraform; function kmsKeyTimeoutsToHclTerraform(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 = { create: { value: cdktf.stringToHclTerraform(struct.create), isBlock: false, type: "simple", storageClassType: "string", }, delete: { value: cdktf.stringToHclTerraform(struct.delete), isBlock: false, type: "simple", storageClassType: "string", }, update: { value: cdktf.stringToHclTerraform(struct.update), isBlock: false, type: "simple", storageClassType: "string", }, }; // remove undefined attributes return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined)); } exports.kmsKeyTimeoutsToHclTerraform = kmsKeyTimeoutsToHclTerraform; class KmsKeyTimeoutsOutputReference 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._create !== undefined) { hasAnyValues = true; internalValueResult.create = this._create; } if (this._delete !== undefined) { hasAnyValues = true; internalValueResult.delete = this._delete; } if (this._update !== undefined) { hasAnyValues = true; internalValueResult.update = this._update; } return hasAnyValues ? internalValueResult : undefined; } set internalValue(value) { if (value === undefined) { this.isEmptyObject = false; this.resolvableValue = undefined; this._create = undefined; this._delete = undefined; this._update = 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._create = value.create; this._delete = value.delete; this._update = value.update; } } get create() { return this.getStringAttribute('create'); } set create(value) { this._create = value; } resetCreate() { this._create = undefined; } // Temporarily expose input value. Use with caution. get createInput() { return this._create; } get delete() { return this.getStringAttribute('delete'); } set delete(value) { this._delete = value; } resetDelete() { this._delete = undefined; } // Temporarily expose input value. Use with caution. get deleteInput() { return this._delete; } get update() { return this.getStringAttribute('update'); } set update(value) { this._update = value; } resetUpdate() { this._update = undefined; } // Temporarily expose input value. Use with caution. get updateInput() { return this._update; } } exports.KmsKeyTimeoutsOutputReference = KmsKeyTimeoutsOutputReference; _k = JSII_RTTI_SYMBOL_1; KmsKeyTimeoutsOutputReference[_k] = { fqn: "rhizo-co-terraform-provider-oci.kmsKey.KmsKeyTimeoutsOutputReference", version: "1.0.0" }; /** * Represents a {@link https://registry.terraform.io/providers/oracle/oci/6.18.0/docs/resources/kms_key oci_kms_key} */ class KmsKey extends cdktf.TerraformResource { // ============== // STATIC Methods // ============== /** * Generates CDKTF code for importing a KmsKey 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 KmsKey to import * @param importFromId The id of the existing KmsKey that should be imported. Refer to the {@link https://registry.terraform.io/providers/oracle/oci/6.18.0/docs/resources/kms_key#import import section} in the documentation of this resource for the id to use * @param provider? Optional instance of the provider where the KmsKey to import is found */ static generateConfigForImport(scope, importToId, importFromId, provider) { return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "oci_kms_key", importId: importFromId, provider }); } // =========== // INITIALIZER // =========== /** * Create a new {@link https://registry.terraform.io/providers/oracle/oci/6.18.0/docs/resources/kms_key oci_kms_key} Resource * * @param scope The scope in which to define this construct * @param id The scoped construct ID. Must be unique amongst siblings in the same scope * @param options KmsKeyConfig */ constructor(scope, id, config) { super(scope, id, { terraformResourceType: 'oci_kms_key', terraformGeneratorMetadata: { providerName: 'oci', providerVersion: '6.18.0', providerVersionConstraint: '~> 6.18.0' }, provider: config.provider, dependsOn: config.dependsOn, count: config.count, lifecycle: config.lifecycle, provisioners: config.provisioners, connection: config.connection, forEach: config.forEach }); // external_key_reference_details - computed: true, optional: false, required: false this._externalKeyReferenceDetails = new KmsKeyExternalKeyReferenceDetailsList(this, "external_key_reference_details", false); // replica_details - computed: true, optional: false, required: false this._replicaDetails = new KmsKeyReplicaDetailsList(this, "replica_details", false); // auto_key_rotation_details - computed: false, optional: true, required: false this._autoKeyRotationDetails = new KmsKeyAutoKeyRotationDetailsOutputReference(this, "auto_key_rotation_details"); // external_key_reference - computed: false, optional: true, required: false this._externalKeyReference = new KmsKeyExternalKeyReferenceOutputReference(this, "external_key_reference"); // key_shape - computed: false, optional: false, required: true this._keyShape = new KmsKeyKeyShapeOutputReference(this, "key_shape"); // restore_from_file - computed: false, optional: true, required: false this._restoreFromFile = new KmsKeyRestoreFromFileOutputReference(this, "restore_from_file"); // restore_from_object_store - computed: false, optional: true, required: false this._restoreFromObjectStore = new KmsKeyRestoreFromObjectStoreOutputReference(this, "restore_from_object_store"); // timeouts - computed: false, optional: true, required: false this._timeouts = new KmsKeyTimeoutsOutputReference(this, "timeouts"); this._compartmentId = config.compartmentId; this._definedTags = config.definedTags; this._desiredState = config.desiredState; this._displayName = config.displayName; this._freeformTags = config.freeformTags; this._id = config.id; this._isAutoRotationEnabled = config.isAutoRotationEnabled; this._managementEndpoint = config.managementEndpoint; this._protectionMode = config.protectionMode; this._restoreTrigger = config.restoreTrigger; this._timeOfDeletion = config.timeOfDeletion; this._autoKeyRotationDetails.internalValue = config.autoKeyRotationDetails; this._externalKeyReference.internalValue = config.externalKeyReference; this._keyShape.internalValue = config.keyShape; this._restoreFromFile.internalValue = config.restoreFromFile; this._restoreFromObjectStore.internalValue = config.restoreFromObjectStore; this._timeouts.internalValue = config.timeouts; } get compartmentId() { return this.getStringAttribute('compartment_id'); } set compartmentId(value) { this._compartmentId = value; } // Temporarily expose input value. Use with caution. get compartmentIdInput() { return this._compartmentId; } // current_key_version - computed: true, optional: false, required: false get currentKeyVersion() { return this.getStringAttribute('current_key_version'); } get definedTags() { return this.getStringMapAttribute('defined_tags'); } set definedTags(value) { this._definedTags = value; } resetDefinedTags() { this._definedTags = undefined; } // Temporarily expose input value. Use with caution. get definedTagsInput() { return this._definedTags; } get desiredState() { return this.getStringAttribute('desired_state'); } set desiredState(value) { this._desiredState = value; } resetDesiredState() { this._desiredState = undefined; } // Temporarily expose input value. Use with caution. get desiredStateInput() { return this._desiredState; } get displayName() { return this.getStringAttribute('display_name'); } set displayName(value) { this._displayName = value; } // Temporarily expose input value. Use with caution. get displayNameInput() { return this._displayName; } get externalKeyReferenceDetails() { return this._externalKeyReferenceDetails; } get freeformTags() { return this.getStringMapAttribute('freeform_tags'); } set freeformTags(value) { this._freeformTags = value; } resetFreeformTags() { this._freeformTags = undefined; } // Temporarily expose input value. Use with caution. get freeformTagsInput() { return this._freeformTags; } 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 isAutoRotationEnabled() { return this.getBooleanAttribute('is_auto_rotation_enabled'); } set isAutoRotationEnabled(value) { this._isAutoRotationEnabled = value; } resetIsAutoRotationEnabled() { this._isAutoRotationEnabled = undefined; } // Temporarily expose input value. Use with caution. get isAutoRotationEnabledInput() { return this._isAutoRotationEnabled; } // is_primary - computed: true, optional: false, required: false get isPrimary() { return this.getBooleanAttribute('is_primary'); } get managementEndpoint() { return this.getStringAttribute('management_endpoint'); } set managementEndpoint(value) { this._managementEndpoint = value; } // Temporarily expose input value. Use with caution. get managementEndpointInput() { return this._managementEndpoint; } get protectionMode() { return this.getStringAttribute('protection_mode'); } set protectionMode(value) { this._protectionMode = value; } resetProtectionMode() { this._protectionMode = undefined; } // Temporarily expose input value. Use with caution. get protectionModeInput() { return this._protectionMode; } get replicaDetails() { return this._replicaDetails; } get restoreTrigger() { return this.getBooleanAttribute('restore_trigger'); } set restoreTrigger(value) { this._restoreTrigger = value; } resetRestoreTrigger() { this._restoreTrigger = undefined; } // Temporarily expose input value. Use with caution. get restoreTriggerInput() { return this._restoreTrigger; } // restored_from_key_id - computed: true, optional: false, required: false get restoredFromKeyId() { return this.getStringAttribute('restored_from_key_id'); } // state - computed: true, optional: false, required: false get state() { return this.getStringAttribute('state'); } // time_created - computed: true, optional: false, required: false get timeCreated() { return this.getStringAttribute('time_created'); } get timeOfDeletion() { return this.getStringAttribute('time_of_deletion'); } set timeOfDeletion(value) { this._timeOfDeletion = value; } resetTimeOfDeletion() { this._timeOfDeletion = undefined; } // Temporarily expose input value. Use with caution. get timeOfDeletionInput() { return this._timeOfDeletion; } // vault_id - computed: true, optional: false, required: false get vaultId() { return this.getStringAttribute('vault_id'); } get autoKeyRotationDetails() { return this._autoKeyRotationDetails; } putAutoKeyRotationDetails(value) { this._autoKeyRotationDetails.internalValue = value; } resetAutoKeyRotationDetails() { this._autoKeyRotationDetails.internalValue = undefined; } // Temporarily expose input value. Use with caution. get autoKeyRotationDetailsInput() { return this._autoKeyRotat