What is meant by class loader ? How many types are there? When will we use them ?

What is meant by class loader ? How many types are there? When will we use them ?

The Class.forName() loads the class into the JVM.
It loads the class into the JVM for further use.
We use this when we want to load JDBC-ODBC drivers.
Class Loader is a part of JVM used to load the classes dynamically. It will load the classes based on demand. Diffrent types of class loaders are extension class loader, system class loader and bootstrap class loader. Bootstrap class loader loads the classes in rt.jar and i18n.jar, extension class loader loads the class in ext dir, system class loader loads all other classes in the class path.
 two type. 
1) Static Loading. 
2) Dynamic Loading. Dynamic way is done by the help of class.forName();
Extensions Class Loader,System Class Loader.

By:Sumit Tripathi
Date:2026-05-15 00:00:00

Post Your Answers


User Email:

User Name:
Answers:

Related Java Subjective Links

Java Subjective interview questions and answers for experienced and fresher