AngleFormat is using a Half-Even rounding, and this is not configurable
-----------------------------------------------------------------------

                 Key: GEOT-2856
                 URL: http://jira.codehaus.org/browse/GEOT-2856
             Project: GeoTools
          Issue Type: Improvement
          Components: core referencing
    Affects Versions: 2.5.3
         Environment: Ubuntu 8.10, Java 1.6_10
            Reporter: Oliver Tupran


AngleFormat is rounding similar to the Half-Even java.text.DecimalFormat 
algorithm, and from an API point of view this can not be changed.

Example:
- Pattern: D
- value (in decimal degrees): 2.5
- AngleFormat.format(2.5) returns 2 instead of 3

AngleFormat format = new AngleFormat("D");
assertEquals("3", format.format(2.5));

Is there any possibility for this to be improved and accept different rounding 
strategies or at lesat implement a Half-Up algorithm, which is closer to what 
everybody is using?

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to