[
https://issues.apache.org/jira/browse/LANG-1603?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17582989#comment-17582989
]
Gilles Sadowski commented on LANG-1603:
---------------------------------------
{quote}[...] reasonable [...]
{quote}
As usual, not all arguments will point to the same conclusion about what is
"reasonable".
IMHO, we improve maintainability by reducing bloat: e.g. deleting the "math"
from [Lang] and relying on the [Numbers] implementation will make it the
"single-point of failure" for bugs related to the low-level functionality. As
commented in LANG-1601, enhancements/fixes were applied to the code originally
in [Math]. I have no idea whether the implementation in [Lang] is subject to
the same issue(s) and, IMO, having to check should count as an argument against
keeping it in [Lang].
IIUC Alex's point, the only (?) "issue" is the formatting of "proper"
fractions. We could perhaps add
* {{public int getProperNumerator()}}
* {{public int getProperWhole()}}
to the {{Fraction}} class in in[Numbers] order to support such formatting (cf.
implementation above), but we should _not_ provide
* {{public String toProperString()}}
because it's but one of the ways an application might want to format a fraction
for purposes other than the "canonical" representation provided by
{{toString()}}.
> Deprecate the "Fraction" class
> ------------------------------
>
> Key: LANG-1603
> URL: https://issues.apache.org/jira/browse/LANG-1603
> Project: Commons Lang
> Issue Type: Sub-task
> Reporter: Gilles Sadowski
> Priority: Major
> Fix For: 4.0
>
> Time Spent: 50m
> Remaining Estimate: 0h
>
> [Fraction|https://gitbox.apache.org/repos/asf?p=commons-lang.git;a=blob;f=src/main/java/org/apache/commons/lang3/math/Fraction.java;h=e90e340ac5578126492471841f4a97548dbb49f7;hb=HEAD]
> in [Lang] vs
> [Fraction|https://gitbox.apache.org/repos/asf?p=commons-numbers.git;a=blob;f=commons-numbers-fraction/src/main/java/org/apache/commons/numbers/fraction/Fraction.java;h=f1bc54278a9a65538638ddbe9d17a28452a60ca4;hb=HEAD]
> in [Numbers].
--
This message was sent by Atlassian Jira
(v8.20.10#820010)