Interface BeanIntrospectionFallback
- All Superinterfaces:
Ordered
- All Known Implementing Classes:
ReflectionBeanIntrospectionFallback
@Indexed(BeanIntrospectionFallback.class)
public interface BeanIntrospectionFallback
extends Ordered
Supplies a
BeanIntrospection for a type that has no generated one.
The default BeanIntrospector serves the introspections the annotation processors generated. When
it has none for a type it asks the fallbacks registered as services, in order, and returns the
first introspection one of them supplies. A fallback decides for itself which types it serves: the
micronaut-reflection module registers one that describes a class reflectively, but only the classes an
application allowed by configuration.
- Since:
- 5.2.0
- Author:
- Denis Stepanov
-
Field Summary
Fields inherited from interface Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Method Summary
Modifier and TypeMethodDescription<T> Optional<BeanIntrospection<T>> findIntrospection(Class<T> beanType) Finds an introspection for a type the introspector has no generated introspection for.
-
Method Details
-
findIntrospection
Finds an introspection for a type the introspector has no generated introspection for.- Type Parameters:
T- The bean type- Parameters:
beanType- The bean type- Returns:
- The introspection, or empty when this fallback does not serve the type
-