Daniele,
DateRanges and NumberRanges are put into the same Set as implemented by
TreeSet. Since neither DateRange nor NumberRange implement Comparable I had to
write the Comparator.
If both elements are DateRange then it passes the responsibility to a
DateRangeComparator, if both are NumberRange it passes the responsibility to a
NumberRangeComparator. If one element is DateRange and the other is NumberRange
the choice of 1 or -1 is arbitary (but done consistently). This allows
consistent ordering and the placement of both Range types into the Set.
The exception being thrown was a ClassCastException: DateRange cannot be cast
to Comparable.
I'm only fixing broken code. Why DateRange and NumberRange are placed into the
same Set, I don't know.
Brett
Sent from my iPad
On 19/07/2013, at 2:42 AM, "Daniele Romagnoli"
<daniele.romagn...@geo-solutions.it<mailto:daniele.romagn...@geo-solutions.it>>
wrote:
Hi Brett,
I did a quick look to the patch and it seems good to me.
The only thing which I didn't understand is why you allow to compare DateRange
with NumberRange (the latest "else if" returning 1 and the last "return -1")
Ranges to be compared should be of the same type (since an additional domain is
made of homogeneous objects... numbers or dates or ...)
Can you fix that?
Cheers,
Daniele
==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more
information.
==
Ing. Daniele Romagnoli
Senior Software Engineer
GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
http://www.geo-solutions.it
http://twitter.com/geosolutions_it
-------------------------------------------------------
On Thu, Jul 18, 2013 at 4:29 PM, Brett Walker
<brett.wal...@geometryit.com<mailto:brett.wal...@geometryit.com>> wrote:
Hi
Could someone review PR #237.
I found and fixed a build error when using JDK7. It is in unsupported module
but it still broke the build.
Additional information is found in the commit message of the pull request.
Thanks,
Brett
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
GeoTools-Devel mailing list
GeoTools-Devel@lists.sourceforge.net<mailto:GeoTools-Devel@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/geotools-devel
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
GeoTools-Devel mailing list
GeoTools-Devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel