Search in sources :

Example 11 with SourceInclusionScanner

use of org.codehaus.plexus.compiler.util.scan.SourceInclusionScanner in project tycho by eclipse.

the class AbstractOsgiCompilerMojo method getSourceInclusionScanner.

@Override
protected SourceInclusionScanner getSourceInclusionScanner(String inputFileEnding) {
    SourceInclusionScanner scanner = null;
    if (includes.isEmpty() && excludes.isEmpty()) {
        includes = Collections.singleton("**/*." + inputFileEnding);
        scanner = new SimpleSourceInclusionScanner(includes, Collections.<String>emptySet());
    } else {
        if (includes.isEmpty()) {
            includes.add("**/*." + inputFileEnding);
        }
        scanner = new SimpleSourceInclusionScanner(includes, excludes);
    }
    return scanner;
}
Also used : SourceInclusionScanner(org.codehaus.plexus.compiler.util.scan.SourceInclusionScanner) SimpleSourceInclusionScanner(org.codehaus.plexus.compiler.util.scan.SimpleSourceInclusionScanner) SimpleSourceInclusionScanner(org.codehaus.plexus.compiler.util.scan.SimpleSourceInclusionScanner)

Aggregations

SourceInclusionScanner (org.codehaus.plexus.compiler.util.scan.SourceInclusionScanner)11 SimpleSourceInclusionScanner (org.codehaus.plexus.compiler.util.scan.SimpleSourceInclusionScanner)9 SuffixMapping (org.codehaus.plexus.compiler.util.scan.mapping.SuffixMapping)5 File (java.io.File)3 HashSet (java.util.HashSet)3 LinkedHashSet (java.util.LinkedHashSet)3 MojoExecutionException (org.apache.maven.plugin.MojoExecutionException)3 InclusionScanException (org.codehaus.plexus.compiler.util.scan.InclusionScanException)3 SourceMapping (org.codehaus.plexus.compiler.util.scan.mapping.SourceMapping)3 ArrayList (java.util.ArrayList)1 StaleSourceScanner (org.codehaus.plexus.compiler.util.scan.StaleSourceScanner)1 SingleTargetSourceMapping (org.codehaus.plexus.compiler.util.scan.mapping.SingleTargetSourceMapping)1