File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
jsonb-generator/src/main/java/io/avaje/jsonb/generator Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 1
1
package io .avaje .jsonb .generator ;
2
2
3
+ import javax .lang .model .element .TypeElement ;
4
+
3
5
import static io .avaje .jsonb .generator .ProcessingContext .element ;
4
6
5
7
import java .util .ArrayList ;
@@ -137,6 +139,10 @@ static String initLower(String name) {
137
139
138
140
/** Return the base type given the JsonAdapter type. */
139
141
static String baseTypeOfAdapter (String adapterFullName ) {
142
+ TypeElement element = element (adapterFullName );
143
+ if (element == null ) {
144
+ throw new NullPointerException ("Element not found for [" + adapterFullName + "]" );
145
+ }
140
146
return element (adapterFullName ).getInterfaces ().stream ()
141
147
.filter (t -> t .toString ().contains ("io.avaje.jsonb.JsonAdapter" ))
142
148
.findFirst ()
You can’t perform that action at this time.
0 commit comments