-
Notifications
You must be signed in to change notification settings - Fork 36
Add options for case insensitive properties and enum values. #82
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
Conversation
...rt/src/main/java/com/fasterxml/jackson/jr/annotationsupport/AnnotationBasedIntrospector.java
Outdated
Show resolved
Hide resolved
...src/main/java/com/fasterxml/jackson/jr/annotationsupport/AnnotationBasedValueRWModifier.java
Outdated
Show resolved
Hide resolved
...src/main/java/com/fasterxml/jackson/jr/annotationsupport/AnnotationBasedValueRWModifier.java
Outdated
Show resolved
Hide resolved
jr-objects/src/main/java/com/fasterxml/jackson/jr/ob/impl/ValueWriterLocator.java
Show resolved
Hide resolved
jr-objects/src/main/java/com/fasterxml/jackson/jr/ob/impl/ValueReaderLocator.java
Show resolved
Hide resolved
Ah, forgot to say first: thank you! These sound like useful improvements. Couple of general notes:
Changes are done by cleverly reusing existing mechanisms. I will need to go over this a few times but so far looks good. |
One other thing: one thing I would need, before merging, is CLA (unless I have asked for one earlier). It's here: https://github.com/FasterXML/jackson/blob/master/contributor-agreement.pdf and the simplest way is usually to print, fill & sign,scan/photo, email to |
Thank you for the initial round of feedback. I'll work on it again tomorrow to split it up, rebase on 2.13, and undo my IDE formatting. |
Very cool, thank you for covering everything I brough up. Yes, C(C)LA is fine. I really appreciate help with jackson-jr: I haven't had quite as much time to look into improving it due to other Jackson related things. But I think there is a lot of potential, and due to smaller size it is still quite a bit easier to make targeted improvements compared to "full" Jackson. |
Rebasing and ensuring every test is passing. |
Rebased and all tests are passing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, will merge!
propMap = Collections.emptyMap(); | ||
} else { | ||
propMap = new HashMap<String, BeanPropertyReader>(); | ||
propMap = JSON.Feature.ACCEPT_CASE_INSENSITIVE_PROPERTIES.isEnabled(_features) ? new TreeMap<String, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this actually make TreeMap
use case-insensitive matching?
Did not realize that... pretty neat if so. :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(and yes, after googling and reading about it found out that's exactly what happens)
Adds options for case insensitive bean properties and enum values.
This change will close #80.
Added new tests to verify this functionality which are passing. All existing tests are passing.
As this is my first PR on this code base please forgive any issues and let me know what needs to be done to address them. I'm more than happy to work with you to get this in. Our team is trying to migrate to jackson-jr from databind to reduce our memory requirements and we've seen a large impact already.