Language/src/V1/Token.php
public function setPartOfSpeech($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Language\V1\PartOfSpeech::class);
        $this->part_of_speech = $var;

        return $this;
    }
public function setPartOfSpeech($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Language\V1\PartOfSpeech::class);
        $this->part_of_speech = $var;

        return $this;
    }
public function setPartOfSpeech ( $ var ) { GPBUtil :: checkMessage ( $ var , \ Google \ Cloud \ Language \ V1 \ PartOfSpeech :: class ) ; $ this -> part_of_speech = $ var ; return $ this ; }
Parts of speech tag for this token.

Generated from protobuf field <code>.google.cloud.language.v1.PartOfSpeech part_of_speech = 2;</code>
@param \Google\Cloud\Language\V1\PartOfSpeech $var
@return $this
Parts of speech tag for this token .