How many methods does cloneable interface contains?

Answer Posted / ram

@Dhinesz :

First of all, a marker interface is an interface by implementing that interface the class will get special behaviour. And it doesn't mean that, marker interface always not have any methods. Ex: Runnable interface is a marker interface and it has run().

Clone() method is a part of Object class, and if you implement cloneable interface for your class, it will force you to override the clone().

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many bytes is a string?

570


What is polymorphism java example?

552


What is variable and example?

523


Can you explain the meaning of aggregation and composition

574


What are recursive functions?

577






Define packages in java?

580


What is parseint?

540


Can you inherit from an abstract class java?

537


What is a parent class in java?

550


When do I need to use reflection feature in java?

627


When should you make a function static?

547


Can we use return in constructor?

497


What is natural ordering in java?

536


Can we have more than one package statement in the source file?

645


List implementations of list interface?

567