What is cloneable interface?

Answer Posted / prashant singh

cloneable interface is a marker interface,found in java.lang package.if we want to clone the object then we have to implement this interface.
if we do not implement it and try to make clone of object then CloneNotSupportedException is thrown.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is main is a keyword?

574


What is a class object?

497


What is difference between iterator and enumeration in java?

522


Give any two differences between C++ and java.

554


1.IN CASE OF DYNAMIC METHOD DISPATCH WHY WE USE REFERENCE VARIABLE,WE CAN USE THE DIFFERENT DEFINED OBJECT DIRECTLY TO ACCESS THE DATA MEMBER AND MEMBER FUNCTION OF THAT RESPECTIVE CLASS?WHAT IS THE MAIN FUNCTION OF "REFERENCE VARIABLE" HERE?

3780






What is thread life cycle in java?

578


What is a condition in java?

533


How many types of gc are there in java?

555


What do you mean by composition in java?

559


Why to use nested classes in java?

583


What is the best definition for data?

517


Can a class have multiple superclasses?

564


Explain where variables are created in memory?

578


What is meant by design patterns?

578


What is difference between path and classpath variables?

563