Tying to generate auto doc using ApiGen. Have add followed comment for doc generation. I was hope that block in "code" will make same appearance as in short's description, but it does not work. I'm not sure how to make the same. Are there some method?
/**
* Short desc
*
* @param array $tabs
*
* For example
* <code>
* $admin_tabs = array(
* 'AdminDeliveryManager' => array('name' => 'Delivery manager', 'id_parent' => 0),
* 'AdminRole' => array('name' => 'Admin role', 'id_parent' => -1),
* 'AdminEmployeeRole' => array('name' => 'Admin role', 'id_parent' => -1)
* );
* </code>
*
* @return boolean true if all tabs created / false if have some error
*/
答案 0 :(得分:1)
ApiGen首先需要简单的描述,然后是所有的标记行。
如何使用该函数的示例应该放在@example
标记中,如下所示:
/**
* Short desc
*
* @param array $tabs
* @return boolean true if all tabs created / false if have some error
* @example
* <code>
* $admin_tabs = array(
* 'AdminDeliveryManager' => array('name' => 'Delivery manager', 'id_parent' => 0),
* 'AdminRole' => array('name' => 'Admin role', 'id_parent' => -1),
* 'AdminEmployeeRole' => array('name' => 'Admin role', 'id_parent' => -1)
* );
* createTabs($admin_tabs);
* </code>
*/