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

com.pulumi.kubernetes.events.v1beta1.EventArgs Maven / Gradle / Ivy

There is a newer version: 4.19.0-alpha.1730750641
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.kubernetes.events.v1beta1;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.core.internal.Codegen;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import com.pulumi.kubernetes.core.v1.inputs.EventSourceArgs;
import com.pulumi.kubernetes.core.v1.inputs.ObjectReferenceArgs;
import com.pulumi.kubernetes.events.v1beta1.inputs.EventSeriesArgs;
import com.pulumi.kubernetes.meta.v1.inputs.ObjectMetaArgs;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class EventArgs extends com.pulumi.resources.ResourceArgs {

    public static final EventArgs Empty = new EventArgs();

    /**
     * What action was taken/failed regarding to the regarding object.
     * 
     */
    @Import(name="action")
    private @Nullable Output action;

    /**
     * @return What action was taken/failed regarding to the regarding object.
     * 
     */
    public Optional> action() {
        return Optional.ofNullable(this.action);
    }

    /**
     * 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
     * 
     */
    @Import(name="apiVersion")
    private @Nullable Output apiVersion;

    /**
     * @return 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
     * 
     */
    public Optional> apiVersion() {
        return Optional.ofNullable(this.apiVersion);
    }

    /**
     * Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    @Import(name="deprecatedCount")
    private @Nullable Output deprecatedCount;

    /**
     * @return Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    public Optional> deprecatedCount() {
        return Optional.ofNullable(this.deprecatedCount);
    }

    /**
     * Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    @Import(name="deprecatedFirstTimestamp")
    private @Nullable Output deprecatedFirstTimestamp;

    /**
     * @return Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    public Optional> deprecatedFirstTimestamp() {
        return Optional.ofNullable(this.deprecatedFirstTimestamp);
    }

    /**
     * Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    @Import(name="deprecatedLastTimestamp")
    private @Nullable Output deprecatedLastTimestamp;

    /**
     * @return Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    public Optional> deprecatedLastTimestamp() {
        return Optional.ofNullable(this.deprecatedLastTimestamp);
    }

    /**
     * Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    @Import(name="deprecatedSource")
    private @Nullable Output deprecatedSource;

    /**
     * @return Deprecated field assuring backward compatibility with core.v1 Event type
     * 
     */
    public Optional> deprecatedSource() {
        return Optional.ofNullable(this.deprecatedSource);
    }

    /**
     * Required. Time when this Event was first observed.
     * 
     */
    @Import(name="eventTime", required=true)
    private Output eventTime;

    /**
     * @return Required. Time when this Event was first observed.
     * 
     */
    public Output eventTime() {
        return this.eventTime;
    }

    /**
     * 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
     * 
     */
    @Import(name="kind")
    private @Nullable Output kind;

    /**
     * @return 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
     * 
     */
    public Optional> kind() {
        return Optional.ofNullable(this.kind);
    }

    @Import(name="metadata")
    private @Nullable Output metadata;

    public Optional> metadata() {
        return Optional.ofNullable(this.metadata);
    }

    /**
     * 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.
     * 
     */
    @Import(name="note")
    private @Nullable Output note;

    /**
     * @return 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.
     * 
     */
    public Optional> note() {
        return Optional.ofNullable(this.note);
    }

    /**
     * Why the action was taken.
     * 
     */
    @Import(name="reason")
    private @Nullable Output reason;

    /**
     * @return Why the action was taken.
     * 
     */
    public Optional> reason() {
        return Optional.ofNullable(this.reason);
    }

    /**
     * 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.
     * 
     */
    @Import(name="regarding")
    private @Nullable Output regarding;

    /**
     * @return 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.
     * 
     */
    public Optional> regarding() {
        return Optional.ofNullable(this.regarding);
    }

    /**
     * Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
     * 
     */
    @Import(name="related")
    private @Nullable Output related;

    /**
     * @return Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
     * 
     */
    public Optional> related() {
        return Optional.ofNullable(this.related);
    }

    /**
     * Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
     * 
     */
    @Import(name="reportingController")
    private @Nullable Output reportingController;

    /**
     * @return Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
     * 
     */
    public Optional> reportingController() {
        return Optional.ofNullable(this.reportingController);
    }

    /**
     * ID of the controller instance, e.g. `kubelet-xyzf`.
     * 
     */
    @Import(name="reportingInstance")
    private @Nullable Output reportingInstance;

    /**
     * @return ID of the controller instance, e.g. `kubelet-xyzf`.
     * 
     */
    public Optional> reportingInstance() {
        return Optional.ofNullable(this.reportingInstance);
    }

    /**
     * Data about the Event series this event represents or nil if it's a singleton Event.
     * 
     */
    @Import(name="series")
    private @Nullable Output series;

    /**
     * @return Data about the Event series this event represents or nil if it's a singleton Event.
     * 
     */
    public Optional> series() {
        return Optional.ofNullable(this.series);
    }

    /**
     * Type of this event (Normal, Warning), new types could be added in the future.
     * 
     */
    @Import(name="type")
    private @Nullable Output type;

    /**
     * @return Type of this event (Normal, Warning), new types could be added in the future.
     * 
     */
    public Optional> type() {
        return Optional.ofNullable(this.type);
    }

    private EventArgs() {}

    private EventArgs(EventArgs $) {
        this.action = $.action;
        this.apiVersion = $.apiVersion;
        this.deprecatedCount = $.deprecatedCount;
        this.deprecatedFirstTimestamp = $.deprecatedFirstTimestamp;
        this.deprecatedLastTimestamp = $.deprecatedLastTimestamp;
        this.deprecatedSource = $.deprecatedSource;
        this.eventTime = $.eventTime;
        this.kind = $.kind;
        this.metadata = $.metadata;
        this.note = $.note;
        this.reason = $.reason;
        this.regarding = $.regarding;
        this.related = $.related;
        this.reportingController = $.reportingController;
        this.reportingInstance = $.reportingInstance;
        this.series = $.series;
        this.type = $.type;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(EventArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private EventArgs $;

        public Builder() {
            $ = new EventArgs();
        }

        public Builder(EventArgs defaults) {
            $ = new EventArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param action What action was taken/failed regarding to the regarding object.
         * 
         * @return builder
         * 
         */
        public Builder action(@Nullable Output action) {
            $.action = action;
            return this;
        }

        /**
         * @param action What action was taken/failed regarding to the regarding object.
         * 
         * @return builder
         * 
         */
        public Builder action(String action) {
            return action(Output.of(action));
        }

        /**
         * @param 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
         * 
         * @return builder
         * 
         */
        public Builder apiVersion(@Nullable Output apiVersion) {
            $.apiVersion = apiVersion;
            return this;
        }

        /**
         * @param 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
         * 
         * @return builder
         * 
         */
        public Builder apiVersion(String apiVersion) {
            return apiVersion(Output.of(apiVersion));
        }

        /**
         * @param deprecatedCount Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedCount(@Nullable Output deprecatedCount) {
            $.deprecatedCount = deprecatedCount;
            return this;
        }

        /**
         * @param deprecatedCount Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedCount(Integer deprecatedCount) {
            return deprecatedCount(Output.of(deprecatedCount));
        }

        /**
         * @param deprecatedFirstTimestamp Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedFirstTimestamp(@Nullable Output deprecatedFirstTimestamp) {
            $.deprecatedFirstTimestamp = deprecatedFirstTimestamp;
            return this;
        }

        /**
         * @param deprecatedFirstTimestamp Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedFirstTimestamp(String deprecatedFirstTimestamp) {
            return deprecatedFirstTimestamp(Output.of(deprecatedFirstTimestamp));
        }

        /**
         * @param deprecatedLastTimestamp Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedLastTimestamp(@Nullable Output deprecatedLastTimestamp) {
            $.deprecatedLastTimestamp = deprecatedLastTimestamp;
            return this;
        }

        /**
         * @param deprecatedLastTimestamp Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedLastTimestamp(String deprecatedLastTimestamp) {
            return deprecatedLastTimestamp(Output.of(deprecatedLastTimestamp));
        }

        /**
         * @param deprecatedSource Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedSource(@Nullable Output deprecatedSource) {
            $.deprecatedSource = deprecatedSource;
            return this;
        }

        /**
         * @param deprecatedSource Deprecated field assuring backward compatibility with core.v1 Event type
         * 
         * @return builder
         * 
         */
        public Builder deprecatedSource(EventSourceArgs deprecatedSource) {
            return deprecatedSource(Output.of(deprecatedSource));
        }

        /**
         * @param eventTime Required. Time when this Event was first observed.
         * 
         * @return builder
         * 
         */
        public Builder eventTime(Output eventTime) {
            $.eventTime = eventTime;
            return this;
        }

        /**
         * @param eventTime Required. Time when this Event was first observed.
         * 
         * @return builder
         * 
         */
        public Builder eventTime(String eventTime) {
            return eventTime(Output.of(eventTime));
        }

        /**
         * @param 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
         * 
         * @return builder
         * 
         */
        public Builder kind(@Nullable Output kind) {
            $.kind = kind;
            return this;
        }

        /**
         * @param 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
         * 
         * @return builder
         * 
         */
        public Builder kind(String kind) {
            return kind(Output.of(kind));
        }

        public Builder metadata(@Nullable Output metadata) {
            $.metadata = metadata;
            return this;
        }

        public Builder metadata(ObjectMetaArgs metadata) {
            return metadata(Output.of(metadata));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder note(@Nullable Output note) {
            $.note = note;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder note(String note) {
            return note(Output.of(note));
        }

        /**
         * @param reason Why the action was taken.
         * 
         * @return builder
         * 
         */
        public Builder reason(@Nullable Output reason) {
            $.reason = reason;
            return this;
        }

        /**
         * @param reason Why the action was taken.
         * 
         * @return builder
         * 
         */
        public Builder reason(String reason) {
            return reason(Output.of(reason));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder regarding(@Nullable Output regarding) {
            $.regarding = regarding;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder regarding(ObjectReferenceArgs regarding) {
            return regarding(Output.of(regarding));
        }

        /**
         * @param related Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
         * 
         * @return builder
         * 
         */
        public Builder related(@Nullable Output related) {
            $.related = related;
            return this;
        }

        /**
         * @param related Optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
         * 
         * @return builder
         * 
         */
        public Builder related(ObjectReferenceArgs related) {
            return related(Output.of(related));
        }

        /**
         * @param reportingController Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
         * 
         * @return builder
         * 
         */
        public Builder reportingController(@Nullable Output reportingController) {
            $.reportingController = reportingController;
            return this;
        }

        /**
         * @param reportingController Name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`.
         * 
         * @return builder
         * 
         */
        public Builder reportingController(String reportingController) {
            return reportingController(Output.of(reportingController));
        }

        /**
         * @param reportingInstance ID of the controller instance, e.g. `kubelet-xyzf`.
         * 
         * @return builder
         * 
         */
        public Builder reportingInstance(@Nullable Output reportingInstance) {
            $.reportingInstance = reportingInstance;
            return this;
        }

        /**
         * @param reportingInstance ID of the controller instance, e.g. `kubelet-xyzf`.
         * 
         * @return builder
         * 
         */
        public Builder reportingInstance(String reportingInstance) {
            return reportingInstance(Output.of(reportingInstance));
        }

        /**
         * @param series Data about the Event series this event represents or nil if it's a singleton Event.
         * 
         * @return builder
         * 
         */
        public Builder series(@Nullable Output series) {
            $.series = series;
            return this;
        }

        /**
         * @param series Data about the Event series this event represents or nil if it's a singleton Event.
         * 
         * @return builder
         * 
         */
        public Builder series(EventSeriesArgs series) {
            return series(Output.of(series));
        }

        /**
         * @param type Type of this event (Normal, Warning), new types could be added in the future.
         * 
         * @return builder
         * 
         */
        public Builder type(@Nullable Output type) {
            $.type = type;
            return this;
        }

        /**
         * @param type Type of this event (Normal, Warning), new types could be added in the future.
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Output.of(type));
        }

        public EventArgs build() {
            $.apiVersion = Codegen.stringProp("apiVersion").output().arg($.apiVersion).getNullable();
            if ($.eventTime == null) {
                throw new MissingRequiredPropertyException("EventArgs", "eventTime");
            }
            $.kind = Codegen.stringProp("kind").output().arg($.kind).getNullable();
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy