Class ReflectionBeanIntrospection<T>

java.lang.Object
io.micronaut.reflection.ReflectionBeanIntrospection<T>
Type Parameters:
T - The bean type
All Implemented Interfaces:
AnnotationMetadata, AnnotationMetadataDelegate, AnnotationMetadataProvider, AnnotationSource, BeanInfo<T>, BeanIntrospection<T>, Ordered, ArgumentCoercible<T>, ReflectiveIntrospection<T>

public final class ReflectionBeanIntrospection<T> extends Object implements ReflectiveIntrospection<T>
A BeanIntrospection over a Class, with the properties, the constructor and the methods a generated introspection would have.

A property is a getter or a setter of the type or of its super classes - named by the prefixes AccessorsStyle declares, get, is and set by default - merged by name, with the field of that name as a member of it: it is read through the getter when there is one and through the field otherwise, written through the setter when there is one and through a non-final field otherwise, and its metadata holds the annotations of all three together with the type-use annotations of the property type. Only an accessor the visibility of the type admits makes a property - by default one the type reaches without reflection: a public one, or a non-private one declared in its own package - and a field alone makes one only when field access is asked for - Introspected.accessKind() on the type, or the access kinds given to of(Class, Set) - which is what the processors admit. The value goes through the members the access kinds admit: an accessor under method access, the field under field access, and a getter beside a private setter or a field no access kind admits makes a read-only property. The accessor of a record component always makes a property, and so does a member annotated Introspected.Property, under the name of the method when the method carries no prefix, read and written as its access kinds allow. A bean method is a public instance method of the type, of its super classes or of its interfaces, Object excluded. The constructor is the static factory annotated Creator when the type declares one, else the constructor annotated Creator, else the only public one, else the public one with no parameter, else the declared one with the most parameters; a type naming a builder in Introspected.builder() is built through that builder.

The type of a property, of a method argument and of a return type is the type the bean type sees: T declared by a Box<T> and read through a StringBox extends Box<String> is String, not the bound of the variable.

Since:
5.2.0
Author:
Denis Stepanov