public class RawQuad extends Number
| Modifier and Type | Field and Description |
|---|---|
static RawQuad |
ZERO
An empty RawQuad value.
|
| Constructor and Description |
|---|
RawQuad(BigInteger nUnscaledValue, int nScale)
Construct a RawQuad from an unscaled integer value and a scale.
|
RawQuad(Binary binBits)
Construct a RawQuad from the raw binary data.
|
RawQuad(double dfl)
Construct a RawQuad from a double.
|
| Modifier and Type | Method and Description |
|---|---|
double |
doubleValue()
Returns the value of the specified number as a
double. |
boolean |
equals(Object o)
Compare this object with another for equality.
|
float |
floatValue()
Returns the value of the specified number as a
float. |
Binary |
getBits()
Obtain the raw binary form of the 128-bit float.
|
int |
hashCode()
Obtain the hashcode for this object.
|
int |
intValue()
Returns the value of the specified number as an
int. |
long |
longValue()
Returns the value of the specified number as a
long. |
int |
scale()
Get the base-2 scale (exponent) of the quad value.
|
String |
toString()
Format this object's data as a human-readable string.
|
BigInteger |
unscaledValue()
Get the base-2 unscaled value (mantissa) of the quad value.
|
byteValue, shortValuepublic static final RawQuad ZERO
public RawQuad(Binary binBits)
binBits - the raw binary form of the 128-bit floatpublic RawQuad(double dfl)
dfl - the double valuepublic RawQuad(BigInteger nUnscaledValue, int nScale)
nUnscaledValue - the unscaled value (mantissa)nScale - the scale (exponent)public int intValue()
int. This may involve rounding or truncation.public long longValue()
long. This may involve rounding or truncation.public float floatValue()
float. This may involve rounding.floatValue in class Numberfloat.public double doubleValue()
double. This may involve rounding.doubleValue in class Numberdouble.public Binary getBits()
public BigInteger unscaledValue()
The name of this method is based on Java's BigDecimal.
public int scale()
The name of this method is based on Java's BigDecimal.
public boolean equals(Object o)
public int hashCode()