@@ -63,9 +63,8 @@ public synchronized void init(ProcessingEnvironment processingEnv) {
6363
6464 /** Loads provider files generated by avaje-inject-maven-plugin */
6565 void loadProvidedFiles (Filer filer ) {
66- targetProvidesLines (filer , "target/avaje-plugin-provides.txt" ).forEach (pluginFileProvided ::add );
67-
68- targetProvidesLines (filer , "target/avaje-module-provides.txt" ).forEach (moduleFileProvided ::add );
66+ pluginFileProvided .addAll (targetProvidesLines (filer , "target/avaje-plugin-provides.txt" ));
67+ moduleFileProvided .addAll (targetProvidesLines (filer , "target/avaje-module-provides.txt" ));
6968 }
7069
7170 private static List <String > targetProvidesLines (Filer filer , String relativeName ) {
@@ -82,26 +81,22 @@ private static List<String> targetProvidesLines(Filer filer, String relativeName
8281
8382 private static String targetProvides (Filer filer , String relativeName ) throws IOException {
8483 return filer
85- .getResource (StandardLocation .CLASS_OUTPUT , "" , relativeName )
86- .toUri ()
87- .toString ()
88- .replace ("/target/classes" , "" );
84+ .getResource (StandardLocation .CLASS_OUTPUT , "" , relativeName )
85+ .toUri ()
86+ .toString ()
87+ .replace ("/target/classes" , "" );
8988 }
9089
9190 @ Override
9291 public boolean process (Set <? extends TypeElement > annotations , RoundEnvironment roundEnv ) {
9392 readModule (roundEnv );
9493 readScopes (roundEnv .getElementsAnnotatedWith (context .element (Constants .SCOPE )));
95- readChangedBeans (
96- roundEnv .getElementsAnnotatedWith (context .element (Constants .FACTORY )), true );
94+ readChangedBeans (roundEnv .getElementsAnnotatedWith (context .element (Constants .FACTORY )), true );
9795 if (defaultScope .includeSingleton ()) {
98- readChangedBeans (
99- roundEnv .getElementsAnnotatedWith (context .element (Constants .SINGLETON )), false );
96+ readChangedBeans (roundEnv .getElementsAnnotatedWith (context .element (Constants .SINGLETON )), false );
10097 }
101- readChangedBeans (
102- roundEnv .getElementsAnnotatedWith (context .element (Constants .COMPONENT )), false );
103- readChangedBeans (
104- roundEnv .getElementsAnnotatedWith (context .element (Constants .PROTOTYPE )), false );
98+ readChangedBeans (roundEnv .getElementsAnnotatedWith (context .element (Constants .COMPONENT )), false );
99+ readChangedBeans (roundEnv .getElementsAnnotatedWith (context .element (Constants .PROTOTYPE )), false );
105100 final var typeElement = elementUtils .getTypeElement (Constants .CONTROLLER );
106101 if (typeElement != null ) {
107102 readChangedBeans (roundEnv .getElementsAnnotatedWith (typeElement ), false );
@@ -186,11 +181,9 @@ private void readModule(RoundEnvironment roundEnv) {
186181 private void readInjectModule (RoundEnvironment roundEnv ) {
187182 // read other that are annotated with InjectModule
188183 for (final Element element : roundEnv .getElementsAnnotatedWith (context .element (Constants .INJECTMODULE ))) {
189-
190184 final var scope = ScopePrism .getInstanceOn (element );
191185 if (scope == null ) {
192186 // it it not a custom scope annotation
193-
194187 final var annotation = InjectModulePrism .getInstanceOn (element );
195188 if (annotation != null ) {
196189 defaultScope .details (annotation .name (), element );
0 commit comments