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

com.pulumi.azurenative.security.AlertsSuppressionRuleArgs Maven / Gradle / Ivy

There is a newer version: 2.72.0
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.azurenative.security;

import com.pulumi.azurenative.security.enums.RuleState;
import com.pulumi.azurenative.security.inputs.SuppressionAlertsScopeArgs;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final AlertsSuppressionRuleArgs Empty = new AlertsSuppressionRuleArgs();

    /**
     * Type of the alert to automatically suppress. For all alert types, use '*'
     * 
     */
    @Import(name="alertType", required=true)
    private Output alertType;

    /**
     * @return Type of the alert to automatically suppress. For all alert types, use '*'
     * 
     */
    public Output alertType() {
        return this.alertType;
    }

    /**
     * The unique name of the suppression alert rule
     * 
     */
    @Import(name="alertsSuppressionRuleName")
    private @Nullable Output alertsSuppressionRuleName;

    /**
     * @return The unique name of the suppression alert rule
     * 
     */
    public Optional> alertsSuppressionRuleName() {
        return Optional.ofNullable(this.alertsSuppressionRuleName);
    }

    /**
     * Any comment regarding the rule
     * 
     */
    @Import(name="comment")
    private @Nullable Output comment;

    /**
     * @return Any comment regarding the rule
     * 
     */
    public Optional> comment() {
        return Optional.ofNullable(this.comment);
    }

    /**
     * Expiration date of the rule, if value is not provided or provided as null there will no expiration at all
     * 
     */
    @Import(name="expirationDateUtc")
    private @Nullable Output expirationDateUtc;

    /**
     * @return Expiration date of the rule, if value is not provided or provided as null there will no expiration at all
     * 
     */
    public Optional> expirationDateUtc() {
        return Optional.ofNullable(this.expirationDateUtc);
    }

    /**
     * The reason for dismissing the alert
     * 
     */
    @Import(name="reason", required=true)
    private Output reason;

    /**
     * @return The reason for dismissing the alert
     * 
     */
    public Output reason() {
        return this.reason;
    }

    /**
     * Possible states of the rule
     * 
     */
    @Import(name="state", required=true)
    private Output> state;

    /**
     * @return Possible states of the rule
     * 
     */
    public Output> state() {
        return this.state;
    }

    /**
     * The suppression conditions
     * 
     */
    @Import(name="suppressionAlertsScope")
    private @Nullable Output suppressionAlertsScope;

    /**
     * @return The suppression conditions
     * 
     */
    public Optional> suppressionAlertsScope() {
        return Optional.ofNullable(this.suppressionAlertsScope);
    }

    private AlertsSuppressionRuleArgs() {}

    private AlertsSuppressionRuleArgs(AlertsSuppressionRuleArgs $) {
        this.alertType = $.alertType;
        this.alertsSuppressionRuleName = $.alertsSuppressionRuleName;
        this.comment = $.comment;
        this.expirationDateUtc = $.expirationDateUtc;
        this.reason = $.reason;
        this.state = $.state;
        this.suppressionAlertsScope = $.suppressionAlertsScope;
    }

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

    public static final class Builder {
        private AlertsSuppressionRuleArgs $;

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

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

        /**
         * @param alertType Type of the alert to automatically suppress. For all alert types, use '*'
         * 
         * @return builder
         * 
         */
        public Builder alertType(Output alertType) {
            $.alertType = alertType;
            return this;
        }

        /**
         * @param alertType Type of the alert to automatically suppress. For all alert types, use '*'
         * 
         * @return builder
         * 
         */
        public Builder alertType(String alertType) {
            return alertType(Output.of(alertType));
        }

        /**
         * @param alertsSuppressionRuleName The unique name of the suppression alert rule
         * 
         * @return builder
         * 
         */
        public Builder alertsSuppressionRuleName(@Nullable Output alertsSuppressionRuleName) {
            $.alertsSuppressionRuleName = alertsSuppressionRuleName;
            return this;
        }

        /**
         * @param alertsSuppressionRuleName The unique name of the suppression alert rule
         * 
         * @return builder
         * 
         */
        public Builder alertsSuppressionRuleName(String alertsSuppressionRuleName) {
            return alertsSuppressionRuleName(Output.of(alertsSuppressionRuleName));
        }

        /**
         * @param comment Any comment regarding the rule
         * 
         * @return builder
         * 
         */
        public Builder comment(@Nullable Output comment) {
            $.comment = comment;
            return this;
        }

        /**
         * @param comment Any comment regarding the rule
         * 
         * @return builder
         * 
         */
        public Builder comment(String comment) {
            return comment(Output.of(comment));
        }

        /**
         * @param expirationDateUtc Expiration date of the rule, if value is not provided or provided as null there will no expiration at all
         * 
         * @return builder
         * 
         */
        public Builder expirationDateUtc(@Nullable Output expirationDateUtc) {
            $.expirationDateUtc = expirationDateUtc;
            return this;
        }

        /**
         * @param expirationDateUtc Expiration date of the rule, if value is not provided or provided as null there will no expiration at all
         * 
         * @return builder
         * 
         */
        public Builder expirationDateUtc(String expirationDateUtc) {
            return expirationDateUtc(Output.of(expirationDateUtc));
        }

        /**
         * @param reason The reason for dismissing the alert
         * 
         * @return builder
         * 
         */
        public Builder reason(Output reason) {
            $.reason = reason;
            return this;
        }

        /**
         * @param reason The reason for dismissing the alert
         * 
         * @return builder
         * 
         */
        public Builder reason(String reason) {
            return reason(Output.of(reason));
        }

        /**
         * @param state Possible states of the rule
         * 
         * @return builder
         * 
         */
        public Builder state(Output> state) {
            $.state = state;
            return this;
        }

        /**
         * @param state Possible states of the rule
         * 
         * @return builder
         * 
         */
        public Builder state(Either state) {
            return state(Output.of(state));
        }

        /**
         * @param state Possible states of the rule
         * 
         * @return builder
         * 
         */
        public Builder state(String state) {
            return state(Either.ofLeft(state));
        }

        /**
         * @param state Possible states of the rule
         * 
         * @return builder
         * 
         */
        public Builder state(RuleState state) {
            return state(Either.ofRight(state));
        }

        /**
         * @param suppressionAlertsScope The suppression conditions
         * 
         * @return builder
         * 
         */
        public Builder suppressionAlertsScope(@Nullable Output suppressionAlertsScope) {
            $.suppressionAlertsScope = suppressionAlertsScope;
            return this;
        }

        /**
         * @param suppressionAlertsScope The suppression conditions
         * 
         * @return builder
         * 
         */
        public Builder suppressionAlertsScope(SuppressionAlertsScopeArgs suppressionAlertsScope) {
            return suppressionAlertsScope(Output.of(suppressionAlertsScope));
        }

        public AlertsSuppressionRuleArgs build() {
            if ($.alertType == null) {
                throw new MissingRequiredPropertyException("AlertsSuppressionRuleArgs", "alertType");
            }
            if ($.reason == null) {
                throw new MissingRequiredPropertyException("AlertsSuppressionRuleArgs", "reason");
            }
            if ($.state == null) {
                throw new MissingRequiredPropertyException("AlertsSuppressionRuleArgs", "state");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy