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

@JsonProperty(defaultValue="...") does not allow float/double values #152

Open
almson opened this issue Oct 31, 2021 · 1 comment · May be fixed by #158
Open

@JsonProperty(defaultValue="...") does not allow float/double values #152

almson opened this issue Oct 31, 2021 · 1 comment · May be fixed by #158

Comments

@almson
Copy link

almson commented Oct 31, 2021

Title is self-explanatory, more details here #73 (comment)

@almson
Copy link
Author

almson commented Oct 31, 2021

I changed

to node.put("default", value.toDouble) and things work. Doubles are doubles and ints are ints. FYI, a double can represent all ints exactly and most longs, up to 2^53. There would be problems however if the default value is something like MAX_LONG (which of course the current implementation doesn't support either).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant