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

com.pulumi.azurenative.costmanagement.kotlin.inputs.ReportScheduleArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 2.82.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azurenative.costmanagement.kotlin.inputs

import com.pulumi.azurenative.costmanagement.inputs.ReportScheduleArgs.builder
import com.pulumi.azurenative.costmanagement.kotlin.enums.RecurrenceType
import com.pulumi.azurenative.costmanagement.kotlin.enums.StatusType
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.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 * The schedule associated with a report.
 * @property recurrence The schedule recurrence.
 * @property recurrencePeriod Has start and end date of the recurrence. The start date must be in future. If present, the end date must be greater than start date.
 * @property status The status of the schedule. Whether active or not. If inactive, the report's scheduled execution is paused.
 */
public data class ReportScheduleArgs(
    public val recurrence: Output>,
    public val recurrencePeriod: Output? = null,
    public val status: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.costmanagement.inputs.ReportScheduleArgs =
        com.pulumi.azurenative.costmanagement.inputs.ReportScheduleArgs.builder()
            .recurrence(
                recurrence.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .recurrencePeriod(recurrencePeriod?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .status(
                status?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            ).build()
}

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

    private var recurrencePeriod: Output? = null

    private var status: Output>? = null

    /**
     * @param value The schedule recurrence.
     */
    @JvmName("mjpkuuiihkikkfnf")
    public suspend fun recurrence(`value`: Output>) {
        this.recurrence = value
    }

    /**
     * @param value Has start and end date of the recurrence. The start date must be in future. If present, the end date must be greater than start date.
     */
    @JvmName("reamfgdyfgnvsiws")
    public suspend fun recurrencePeriod(`value`: Output) {
        this.recurrencePeriod = value
    }

    /**
     * @param value The status of the schedule. Whether active or not. If inactive, the report's scheduled execution is paused.
     */
    @JvmName("vkegndiehbbkortg")
    public suspend fun status(`value`: Output>) {
        this.status = value
    }

    /**
     * @param value The schedule recurrence.
     */
    @JvmName("xqwdogdiurueylds")
    public suspend fun recurrence(`value`: Either) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.recurrence = mapped
    }

    /**
     * @param value The schedule recurrence.
     */
    @JvmName("kkmyeonlydnphrrq")
    public fun recurrence(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.recurrence = mapped
    }

    /**
     * @param value The schedule recurrence.
     */
    @JvmName("cxlhdwfkucyblehh")
    public fun recurrence(`value`: RecurrenceType) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.recurrence = mapped
    }

    /**
     * @param value Has start and end date of the recurrence. The start date must be in future. If present, the end date must be greater than start date.
     */
    @JvmName("qrssvmmjqsjndual")
    public suspend fun recurrencePeriod(`value`: ReportRecurrencePeriodArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.recurrencePeriod = mapped
    }

    /**
     * @param argument Has start and end date of the recurrence. The start date must be in future. If present, the end date must be greater than start date.
     */
    @JvmName("prcooigmopkpvvaa")
    public suspend fun recurrencePeriod(argument: suspend ReportRecurrencePeriodArgsBuilder.() -> Unit) {
        val toBeMapped = ReportRecurrencePeriodArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.recurrencePeriod = mapped
    }

    /**
     * @param value The status of the schedule. Whether active or not. If inactive, the report's scheduled execution is paused.
     */
    @JvmName("xhjfgufileryvqeb")
    public suspend fun status(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.status = mapped
    }

    /**
     * @param value The status of the schedule. Whether active or not. If inactive, the report's scheduled execution is paused.
     */
    @JvmName("bwnheiamotnsllhw")
    public fun status(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.status = mapped
    }

    /**
     * @param value The status of the schedule. Whether active or not. If inactive, the report's scheduled execution is paused.
     */
    @JvmName("ixcftkvkcypjlgvr")
    public fun status(`value`: StatusType) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.status = mapped
    }

    internal fun build(): ReportScheduleArgs = ReportScheduleArgs(
        recurrence = recurrence ?: throw PulumiNullFieldException("recurrence"),
        recurrencePeriod = recurrencePeriod,
        status = status,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy