Re: Re: suggestions for newbee
Rohan Hart <[email protected]> Thu, 07 Jul 2005 16:25:28 +1200
| Newsgroups | gmane.comp.lang.nice.general |
|---|---|
| Message-ID | <[email protected]> |
On Thu, 7 Jul 2005, Tom Kaitchuck said: > Shouldn't ShallowEquals be "==" and DeepEquals be a.equals(b)? Java coders will expect "==" to be identity. Not that I wouldn't prefer "==" to mean equality (however the object defines it) given the number of times I actually want identity. While we're on the subject... having been tripped up before by the default equals method being identity I'd rather it be moved to a new Equatable interface without default. Of course Having an equals builder (ShallowEquatable, DeepEquatable) which covered all Equatable fields would be nice. Turning off Object.equals from the Java side of the fence might require a new (virtual) root in nice.lang.Object which throws OperationNotSupportedException (bet that will be unexpected!). Rohan ------------------------------------------------------- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click