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

package com.azure.resourcemanager.redis.models;

import com.azure.core.util.ExpandableStringEnum;
import com.fasterxml.jackson.annotation.JsonCreator;
import java.util.Collection;

/** Which Redis node(s) to reboot. Depending on this value data loss is possible. */
public final class RebootType extends ExpandableStringEnum<RebootType> {
    /** Static value PrimaryNode for RebootType. */
    public static final RebootType PRIMARY_NODE = fromString("PrimaryNode");

    /** Static value SecondaryNode for RebootType. */
    public static final RebootType SECONDARY_NODE = fromString("SecondaryNode");

    /** Static value AllNodes for RebootType. */
    public static final RebootType ALL_NODES = fromString("AllNodes");

    /**
     * Creates a new instance of RebootType value.
     *
     * @deprecated Use the {@link #fromString(String)} factory method.
     */
    @Deprecated
    public RebootType() {
    }

    /**
     * Creates or finds a RebootType from its string representation.
     *
     * @param name a name to look for.
     * @return the corresponding RebootType.
     */
    @JsonCreator
    public static RebootType fromString(String name) {
        return fromString(name, RebootType.class);
    }

    /**
     * Gets known RebootType values.
     *
     * @return known RebootType values.
     */
    public static Collection<RebootType> values() {
        return values(RebootType.class);
    }
}
