The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
January 2002



This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.


don't really understand

Posted by Chin Loong on January 20, 2002 at 3:03 PM

> To add a few thoughts on this part, the behaviour of clone() is entirely dependant on how the method is implemented. For example, if the class implementing clone() has an instance of another class, the member object's clone() method (if present at all)is not called by default. Unless an explicit call to clone() is made to the member object, both the clones refer to the same member object!

both the clone() ? both of which clone(), since your statement includes this phrase "unless an explicit call to clone() is made to the member object"? and both refer to which member object?


Sponsored Links

Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us