@Test public void acceptsValuesWithTheSameDigitsThanSpecified() throws Exception { assertThat(DoubleUtils.hasPrecision(0.12345,5),equalTo(true)); }
static boolean hasPrecision(final double value, final int decimals) { final double scaled=value*scale(decimals); return Double.doubleToRawLongBits(scaled-(long)scaled)==0; }
DoubleUtils { static boolean hasPrecision(final double value, final int decimals) { final double scaled=value*scale(decimals); return Double.doubleToRawLongBits(scaled-(long)scaled)==0; } }
DoubleUtils { static boolean hasPrecision(final double value, final int decimals) { final double scaled=value*scale(decimals); return Double.doubleToRawLongBits(scaled-(long)scaled)==0; } private  DoubleUtils(); }
DoubleUtils { static boolean hasPrecision(final double value, final int decimals) { final double scaled=value*scale(decimals); return Double.doubleToRawLongBits(scaled-(long)scaled)==0; } private  DoubleUtils();  }
DoubleUtils { static boolean hasPrecision(final double value, final int decimals) { final double scaled=value*scale(decimals); return Double.doubleToRawLongBits(scaled-(long)scaled)==0; } private  DoubleUtils();   }