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

package com.azure.resourcemanager.security.models;

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

/** The status of the long run operation result of governance rule. */
public final class OperationResult extends ExpandableStringEnum<OperationResult> {
    /** Static value Succeeded for OperationResult. */
    public static final OperationResult SUCCEEDED = fromString("Succeeded");

    /** Static value Failed for OperationResult. */
    public static final OperationResult FAILED = fromString("Failed");

    /** Static value Canceled for OperationResult. */
    public static final OperationResult CANCELED = fromString("Canceled");

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

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

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