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

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

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

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

import com.pulumi.azure.compute.inputs.OrchestratedVirtualMachineScaleSetNetworkInterfaceArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property dnsServers A list of IP Addresses of DNS Servers which should be assigned to the Network Interface.
 * @property enableAcceleratedNetworking Does this Network Interface support Accelerated Networking? Possible values are `true` and `false`. Defaults to `false`.
 * @property enableIpForwarding Does this Network Interface support IP Forwarding? Possible values are `true` and `false`. Defaults to `false`.
 * @property ipConfigurations One or more `ip_configuration` blocks as defined above.
 * @property name The Name which should be used for this Network Interface. Changing this forces a new resource to be created.
 * @property networkSecurityGroupId The ID of a Network Security Group which should be assigned to this Network Interface.
 * @property primary Is this the Primary IP Configuration? Possible values are `true` and `false`. Defaults to `false`.
 * > **Note:** If multiple `network_interface` blocks are specified, one must be set to `primary`.
 */
public data class OrchestratedVirtualMachineScaleSetNetworkInterfaceArgs(
    public val dnsServers: Output>? = null,
    public val enableAcceleratedNetworking: Output? = null,
    public val enableIpForwarding: Output? = null,
    public val ipConfigurations: Output>,
    public val name: Output,
    public val networkSecurityGroupId: Output? = null,
    public val primary: Output? = null,
) :
    ConvertibleToJava {
    override fun toJava(): com.pulumi.azure.compute.inputs.OrchestratedVirtualMachineScaleSetNetworkInterfaceArgs =
        com.pulumi.azure.compute.inputs.OrchestratedVirtualMachineScaleSetNetworkInterfaceArgs.builder()
            .dnsServers(dnsServers?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .enableAcceleratedNetworking(enableAcceleratedNetworking?.applyValue({ args0 -> args0 }))
            .enableIpForwarding(enableIpForwarding?.applyValue({ args0 -> args0 }))
            .ipConfigurations(
                ipConfigurations.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .name(name.applyValue({ args0 -> args0 }))
            .networkSecurityGroupId(networkSecurityGroupId?.applyValue({ args0 -> args0 }))
            .primary(primary?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [OrchestratedVirtualMachineScaleSetNetworkInterfaceArgs].
 */
@PulumiTagMarker
public class OrchestratedVirtualMachineScaleSetNetworkInterfaceArgsBuilder internal constructor() {
    private var dnsServers: Output>? = null

    private var enableAcceleratedNetworking: Output? = null

    private var enableIpForwarding: Output? = null

    private var ipConfigurations:
        Output>? = null

    private var name: Output? = null

    private var networkSecurityGroupId: Output? = null

    private var primary: Output? = null

    /**
     * @param value A list of IP Addresses of DNS Servers which should be assigned to the Network Interface.
     */
    @JvmName("nvvboyhvqekknvhi")
    public suspend fun dnsServers(`value`: Output>) {
        this.dnsServers = value
    }

    @JvmName("vdqwoqteoqbeamnu")
    public suspend fun dnsServers(vararg values: Output) {
        this.dnsServers = Output.all(values.asList())
    }

    /**
     * @param values A list of IP Addresses of DNS Servers which should be assigned to the Network Interface.
     */
    @JvmName("favxjfqwfbllohja")
    public suspend fun dnsServers(values: List>) {
        this.dnsServers = Output.all(values)
    }

    /**
     * @param value Does this Network Interface support Accelerated Networking? Possible values are `true` and `false`. Defaults to `false`.
     */
    @JvmName("soaiirowkdhpvwlf")
    public suspend fun enableAcceleratedNetworking(`value`: Output) {
        this.enableAcceleratedNetworking = value
    }

    /**
     * @param value Does this Network Interface support IP Forwarding? Possible values are `true` and `false`. Defaults to `false`.
     */
    @JvmName("conrjddfrupbfenl")
    public suspend fun enableIpForwarding(`value`: Output) {
        this.enableIpForwarding = value
    }

    /**
     * @param value One or more `ip_configuration` blocks as defined above.
     */
    @JvmName("ttrhctimsfcbicrs")
    public suspend fun ipConfigurations(`value`: Output>) {
        this.ipConfigurations = value
    }

    @JvmName("xrvasdmtfmsixajd")
    public suspend fun ipConfigurations(vararg values: Output) {
        this.ipConfigurations = Output.all(values.asList())
    }

    /**
     * @param values One or more `ip_configuration` blocks as defined above.
     */
    @JvmName("nffoxgsyjlnnhuum")
    public suspend fun ipConfigurations(values: List>) {
        this.ipConfigurations = Output.all(values)
    }

    /**
     * @param value The Name which should be used for this Network Interface. Changing this forces a new resource to be created.
     */
    @JvmName("gjoeaarwiibvccot")
    public suspend fun name(`value`: Output) {
        this.name = value
    }

    /**
     * @param value The ID of a Network Security Group which should be assigned to this Network Interface.
     */
    @JvmName("hxgtmgprlptadybi")
    public suspend fun networkSecurityGroupId(`value`: Output) {
        this.networkSecurityGroupId = value
    }

    /**
     * @param value Is this the Primary IP Configuration? Possible values are `true` and `false`. Defaults to `false`.
     * > **Note:** If multiple `network_interface` blocks are specified, one must be set to `primary`.
     */
    @JvmName("hqrpvfmfrwrvvcxy")
    public suspend fun primary(`value`: Output) {
        this.primary = value
    }

    /**
     * @param value A list of IP Addresses of DNS Servers which should be assigned to the Network Interface.
     */
    @JvmName("txjowhqrqiqasunj")
    public suspend fun dnsServers(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.dnsServers = mapped
    }

    /**
     * @param values A list of IP Addresses of DNS Servers which should be assigned to the Network Interface.
     */
    @JvmName("khudvlutprgbtsju")
    public suspend fun dnsServers(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.dnsServers = mapped
    }

    /**
     * @param value Does this Network Interface support Accelerated Networking? Possible values are `true` and `false`. Defaults to `false`.
     */
    @JvmName("axklkmxwrdkaqtfk")
    public suspend fun enableAcceleratedNetworking(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.enableAcceleratedNetworking = mapped
    }

    /**
     * @param value Does this Network Interface support IP Forwarding? Possible values are `true` and `false`. Defaults to `false`.
     */
    @JvmName("buwhftnogdxuhvpm")
    public suspend fun enableIpForwarding(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.enableIpForwarding = mapped
    }

    /**
     * @param value One or more `ip_configuration` blocks as defined above.
     */
    @JvmName("osjlhiawuchuorgy")
    public suspend fun ipConfigurations(`value`: List) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.ipConfigurations = mapped
    }

    /**
     * @param argument One or more `ip_configuration` blocks as defined above.
     */
    @JvmName("xrtscvifibeyqita")
    public suspend fun ipConfigurations(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            OrchestratedVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.ipConfigurations = mapped
    }

    /**
     * @param argument One or more `ip_configuration` blocks as defined above.
     */
    @JvmName("betslixvpafhysxk")
    public suspend fun ipConfigurations(vararg argument: suspend OrchestratedVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            OrchestratedVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.ipConfigurations = mapped
    }

    /**
     * @param argument One or more `ip_configuration` blocks as defined above.
     */
    @JvmName("wlbwlvkvemgdaqod")
    public suspend fun ipConfigurations(argument: suspend OrchestratedVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgsBuilder.() -> Unit) {
        val toBeMapped =
            listOf(
                OrchestratedVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgsBuilder().applySuspend
                    { argument() }.build(),
            )
        val mapped = of(toBeMapped)
        this.ipConfigurations = mapped
    }

    /**
     * @param values One or more `ip_configuration` blocks as defined above.
     */
    @JvmName("iehyidlkxhjumorr")
    public suspend fun ipConfigurations(vararg values: OrchestratedVirtualMachineScaleSetNetworkInterfaceIpConfigurationArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.ipConfigurations = mapped
    }

    /**
     * @param value The Name which should be used for this Network Interface. Changing this forces a new resource to be created.
     */
    @JvmName("kupsvousykxckatl")
    public suspend fun name(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.name = mapped
    }

    /**
     * @param value The ID of a Network Security Group which should be assigned to this Network Interface.
     */
    @JvmName("kullejjejfkqavcj")
    public suspend fun networkSecurityGroupId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.networkSecurityGroupId = mapped
    }

    /**
     * @param value Is this the Primary IP Configuration? Possible values are `true` and `false`. Defaults to `false`.
     * > **Note:** If multiple `network_interface` blocks are specified, one must be set to `primary`.
     */
    @JvmName("oenclhjhffjttnme")
    public suspend fun primary(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.primary = mapped
    }

    internal fun build(): OrchestratedVirtualMachineScaleSetNetworkInterfaceArgs =
        OrchestratedVirtualMachineScaleSetNetworkInterfaceArgs(
            dnsServers = dnsServers,
            enableAcceleratedNetworking = enableAcceleratedNetworking,
            enableIpForwarding = enableIpForwarding,
            ipConfigurations = ipConfigurations ?: throw PulumiNullFieldException("ipConfigurations"),
            name = name ?: throw PulumiNullFieldException("name"),
            networkSecurityGroupId = networkSecurityGroupId,
            primary = primary,
        )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy