Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-9572

Replace all "BigDecimal ZERO" by BigDecimal.ZERO

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Implemented
    • None
    • 18.12.01
    • None
    • None

    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.

      1. But, like in any BigDecimal comparison, values compared to BigDecimal.ZERO must be weighted by using setScale()
      2. Like I did in OFBIZ-9571 we must always use the setScale() variant with integer but the one with RoundingMode.

      Attachments

        Issue Links

          Activity

            People

              jleroux Jacques Le Roux
              jleroux Jacques Le Roux
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: