Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve BsonNumber support for Decimal128 #1283

Merged
merged 2 commits into from
Jan 3, 2024
Merged

Conversation

jyemin
Copy link
Contributor

@jyemin jyemin commented Dec 18, 2023

  • Change implementation of BsonDecimal128#intValue/longValue/doubleValue to just call the corresponding methods in Decimal128, which handle infinity and NaN similarly to JDK classes
  • Change BsonValue#isNumber/asNumber to treat BsonDecimal128 as a number

JAVA-5265

* Change implementation of BsonDecimal128#intValue/longValue/doubleValue
  to just call the corresponding methods in Decimal128, which handle
  infinity and NaN similarly to JDK classes
* Change BsonValue#isNumber/asNumber to treat BsonDecimal128 as a number

JAVA-5265
@jyemin jyemin self-assigned this Dec 18, 2023
bson/src/main/org/bson/BsonValue.java Outdated Show resolved Hide resolved
Co-authored-by: Valentin Kovalenko <valentin.male.kovalenko@gmail.com>
@jyemin jyemin requested a review from stIncMale January 2, 2024 23:54
@jyemin jyemin merged commit 89512cd into mongodb:master Jan 3, 2024
58 checks passed
@jyemin jyemin deleted the j5265 branch January 3, 2024 00:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants