class
First, the class class can record information about the properties, methods, and so on for all classes. This is the runtime category tag, which records the class information for all objects (such as int,myclass,void, arrays, and so on ) .
Class Object
The JVM will have corresponding class objects for each object used, either this type of class object is created or a new class object is created .
ClassLoader class
the ClassLoader class is responsible for loading a class. That is, given this class-related name, locate or generate this class-related definition information. ClassLoader Object . LoadClass (" class name ") =classloader object . LoadClass (" class name ", parsing class = False).
The loading process of the class
load ------> Links ( verify ---- Prepare ---- Resolve "JVM replaces symbolic references in constant pools with direct references")------ > Initialize ------> ...
get the Class object
class. forname (" Name of Class" ) =class.forname (" Name of Class ", initialization =true,c Lassloader Object ), after the initialization of the CLass object, which is the execution of a static method in the class
ClassLoader.loadclass( fully qualified name of Class) does not perform initialization
To generate a new class object
The class object that was generated in the previous step executes the . newinstance () method
The initialization method of the class object is automatically executed when the n ew class name () is not initialized
In addition, if the parent class object is not initialized, the initialization method of the parent class class object is executed first when the subclass is called .
Class.forName and Classloader.loadclass, etc.