As an example of a class loader hierarchy in action, Figure 1 shows the class loader hierarchy defined by the Tomcat servlet engine.
作为类装入器层次结构的实际示例,图1显示了Tomcatservlet引擎定义的类装入器层次结构。
When there is a hierarchy of class loaders, the root class loader, which is the bootstrap class loader, attempts to load the class first.
当类加载器存在一个层次结构时,根类加载器(即引导类加载器)将首先尝试加载类。
In the Tomcat hierarchy of class loaders shown in Figure 1, for instance, classes loaded by the Common class loader will never be able to directly access (by name) classes loaded by a Web application.
例如,在图1显示的Tomcat类装入器层次结构中,由common类装入器装入的类决不能(根据名称)直接访问由Web应用程序装入的类。
In the Tomcat hierarchy of class loaders shown in Figure 1, for instance, classes loaded by the Common class loader will never be able to directly access (by name) classes loaded by a Web application.
例如,在图1显示的Tomcat类装入器层次结构中,由common类装入器装入的类决不能(根据名称)直接访问由Web应用程序装入的类。
应用推荐