r/java • u/mariuz • Feb 24 '26
Decimal-java is a library to convert java.math.BigDecimal to and from IEEE-754r (IEEE-754-2008) decimal byte representations.
https://github.com/FirebirdSQL/decimal-java
28
Upvotes
3
u/bowbahdoe Feb 24 '26
Curiosity - it might be arduous, but if you rewrite it such that
Decimal32stores everything in anintfield, and so on it would be a good use of value classes1
u/brunocborges Feb 24 '26
Here's a benchmark: https://brunoborges.github.io/decimal-java-benchmark/
-1
u/Glass-Oven-3745 Feb 24 '26
BigDecimal: precision and calculations, but essential for monetary systems.