This repository was archived by the owner on Oct 22, 2020. It is now read-only.
File tree Expand file tree Collapse file tree
src/main/java/io/ebean/querybean/generator Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -14,6 +14,7 @@ interface Constants {
1414 String ENTITY = "javax.persistence.Entity" ;
1515 String EMBEDDABLE = "javax.persistence.Embeddable" ;
1616 String CONVERTER = "javax.persistence.Converter" ;
17+ String EBEAN_COMPONENT = "io.ebean.annotation.EbeanComponent" ;
1718
1819 String DBARRAY = "io.ebean.annotation.DbArray" ;
1920 String DBJSON = "io.ebean.annotation.DbJson" ;
Original file line number Diff line number Diff line change @@ -117,6 +117,10 @@ TypeElement converterAnnotation() {
117117 return elementUtils .getTypeElement (CONVERTER );
118118 }
119119
120+ TypeElement componentAnnotation () {
121+ return elementUtils .getTypeElement (EBEAN_COMPONENT );
122+ }
123+
120124 private String generatedAnnotation (boolean jdk8 ) {
121125 if (jdk8 ) {
122126 return isTypeAvailable (GENERATED_8 ) ? GENERATED_8 : null ;
Original file line number Diff line number Diff line change @@ -43,6 +43,7 @@ public Set<String> getSupportedAnnotationTypes() {
4343 annotations .add (ENTITY );
4444 annotations .add (EMBEDDABLE );
4545 annotations .add (CONVERTER );
46+ annotations .add (EBEAN_COMPONENT );
4647 annotations .add (MODULEINFO );
4748 return annotations ;
4849 }
@@ -86,6 +87,9 @@ private void processOthers(RoundEnvironment roundEnv) {
8687 for (Element element : roundEnv .getElementsAnnotatedWith (processingContext .converterAnnotation ())) {
8788 processingContext .addOther (element );
8889 }
90+ for (Element element : roundEnv .getElementsAnnotatedWith (processingContext .componentAnnotation ())) {
91+ processingContext .addOther (element );
92+ }
8993 }
9094
9195 private void writeModuleInfoBean () {
You can’t perform that action at this time.
0 commit comments