<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/ces/v1/app.proto

namespace Google\Cloud\Ces\V1\EvaluationMetricsThresholds\GoldenEvaluationMetricsThresholds\TurnLevelMetricsThresholds;

use UnexpectedValueException;

/**
 * Semantic similarity channel to use.
 *
 * Protobuf type <code>google.cloud.ces.v1.EvaluationMetricsThresholds.GoldenEvaluationMetricsThresholds.TurnLevelMetricsThresholds.SemanticSimilarityChannel</code>
 */
class SemanticSimilarityChannel
{
    /**
     * Metric unspecified. Defaults to TEXT.
     *
     * Generated from protobuf enum <code>SEMANTIC_SIMILARITY_CHANNEL_UNSPECIFIED = 0;</code>
     */
    const SEMANTIC_SIMILARITY_CHANNEL_UNSPECIFIED = 0;
    /**
     * Use text semantic similarity.
     *
     * Generated from protobuf enum <code>TEXT = 1;</code>
     */
    const TEXT = 1;
    /**
     * Use audio semantic similarity.
     *
     * Generated from protobuf enum <code>AUDIO = 2;</code>
     */
    const AUDIO = 2;

    private static $valueToName = [
        self::SEMANTIC_SIMILARITY_CHANNEL_UNSPECIFIED => 'SEMANTIC_SIMILARITY_CHANNEL_UNSPECIFIED',
        self::TEXT => 'TEXT',
        self::AUDIO => 'AUDIO',
    ];

    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);
    }
}


