Thanks for the feedback Jesse.
I also fixed the assertion error in DirectPosition2D.hashCode(), but in this
case the assertion revealed a deeper issue (explained in my previous "Note on
equals(Object)" email).
In short: DirectPosition2D is both a DirectPosition and Point2D. Unfortunatly I
realized (thanks to the assertions) that it is safe for use only in:
HashSet<DirectPosition> or HashMap<DirectPosition,?>
it is unsafe for use in
HashSet<Point2D> or HashMap<Point2D,?>
(it could be the converse, but unfortunatly in can be only one or the other - it
can not be safe in both cases).
Collections that don't use hashCode() like ArrayList are unaffected.
I documented this fact in the Javadoc.
Martin
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel