
com.pulumi.azurenative.recoveryservices.kotlin.inputs.RetentionDurationArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azurenative.recoveryservices.kotlin.inputs
import com.pulumi.azurenative.recoveryservices.inputs.RetentionDurationArgs.builder
import com.pulumi.azurenative.recoveryservices.kotlin.enums.RetentionDurationType
import com.pulumi.core.Either
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
/**
* Retention duration.
* @property count Count of duration types. Retention duration is obtained by the counting the duration type Count times.
* For example, when Count = 3 and DurationType = Weeks, retention duration will be three weeks.
* @property durationType Retention duration type of retention policy.
*/
public data class RetentionDurationArgs(
public val count: Output? = null,
public val durationType: Output>? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.azurenative.recoveryservices.inputs.RetentionDurationArgs =
com.pulumi.azurenative.recoveryservices.inputs.RetentionDurationArgs.builder()
.count(count?.applyValue({ args0 -> args0 }))
.durationType(
durationType?.applyValue({ args0 ->
args0.transform({ args0 -> args0 }, { args0 ->
args0.let({ args0 -> args0.toJava() })
})
}),
).build()
}
/**
* Builder for [RetentionDurationArgs].
*/
@PulumiTagMarker
public class RetentionDurationArgsBuilder internal constructor() {
private var count: Output? = null
private var durationType: Output>? = null
/**
* @param value Count of duration types. Retention duration is obtained by the counting the duration type Count times.
* For example, when Count = 3 and DurationType = Weeks, retention duration will be three weeks.
*/
@JvmName("wcnydcrcvtkbsngw")
public suspend fun count(`value`: Output) {
this.count = value
}
/**
* @param value Retention duration type of retention policy.
*/
@JvmName("dtwfwffsxvwwdxjd")
public suspend fun durationType(`value`: Output>) {
this.durationType = value
}
/**
* @param value Count of duration types. Retention duration is obtained by the counting the duration type Count times.
* For example, when Count = 3 and DurationType = Weeks, retention duration will be three weeks.
*/
@JvmName("vuuvcngeoixitibr")
public suspend fun count(`value`: Int?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.count = mapped
}
/**
* @param value Retention duration type of retention policy.
*/
@JvmName("wwnbhnclwjhpnjms")
public suspend fun durationType(`value`: Either?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.durationType = mapped
}
/**
* @param value Retention duration type of retention policy.
*/
@JvmName("hjlpedpjltqtvfxg")
public fun durationType(`value`: String) {
val toBeMapped = Either.ofLeft(value)
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.durationType = mapped
}
/**
* @param value Retention duration type of retention policy.
*/
@JvmName("dpjwifmawjefoqat")
public fun durationType(`value`: RetentionDurationType) {
val toBeMapped = Either.ofRight(value)
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.durationType = mapped
}
internal fun build(): RetentionDurationArgs = RetentionDurationArgs(
count = count,
durationType = durationType,
)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy