-
Notifications
You must be signed in to change notification settings - Fork 61
Switch to SISU annotations and plugin, fixes #217 #313
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,19 +25,19 @@ | |
*/ | ||
|
||
import org.codehaus.plexus.compiler.Compiler; | ||
import org.codehaus.plexus.component.annotations.Component; | ||
import org.codehaus.plexus.component.annotations.Requirement; | ||
|
||
import javax.inject.Inject; | ||
import javax.inject.Named; | ||
import java.util.Map; | ||
|
||
/** | ||
* @author <a href="mailto:[email protected]">Trygve Laugstøl</a> | ||
*/ | ||
@Component( role = CompilerManager.class ) | ||
@Named | ||
public class DefaultCompilerManager | ||
implements CompilerManager | ||
{ | ||
@Requirement | ||
@Inject | ||
private Map<String, Compiler> compilers; | ||
|
||
// ---------------------------------------------------------------------- | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,15 +10,15 @@ | |
import org.aspectj.org.eclipse.jdt.internal.compiler.classfmt.ClassFileConstants; | ||
import org.aspectj.tools.ajc.Main; | ||
import org.codehaus.plexus.compiler.AbstractCompiler; | ||
import org.codehaus.plexus.compiler.Compiler; | ||
import org.codehaus.plexus.compiler.CompilerConfiguration; | ||
import org.codehaus.plexus.compiler.CompilerException; | ||
import org.codehaus.plexus.compiler.CompilerMessage; | ||
import org.codehaus.plexus.compiler.CompilerOutputStyle; | ||
import org.codehaus.plexus.compiler.CompilerResult; | ||
import org.codehaus.plexus.component.annotations.Component; | ||
import org.codehaus.plexus.util.DirectoryScanner; | ||
|
||
import javax.inject.Named; | ||
import javax.inject.Singleton; | ||
import java.io.File; | ||
import java.io.IOException; | ||
import java.net.MalformedURLException; | ||
|
@@ -287,7 +287,7 @@ | |
* | ||
* @author <a href="mailto:[email protected]">Jason van Zyl</a> | ||
*/ | ||
@Component( role = Compiler.class, hint = "aspectj") | ||
@Named("aspectj") | ||
public class AspectJCompiler | ||
extends AbstractCompiler | ||
{ | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,13 +17,11 @@ | |
*/ | ||
|
||
import org.codehaus.plexus.compiler.AbstractCompiler; | ||
import org.codehaus.plexus.compiler.Compiler; | ||
import org.codehaus.plexus.compiler.CompilerConfiguration; | ||
import org.codehaus.plexus.compiler.CompilerException; | ||
import org.codehaus.plexus.compiler.CompilerMessage; | ||
import org.codehaus.plexus.compiler.CompilerOutputStyle; | ||
import org.codehaus.plexus.compiler.CompilerResult; | ||
import org.codehaus.plexus.component.annotations.Component; | ||
import org.codehaus.plexus.util.DirectoryScanner; | ||
import org.codehaus.plexus.util.IOUtil; | ||
import org.codehaus.plexus.util.Os; | ||
|
@@ -34,6 +32,7 @@ | |
import org.codehaus.plexus.util.cli.StreamConsumer; | ||
import org.codehaus.plexus.util.cli.WriterStreamConsumer; | ||
|
||
import javax.inject.Named; | ||
import java.io.BufferedReader; | ||
import java.io.File; | ||
import java.io.FileWriter; | ||
|
@@ -57,7 +56,7 @@ | |
* @author <a href="mailto:[email protected]">Matthew Pocock</a> | ||
* @author <a href="mailto:[email protected]">Chris Stevenson</a> | ||
*/ | ||
@Component( role = Compiler.class, hint = "csharp" ) | ||
@Named( "csharp" ) | ||
public class CSharpCompiler | ||
extends AbstractCompiler | ||
{ | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,16 +18,15 @@ | |
|
||
import com.google.errorprone.ErrorProneJavaCompiler; | ||
|
||
import org.codehaus.plexus.compiler.Compiler; | ||
import org.codehaus.plexus.compiler.CompilerConfiguration; | ||
import org.codehaus.plexus.compiler.CompilerException; | ||
import org.codehaus.plexus.compiler.CompilerMessage; | ||
import org.codehaus.plexus.compiler.CompilerResult; | ||
import org.codehaus.plexus.compiler.javac.InProcessCompiler; | ||
import org.codehaus.plexus.compiler.javac.JavacCompiler; | ||
import org.codehaus.plexus.compiler.javac.JavaxToolsCompiler; | ||
import org.codehaus.plexus.component.annotations.Component; | ||
|
||
import javax.inject.Named; | ||
import javax.tools.JavaCompiler; | ||
|
||
import java.net.MalformedURLException; | ||
|
@@ -40,7 +39,7 @@ | |
* | ||
* @author <a href="mailto:[email protected]">Alex Eagle</a> | ||
*/ | ||
@Component( role = Compiler.class, hint = "javac-with-errorprone") | ||
@Named("javac-with-errorprone") | ||
public class JavacCompilerWithErrorProne | ||
extends JavacCompiler | ||
{ | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -63,29 +63,31 @@ | |
import java.util.concurrent.CopyOnWriteArrayList; | ||
|
||
import org.codehaus.plexus.compiler.AbstractCompiler; | ||
import org.codehaus.plexus.compiler.Compiler; | ||
import org.codehaus.plexus.compiler.CompilerConfiguration; | ||
import org.codehaus.plexus.compiler.CompilerException; | ||
import org.codehaus.plexus.compiler.CompilerMessage; | ||
import org.codehaus.plexus.compiler.CompilerOutputStyle; | ||
import org.codehaus.plexus.compiler.CompilerResult; | ||
import org.codehaus.plexus.component.annotations.Component; | ||
import org.codehaus.plexus.component.annotations.Requirement; | ||
import org.codehaus.plexus.util.FileUtils; | ||
import org.codehaus.plexus.util.Os; | ||
import org.codehaus.plexus.util.StringUtils; | ||
import org.codehaus.plexus.util.cli.CommandLineException; | ||
import org.codehaus.plexus.util.cli.CommandLineUtils; | ||
import org.codehaus.plexus.util.cli.Commandline; | ||
|
||
import javax.inject.Inject; | ||
import javax.inject.Named; | ||
import javax.inject.Singleton; | ||
|
||
/** | ||
* @author <a href="mailto:[email protected]">Trygve Laugstøl</a> | ||
* @author <a href="mailto:[email protected]">Matthew Pocock</a> | ||
* @author <a href="mailto:[email protected]">Jörg Waßmer</a> | ||
* @author Others | ||
* | ||
*/ | ||
@Component( role = Compiler.class, hint = "javac" ) | ||
@Named("javac") | ||
@Singleton | ||
public class JavacCompiler | ||
extends AbstractCompiler | ||
{ | ||
|
@@ -107,7 +109,7 @@ public class JavacCompiler | |
|
||
private final List<Class<?>> javaccClasses = new CopyOnWriteArrayList<>(); | ||
|
||
@Requirement | ||
@Inject | ||
private InProcessCompiler inProcessCompiler; | ||
|
||
// ---------------------------------------------------------------------- | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,10 +22,10 @@ | |
import org.codehaus.plexus.compiler.CompilerMessage; | ||
import org.codehaus.plexus.compiler.CompilerException; | ||
import org.codehaus.plexus.compiler.CompilerResult; | ||
import org.codehaus.plexus.component.annotations.Component; | ||
import org.slf4j.Logger; | ||
import org.slf4j.LoggerFactory; | ||
|
||
import javax.inject.Named; | ||
import javax.tools.Diagnostic; | ||
import javax.tools.DiagnosticCollector; | ||
import javax.tools.JavaCompiler; | ||
|
@@ -45,7 +45,7 @@ | |
* @author <a href="mailto:[email protected]">David M. Lloyd</a> | ||
* @since 2.0 | ||
*/ | ||
@Component( role = InProcessCompiler.class ) | ||
@Named | ||
public class JavaxToolsCompiler implements InProcessCompiler | ||
{ | ||
private final Logger log = LoggerFactory.getLogger( getClass() ); | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.