Java Utililty Methods Double Number Create

List of utility methods to do Double Number Create

Description

The list of methods to do Double Number Create are organized into topic(s).

Method

doubletoDouble(byte[] data, int offset)
to Double
long l = toLong(data, offset);
return Double.longBitsToDouble(l);
doubletoDouble(byte[] si, boolean isReverseOrder)
Convert a byte[] to the corresponding double value.
double d = 0.0;
long l = toLong(si, isReverseOrder);
d = Double.longBitsToDouble(l);
return d;
doubletoDouble(byte[] value)
to Double
long longValue = toLong(value);
double result = Double.longBitsToDouble(longValue);
return result;
doubletoDouble(final byte[] array, final int offset, final int length)
to Double
return Double.longBitsToDouble(toLong(array, offset, DOUBLE_BYTES));
doubletoDouble(final byte[] bytes)
to Double
return toDouble(bytes, 0);
doubletoDouble(final byte[] bytes)
to Double
return toDouble(bytes, 0);
doubletoDouble(final byte[] inputBytes, final int offset)
to Double
return Double.longBitsToDouble(toLong(inputBytes, offset));
double[]toDouble(final int[] a, final int len)
to Double
final double[] b = new double[len];
for (int i = 0; i < len; i++)
    b[i] = a[i];
return b;
DoubletoDouble(final Number n)
Converts the given Number to a Double
return n == null ? null : n instanceof Double ? (Double) n : new Double(n.doubleValue());
doubletoDouble(final Object obj)
to Double
if (obj instanceof Number) {
    return ((Number) obj).doubleValue();
if (obj instanceof Boolean) {
    return (Boolean) obj ? 1.0 : 0.0;
if (obj instanceof String) {
    if ("true".equals(obj)) {
...