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

package com.azure.resourcemanager.datamigration.models;

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

/** The reason why the name is not available, if nameAvailable is false. */
public final class NameCheckFailureReason extends ExpandableStringEnum<NameCheckFailureReason> {
    /** Static value AlreadyExists for NameCheckFailureReason. */
    public static final NameCheckFailureReason ALREADY_EXISTS = fromString("AlreadyExists");

    /** Static value Invalid for NameCheckFailureReason. */
    public static final NameCheckFailureReason INVALID = fromString("Invalid");

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

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

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