All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azure.compute.kotlin.inputs.ManagedDiskEncryptionSettingsArgs.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azure.compute.kotlin.inputs

import com.pulumi.azure.compute.inputs.ManagedDiskEncryptionSettingsArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.Deprecated
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 *
 * @property diskEncryptionKey A `disk_encryption_key` block as defined above.
 * @property enabled
 * @property keyEncryptionKey A `key_encryption_key` block as defined below.
 */
public data class ManagedDiskEncryptionSettingsArgs(
    public val diskEncryptionKey: Output? = null,
    @Deprecated(
        message = """
  Deprecated, Azure Disk Encryption is now configured directly by `disk_encryption_key` and
      `key_encryption_key`. To disable Azure Disk Encryption, please remove `encryption_settings`
      block. To enabled, specify a `encryption_settings` block`
  """,
    )
    public val enabled: Output? = null,
    public val keyEncryptionKey: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.compute.inputs.ManagedDiskEncryptionSettingsArgs =
        com.pulumi.azure.compute.inputs.ManagedDiskEncryptionSettingsArgs.builder()
            .diskEncryptionKey(diskEncryptionKey?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .enabled(enabled?.applyValue({ args0 -> args0 }))
            .keyEncryptionKey(
                keyEncryptionKey?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            ).build()
}

/**
 * Builder for [ManagedDiskEncryptionSettingsArgs].
 */
@PulumiTagMarker
public class ManagedDiskEncryptionSettingsArgsBuilder internal constructor() {
    private var diskEncryptionKey: Output? = null

    private var enabled: Output? = null

    private var keyEncryptionKey: Output? = null

    /**
     * @param value A `disk_encryption_key` block as defined above.
     */
    @JvmName("hcljhutcqtmvubop")
    public suspend fun diskEncryptionKey(`value`: Output) {
        this.diskEncryptionKey = value
    }

    /**
     * @param value
     */
    @Deprecated(
        message = """
  Deprecated, Azure Disk Encryption is now configured directly by `disk_encryption_key` and
      `key_encryption_key`. To disable Azure Disk Encryption, please remove `encryption_settings`
      block. To enabled, specify a `encryption_settings` block`
  """,
    )
    @JvmName("hblsomfumtfqfjxr")
    public suspend fun enabled(`value`: Output) {
        this.enabled = value
    }

    /**
     * @param value A `key_encryption_key` block as defined below.
     */
    @JvmName("nwjtmwaoyapxywgf")
    public suspend fun keyEncryptionKey(`value`: Output) {
        this.keyEncryptionKey = value
    }

    /**
     * @param value A `disk_encryption_key` block as defined above.
     */
    @JvmName("nnfogxwftrwymbrh")
    public suspend fun diskEncryptionKey(`value`: ManagedDiskEncryptionSettingsDiskEncryptionKeyArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.diskEncryptionKey = mapped
    }

    /**
     * @param argument A `disk_encryption_key` block as defined above.
     */
    @JvmName("hedksrgdsaglkudo")
    public suspend fun diskEncryptionKey(argument: suspend ManagedDiskEncryptionSettingsDiskEncryptionKeyArgsBuilder.() -> Unit) {
        val toBeMapped = ManagedDiskEncryptionSettingsDiskEncryptionKeyArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.diskEncryptionKey = mapped
    }

    /**
     * @param value
     */
    @Deprecated(
        message = """
  Deprecated, Azure Disk Encryption is now configured directly by `disk_encryption_key` and
      `key_encryption_key`. To disable Azure Disk Encryption, please remove `encryption_settings`
      block. To enabled, specify a `encryption_settings` block`
  """,
    )
    @JvmName("ftudntqxnrcrlrpg")
    public suspend fun enabled(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.enabled = mapped
    }

    /**
     * @param value A `key_encryption_key` block as defined below.
     */
    @JvmName("dtowdcaqdffllyaq")
    public suspend fun keyEncryptionKey(`value`: ManagedDiskEncryptionSettingsKeyEncryptionKeyArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.keyEncryptionKey = mapped
    }

    /**
     * @param argument A `key_encryption_key` block as defined below.
     */
    @JvmName("kldsmhxpfqwhtstd")
    public suspend fun keyEncryptionKey(argument: suspend ManagedDiskEncryptionSettingsKeyEncryptionKeyArgsBuilder.() -> Unit) {
        val toBeMapped = ManagedDiskEncryptionSettingsKeyEncryptionKeyArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.keyEncryptionKey = mapped
    }

    internal fun build(): ManagedDiskEncryptionSettingsArgs = ManagedDiskEncryptionSettingsArgs(
        diskEncryptionKey = diskEncryptionKey,
        enabled = enabled,
        keyEncryptionKey = keyEncryptionKey,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy