<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/dialogflow/v2/conversation_profile.proto

namespace Google\Cloud\Dialogflow\V2\SuggestionFeature;

use UnexpectedValueException;

/**
 * Defines the type of Human Agent Assistant feature.
 *
 * Protobuf type <code>google.cloud.dialogflow.v2.SuggestionFeature.Type</code>
 */
class Type
{
    /**
     * Unspecified feature type.
     *
     * Generated from protobuf enum <code>TYPE_UNSPECIFIED = 0;</code>
     */
    const TYPE_UNSPECIFIED = 0;
    /**
     * Run article suggestion model.
     *
     * Generated from protobuf enum <code>ARTICLE_SUGGESTION = 1;</code>
     */
    const ARTICLE_SUGGESTION = 1;
    /**
     * Run FAQ model.
     *
     * Generated from protobuf enum <code>FAQ = 2;</code>
     */
    const FAQ = 2;
    /**
     * Run smart reply model.
     *
     * Generated from protobuf enum <code>SMART_REPLY = 3;</code>
     */
    const SMART_REPLY = 3;

    private static $valueToName = [
        self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED',
        self::ARTICLE_SUGGESTION => 'ARTICLE_SUGGESTION',
        self::FAQ => 'FAQ',
        self::SMART_REPLY => 'SMART_REPLY',
    ];

    public static function name($value)
    {
        if (!isset(self::$valueToName[$value])) {
            throw new UnexpectedValueException(sprintf(
                    'Enum %s has no name defined for value %s', __CLASS__, $value));
        }
        return self::$valueToName[$value];
    }


    public static function value($name)
    {
        $const = __CLASS__ . '::' . strtoupper($name);
        if (!defined($const)) {
            throw new UnexpectedValueException(sprintf(
                    'Enum %s has no value defined for name %s', __CLASS__, $name));
        }
        return constant($const);
    }
}

// Adding a class alias for backwards compatibility with the previous class name.
class_alias(Type::class, \Google\Cloud\Dialogflow\V2\SuggestionFeature_Type::class);

