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

com.pulumi.azurenative.alertsmanagement.outputs.AlertProcessingRulePropertiesResponse Maven / Gradle / Ivy

There is a newer version: 2.89.2
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.alertsmanagement.outputs;

import com.pulumi.azurenative.alertsmanagement.outputs.AddActionGroupsResponse;
import com.pulumi.azurenative.alertsmanagement.outputs.ConditionResponse;
import com.pulumi.azurenative.alertsmanagement.outputs.RemoveAllActionGroupsResponse;
import com.pulumi.azurenative.alertsmanagement.outputs.ScheduleResponse;
import com.pulumi.core.Either;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class AlertProcessingRulePropertiesResponse {
    /**
     * @return Actions to be applied.
     * 
     */
    private List> actions;
    /**
     * @return Conditions on which alerts will be filtered.
     * 
     */
    private @Nullable List conditions;
    /**
     * @return Description of alert processing rule.
     * 
     */
    private @Nullable String description;
    /**
     * @return Indicates if the given alert processing rule is enabled or disabled.
     * 
     */
    private @Nullable Boolean enabled;
    /**
     * @return Scheduling for alert processing rule.
     * 
     */
    private @Nullable ScheduleResponse schedule;
    /**
     * @return Scopes on which alert processing rule will apply.
     * 
     */
    private List scopes;

    private AlertProcessingRulePropertiesResponse() {}
    /**
     * @return Actions to be applied.
     * 
     */
    public List> actions() {
        return this.actions;
    }
    /**
     * @return Conditions on which alerts will be filtered.
     * 
     */
    public List conditions() {
        return this.conditions == null ? List.of() : this.conditions;
    }
    /**
     * @return Description of alert processing rule.
     * 
     */
    public Optional description() {
        return Optional.ofNullable(this.description);
    }
    /**
     * @return Indicates if the given alert processing rule is enabled or disabled.
     * 
     */
    public Optional enabled() {
        return Optional.ofNullable(this.enabled);
    }
    /**
     * @return Scheduling for alert processing rule.
     * 
     */
    public Optional schedule() {
        return Optional.ofNullable(this.schedule);
    }
    /**
     * @return Scopes on which alert processing rule will apply.
     * 
     */
    public List scopes() {
        return this.scopes;
    }

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

    public static Builder builder(AlertProcessingRulePropertiesResponse defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private List> actions;
        private @Nullable List conditions;
        private @Nullable String description;
        private @Nullable Boolean enabled;
        private @Nullable ScheduleResponse schedule;
        private List scopes;
        public Builder() {}
        public Builder(AlertProcessingRulePropertiesResponse defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.actions = defaults.actions;
    	      this.conditions = defaults.conditions;
    	      this.description = defaults.description;
    	      this.enabled = defaults.enabled;
    	      this.schedule = defaults.schedule;
    	      this.scopes = defaults.scopes;
        }

        @CustomType.Setter
        public Builder actions(List> actions) {
            if (actions == null) {
              throw new MissingRequiredPropertyException("AlertProcessingRulePropertiesResponse", "actions");
            }
            this.actions = actions;
            return this;
        }
        public Builder actions(Either... actions) {
            return actions(List.of(actions));
        }
        @CustomType.Setter
        public Builder conditions(@Nullable List conditions) {

            this.conditions = conditions;
            return this;
        }
        public Builder conditions(ConditionResponse... conditions) {
            return conditions(List.of(conditions));
        }
        @CustomType.Setter
        public Builder description(@Nullable String description) {

            this.description = description;
            return this;
        }
        @CustomType.Setter
        public Builder enabled(@Nullable Boolean enabled) {

            this.enabled = enabled;
            return this;
        }
        @CustomType.Setter
        public Builder schedule(@Nullable ScheduleResponse schedule) {

            this.schedule = schedule;
            return this;
        }
        @CustomType.Setter
        public Builder scopes(List scopes) {
            if (scopes == null) {
              throw new MissingRequiredPropertyException("AlertProcessingRulePropertiesResponse", "scopes");
            }
            this.scopes = scopes;
            return this;
        }
        public Builder scopes(String... scopes) {
            return scopes(List.of(scopes));
        }
        public AlertProcessingRulePropertiesResponse build() {
            final var _resultValue = new AlertProcessingRulePropertiesResponse();
            _resultValue.actions = actions;
            _resultValue.conditions = conditions;
            _resultValue.description = description;
            _resultValue.enabled = enabled;
            _resultValue.schedule = schedule;
            _resultValue.scopes = scopes;
            return _resultValue;
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy