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

Support property naming strategy for Guava Ranges #57

Merged
merged 4 commits into from
Sep 5, 2019

Conversation

philleonard
Copy link

Follow up PR for #56. Unsure if the public constructors are better off with a different overload structure to preserve backwards compatibility.

@cowtowncoder
Copy link
Member

Ok. So, what I was thinking was to apply transformations right within createContextual() and pass transformed names; or, transform within constructor. While overhead of name transformations may not be humongous it is something that can be pre-computed.

But other than that I think this makes sense.

@@ -12,6 +12,7 @@

import com.google.common.collect.BoundType;
import com.google.common.collect.Range;
import java.util.Optional;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: JDK 8, can not use for Jackson 2.x

@cowtowncoder
Copy link
Member

I merged unit test part (well, second of tests) in 2.10, to help verify, merge the fix.

@philleonard
Copy link
Author

Thanks @cowtowncoder. I have fixed it to transform the names in createContextual and have removed the JDK 8 usages. LMK if there is a better way to do this.

@cowtowncoder
Copy link
Member

@philleonard Looks good, I think, any tweaks I can think I can do post-merge I think. The only other thing is that I'd like to get this in 2.10, will see what'd be the best way.

Just one other thing before I can merge this: if I have not yet asked for CLA (https://github.com/FasterXML/jackson/blob/master/contributor-agreement.pdf), I would need that now, before the first contribution. After I receive filled one I can merge any and all contributions across projects, so it is just one time hassle.
The most common way to do this is to print, fill & sign, scan (cell phone photo is fine), email to info at fasterxml dot com.

Looking forward to merging this fix, thank you again for contributing it!

@philleonard
Copy link
Author

Thanks, contributor agreement has been sent your way.

@cowtowncoder cowtowncoder merged commit 400f5be into FasterXML:master Sep 5, 2019
@cowtowncoder cowtowncoder added this to the 2.10.0 milestone Sep 5, 2019
@cowtowncoder
Copy link
Member

Thank you again -- I merged this, and will merge in 2.10, do some light touch up.

In future it might be neat to simplify the process too, but first things first.

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

Successfully merging this pull request may close these issues.

2 participants