Enum Class MergedAnnotations.SearchStrategy
- 所有已实现的接口:
Serializable,Comparable<MergedAnnotations.SearchStrategy>,Constable
- 封闭接口:
- MergedAnnotations
MergedAnnotations.search(SearchStrategy)
as well as MergedAnnotations.from(AnnotatedElement, SearchStrategy)
and variants of that method.
Each strategy creates a different set of aggregates that will be
combined to create the final MergedAnnotations.
-
嵌套类概要
从类继承的嵌套类/接口 java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
枚举常量概要
枚举常量枚举常量说明Find only directly declared annotations, without considering@Inheritedannotations and without searching superclasses or implemented interfaces.Find all directly declared annotations as well as any@Inheritedsuperclass annotations.Find all directly declared and superclass annotations.Perform a full search of the entire type hierarchy, including superclasses and implemented interfaces. -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明Returns the enum constant of this class with the specified name.static MergedAnnotations.SearchStrategy[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
枚举常量详细资料
-
DIRECT
Find only directly declared annotations, without considering@Inheritedannotations and without searching superclasses or implemented interfaces. -
INHERITED_ANNOTATIONS
Find all directly declared annotations as well as any@Inheritedsuperclass annotations.This strategy is only really useful when used with
Classtypes since the@Inheritedannotation is ignored for all other annotated elements.This strategy does not search implemented interfaces.
-
SUPERCLASS
Find all directly declared and superclass annotations.This strategy is similar to
INHERITED_ANNOTATIONSexcept the annotations do not need to be meta-annotated with@Inherited.This strategy does not search implemented interfaces.
-
TYPE_HIERARCHY
Perform a full search of the entire type hierarchy, including superclasses and implemented interfaces.When combined with
MergedAnnotations.Search.withEnclosingClasses(Predicate), enclosing classes will also be recursively searched if the suppliedPredicateevaluates totrue.Superclass and enclosing class annotations do not need to be meta-annotated with
@Inherited.
-
-
构造器详细资料
-
SearchStrategy
private SearchStrategy()
-
-
方法详细资料
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- 返回:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- 参数:
name- 要返回的枚举常量的名称。- 返回:
- 返回带有指定名称的枚举常量
- 抛出:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- 如果参数为空值
-