Zhamao Framework  3.0.0-beta1
A high-performance chatbot + web framework
AnnotationParser类 参考

Public 成员函数

 __construct (bool $with_internal_parsers=true)
 
 addSpecialParser (string $class_name, callable $callback)
 
 parse (array $path)
 
 parseAll ()
 
 generateAnnotationList ()
 
 parseSpecial ($annotation, $same_method_annotations=null)
 
 addRegisterPath (string $path, string $indoor_name)
 
 getUsedTime ()
 
 getAnnotationMap ()
 

详细描述

注解解析器

构造及析构函数说明

◆ __construct()

__construct ( bool  $with_internal_parsers = true)

AnnotationParser constructor.

函数调用图:

成员函数说明

◆ addRegisterPath()

addRegisterPath ( string  $path,
string  $indoor_name 
)

添加解析的路径

参数
string$path注册解析注解的路径
string$indoor_name起始命名空间的名称
函数调用图:

◆ addSpecialParser()

addSpecialParser ( string  $class_name,
callable  $callback 
)

设置自定义的注解解析方法

参数
string$class_name注解类名
callable$callback回调函数

◆ generateAnnotationList()

generateAnnotationList ( )

生成排序后的注解列表

◆ getAnnotationMap()

getAnnotationMap ( )

获取注解的注册map

◆ getUsedTime()

getUsedTime ( )

获取解析器调用的时间(秒)

◆ parse()

parse ( array  $path)
函数调用图:

◆ parseAll()

parseAll ( )

注册各个模块类的注解和模块level的排序

函数调用图:

◆ parseSpecial()

parseSpecial (   $annotation,
  $same_method_annotations = null 
)

该类的文档由以下文件生成: