> the objectives of scjp 5 doesn't mention it > I think theres only 1 thing to remember about cloneable interface. For implementing cloneable you dont have to define any methods; marking a class cloneable is just marking a flag for the class which enables its objects to be cloned. api of cloneable inteface shows that there are no methods.
The method clone is available in every class because it is a public method in Object class.
Just implement Cloneable interface and you can use the method but if you call clone method without implementing the above mentioned interface, CloneNotSupported Exception is thrown.
Other thing to note about is deep cloning where in each object is carbon copied so that each reference of the clone refers to a new object instead of the objects referred by corresponding reference variables in the original copy.