What is object cloning?

What is object cloning?

Object cloning means creating the identical object of any object. If you say :

obj1=obj2;

In the above statement obj1 is not actually making another copy of object, it simply makes the copy of reference bits. For this purpose java provides the clone() method for object cloning. This method is defined by the Object class. 

By:Jalees
Date:2015-01-09 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