// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.ai.metricsadvisor.implementation.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;

/** The ChangeThresholdConditionPatch model. */
@Fluent
public final class ChangeThresholdConditionPatch {
    /*
     * change percentage, value range : [0, +∞)
     */
    @JsonProperty(value = "changePercentage")
    private Double changePercentage;

    /*
     * shift point, value range : [1, +∞)
     */
    @JsonProperty(value = "shiftPoint")
    private Integer shiftPoint;

    /*
     * if the withinRange = true, detected data is abnormal when the value falls in the range, in this case
     * anomalyDetectorDirection must be Both
     * if the withinRange = false, detected data is abnormal when the value falls out of the range
     */
    @JsonProperty(value = "withinRange")
    private Boolean withinRange;

    /*
     * detection direction
     */
    @JsonProperty(value = "anomalyDetectorDirection")
    private AnomalyDetectorDirection anomalyDetectorDirection;

    /*
     * The suppressCondition property.
     */
    @JsonProperty(value = "suppressCondition")
    private SuppressConditionPatch suppressCondition;

    /** Creates an instance of ChangeThresholdConditionPatch class. */
    public ChangeThresholdConditionPatch() {}

    /**
     * Get the changePercentage property: change percentage, value range : [0, +∞).
     *
     * @return the changePercentage value.
     */
    public Double getChangePercentage() {
        return this.changePercentage;
    }

    /**
     * Set the changePercentage property: change percentage, value range : [0, +∞).
     *
     * @param changePercentage the changePercentage value to set.
     * @return the ChangeThresholdConditionPatch object itself.
     */
    public ChangeThresholdConditionPatch setChangePercentage(Double changePercentage) {
        this.changePercentage = changePercentage;
        return this;
    }

    /**
     * Get the shiftPoint property: shift point, value range : [1, +∞).
     *
     * @return the shiftPoint value.
     */
    public Integer getShiftPoint() {
        return this.shiftPoint;
    }

    /**
     * Set the shiftPoint property: shift point, value range : [1, +∞).
     *
     * @param shiftPoint the shiftPoint value to set.
     * @return the ChangeThresholdConditionPatch object itself.
     */
    public ChangeThresholdConditionPatch setShiftPoint(Integer shiftPoint) {
        this.shiftPoint = shiftPoint;
        return this;
    }

    /**
     * Get the withinRange property: if the withinRange = true, detected data is abnormal when the value falls in the
     * range, in this case anomalyDetectorDirection must be Both if the withinRange = false, detected data is abnormal
     * when the value falls out of the range.
     *
     * @return the withinRange value.
     */
    public Boolean isWithinRange() {
        return this.withinRange;
    }

    /**
     * Set the withinRange property: if the withinRange = true, detected data is abnormal when the value falls in the
     * range, in this case anomalyDetectorDirection must be Both if the withinRange = false, detected data is abnormal
     * when the value falls out of the range.
     *
     * @param withinRange the withinRange value to set.
     * @return the ChangeThresholdConditionPatch object itself.
     */
    public ChangeThresholdConditionPatch setWithinRange(Boolean withinRange) {
        this.withinRange = withinRange;
        return this;
    }

    /**
     * Get the anomalyDetectorDirection property: detection direction.
     *
     * @return the anomalyDetectorDirection value.
     */
    public AnomalyDetectorDirection getAnomalyDetectorDirection() {
        return this.anomalyDetectorDirection;
    }

    /**
     * Set the anomalyDetectorDirection property: detection direction.
     *
     * @param anomalyDetectorDirection the anomalyDetectorDirection value to set.
     * @return the ChangeThresholdConditionPatch object itself.
     */
    public ChangeThresholdConditionPatch setAnomalyDetectorDirection(
            AnomalyDetectorDirection anomalyDetectorDirection) {
        this.anomalyDetectorDirection = anomalyDetectorDirection;
        return this;
    }

    /**
     * Get the suppressCondition property: The suppressCondition property.
     *
     * @return the suppressCondition value.
     */
    public SuppressConditionPatch getSuppressCondition() {
        return this.suppressCondition;
    }

    /**
     * Set the suppressCondition property: The suppressCondition property.
     *
     * @param suppressCondition the suppressCondition value to set.
     * @return the ChangeThresholdConditionPatch object itself.
     */
    public ChangeThresholdConditionPatch setSuppressCondition(SuppressConditionPatch suppressCondition) {
        this.suppressCondition = suppressCondition;
        return this;
    }
}
