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

namespace Google\Cloud\Dialogflow\V2\HumanAgentAssistantConfig\SuggestionQueryConfig\Sections;

use UnexpectedValueException;

/**
 * Selectable sections to return when requesting a summary of a
 * conversation.
 *
 * Protobuf type <code>google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionQueryConfig.Sections.SectionType</code>
 */
class SectionType
{
    /**
     * Undefined section type, does not return anything.
     *
     * Generated from protobuf enum <code>SECTION_TYPE_UNSPECIFIED = 0;</code>
     */
    const SECTION_TYPE_UNSPECIFIED = 0;
    /**
     * What the customer needs help with or has question about.
     * Section name: "situation".
     *
     * Generated from protobuf enum <code>SITUATION = 1;</code>
     */
    const SITUATION = 1;
    /**
     * What the agent does to help the customer.
     * Section name: "action".
     *
     * Generated from protobuf enum <code>ACTION = 2;</code>
     */
    const ACTION = 2;
    /**
     * Result of the customer service. A single word describing the result
     * of the conversation.
     * Section name: "resolution".
     *
     * Generated from protobuf enum <code>RESOLUTION = 3;</code>
     */
    const RESOLUTION = 3;
    /**
     * Reason for cancellation if the customer requests for a cancellation.
     * "N/A" otherwise.
     * Section name: "reason_for_cancellation".
     *
     * Generated from protobuf enum <code>REASON_FOR_CANCELLATION = 4;</code>
     */
    const REASON_FOR_CANCELLATION = 4;
    /**
     * "Unsatisfied" or "Satisfied" depending on the customer's feelings at
     * the end of the conversation.
     * Section name: "customer_satisfaction".
     *
     * Generated from protobuf enum <code>CUSTOMER_SATISFACTION = 5;</code>
     */
    const CUSTOMER_SATISFACTION = 5;
    /**
     * Key entities extracted from the conversation, such as ticket number,
     * order number, dollar amount, etc.
     * Section names are prefixed by "entities/".
     *
     * Generated from protobuf enum <code>ENTITIES = 6;</code>
     */
    const ENTITIES = 6;

    private static $valueToName = [
        self::SECTION_TYPE_UNSPECIFIED => 'SECTION_TYPE_UNSPECIFIED',
        self::SITUATION => 'SITUATION',
        self::ACTION => 'ACTION',
        self::RESOLUTION => 'RESOLUTION',
        self::REASON_FOR_CANCELLATION => 'REASON_FOR_CANCELLATION',
        self::CUSTOMER_SATISFACTION => 'CUSTOMER_SATISFACTION',
        self::ENTITIES => 'ENTITIES',
    ];

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

