/**
  * @depends testGetName
  */
 public function testSetName()
 {
     $var = new VariableNode(T_VARIABLE, '$x');
     $var->setName('$y');
     $this->assertEquals('y', $var->getName());
     $var->setName('z');
     $this->assertEquals('z', $var->getName());
 }
Ejemplo n.º 2
0
 /**
  * Get the doc block tag associated with this parameter.
  *
  * @return null|\phpDocumentor\Reflection\DocBlock\Tag\ParamTag
  *   The parameter tag or null if not found.
  */
 public function getDocBlockTag()
 {
     $doc_comment = $this->getFunction()->getDocComment();
     return $doc_comment ? $doc_comment->getParameter($this->name->getText()) : NULL;
 }