PHP code example of lascyb / tp6-multi-app-reflection-parsing
1. Go to this page and download the library: Download lascyb/tp6-multi-app-reflection-parsing library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
lascyb / tp6-multi-app-reflection-parsing example snippets
$node=(
new \lascyb\Tp6MultiAppReflectionParsing(
["admin",'home','api',"index"],
["node","group","param"=>"/@param[ ]*(.*)[ ]*\n/"]
)
)->getNodes();
angular2html
array:3 [▼
"admin" => array:3 [▼
"Index" => array:3 [▼
"reflection" => ReflectionClass {#68 ▶}
"class" => "app\admin\controller\Index"
"methods" => array:6 [▼
"index" => array:4 [▼
"ref" => array:3 [▼
"node" => array:1 [▼
0 => array:2 [▼
0 => "@node = "列表""
1 => "列表"
]
]
"group" => array:1 [▶]
"param" => array:2 [▼
0 => array:2 [▼
0 => "@param string $name"
1 => "string $name"
]
1 => array:2 [▼
0 => "@param int $age"
1 => "int $age"
]
]
]
"doc" => """
/**
* @node = "列表"
* @group = "mall/order"
*
* @param string $name
* @param int $age
* @return string
*/
"""
"reflection" => ReflectionMethod {#69 ▶}
"url" => "admin/Index/index"
]
"save" => array:4 [▶]
"read" => array:4 [▶]
"edit" => array:4 [▶]
"update" => array:4 [▶]
"delete" => array:4 [▶]
]
]
"mall.Order" => array:3 [▶]
"mall.user.Info" => array:3 [▶]
]
"api" => array:2 [▶]
"home" => array:1 [▶]
]