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

package com.azure.resourcemanager.mobilenetwork.models;

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

/** Preemption capability. */
public final class PreemptionCapability extends ExpandableStringEnum<PreemptionCapability> {
    /** Static value NotPreempt for PreemptionCapability. */
    public static final PreemptionCapability NOT_PREEMPT = fromString("NotPreempt");

    /** Static value MayPreempt for PreemptionCapability. */
    public static final PreemptionCapability MAY_PREEMPT = fromString("MayPreempt");

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

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

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