类 ReflectionHints
java.lang.Object
cn.taketoday.aot.hint.ReflectionHints
Gather the need for reflection at runtime.
- 从以下版本开始:
- 4.0
- 作者:
- Stephane Nicoll, Phillip Webb, Andy Wilkinson, Sebastien Deleuze
-
字段概要
字段 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明getTypeHint(TypeReference type) Return the reflection hints for the type defined by the specifiedTypeReference.getTypeHint(Class<?> type) Return the reflection hints for the specified type.private List<TypeReference>mapParameters(Executable executable) registerConstructor(Constructor<?> constructor, ExecutableMode mode) Register the need for reflection on the specifiedConstructor, using the specifiedExecutableMode.registerField(Field field) Register the need for reflection on the specifiedField.registerMethod(Method method, ExecutableMode mode) Register the need for reflection on the specifiedMethod, using the specifiedExecutableMode.registerType(TypeReference type, MemberCategory... memberCategories) Register or customize reflection hints for the specified type using the specifiedMemberCategories.registerType(TypeReference type, Consumer<TypeHint.Builder> typeHint) Register or customize reflection hints for the type defined by the specifiedTypeReference.registerType(Class<?> type, MemberCategory... memberCategories) Register or customize reflection hints for the specified type using the specifiedMemberCategories.registerType(Class<?> type, Consumer<TypeHint.Builder> typeHint) Register or customize reflection hints for the specified type.registerTypeIfPresent(ClassLoader classLoader, String typeName, MemberCategory... memberCategories) Register or customize reflection hints for the specified type if it is available using the specifiedClassLoader.registerTypeIfPresent(ClassLoader classLoader, String typeName, Consumer<TypeHint.Builder> typeHint) Register or customize reflection hints for the specified type if it is available using the specifiedClassLoader.registerTypes(Iterable<TypeReference> types, Consumer<TypeHint.Builder> typeHint) Register or customize reflection hints for the types defined by the specified list oftype references.Return the types that require reflection.
-
字段详细资料
-
types
-
-
构造器详细资料
-
ReflectionHints
public ReflectionHints()
-
-
方法详细资料
-
typeHints
Return the types that require reflection.- 返回:
- the type hints
-
getTypeHint
Return the reflection hints for the type defined by the specifiedTypeReference.- 参数:
type- the type to inspect- 返回:
- the reflection hints for this type, or
null
-
getTypeHint
Return the reflection hints for the specified type.- 参数:
type- the type to inspect- 返回:
- the reflection hints for this type, or
null
-
registerType
Register or customize reflection hints for the type defined by the specifiedTypeReference.- 参数:
type- the type to customizetypeHint- a builder to further customize hints for that type- 返回:
this, to facilitate method chaining- 另请参阅:
-
registerType
Register or customize reflection hints for the specified type using the specifiedMemberCategories.- 参数:
type- the type to customizememberCategories- the member categories to apply- 返回:
this, to facilitate method chaining
-
registerType
Register or customize reflection hints for the specified type.- 参数:
type- the type to customizetypeHint- a builder to further customize hints for that type- 返回:
this, to facilitate method chaining- 另请参阅:
-
registerType
Register or customize reflection hints for the specified type using the specifiedMemberCategories.- 参数:
type- the type to customizememberCategories- the member categories to apply- 返回:
this, to facilitate method chaining
-
registerTypeIfPresent
public ReflectionHints registerTypeIfPresent(@Nullable ClassLoader classLoader, String typeName, Consumer<TypeHint.Builder> typeHint) Register or customize reflection hints for the specified type if it is available using the specifiedClassLoader.- 参数:
classLoader- the classloader to use to check if the type is presenttypeName- the type to customizetypeHint- a builder to further customize hints for that type- 返回:
this, to facilitate method chaining- 另请参阅:
-
registerTypeIfPresent
public ReflectionHints registerTypeIfPresent(@Nullable ClassLoader classLoader, String typeName, MemberCategory... memberCategories) Register or customize reflection hints for the specified type if it is available using the specifiedClassLoader.- 参数:
classLoader- the classloader to use to check if the type is presenttypeName- the type to customizememberCategories- the member categories to apply- 返回:
this, to facilitate method chaining
-
registerTypes
public ReflectionHints registerTypes(Iterable<TypeReference> types, Consumer<TypeHint.Builder> typeHint) Register or customize reflection hints for the types defined by the specified list oftype references. The specifiedtypeHintconsumer is invoked for each type.- 参数:
types- the types to customizetypeHint- a builder to further customize hints for each type- 返回:
this, to facilitate method chaining
-
registerField
Register the need for reflection on the specifiedField.- 参数:
field- the field that requires reflection- 返回:
this, to facilitate method chaining
-
registerConstructor
Register the need for reflection on the specifiedConstructor, using the specifiedExecutableMode.- 参数:
constructor- the constructor that requires reflectionmode- the requested mode- 返回:
this, to facilitate method chaining
-
registerMethod
Register the need for reflection on the specifiedMethod, using the specifiedExecutableMode.- 参数:
method- the method that requires reflectionmode- the requested mode- 返回:
this, to facilitate method chaining
-
mapParameters
-