Skip to content

Commit 365be8b

Browse files
committed
Generate java-* Samples
Signed-off-by: Chrimle <28791817+Chrimle@users.noreply.github.com>
1 parent bd3c7fa commit 365be8b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+58
-232
lines changed

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/Addressable.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -131,10 +131,7 @@ public String toString() {
131131
* (except the first line).
132132
*/
133133
private String toIndentedString(Object o) {
134-
if (o == null) {
135-
return "null";
136-
}
137-
return o.toString().replace("\n", "\n ");
134+
return o == null ? "null" : o.toString().replace("\n", "\n ");
138135
}
139136

140137
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/Apple.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -134,10 +134,7 @@ public String toString() {
134134
* (except the first line).
135135
*/
136136
private String toIndentedString(Object o) {
137-
if (o == null) {
138-
return "null";
139-
}
140-
return o.toString().replace("\n", "\n ");
137+
return o == null ? "null" : o.toString().replace("\n", "\n ");
141138
}
142139

143140
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/Banana.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -134,10 +134,7 @@ public String toString() {
134134
* (except the first line).
135135
*/
136136
private String toIndentedString(Object o) {
137-
if (o == null) {
138-
return "null";
139-
}
140-
return o.toString().replace("\n", "\n ");
137+
return o == null ? "null" : o.toString().replace("\n", "\n ");
141138
}
142139

143140
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/Bar.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -233,10 +233,7 @@ public String toString() {
233233
* (except the first line).
234234
*/
235235
private String toIndentedString(Object o) {
236-
if (o == null) {
237-
return "null";
238-
}
239-
return o.toString().replace("\n", "\n ");
236+
return o == null ? "null" : o.toString().replace("\n", "\n ");
240237
}
241238

242239
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/BarCreate.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -208,10 +208,7 @@ public String toString() {
208208
* (except the first line).
209209
*/
210210
private String toIndentedString(Object o) {
211-
if (o == null) {
212-
return "null";
213-
}
214-
return o.toString().replace("\n", "\n ");
211+
return o == null ? "null" : o.toString().replace("\n", "\n ");
215212
}
216213

217214
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/BarRef.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,10 +109,7 @@ public String toString() {
109109
* (except the first line).
110110
*/
111111
private String toIndentedString(Object o) {
112-
if (o == null) {
113-
return "null";
114-
}
115-
return o.toString().replace("\n", "\n ");
112+
return o == null ? "null" : o.toString().replace("\n", "\n ");
116113
}
117114

118115
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/Cat.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,7 @@ public String toString() {
9999
* (except the first line).
100100
*/
101101
private String toIndentedString(Object o) {
102-
if (o == null) {
103-
return "null";
104-
}
105-
return o.toString().replace("\n", "\n ");
102+
return o == null ? "null" : o.toString().replace("\n", "\n ");
106103
}
107104

108105
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/Dog.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,7 @@ public String toString() {
9999
* (except the first line).
100100
*/
101101
private String toIndentedString(Object o) {
102-
if (o == null) {
103-
return "null";
104-
}
105-
return o.toString().replace("\n", "\n ");
102+
return o == null ? "null" : o.toString().replace("\n", "\n ");
106103
}
107104

108105
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/Entity.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -244,10 +244,7 @@ public String toString() {
244244
* (except the first line).
245245
*/
246246
private String toIndentedString(Object o) {
247-
if (o == null) {
248-
return "null";
249-
}
250-
return o.toString().replace("\n", "\n ");
247+
return o == null ? "null" : o.toString().replace("\n", "\n ");
251248
}
252249

253250
}

samples/client/others/java/restclient-sealedInterface/src/main/java/org/openapitools/client/model/EntityRef.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -304,10 +304,7 @@ public String toString() {
304304
* (except the first line).
305305
*/
306306
private String toIndentedString(Object o) {
307-
if (o == null) {
308-
return "null";
309-
}
310-
return o.toString().replace("\n", "\n ");
307+
return o == null ? "null" : o.toString().replace("\n", "\n ");
311308
}
312309

313310
}

0 commit comments

Comments
 (0)