Commit 65b1859
authored
Add nullability annotations to Java generated clients (#19617)
* issue-1960: Add nullability annotations to Java generated clients
Motivations:
Have generated clients properly annotated for nullability to be able to check code using them with tools like NullAway
Modifications:
* Add nullable_var_annotations template to handle nullability annotation on vars
* Add pojo templates to use the nullability template
* Adapt tests
* issue-1960: Add nullability annotations to Java generated clients
Modifications:
* Run export_docs_generator.sh script to update samples1 parent 8f7d9f7 commit 65b1859
1,582 files changed
Lines changed: 14871 additions & 9980 deletions
File tree
- modules/openapi-generator/src
- main/resources/Java
- libraries
- feign
- jersey2
- jersey3
- native
- okhttp-gson
- test/java/org/openapitools/codegen/java
- samples
- client
- echo_api/java
- apache-httpclient/src/main/java/org/openapitools/client/model
- feign-gson/src/main/java/org/openapitools/client/model
- native/src/main/java/org/openapitools/client/model
- okhttp-gson-user-defined-templates/src/main/java/org/openapitools/client/model
- okhttp-gson/src/main/java/org/openapitools/client/model
- restclient/src/main/java/org/openapitools/client/model
- resteasy/src/main/java/org/openapitools/client/model
- resttemplate/src/main/java/org/openapitools/client/model
- others/java
- okhttp-gson-oneOf-array/src/main/java/org/openapitools/client/model
- okhttp-gson-streaming/src/main/java/org/openapitools/client/model
- petstore/java
- apache-httpclient/src/main/java/org/openapitools/client/model
- feign-no-nullable/src/main/java/org/openapitools/client/model
- feign/src/main/java/org/openapitools/client/model
- google-api-client/src/main/java/org/openapitools/client/model
- jersey2-java8-localdatetime/src/main/java/org/openapitools/client/model
- jersey2-java8/src/main/java/org/openapitools/client/model
- jersey3-oneOf/src/main/java/org/openapitools/client/model
- jersey3/src/main/java/org/openapitools/client/model
- native-async/src/main/java/org/openapitools/client/model
- native-jakarta/src/main/java/org/openapitools/client/model
- native/src/main/java/org/openapitools/client/model
- okhttp-gson-3.1/src/main/java/org/openapitools/client/model
- okhttp-gson-awsv4signature/src/main/java/org/openapitools/client/model
- okhttp-gson-dynamicOperations/src/main/java/org/openapitools/client/model
- okhttp-gson-group-parameter/src/main/java/org/openapitools/client/model
- okhttp-gson-nullable-required/src/main/java/org/openapitools/client/model
- okhttp-gson-parcelableModel/src/main/java/org/openapitools/client/model
- okhttp-gson-swagger1/src/main/java/org/openapitools/client/model
- okhttp-gson-swagger2/src/main/java/org/openapitools/client/model
- okhttp-gson/src/main/java/org/openapitools/client/model
- rest-assured-jackson/src/main/java/org/openapitools/client/model
- rest-assured/src/main/java/org/openapitools/client/model
- restclient-nullable-arrays/src/main/java/org/openapitools/client/model
- restclient-swagger2/src/main/java/org/openapitools/client/model
- restclient-useSingleRequestParameter/src/main/java/org/openapitools/client/model
- restclient/src/main/java/org/openapitools/client/model
- resteasy/src/main/java/org/openapitools/client/model
- resttemplate-jakarta/src/main/java/org/openapitools/client/model
- resttemplate-swagger1/src/main/java/org/openapitools/client/model
- resttemplate-swagger2/src/main/java/org/openapitools/client/model
- resttemplate-withXml/src/main/java/org/openapitools/client/model
- resttemplate/src/main/java/org/openapitools/client/model
- retrofit2-play26/src/main/java/org/openapitools/client/model
- retrofit2rx2/src/main/java/org/openapitools/client/model
- retrofit2rx3/src/main/java/org/openapitools/client/model
- retrofit2/src/main/java/org/openapitools/client/model
- vertx-no-nullable/src/main/java/org/openapitools/client/model
- vertx/src/main/java/org/openapitools/client/model
- webclient-jakarta/src/main/java/org/openapitools/client/model
- webclient-nullable-arrays/src/main/java/org/openapitools/client/model
- webclient-swagger2/src/main/java/org/openapitools/client/model
- webclient/src/main/java/org/openapitools/client/model
- openapi3/client/petstore/java
- jersey2-java8-special-characters/src/main/java/org/openapitools/client/model
- jersey2-java8-swagger1/src/main/java/org/openapitools/client/model
- jersey2-java8-swagger2/src/main/java/org/openapitools/client/model
- jersey2-java8/src/main/java/org/openapitools/client/model
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 4 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
| 75 | + | |
75 | 76 | | |
76 | 77 | | |
77 | 78 | | |
| |||
113 | 114 | | |
114 | 115 | | |
115 | 116 | | |
116 | | - | |
| 117 | + | |
117 | 118 | | |
118 | 119 | | |
119 | 120 | | |
| |||
189 | 190 | | |
190 | 191 | | |
191 | 192 | | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | | - | |
197 | | - | |
198 | | - | |
199 | | - | |
200 | | - | |
201 | | - | |
202 | | - | |
| 193 | + | |
203 | 194 | | |
204 | 195 | | |
205 | 196 | | |
| |||
246 | 237 | | |
247 | 238 | | |
248 | 239 | | |
249 | | - | |
| 240 | + | |
250 | 241 | | |
251 | 242 | | |
252 | 243 | | |
| |||
Lines changed: 4 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
| 84 | + | |
84 | 85 | | |
85 | 86 | | |
86 | 87 | | |
| |||
113 | 114 | | |
114 | 115 | | |
115 | 116 | | |
116 | | - | |
| 117 | + | |
117 | 118 | | |
118 | 119 | | |
119 | 120 | | |
| |||
197 | 198 | | |
198 | 199 | | |
199 | 200 | | |
200 | | - | |
201 | | - | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
| 201 | + | |
211 | 202 | | |
212 | 203 | | |
213 | 204 | | |
| |||
257 | 248 | | |
258 | 249 | | |
259 | 250 | | |
260 | | - | |
| 251 | + | |
261 | 252 | | |
262 | 253 | | |
263 | 254 | | |
| |||
Lines changed: 4 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
| 84 | + | |
84 | 85 | | |
85 | 86 | | |
86 | 87 | | |
| |||
113 | 114 | | |
114 | 115 | | |
115 | 116 | | |
116 | | - | |
| 117 | + | |
117 | 118 | | |
118 | 119 | | |
119 | 120 | | |
| |||
197 | 198 | | |
198 | 199 | | |
199 | 200 | | |
200 | | - | |
201 | | - | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | | - | |
208 | | - | |
209 | | - | |
210 | | - | |
| 201 | + | |
211 | 202 | | |
212 | 203 | | |
213 | 204 | | |
| |||
257 | 248 | | |
258 | 249 | | |
259 | 250 | | |
260 | | - | |
| 251 | + | |
261 | 252 | | |
262 | 253 | | |
263 | 254 | | |
| |||
Lines changed: 5 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
| 78 | + | |
78 | 79 | | |
79 | 80 | | |
80 | 81 | | |
| |||
104 | 105 | | |
105 | 106 | | |
106 | 107 | | |
107 | | - | |
| 108 | + | |
108 | 109 | | |
109 | 110 | | |
110 | 111 | | |
| |||
188 | 189 | | |
189 | 190 | | |
190 | 191 | | |
191 | | - | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | | - | |
197 | | - | |
198 | | - | |
199 | | - | |
200 | | - | |
201 | | - | |
| 192 | + | |
202 | 193 | | |
203 | 194 | | |
204 | 195 | | |
| |||
244 | 235 | | |
245 | 236 | | |
246 | 237 | | |
247 | | - | |
| 238 | + | |
248 | 239 | | |
249 | 240 | | |
250 | 241 | | |
| |||
266 | 257 | | |
267 | 258 | | |
268 | 259 | | |
269 | | - | |
| 260 | + | |
270 | 261 | | |
271 | 262 | | |
272 | 263 | | |
| |||
Lines changed: 4 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| 73 | + | |
73 | 74 | | |
74 | 75 | | |
75 | 76 | | |
| |||
106 | 107 | | |
107 | 108 | | |
108 | 109 | | |
109 | | - | |
| 110 | + | |
110 | 111 | | |
111 | 112 | | |
112 | 113 | | |
| |||
153 | 154 | | |
154 | 155 | | |
155 | 156 | | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | | - | |
165 | | - | |
166 | | - | |
| 157 | + | |
167 | 158 | | |
168 | 159 | | |
169 | 160 | | |
| |||
183 | 174 | | |
184 | 175 | | |
185 | 176 | | |
186 | | - | |
| 177 | + | |
187 | 178 | | |
188 | 179 | | |
189 | 180 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
Lines changed: 5 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| 68 | + | |
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
| |||
134 | 135 | | |
135 | 136 | | |
136 | 137 | | |
137 | | - | |
| 138 | + | |
138 | 139 | | |
139 | 140 | | |
140 | 141 | | |
| |||
210 | 211 | | |
211 | 212 | | |
212 | 213 | | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
| 214 | + | |
224 | 215 | | |
225 | 216 | | |
226 | 217 | | |
| |||
270 | 261 | | |
271 | 262 | | |
272 | 263 | | |
273 | | - | |
| 264 | + | |
274 | 265 | | |
275 | 266 | | |
276 | 267 | | |
| |||
285 | 276 | | |
286 | 277 | | |
287 | 278 | | |
288 | | - | |
| 279 | + | |
289 | 280 | | |
290 | 281 | | |
291 | 282 | | |
| |||
Lines changed: 8 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1954 | 1954 | | |
1955 | 1955 | | |
1956 | 1956 | | |
1957 | | - | |
| 1957 | + | |
1958 | 1958 | | |
1959 | | - | |
| 1959 | + | |
1960 | 1960 | | |
1961 | 1961 | | |
1962 | 1962 | | |
| |||
1971 | 1971 | | |
1972 | 1972 | | |
1973 | 1973 | | |
1974 | | - | |
| 1974 | + | |
1975 | 1975 | | |
1976 | | - | |
| 1976 | + | |
1977 | 1977 | | |
1978 | 1978 | | |
1979 | 1979 | | |
| |||
1989 | 1989 | | |
1990 | 1990 | | |
1991 | 1991 | | |
1992 | | - | |
| 1992 | + | |
1993 | 1993 | | |
1994 | | - | |
| 1994 | + | |
1995 | 1995 | | |
1996 | 1996 | | |
1997 | 1997 | | |
| |||
2008 | 2008 | | |
2009 | 2009 | | |
2010 | 2010 | | |
2011 | | - | |
| 2011 | + | |
2012 | 2012 | | |
2013 | 2013 | | |
2014 | 2014 | | |
2015 | 2015 | | |
2016 | 2016 | | |
2017 | | - | |
| 2017 | + | |
2018 | 2018 | | |
2019 | 2019 | | |
2020 | 2020 | | |
| |||
Lines changed: 6 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
| 39 | + | |
39 | 40 | | |
40 | 41 | | |
41 | 42 | | |
| 43 | + | |
42 | 44 | | |
43 | 45 | | |
44 | 46 | | |
45 | 47 | | |
46 | 48 | | |
47 | | - | |
| 49 | + | |
48 | 50 | | |
49 | 51 | | |
50 | 52 | | |
| |||
65 | 67 | | |
66 | 68 | | |
67 | 69 | | |
68 | | - | |
| 70 | + | |
69 | 71 | | |
70 | 72 | | |
71 | 73 | | |
72 | | - | |
| 74 | + | |
73 | 75 | | |
74 | 76 | | |
75 | 77 | | |
| |||
90 | 92 | | |
91 | 93 | | |
92 | 94 | | |
93 | | - | |
| 95 | + | |
94 | 96 | | |
95 | 97 | | |
96 | 98 | | |
| |||
0 commit comments