-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1553 from unkish/issues/1550
Prevent generating duplicate constructors when all properties are required; and both includeAllPropertiesConstructor and includeRequiredPropertiesConstructor are true
- Loading branch information
Showing
6 changed files
with
127 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
...tion-tests/src/test/resources/schema.useInnerClassBuilders/child_parent_all_required.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"type": "object", | ||
"extends": { | ||
"$ref": "parent_all_required.json" | ||
}, | ||
"properties": { | ||
"childProperty": { | ||
"type": "integer" | ||
}, | ||
"sharedProperty": { | ||
"type": "string", | ||
"required": true | ||
} | ||
} | ||
} |
8 changes: 8 additions & 0 deletions
8
...ntegration-tests/src/test/resources/schema.useInnerClassBuilders/parent_all_required.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"type" : "object", | ||
"properties" : { | ||
"parentProperty" : { "type" : "string" }, | ||
"sharedProperty" : { "type" : "string" } | ||
}, | ||
"required" : ["parentProperty", "sharedProperty"] | ||
} |
26 changes: 26 additions & 0 deletions
26
...ration-tests/src/test/resources/schema/constructors/allPropertiesRequiredConstructor.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"type" : "object", | ||
"properties" : { | ||
"type" : { | ||
"type" : "string", | ||
"default" : "event", | ||
"required": true | ||
}, | ||
"id" : { | ||
"type" : "integer", | ||
"required": true | ||
}, | ||
"has_tickets" : { | ||
"type" : "boolean", | ||
"required": true | ||
}, | ||
"provider" : { | ||
"type" : "string", | ||
"required": true | ||
}, | ||
"starttime" : { | ||
"type" : "string", | ||
"required": true | ||
} | ||
} | ||
} |