PHP code instant generator automatically adds documentation to classes, operations and attributes.
<?
/**
* @access public
*/
class Company {
/**
* @AssociationType Employee
* @AssociationMultiplicity 1..*
*/
public $employee = array();
}
?>
I know one can customize the VTL templates but the documentation is retrieved via .t_getDocumentation(…) method. Where does the method reach for the documentation. Is there a way to customize this so that for example attribute has only the following documentation:
<?
class Company {
/**
* @var Employee
*/
public $employee = array();
}
?>
Would you mind to send me a sample project and expectation based on your sample project so our engineers can understand your need precisely? Thanks in advance!
I have attached an archive with an example of the desired functionality:
phpdocexample.tar.gz - Example VP project
generated/*.php - The code generated by VP
expected/*.php - The generated code formatted to conform to phpdoc syntax
This example does not cover all of the possibilities for the generated documentation, just the basic class/attribute/operation stuff. It would be great if all of the generated documentation for php code conformed to the phpdoc syntax, or if we could have some degree of customization that would allow for this.
I apologize for my late response on this issue. Attached you can find a sample Instant Generator code template for PHP, and it can help you to generate the results you need.
Hope this helps. If there is anything else we can do to help, please feel free to ask.