Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Login         

View Questions and Answers by Category

Advertisements


 
Have Programming Question? Ask it here!
 
 
 


Harjindra Singh
Class Loader
1 Answer(s)      2 years and 2 months ago
Posted in : Design concepts & design patterns


What is class loader? Explain in detail.


Advertisement
View Answers

July 30, 2012 at 10:25 AM


The Java ClassLoader is a an abstract class which extends the Object class. Java class loader is a part of the Java Runtime Environment that dynamically loads Java classes into the Java Virtual Machine. Generally Java virtual machine load the classes only on demand. It is not necessary for Java run time system to know about files and file systems because of class loaders. Delegation provides a concept to understand when learning about class loaders.

Libraries in java are usually packaged in Jar files. A software library is a collection of more or less related object code. Libraries may include different sorts of objects, while Java class is the most popular type of objects contained in a Jar file. A class can be supposed as a unit of code having a name. The class loader locates libraries, reads their contents, and loads the classes contained within the libraries. Loading does not occur until the program uses the class bcoz loading is done on demand. A classloader loads only once to a class with a given name.

A class loader should locate or generate data constituting a definition for the class. A usual strategy performs transformation of the name into a file name and then reads a file of that name from the file system. Class loader does not create class object for array classes, but they are automatically created since required by the Java runtime. For primitive type elements array class has no class loader. Subclasses of ClassLoader class are implemented by the applications so that the Java virtual machine can dynamically load classes.



Related Tutorials/Questions & Answers:
Class Loader
Class Loader  What is class loader? Explain in detail.   ... class loader is a part of the Java Runtime Environment that dynamically loads... be supposed as a unit of code having a name. The class loader locates libraries
Class Loader
Class Loader  What is class loader? Explain in detail.   ... class loader is a part of the Java Runtime Environment that dynamically loads... be supposed as a unit of code having a name. The class loader locates libraries
Advertisements
Class Loader
Class Loader      ... class loader is a part of the Java Runtime Environment that dynamically loads Java... be supposed as a unit of code having a name. The class loader locates libraries, reads
Mysql Loader Examples
Mysql Loader Examples       Mysql Loader Example is used to create the backup of data ... with Example The Tutorial illustrate an example from 'Mysql Loader Examples
Mysql Loader Examples
Mysql Loader Examples       Mysql Loader Example is used to create the backup...; Understand with Example The Tutorial illustrate an example from 'Mysql Loader
Mysql Loader Control File
Mysql Loader Control File       Mysql Loader Control File is the mean to import a data... illustrate an example from 'Mysql Loader Control File'.To grasp this example we create
Mysql Loader Control File
Mysql Loader Control File       Mysql Loader Control File is the mean to import a data... illustrate an example from 'Mysql Loader Control File'.To grasp this example we
Spring Context Loader Servlet
Spring Context Loader Servlet   ... loader servlet and then see how to add the required configuration... (org.springframework.web.context.ContextLoaderServlet) Context Loader Servlet start up
class
class  Is a class a subclass of itself
class
is a class to represent a country in medal tally. It has an attribute of country... medals. In this class, you should also define constructors, and assessor, mutator methods. Task 2 MedalTally.java is a class to model a medal tally, containing
Class
Class, Object and Methods       Class : Whatever we can see in this world all the things... is termed as a class. All the objects are direct interacted with its class
Class names don't identify a class - Java Tutorials
to this class loader, then it loaded the classes from their. Consider a simple example...Class names don't identify a class In JDK 1.2 the Sum Microsystems have added a new feature that allows you to identify a class not only by its name
Super class of an Exception class
Super class of an Exception class  hello,,, What is super class of an Exception class?   hii,, the super class of an exception is throwable class. and the super class of an throwable class is the object class
Class
Class       This section explores the concept of a class in reference to object oriented programming techniques. A class defines the properties of  objects and methods used
Explain final class, abstract class and super class.
Explain final class, abstract class and super class.  Explain final class, abstract class and super class.   Explain final class, abstract class and super class. A final class cannot be extended. A final class
class file
class file  How to create class file in jsf easily
class loaders
class loaders   Explain static and dynamic class loaders
.class and .tld
.class and .tld  how to create .class and .tld file
inner class
inner class  what is mean by inner class   Inner class is a non-static class which is defined inside another class
Node class
Node class   hii, What is a node class?   hello, A node class is a class that has added new services or functionality beyond the services inherited from its base class
Matrix Class
Matrix Class   A class to manage matrices and add them. Create in the driver class two objects of it and use the add method
Matrix Class
Matrix Class   A class to manage matrices and add them. Create in the driver class two objects of it and use the add method
wrapper class
wrapper class  list wrapper class methods
wrapper class
wrapper class  wrapper class methods
printstrim class
printstrim class  discribe PrintStream class
printstrim class
printstrim class  discribe PrintStream class
Abstract class
Abstract class  what is an Abstract class
singleton class
singleton class  What is singleton class
Abstract class
Abstract class  Can an abstract class be final
Locale class
Locale class  What is the Locale class
immutable class
immutable class  How to make a class immutable
Advertisements
 

 

 

DMCA.com