File tree Expand file tree Collapse file tree 4 files changed +14
-11
lines changed
http-generator-client/src/main/java/io/avaje/http/generator/client
http-generator-javalin/src/main/java/io/avaje/http/generator/javalin
http-generator-nima/src/main/java/io/avaje/http/generator/helidon/nima Expand file tree Collapse file tree 4 files changed +14
-11
lines changed Original file line number Diff line number Diff line change @@ -139,7 +139,7 @@ private void writeResponse(UType type) {
139139 } else if (isHttpResponse (mainType )) {
140140 writeWithHandler ();
141141 } else {
142- writer .append (".bean(" ). eol () ;
142+ writer .append (".bean(" );
143143 writeGeneric (type );
144144 }
145145 }
Original file line number Diff line number Diff line change @@ -27,15 +27,16 @@ public class ClientProcessor extends AbstractProcessor {
2727
2828 protected ProcessingContext ctx ;
2929
30- private boolean useJsonB ;
30+ private final boolean useJsonB ;
3131
3232 public ClientProcessor () {
33+ var jsonBOnClassPath = false ;
3334 try {
3435 Class .forName ("io.avaje.jsonb.Jsonb" );
35- this . useJsonB = true ;
36+ jsonBOnClassPath = true ;
3637 } catch (final ClassNotFoundException e ) {
37- this .useJsonB = false ;
3838 }
39+ useJsonB = jsonBOnClassPath ;
3940 }
4041
4142 public ClientProcessor (boolean useJsonb ) {
@@ -122,7 +123,7 @@ private void writeClient(Element controller) {
122123 }
123124
124125 protected String writeClientAdapter (ProcessingContext ctx , ControllerReader reader ) throws IOException {
125- return new ClientWriter (reader , ctx ,useJsonB ).write ();
126+ return new ClientWriter (reader , ctx , useJsonB ).write ();
126127 }
127128
128129}
Original file line number Diff line number Diff line change 99
1010public class JavalinProcessor extends BaseProcessor {
1111
12- private boolean useJsonB ;
12+ private final boolean useJsonB ;
1313
1414 public JavalinProcessor () {
15+ var jsonBOnClassPath = false ;
1516 try {
1617 Class .forName ("io.avaje.jsonb.Jsonb" );
17- this . useJsonB = true ;
18+ jsonBOnClassPath = true ;
1819 } catch (final ClassNotFoundException e ) {
19- this .useJsonB = false ;
2020 }
21+ useJsonB = jsonBOnClassPath ;
2122 }
2223
2324 public JavalinProcessor (boolean useJsonb ) {
Original file line number Diff line number Diff line change 99
1010public class NimaProcessor extends BaseProcessor {
1111
12- private boolean jsonB ;
12+ private final boolean jsonB ;
1313
1414 public NimaProcessor () {
15+ var jsonBOnClassPath = false ;
1516 try {
1617 Class .forName ("io.avaje.jsonb.Jsonb" );
17- this . jsonB = true ;
18+ jsonBOnClassPath = true ;
1819 } catch (final ClassNotFoundException e ) {
19- this .jsonB = false ;
2020 }
21+ jsonB = jsonBOnClassPath ;
2122 }
2223
2324 public NimaProcessor (boolean useJsonb ) {
You can’t perform that action at this time.
0 commit comments