2

I am trying to write decimal pattern for Camel Bindy so it formats decimal number in this way ( it removes ".0" for integer numbers ): 1.1333333 - 1.1333333, 1.0 - 1, -2.0 - -2,

For each field I have different precision. I have managed to create something like that:

@DataField(pos = 12, columnName = "", precision = 16, decimalSeparator = ".", pattern = "#.#")

It converts in this way: 1.1333333 - 1.1333333, 0.123456789123456 - 0.123456789123456, 1.0 - 1.0, -2.0 - -2.0,

Any one can help. I could not find any examples on google.

Kenster
  • 23,465
  • 21
  • 80
  • 106

0 Answers0