gossi\codegen\model\PhpProperty::generateDocblock PHP Method

generateDocblock() public method

Generates docblock based on provided information
public generateDocblock ( )
    public function generateDocblock()
    {
        $docblock = $this->getDocblock();
        $docblock->setShortDescription($this->getDescription());
        $docblock->setLongDescription($this->getLongDescription());
        // var tag
        $this->generateTypeTag(new VarTag());
    }

Usage Example

 public function testEmptyProperty()
 {
     $property = new PhpProperty(self::PROP);
     $property->generateDocblock();
     $this->assertTrue($property->getDocblock()->isEmpty());
 }