This repository was archived by the owner on Dec 25, 2024. It is now read-only.
Commit 5804717
authored
Java, eliminate unsafe casts (#338)
* Updates FrozenList/Map to use AbstractList/Map
* Refactors castToAllowedTypes into JsonSchema
* Fixes for any type schemas
* Fixes more template errors
* Removes unneeded casting methods
* Removes more unneeded methods
* Fixes java tests
* Removes getNewInstance from non collection types
* Has casting return list and map wildcard types
* Removes unchecked casts in getNewInstance
* Removes unchecked casts in getnewinstance with object input
* Removes unused variables, fixes variable names
* Updates ArrayTypeSchemaTest
* Updates ObjectTypeSchemaTest
* Java tests fixed
* Samples regen1 parent 1a7800b commit 5804717
File tree
530 files changed
+9155
-20567
lines changed- samples/client
- 3_0_3_unit_test/java
- docs/components/schemas
- src
- main/java/org/openapijsonschematools/client
- components/schemas
- schemas
- validation
- test/java/org/openapijsonschematools/client/schemas
- validation
- petstore/java
- docs
- components
- requestbodies/userarray/content/applicationjson
- responses
- successfulxmlandjsonarrayofpet/content
- applicationjson
- applicationxml
- successinlinecontentandheader/content/applicationjson
- schemas
- paths
- fakeinlineadditionalproperties/post/requestbody/content/applicationjson
- fakeinlinecomposition/post
- parameters/parameter1
- requestbody/content/multipartformdata
- responses/response200/content/multipartformdata
- fakejsonformdata/get/requestbody/content/applicationxwwwformurlencoded
- fakemultiplerequestbodycontenttypes/post/requestbody/content
- applicationjson
- multipartformdata
- fakeobjinquery/get/parameters/parameter0
- fakepetiduploadimagewithrequiredfile/post/requestbody/content/multipartformdata
- faketestqueryparamters/put/parameters
- parameter0
- parameter1
- parameter2
- parameter3
- parameter4
- fakeuploadfiles/post/requestbody/content/multipartformdata
- fakeuploadfile/post/requestbody/content/multipartformdata
- fake
- get
- parameters
- parameter0
- parameter2
- requestbody/content/applicationxwwwformurlencoded
- post/requestbody/content/applicationxwwwformurlencoded
- foo/get/responses/responsedefault/content/applicationjson
- petfindbystatus/get/parameters/parameter0
- petfindbytags/get/parameters/parameter0
- petpetiduploadimage/post/requestbody/content/multipartformdata
- petpetid/post/requestbody/content/applicationxwwwformurlencoded
- src
- main/java/org/openapijsonschematools/client
- components
- requestbodies/userarray/content/applicationjson
- responses
- headerswithnobody
- successfulxmlandjsonarrayofpet/content
- applicationjson
- applicationxml
- successinlinecontentandheader
- content/applicationjson
- successwithjsonapiresponse
- schemas
- paths
- commonparamsubdir
- delete
- parameters/parameter1
- get
- parameters/parameter0
- post
- fakebodywithqueryparams/put
- fakecasesensitiveparams/put
- fakedeletecoffeeid/delete
- fakeinlineadditionalproperties/post/requestbody/content/applicationjson
- fakeinlinecomposition/post
- parameters
- parameter0
- parameter1
- requestbody/content
- applicationjson
- multipartformdata
- responses/response200/content
- applicationjson
- multipartformdata
- fakejsonformdata/get/requestbody/content/applicationxwwwformurlencoded
- fakemultiplerequestbodycontenttypes/post/requestbody/content
- applicationjson
- multipartformdata
- fakeobjinquery/get
- parameters/parameter0
- fakeparametercollisions1ababselfab/post
- fakepetiduploadimagewithrequiredfile/post
- requestbody/content/multipartformdata
- fakequeryparamwithjsoncontenttype/get
- fakerefobjinquery/get
- faketestqueryparamters/put
- parameters
- parameter0
- parameter1
- parameter2
- parameter3
- parameter4
- fakeuploadfiles/post/requestbody/content/multipartformdata
- fakeuploadfile/post/requestbody/content/multipartformdata
- fake
- delete
- parameters
- parameter1
- parameter4
- get
- parameters
- parameter0
- parameter1
- parameter2
- parameter3
- parameter4
- parameter5
- requestbody/content/applicationxwwwformurlencoded
- post/requestbody/content/applicationxwwwformurlencoded
- foo/get/responses/responsedefault/content/applicationjson
- petfindbystatus/get
- parameters/parameter0
- petfindbytags/get
- parameters/parameter0
- petpetiduploadimage/post
- requestbody/content/multipartformdata
- petpetid
- delete
- get
- post
- requestbody/content/applicationxwwwformurlencoded
- storeorderorderid
- delete
- get
- parameters/parameter0
- userlogin/get
- responses/response200
- userusername
- delete
- get
- put
- schemas
- validation
- test/java/org/openapijsonschematools/client/schemas
- validation
- src/main
- java/org/openapijsonschematools/codegen/generators
- resources/java/src
- main/java/packagename
- components/schemas/SchemaClass
- schemas
- validation
- test/java/packagename/schemas
- validation
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
530 files changed
+9155
-20567
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
| 53 | + | |
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
| 53 | + | |
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| |||
Lines changed: 4 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
69 | | - | |
| 69 | + | |
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| |||
134 | 134 | | |
135 | 135 | | |
136 | 136 | | |
137 | | - | |
| 137 | + | |
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
| |||
200 | 200 | | |
201 | 201 | | |
202 | 202 | | |
203 | | - | |
| 203 | + | |
204 | 204 | | |
205 | 205 | | |
206 | 206 | | |
| |||
264 | 264 | | |
265 | 265 | | |
266 | 266 | | |
267 | | - | |
| 267 | + | |
268 | 268 | | |
269 | 269 | | |
270 | 270 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
| 82 | + | |
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | | - | |
| 52 | + | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | | - | |
| 52 | + | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | | - | |
| 57 | + | |
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
| |||
0 commit comments