-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
MapperFeature.REQUIRE_SETTERS_FOR_GETTERS
has no effect
#736
Comments
Interesting. Sounds like a bug; I am guessing existence of the matching field might be mistaken as indication of a setter. Which version is this with? |
2.5.1 |
Ok, I can reproduce this. And it does look like problem with a field. But I'll have to handle this carefully: as per its Javadoc, |
Thanks. If I understand correctly, in this case the matching mutator ( |
@migel Yes, for getter action. But for "setter" action lower visibility is accepted. However, you have defined If you want to try setting So, yes, I think there is a problem here. I am just not fully sure how to tackle it. As a work-around on short term you may want to use explicit |
MapperFeature.REQUIRE_SETTERS_FOR_GETTERS
has no effect
Hi, I've tried the code below to serialize properties that have both a getter and a setter. However the output is:
{"readonly":1,"readwrite":2}
while I expected it to be:{"readwrite":2}
.The text was updated successfully, but these errors were encountered: