public final class BsonDecimal128 extends BsonNumber
| Constructor and Description |
|---|
BsonDecimal128(Decimal128 value)
Construct a new instance with the given value.
|
| Modifier and Type | Method and Description |
|---|---|
Decimal128 |
decimal128Value()
Returns the value of the specified number as a
Decimal128, which may involve rounding. |
double |
doubleValue()
Returns the value of the specified number as a
double, which may involve rounding. |
boolean |
equals(Object o) |
BsonType |
getBsonType()
Gets the BSON type of this value.
|
Decimal128 |
getValue()
Gets the Decimal128 value.
|
int |
hashCode() |
int |
intValue()
Returns the value of the specified number as an
int, which may involve rounding or truncation. |
long |
longValue()
Returns the value of the specified number as an
long, which may involve rounding or truncation. |
String |
toString() |
asArray, asBinary, asBoolean, asDateTime, asDBPointer, asDecimal128, asDocument, asDouble, asInt32, asInt64, asJavaScript, asJavaScriptWithScope, asNumber, asObjectId, asRegularExpression, asString, asSymbol, asTimestamp, isArray, isBinary, isBoolean, isDateTime, isDBPointer, isDecimal128, isDocument, isDouble, isInt32, isInt64, isJavaScript, isJavaScriptWithScope, isNull, isNumber, isObjectId, isRegularExpression, isString, isSymbol, isTimestamppublic BsonDecimal128(Decimal128 value)
value - the value, which may not be nullpublic BsonType getBsonType()
BsonValuegetBsonType in class BsonValuepublic Decimal128 getValue()
public int intValue()
BsonNumberint, which may involve rounding or truncation.intValue in class BsonNumberint.public long longValue()
BsonNumberlong, which may involve rounding or truncation.longValue in class BsonNumberlong.public double doubleValue()
BsonNumberdouble, which may involve rounding.doubleValue in class BsonNumberdouble.public Decimal128 decimal128Value()
BsonNumberDecimal128, which may involve rounding.decimal128Value in class BsonNumberDecimal128.