Reflection or runtime introspection is a powerful feature in Java. some cool features we use in Spring like copyProperties, core concepts are come from Jdk only.
Under JDK java.beans package, there are some key classes used for reflection.
Introspector
BeanInfo
PropertyDescriptor
MethodDescriptor
Introspector: It conducts introspective analysis of a JavaBean class through the getBeanInfo method and generates a BeanInfo object.
BeanInfo: It contains an array of property descriptors and an array of method descriptors of a JavaBean.
PropertyDescriptor: It represents a property of a JavaBean and includes the property name, property type, the reading method (getter), and the writing method (setter).
MethodDescriptor: It represents a method in a JavaBean and contains a Method object.
Method: It is a class in the Java reflection mechanism. Both the PropertyDescriptor and MethodDescriptor reference it, which is used to call methods at runtime.
Copyright Declaration: This station is mainly used to sort out incomprehensible knowledge. I have not fully mastered most of the content. Please refer carefully.