Top Description Fields Constructors Methods
org.apache.derby.client.am

public Class FloatingPoint

extends Object
Class Inheritance

Converters from floating point bytes to Java float, double, or java.math.BigDecimal.

Field Summary

Modifier and TypeField and Description
public static final int
IEEE_754_FLOATING_POINT

Supported Unix Big Endian IEEE 754 floating point representation.

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
private static final int
convertFromByteToInt(byte[] buffer, int offset)

Convert the byte array to an int.

private static final long
convertFromByteToLong(byte[] buffer, int offset)

Convert the byte array to a long.

pack-priv static double
getDouble(byte[] buffer, int offset)

Build a Java double from an 8-byte floating point representation.

pack-priv static float
getFloat(byte[] buffer, int offset)

Build a Java float from a 4-byte floating point representation.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

IEEE_754_FLOATING_POINTback to summary
public static final int IEEE_754_FLOATING_POINT

Supported Unix Big Endian IEEE 754 floating point representation.

Constructor Detail

FloatingPointback to summary
private FloatingPoint()

Method Detail

convertFromByteToIntback to summary
private static final int convertFromByteToInt(byte[] buffer, int offset)

Convert the byte array to an int.

convertFromByteToLongback to summary
private static final long convertFromByteToLong(byte[] buffer, int offset)

Convert the byte array to a long.

getDoubleback to summary
pack-priv static double getDouble(byte[] buffer, int offset)

Build a Java double from an 8-byte floating point representation.

This includes DERBY types:

  • FLOAT
  • DOUBLE [PRECISION]
Exceptions
IllegalArgumentException:
if the specified representation is not recognized.
getFloatback to summary
pack-priv static float getFloat(byte[] buffer, int offset)

Build a Java float from a 4-byte floating point representation.

This includes DERBY types:

  • REAL
  • FLOAT(1<=n<=24)
Exceptions
IllegalArgumentException:
if the specified representation is not recognized.