$test = new Test(); $DocClass = new DocClass(); $file_name = __DIR__ . "/doc/" . "index.html"; /* * get all class methods */ $class_methods = get_class_methods($test); $r = new ReflectionClass($test); $menus = array(); $i = 0; foreach ($class_methods as $func) { $fn = $r->getMethod($func)->getDocComment(); /* * get name */ $name = $DocClass->getDocCommentObject('name', $fn); $name = $DocClass->filterObj($name[1][0]); $menus[$i]['name'] = $name; /* * get method */ $method = $DocClass->getDocCommentObject('method', $fn); $method = $DocClass->filterObj($method[1][0]); $menus[$i]['method'] = $method; /* * get parms */ $param = $DocClass->getDocCommentObject('parms', $fn); $param = $DocClass->filterObj($param[1]); /* * get url