google.cloud.dialogflow.v2.Intent.Message.SelectItemInfo
*/
class Intent_Message_SelectItemInfo extends \Google\Protobuf\Internal\Message
{
/**
* Required. A unique key that will be sent back to the agent if this
* response is given.
*
* Generated from protobuf field string key = 1;
*/
private $key = '';
/**
* Optional. A list of synonyms that can also be used to trigger this
* item in dialog.
*
* Generated from protobuf field repeated string synonyms = 2;
*/
private $synonyms;
public function __construct() {
\GPBMetadata\Google\Cloud\Dialogflow\V2\Intent::initOnce();
parent::__construct();
}
/**
* Required. A unique key that will be sent back to the agent if this
* response is given.
*
* Generated from protobuf field string key = 1;
* @return string
*/
public function getKey()
{
return $this->key;
}
/**
* Required. A unique key that will be sent back to the agent if this
* response is given.
*
* Generated from protobuf field string key = 1;
* @param string $var
* @return $this
*/
public function setKey($var)
{
GPBUtil::checkString($var, True);
$this->key = $var;
return $this;
}
/**
* Optional. A list of synonyms that can also be used to trigger this
* item in dialog.
*
* Generated from protobuf field repeated string synonyms = 2;
* @return \Google\Protobuf\Internal\RepeatedField
*/
public function getSynonyms()
{
return $this->synonyms;
}
/**
* Optional. A list of synonyms that can also be used to trigger this
* item in dialog.
*
* Generated from protobuf field repeated string synonyms = 2;
* @param string[]|\Google\Protobuf\Internal\RepeatedField $var
* @return $this
*/
public function setSynonyms($var)
{
$arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
$this->synonyms = $arr;
return $this;
}
}