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

com.pulumi.kubernetes.events.v1beta1.kotlin.EventArgs.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.

The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.kubernetes.events.v1beta1.kotlin

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 com.pulumi.kubernetes.core.v1.kotlin.inputs.EventSourceArgs
import com.pulumi.kubernetes.core.v1.kotlin.inputs.EventSourceArgsBuilder
import com.pulumi.kubernetes.core.v1.kotlin.inputs.ObjectReferenceArgs
import com.pulumi.kubernetes.core.v1.kotlin.inputs.ObjectReferenceArgsBuilder
import com.pulumi.kubernetes.events.v1beta1.EventArgs.builder
import com.pulumi.kubernetes.events.v1beta1.kotlin.inputs.EventSeriesArgs
import com.pulumi.kubernetes.events.v1beta1.kotlin.inputs.EventSeriesArgsBuilder
import com.pulumi.kubernetes.meta.v1.kotlin.inputs.ObjectMetaArgs
import com.pulumi.kubernetes.meta.v1.kotlin.inputs.ObjectMetaArgsBuilder
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 * Event is a report of an event somewhere in the cluster. It generally denotes some state change in the system.
 * @property action What action was taken/failed regarding to the regarding object.
 * @property apiVersion APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
 * @property deprecatedCount Deprecated field assuring backward compatibility with core.v1 Event type
 * @property deprecatedFirstTimestamp Deprecated field assuring backward compatibility with core.v1 Event type
 * @property deprecatedLastTimestamp Deprecated field assuring backward compatibility with core.v1 Event type
 * @property deprecatedSource Deprecated field assuring backward compatibility with core.v1 Event type
 * @property eventTime Required. Time when this Event was first observed.
 * @property kind Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
 * @property metadata
 * @property note Optional. A human-readable description of the status of this operation. Maximal length of the note is 1kB, but libraries should be prepared to handle values up to 64kB.
 * @property reason Why the action was taken.
 * @property regarding The object this Event is about. In most cases it's an Object reporting controller implements. E.g. ReplicaSetController implements ReplicaSets and this event is emitted because it acts on some changes in a ReplicaSet object.
 * @property related Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
 * @property reportingController Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
 * @property reportingInstance ID of the controller instance, e.g. `kubelet-xyzf`.
 * @property series Data about the Event series this event represents or nil if it's a singleton Event.
 * @property type Type of this event (Normal, Warning), new types could be added in the future.
 */
public data class EventArgs(
    public val action: Output? = null,
    public val apiVersion: Output? = null,
    public val deprecatedCount: Output? = null,
    public val deprecatedFirstTimestamp: Output? = null,
    public val deprecatedLastTimestamp: Output? = null,
    public val deprecatedSource: Output? = null,
    public val eventTime: Output? = null,
    public val kind: Output? = null,
    public val metadata: Output? = null,
    public val note: Output? = null,
    public val reason: Output? = null,
    public val regarding: Output? = null,
    public val related: Output? = null,
    public val reportingController: Output? = null,
    public val reportingInstance: Output? = null,
    public val series: Output? = null,
    public val type: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.kubernetes.events.v1beta1.EventArgs =
        com.pulumi.kubernetes.events.v1beta1.EventArgs.builder()
            .action(action?.applyValue({ args0 -> args0 }))
            .apiVersion(apiVersion?.applyValue({ args0 -> args0 }))
            .deprecatedCount(deprecatedCount?.applyValue({ args0 -> args0 }))
            .deprecatedFirstTimestamp(deprecatedFirstTimestamp?.applyValue({ args0 -> args0 }))
            .deprecatedLastTimestamp(deprecatedLastTimestamp?.applyValue({ args0 -> args0 }))
            .deprecatedSource(deprecatedSource?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .eventTime(eventTime?.applyValue({ args0 -> args0 }))
            .kind(kind?.applyValue({ args0 -> args0 }))
            .metadata(metadata?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .note(note?.applyValue({ args0 -> args0 }))
            .reason(reason?.applyValue({ args0 -> args0 }))
            .regarding(regarding?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .related(related?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .reportingController(reportingController?.applyValue({ args0 -> args0 }))
            .reportingInstance(reportingInstance?.applyValue({ args0 -> args0 }))
            .series(series?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .type(type?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [EventArgs].
 */
@PulumiTagMarker
public class EventArgsBuilder internal constructor() {
    private var action: Output? = null

    private var apiVersion: Output? = null

    private var deprecatedCount: Output? = null

    private var deprecatedFirstTimestamp: Output? = null

    private var deprecatedLastTimestamp: Output? = null

    private var deprecatedSource: Output? = null

    private var eventTime: Output? = null

    private var kind: Output? = null

    private var metadata: Output? = null

    private var note: Output? = null

    private var reason: Output? = null

    private var regarding: Output? = null

    private var related: Output? = null

    private var reportingController: Output? = null

    private var reportingInstance: Output? = null

    private var series: Output? = null

    private var type: Output? = null

    /**
     * @param value What action was taken/failed regarding to the regarding object.
     */
    @JvmName("wykhqwnhfctipmvu")
    public suspend fun action(`value`: Output) {
        this.action = value
    }

    /**
     * @param value APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
     */
    @JvmName("drhmhubpqrbrlgin")
    public suspend fun apiVersion(`value`: Output) {
        this.apiVersion = value
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("tetuytljmkwuuuvn")
    public suspend fun deprecatedCount(`value`: Output) {
        this.deprecatedCount = value
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("pmcacftcsfpcqasx")
    public suspend fun deprecatedFirstTimestamp(`value`: Output) {
        this.deprecatedFirstTimestamp = value
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("hecmausbhgbsmnir")
    public suspend fun deprecatedLastTimestamp(`value`: Output) {
        this.deprecatedLastTimestamp = value
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("batlfbvjmraesixk")
    public suspend fun deprecatedSource(`value`: Output) {
        this.deprecatedSource = value
    }

    /**
     * @param value Required. Time when this Event was first observed.
     */
    @JvmName("wlghkskdatyqvrnn")
    public suspend fun eventTime(`value`: Output) {
        this.eventTime = value
    }

    /**
     * @param value Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
     */
    @JvmName("dtviwdpmypnicpya")
    public suspend fun kind(`value`: Output) {
        this.kind = value
    }

    /**
     * @param value
     */
    @JvmName("acexwpplsibumfkn")
    public suspend fun metadata(`value`: Output) {
        this.metadata = value
    }

    /**
     * @param value Optional. A human-readable description of the status of this operation. Maximal length of the note is 1kB, but libraries should be prepared to handle values up to 64kB.
     */
    @JvmName("gaacvwdpjngtmcpj")
    public suspend fun note(`value`: Output) {
        this.note = value
    }

    /**
     * @param value Why the action was taken.
     */
    @JvmName("gvxnustfiakfjdgv")
    public suspend fun reason(`value`: Output) {
        this.reason = value
    }

    /**
     * @param value The object this Event is about. In most cases it's an Object reporting controller implements. E.g. ReplicaSetController implements ReplicaSets and this event is emitted because it acts on some changes in a ReplicaSet object.
     */
    @JvmName("swuyntusbgkvsoff")
    public suspend fun regarding(`value`: Output) {
        this.regarding = value
    }

    /**
     * @param value Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
     */
    @JvmName("mmwdhkaabgnvmiuu")
    public suspend fun related(`value`: Output) {
        this.related = value
    }

    /**
     * @param value Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
     */
    @JvmName("vwslsiomdioigfvd")
    public suspend fun reportingController(`value`: Output) {
        this.reportingController = value
    }

    /**
     * @param value ID of the controller instance, e.g. `kubelet-xyzf`.
     */
    @JvmName("xlodsypiwiillglm")
    public suspend fun reportingInstance(`value`: Output) {
        this.reportingInstance = value
    }

    /**
     * @param value Data about the Event series this event represents or nil if it's a singleton Event.
     */
    @JvmName("tylsgjgyuftwxrxq")
    public suspend fun series(`value`: Output) {
        this.series = value
    }

    /**
     * @param value Type of this event (Normal, Warning), new types could be added in the future.
     */
    @JvmName("ylibokdkskaksogf")
    public suspend fun type(`value`: Output) {
        this.type = value
    }

    /**
     * @param value What action was taken/failed regarding to the regarding object.
     */
    @JvmName("cgnemhqohlwpntoj")
    public suspend fun action(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.action = mapped
    }

    /**
     * @param value APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
     */
    @JvmName("punnyikdbxehefad")
    public suspend fun apiVersion(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.apiVersion = mapped
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("suthvfhlvmwgniam")
    public suspend fun deprecatedCount(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.deprecatedCount = mapped
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("dqjiyuefdcppucug")
    public suspend fun deprecatedFirstTimestamp(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.deprecatedFirstTimestamp = mapped
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("pkmfjqyrffmtdevv")
    public suspend fun deprecatedLastTimestamp(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.deprecatedLastTimestamp = mapped
    }

    /**
     * @param value Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("scfaomsxgpwrtwdv")
    public suspend fun deprecatedSource(`value`: EventSourceArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.deprecatedSource = mapped
    }

    /**
     * @param argument Deprecated field assuring backward compatibility with core.v1 Event type
     */
    @JvmName("dfqrlrtnudqaaaai")
    public suspend fun deprecatedSource(argument: suspend EventSourceArgsBuilder.() -> Unit) {
        val toBeMapped = EventSourceArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.deprecatedSource = mapped
    }

    /**
     * @param value Required. Time when this Event was first observed.
     */
    @JvmName("owecvmxnuwrwycaj")
    public suspend fun eventTime(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.eventTime = mapped
    }

    /**
     * @param value Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
     */
    @JvmName("irfnwrncscevqtpn")
    public suspend fun kind(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.kind = mapped
    }

    /**
     * @param value
     */
    @JvmName("vhfhgmglrvpmwqte")
    public suspend fun metadata(`value`: ObjectMetaArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.metadata = mapped
    }

    /**
     * @param argument
     */
    @JvmName("nbhdygrhnevqkmyk")
    public suspend fun metadata(argument: suspend ObjectMetaArgsBuilder.() -> Unit) {
        val toBeMapped = ObjectMetaArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.metadata = mapped
    }

    /**
     * @param value Optional. A human-readable description of the status of this operation. Maximal length of the note is 1kB, but libraries should be prepared to handle values up to 64kB.
     */
    @JvmName("nvysuqrsxmreicxf")
    public suspend fun note(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.note = mapped
    }

    /**
     * @param value Why the action was taken.
     */
    @JvmName("cnprpimjimfxyowb")
    public suspend fun reason(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.reason = mapped
    }

    /**
     * @param value The object this Event is about. In most cases it's an Object reporting controller implements. E.g. ReplicaSetController implements ReplicaSets and this event is emitted because it acts on some changes in a ReplicaSet object.
     */
    @JvmName("hdpmfgidpsvjdeil")
    public suspend fun regarding(`value`: ObjectReferenceArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.regarding = mapped
    }

    /**
     * @param argument The object this Event is about. In most cases it's an Object reporting controller implements. E.g. ReplicaSetController implements ReplicaSets and this event is emitted because it acts on some changes in a ReplicaSet object.
     */
    @JvmName("glamqnplujaqepjw")
    public suspend fun regarding(argument: suspend ObjectReferenceArgsBuilder.() -> Unit) {
        val toBeMapped = ObjectReferenceArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.regarding = mapped
    }

    /**
     * @param value Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
     */
    @JvmName("tkmjhoectusagooq")
    public suspend fun related(`value`: ObjectReferenceArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.related = mapped
    }

    /**
     * @param argument Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
     */
    @JvmName("ondanlbtvlcjclef")
    public suspend fun related(argument: suspend ObjectReferenceArgsBuilder.() -> Unit) {
        val toBeMapped = ObjectReferenceArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.related = mapped
    }

    /**
     * @param value Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
     */
    @JvmName("tahxdpcvqarafbgv")
    public suspend fun reportingController(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.reportingController = mapped
    }

    /**
     * @param value ID of the controller instance, e.g. `kubelet-xyzf`.
     */
    @JvmName("nvqijylvblmanuok")
    public suspend fun reportingInstance(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.reportingInstance = mapped
    }

    /**
     * @param value Data about the Event series this event represents or nil if it's a singleton Event.
     */
    @JvmName("xiubtdwgfhmkbvvp")
    public suspend fun series(`value`: EventSeriesArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.series = mapped
    }

    /**
     * @param argument Data about the Event series this event represents or nil if it's a singleton Event.
     */
    @JvmName("clrhxdjxvvxhvxek")
    public suspend fun series(argument: suspend EventSeriesArgsBuilder.() -> Unit) {
        val toBeMapped = EventSeriesArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.series = mapped
    }

    /**
     * @param value Type of this event (Normal, Warning), new types could be added in the future.
     */
    @JvmName("bcfbvowjpvbsryjc")
    public suspend fun type(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.type = mapped
    }

    internal fun build(): EventArgs = EventArgs(
        action = action,
        apiVersion = apiVersion,
        deprecatedCount = deprecatedCount,
        deprecatedFirstTimestamp = deprecatedFirstTimestamp,
        deprecatedLastTimestamp = deprecatedLastTimestamp,
        deprecatedSource = deprecatedSource,
        eventTime = eventTime,
        kind = kind,
        metadata = metadata,
        note = note,
        reason = reason,
        regarding = regarding,
        related = related,
        reportingController = reportingController,
        reportingInstance = reportingInstance,
        series = series,
        type = type,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy