On Thu, Jan 9, 2020 at 8:01 AM TheCrisbros15 <[email protected]> wrote:

> It seems after some more digging I have answered my own question. Sorry
> for possibly wasting your time. I missed the getNumberType method.... I
> knew I overlooked something. I’ll wait longer next time.
>

Glad you found it even before I had a chance to suggest it! No problem at
all wrt asking: that's why this group is for.

There is also `getNumberValue()`, I think, for general "it's a number". And
`getXxxValue()` methods handle coercions wherever applicable.
For what it is worth, not distinguishing `float` vs `double` is for legacy
reasons: distinction can not usually be made for JSON given its textual
representation. But binary-backed formats do keep track of physical
representation, and it can be accessed the way you found (getNumberType()).

-+ Tatu +-


>
> --
> You received this message because you are subscribed to the Google Groups
> "jackson-user" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jackson-user/528ade61-a0f3-4d02-b523-d25bb10d8105%40googlegroups.com
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"jackson-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jackson-user/CAGrxA245USEb%3D7Vm7SDhhJi3oji1vFK57cjO0TNaN6mHTjo1kw%40mail.gmail.com.

Reply via email to