name() |
string |
名称 |
it.name() |
hasAnn("annotation_name") |
boolean |
是否有指定注解 |
it.hasAnn("org.springframework.web.bind.annotation.RequestBody") |
ann("annotation_name") |
string |
获取指定注解值(默认value) |
it.ann("org.springframework.web.bind.annotation.RequestBody") |
ann("annotation_name","attr") |
string |
获取指定注解中的指定参数值 |
it.ann("org.springframework.web.bind.annotation.RequestMapping","path") |
annMap("annotation_name") |
map |
获取指定注解所有的参数 |
it.annMap("org.springframework.web.bind.annotation.RequestMapping") |
annMaps("annotation_name") |
map[] |
获取指定可重复注解所有的参数 |
it.annMaps("javax.validation.constraints.Max") |
annValue("annotation_name") |
object |
获取指定注解值(默认value),与ann不同,会保持原有类型,不强制转换为string |
it.annValue("org.springframework.web.bind.annotation.RequestBody") |
annValue("annotation_name","attr") |
object |
获取指定注解中的指定参数值,与ann不同,会保持原有类型,不强制转换为string |
it.annValue("org.springframework.web.bind.annotation.RequestMapping","path") |
doc() |
string |
获取注释值 |
it.doc() |
doc("tag") |
string |
获取注释tag值(不需要加@) |
it.doc("return") |
docs("tag") |
array |
获取多个注释tag值(不需要加@) |
it.docs("see") |
doc("tag","subTag") |
string |
获取二级注释tag值 |
it.doc("param","a") |
hasDoc("tag") |
string |
是否有指定注释tag |
it.hasDoc("ignore") |
hasModifier("modifier") |
string |
是否有指定修饰 |
it.hasModifier("public") |
modifiers() |
string |
获取所有修饰 |
it.modifiers() |
sourceCode() |
string |
获取当前对象源码 |
it.sourceCode() |
defineCode() |
string |
获取当前对象纯定义代码 |
it.defineCode() |
contextType() |
string |
当前上下文类型 class/field/method/param |
it.contextType() |