php - Get Comments on Properties -


i wondering if possible (easily) in php comments on class' properties e.g.:

/**  * test class * * @param int $testid primary * @param string $name * @param int $age * @param char $gender * @param date $dob */ class test extends dataobject {     /**     *     * want     *     */     public $testid = 0;     public $name = "";     public $age = 0;     public $gender = "m";     public $dob = ""; } 

i'm trying see if can comment property testid easily?

see reflectionproperty::getdoccomment

something like:

$prop = new reflectionproperty('test', 'testid'); print $prop->getdoccomment(); 

there's no doccomment parser built in, wrote 1 here if you're interested.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -