Comment on Tutorial - clone() and the Cloneable Interface in Java By Henry
Comment Added by : siva kiran
Comment Added at : 2011-01-20 11:40:23
Comment on Tutorial : clone() and the Cloneable Interface in Java By Henry
Question: if clone is a protected method then why the sub class has to implement Cloneable interface type to use its super class method?
Answer: clone is a dangerous method. So by implementing Cloneable interface you are telling JVM that "There is a good reason to clone my class, so please allow me"
- Data Science
- Cloud Computing
- Java Beans
- Mac OS X
- Office 365
- Tech Reviews
Subscribe to Tutorials
1. This is the helpful Site for beginner....!!!!!!!!!
View Tutorial By: Anup at 2013-07-26 13:40:49
2. This is so phat. Maybe the best explanation ever t
View Tutorial By: Devin Prince III at 2010-08-11 10:01:04
3. I have a mac book dual booting with snow leopard (
View Tutorial By: david at 2015-06-27 15:33:07
6. Thanks bro...you save me from a great problem...ve
View Tutorial By: Tishan at 2012-07-09 09:14:07
10. I want an example...to get multiple values using S
View Tutorial By: Madhu at 2015-07-13 19:57:14