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

namespace Google\Cloud\Dialogflow\V2;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\GPBUtil;
use Google\Protobuf\RepeatedField;

/**
 * The request message for
 * [ConversationModels.CreateConversationModelEvaluation][google.cloud.dialogflow.v2.ConversationModels.CreateConversationModelEvaluation]
 *
 * Generated from protobuf message <code>google.cloud.dialogflow.v2.CreateConversationModelEvaluationRequest</code>
 */
class CreateConversationModelEvaluationRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Required. The conversation model resource name. Format:
     * `projects/<Project ID>/locations/<Location
     * ID>/conversationModels/<Conversation Model ID>`
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     */
    protected $parent = '';
    /**
     * Required. The conversation model evaluation to be created.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.ConversationModelEvaluation conversation_model_evaluation = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $conversation_model_evaluation = null;

    /**
     * @param string                                                  $parent                      Required. The conversation model resource name. Format:
     *                                                                                             `projects/<Project ID>/locations/<Location
     *                                                                                             ID>/conversationModels/<Conversation Model ID>`
     *                                                                                             Please see {@see ConversationModelsClient::conversationModelName()} for help formatting this field.
     * @param \Google\Cloud\Dialogflow\V2\ConversationModelEvaluation $conversationModelEvaluation Required. The conversation model evaluation to be created.
     *
     * @return \Google\Cloud\Dialogflow\V2\CreateConversationModelEvaluationRequest
     *
     * @experimental
     */
    public static function build(string $parent, \Google\Cloud\Dialogflow\V2\ConversationModelEvaluation $conversationModelEvaluation): self
    {
        return (new self())
            ->setParent($parent)
            ->setConversationModelEvaluation($conversationModelEvaluation);
    }

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $parent
     *           Required. The conversation model resource name. Format:
     *           `projects/<Project ID>/locations/<Location
     *           ID>/conversationModels/<Conversation Model ID>`
     *     @type \Google\Cloud\Dialogflow\V2\ConversationModelEvaluation $conversation_model_evaluation
     *           Required. The conversation model evaluation to be created.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Dialogflow\V2\ConversationModel::initOnce();
        parent::__construct($data);
    }

    /**
     * Required. The conversation model resource name. Format:
     * `projects/<Project ID>/locations/<Location
     * ID>/conversationModels/<Conversation Model ID>`
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getParent()
    {
        return $this->parent;
    }

    /**
     * Required. The conversation model resource name. Format:
     * `projects/<Project ID>/locations/<Location
     * ID>/conversationModels/<Conversation Model ID>`
     *
     * Generated from protobuf field <code>string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setParent($var)
    {
        GPBUtil::checkString($var, True);
        $this->parent = $var;

        return $this;
    }

    /**
     * Required. The conversation model evaluation to be created.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.ConversationModelEvaluation conversation_model_evaluation = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\Dialogflow\V2\ConversationModelEvaluation|null
     */
    public function getConversationModelEvaluation()
    {
        return $this->conversation_model_evaluation;
    }

    public function hasConversationModelEvaluation()
    {
        return isset($this->conversation_model_evaluation);
    }

    public function clearConversationModelEvaluation()
    {
        unset($this->conversation_model_evaluation);
    }

    /**
     * Required. The conversation model evaluation to be created.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.ConversationModelEvaluation conversation_model_evaluation = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\Dialogflow\V2\ConversationModelEvaluation $var
     * @return $this
     */
    public function setConversationModelEvaluation($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dialogflow\V2\ConversationModelEvaluation::class);
        $this->conversation_model_evaluation = $var;

        return $this;
    }

}

