-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Getter Setter wrong names #840
Comments
Hi. I assume you are using the default propertyWordDelimiters, and so the Java name for this field is The Java Bean convention (that defines how getters and setters should be named) dictates that a getter called This relates to changes made in #756. It's one of the breaking changes that have forced the latest jsonschema2pojo release to move from 0.x to 1.x. There's more information about this particular quirk of the Java Bean spec here:
If you have some other tool or library that expects the gett for |
Thank you for perfect description. We will change our code to follow new
rules.
Regards
Jan
2018-03-08 16:17 GMT+01:00 Joe Littlejohn <notifications@github.com>:
… Hi. I assume you are using the default propertyWordDelimiters, and so the
Java name for this field is vItemHidden. Is that right?
The Java Bean convention (that defines how getters and setters should be
named) dictates that a getter called getVItemHidden relates to a Java
field named VItemHidden. If you have a field named vItemHidden then the
correct name for the getter is getvItemHidden.
This relates to changes made in #756
<#756>. It's one
of the breaking changes that have forced the latest releases to move from
v0.x to v1.x. There's more information about this particular quirk of the
Java Bean spec here:
- FasterXML/jackson-databind#653
<FasterXML/jackson-databind#653>
- https://bugs.eclipse.org/bugs/show_bug.cgi?id=322223
If you have some other tool or library that expects the gett for
vItemHidden to be getVItemHidden then that library or tool has a bug.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#840 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ARbL1bVzPhxrRgokEx-7dnavKYIzXafhks5tcUuhgaJpZM4Si0CM>
.
|
In the latest.integration gradle plugin we are facing the issue with the getter/setter names generation.
in case of json like
{ "id": "http://some.site.somewhere/entry-schema#", "$schema": "http://json-schema.org/draft-04/schema#", "description": "schema for risks data", "type": "object", "javaInterfaces": ["java.io.Serializable", "Cloneable"], "required": ["ris_id"], "properties": { "v_item_hidden": { "type": "boolean", "default": "false" }, .... } }
the generated getter/setter for v_item_hidden is getvItemHidden() instead of getVItemHidden().
The text was updated successfully, but these errors were encountered: