[jira] [Updated] (OFBIZ-9572) Replace all "BigDecimal ZERO" by BigDecimal.ZERO

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Updated] (OFBIZ-9572) Replace all "BigDecimal ZERO" by BigDecimal.ZERO

Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-9572?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacques Le Roux updated OFBIZ-9572:
-----------------------------------
    Description:
Using "BigDecimal ZERO" instead of BigDecimal.ZERO does not add anything but more useless code. They are both constants and the compiler will made them so.
# But, like in any BigDecimal comparison, values compared to BigDecimal.ZERO must be weighted by using setScale()
# Like I did in OFBIZ-9571 we must always use the setScale() variant with integer but the one with RoundingMode.


  was:
Using "BigDecimal ZERO" instead of BigDecimal.ZERO does not add anything but more useless code. They are both constants and the compiler will made them so.




> Replace all "BigDecimal ZERO" by BigDecimal.ZERO
> ------------------------------------------------
>
>                 Key: OFBIZ-9572
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-9572
>             Project: OFBiz
>          Issue Type: Improvement
>            Reporter: Jacques Le Roux
>
> Using "BigDecimal ZERO" instead of BigDecimal.ZERO does not add anything but more useless code. They are both constants and the compiler will made them so.
> # But, like in any BigDecimal comparison, values compared to BigDecimal.ZERO must be weighted by using setScale()
> # Like I did in OFBIZ-9571 we must always use the setScale() variant with integer but the one with RoundingMode.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)