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

com.pulumi.awsnative.ec2.kotlin.IpamAllocationArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.awsnative.ec2.kotlin

import com.pulumi.awsnative.ec2.IpamAllocationArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.jvm.JvmName

/**
 * Resource Schema of AWS::EC2::IPAMAllocation Type
 * @property cidr The CIDR you would like to allocate from the IPAM pool. Note the following:
 * - If there is no DefaultNetmaskLength allocation rule set on the pool, you must specify either the NetmaskLength or the CIDR.
 * - If the DefaultNetmaskLength allocation rule is set on the pool, you can specify either the NetmaskLength or the CIDR and the DefaultNetmaskLength allocation rule will be ignored.
 * Possible values: Any available IPv4 or IPv6 CIDR.
 * @property description A description for the allocation.
 * @property ipamPoolId Id of the IPAM Pool.
 * @property netmaskLength The desired netmask length of the allocation. If set, IPAM will choose a block of free space with this size and return the CIDR representing it.
 */
public data class IpamAllocationArgs(
    public val cidr: Output? = null,
    public val description: Output? = null,
    public val ipamPoolId: Output? = null,
    public val netmaskLength: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.ec2.IpamAllocationArgs =
        com.pulumi.awsnative.ec2.IpamAllocationArgs.builder()
            .cidr(cidr?.applyValue({ args0 -> args0 }))
            .description(description?.applyValue({ args0 -> args0 }))
            .ipamPoolId(ipamPoolId?.applyValue({ args0 -> args0 }))
            .netmaskLength(netmaskLength?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [IpamAllocationArgs].
 */
@PulumiTagMarker
public class IpamAllocationArgsBuilder internal constructor() {
    private var cidr: Output? = null

    private var description: Output? = null

    private var ipamPoolId: Output? = null

    private var netmaskLength: Output? = null

    /**
     * @param value The CIDR you would like to allocate from the IPAM pool. Note the following:
     * - If there is no DefaultNetmaskLength allocation rule set on the pool, you must specify either the NetmaskLength or the CIDR.
     * - If the DefaultNetmaskLength allocation rule is set on the pool, you can specify either the NetmaskLength or the CIDR and the DefaultNetmaskLength allocation rule will be ignored.
     * Possible values: Any available IPv4 or IPv6 CIDR.
     */
    @JvmName("gjlljbpfoegtwhbq")
    public suspend fun cidr(`value`: Output) {
        this.cidr = value
    }

    /**
     * @param value A description for the allocation.
     */
    @JvmName("pmxgowksmgkqeanq")
    public suspend fun description(`value`: Output) {
        this.description = value
    }

    /**
     * @param value Id of the IPAM Pool.
     */
    @JvmName("pboygabrmqetxkjr")
    public suspend fun ipamPoolId(`value`: Output) {
        this.ipamPoolId = value
    }

    /**
     * @param value The desired netmask length of the allocation. If set, IPAM will choose a block of free space with this size and return the CIDR representing it.
     */
    @JvmName("jljpogkghxwyadhl")
    public suspend fun netmaskLength(`value`: Output) {
        this.netmaskLength = value
    }

    /**
     * @param value The CIDR you would like to allocate from the IPAM pool. Note the following:
     * - If there is no DefaultNetmaskLength allocation rule set on the pool, you must specify either the NetmaskLength or the CIDR.
     * - If the DefaultNetmaskLength allocation rule is set on the pool, you can specify either the NetmaskLength or the CIDR and the DefaultNetmaskLength allocation rule will be ignored.
     * Possible values: Any available IPv4 or IPv6 CIDR.
     */
    @JvmName("ghsdrshvjgnvwgil")
    public suspend fun cidr(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.cidr = mapped
    }

    /**
     * @param value A description for the allocation.
     */
    @JvmName("weisonqlwwocoduy")
    public suspend fun description(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.description = mapped
    }

    /**
     * @param value Id of the IPAM Pool.
     */
    @JvmName("gtroubdluyxhfsiq")
    public suspend fun ipamPoolId(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.ipamPoolId = mapped
    }

    /**
     * @param value The desired netmask length of the allocation. If set, IPAM will choose a block of free space with this size and return the CIDR representing it.
     */
    @JvmName("rpdgijpreatytvri")
    public suspend fun netmaskLength(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.netmaskLength = mapped
    }

    internal fun build(): IpamAllocationArgs = IpamAllocationArgs(
        cidr = cidr,
        description = description,
        ipamPoolId = ipamPoolId,
        netmaskLength = netmaskLength,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy