You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by hb...@apache.org on 2014/10/05 11:27:04 UTC

svn commit: r1629481 - in /maven/plugins/trunk/maven-compiler-plugin/src: it/MCOMPILER-157/ it/MCOMPILER-157/annotation-processor/ it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/ it/MCOMPILER-157/annotation-user/ it/MCOMPILER-157/annotat...

Author: hboutemy
Date: Sun Oct  5 09:27:03 2014
New Revision: 1629481

URL: http://svn.apache.org/r1629481
Log:
fixed errors reported by RAT and Checkstyle

Modified:
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/pom.xml
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotation.java
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotationProcessor.java
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/pom.xml
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/main/java/org/issue/SimpleObject.java
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/test/java/org/issue/SimpleTestObject.java
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/pom.xml
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/src/main/java/org/issue/SourcePathReadGoal.java
    maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/invoker.properties
    maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java
    maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/TestCompilerMojo.java

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/pom.xml?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/pom.xml (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/pom.xml Sun Oct  5 09:27:03 2014
@@ -1,3 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
   <modelVersion>4.0.0</modelVersion>

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotation.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotation.java?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotation.java (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotation.java Sun Oct  5 09:27:03 2014
@@ -1,5 +1,24 @@
 package org.issue;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 import java.lang.annotation.ElementType;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotationProcessor.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotationProcessor.java?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotationProcessor.java (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-processor/src/main/java/org/issue/SimpleAnnotationProcessor.java Sun Oct  5 09:27:03 2014
@@ -1,5 +1,24 @@
 package org.issue;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 import java.io.IOException;
 import java.io.Writer;
 import java.util.Set;
@@ -18,35 +37,44 @@ import javax.lang.model.util.Elements;
 import javax.tools.FileObject;
 import javax.tools.StandardLocation;
 
-@SupportedSourceVersion(SourceVersion.RELEASE_6)
-@SupportedAnnotationTypes("org.issue.SimpleAnnotation")
-public class SimpleAnnotationProcessor extends AbstractProcessor {
+@SupportedSourceVersion( SourceVersion.RELEASE_6 )
+@SupportedAnnotationTypes( "org.issue.SimpleAnnotation" )
+public class SimpleAnnotationProcessor
+    extends AbstractProcessor
+{
 
     @Override
-    public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment roundEnv) {
-	Filer filer = processingEnv.getFiler();
-
-	Elements elementUtils = processingEnv.getElementUtils();
-
-	Set<? extends Element> elements = roundEnv.getElementsAnnotatedWith(SimpleAnnotation.class);
-
-	for (Element element : elements) {
-	    Name name = element.getSimpleName();
-
-	    PackageElement packageElement = elementUtils.getPackageOf(element);
-
-	    try {
-		FileObject resource = filer.createResource(StandardLocation.SOURCE_OUTPUT, packageElement.getQualifiedName(), name + ".txt", element);
-
-		Writer writer = resource.openWriter();
-		writer.write(name.toString());
-		writer.close();
-	    } catch (IOException e) {
-		throw new RuntimeException(e);
-	    }
-	}
+    public boolean process( Set<? extends TypeElement> annotations, RoundEnvironment roundEnv )
+    {
+        Filer filer = processingEnv.getFiler();
+
+        Elements elementUtils = processingEnv.getElementUtils();
+
+        Set<? extends Element> elements = roundEnv.getElementsAnnotatedWith( SimpleAnnotation.class );
+
+        for ( Element element : elements )
+        {
+            Name name = element.getSimpleName();
+
+            PackageElement packageElement = elementUtils.getPackageOf( element );
+
+            try
+            {
+                FileObject resource =
+                    filer.createResource( StandardLocation.SOURCE_OUTPUT, packageElement.getQualifiedName(), name
+                        + ".txt", element );
+
+                Writer writer = resource.openWriter();
+                writer.write( name.toString() );
+                writer.close();
+            }
+            catch ( IOException e )
+            {
+                throw new RuntimeException( e );
+            }
+        }
 
-	return !elements.isEmpty();
+        return !elements.isEmpty();
     }
 
 }

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/pom.xml?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/pom.xml (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/pom.xml Sun Oct  5 09:27:03 2014
@@ -1,3 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
   <modelVersion>4.0.0</modelVersion>

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/main/java/org/issue/SimpleObject.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/main/java/org/issue/SimpleObject.java?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/main/java/org/issue/SimpleObject.java (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/main/java/org/issue/SimpleObject.java Sun Oct  5 09:27:03 2014
@@ -1,6 +1,26 @@
 package org.issue;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 @SimpleAnnotation
-public class SimpleObject {
+public class SimpleObject
+{
 
 }

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/test/java/org/issue/SimpleTestObject.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/test/java/org/issue/SimpleTestObject.java?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/test/java/org/issue/SimpleTestObject.java (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-user/src/test/java/org/issue/SimpleTestObject.java Sun Oct  5 09:27:03 2014
@@ -1,6 +1,26 @@
 package org.issue;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 @SimpleAnnotation
-public class SimpleTestObject {
+public class SimpleTestObject
+{
 
 }

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/pom.xml?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/pom.xml (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/pom.xml Sun Oct  5 09:27:03 2014
@@ -1,3 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
   <modelVersion>4.0.0</modelVersion>

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/src/main/java/org/issue/SourcePathReadGoal.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/src/main/java/org/issue/SourcePathReadGoal.java?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/src/main/java/org/issue/SourcePathReadGoal.java (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/annotation-verify/src/main/java/org/issue/SourcePathReadGoal.java Sun Oct  5 09:27:03 2014
@@ -1,5 +1,24 @@
 package org.issue;
 
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
 import java.io.File;
 import java.io.IOException;
 import java.util.List;

Modified: maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/invoker.properties
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/invoker.properties?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/invoker.properties (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/it/MCOMPILER-157/invoker.properties Sun Oct  5 09:27:03 2014
@@ -1 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
 invoker.goals=clean process-test-classes
\ No newline at end of file

Modified: maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java Sun Oct  5 09:27:03 2014
@@ -260,12 +260,12 @@ public abstract class AbstractCompilerMo
     
     /**
      * <p>
-     * Sets the unformatted single argument string to be passed to the compiler if {@link #fork} is set to <code>true</code>.
-     * To pass multiple arguments such as <code>-Xmaxerrs 1000</code> (which are actually two arguments) you have to use {@link #compilerArguments}.
+     * Sets the unformatted single argument string to be passed to the compiler if {@link #fork} is set to
+     * <code>true</code>. To pass multiple arguments such as <code>-Xmaxerrs 1000</code> (which are actually two
+     * arguments) you have to use {@link #compilerArguments}.
      * </p>
      * <p>
-     * This is because the list of valid arguments passed to a Java compiler
-     * varies based on the compiler version.
+     * This is because the list of valid arguments passed to a Java compiler varies based on the compiler version.
      * </p>
      */
     @Parameter
@@ -326,7 +326,8 @@ public abstract class AbstractCompilerMo
     private MavenSession session;
 
     /**
-     * The current project instance. This is used for propagating generated-sources paths as compile/testCompile source roots.
+     * The current project instance. This is used for propagating generated-sources paths as compile/testCompile source
+     * roots.
      */
     @Parameter( defaultValue = "${project}", readonly = true, required = true )
     private MavenProject project;
@@ -334,9 +335,10 @@ public abstract class AbstractCompilerMo
     /**
      * Strategy to re use javacc class created:
      * <ul>
-     * <li><code>reuseCreated</code> (default): will reuse already created but in case of multi-threaded builds,
-     * each thread will have its own instance</li>
-     * <li><code>reuseSame</code>: the same Javacc class will be used for each compilation even for multi-threaded build</li>
+     * <li><code>reuseCreated</code> (default): will reuse already created but in case of multi-threaded builds, each
+     * thread will have its own instance</li>
+     * <li><code>reuseSame</code>: the same Javacc class will be used for each compilation even for multi-threaded build
+     * </li>
      * <li><code>alwaysNew</code>: a new Javacc class will be created for each compilation</li>
      * </ul>
      * Note this parameter value depends on the os/jdk you are using, but the default value should work on most of env.
@@ -481,10 +483,11 @@ public abstract class AbstractCompilerMo
             String[] split = StringUtils.split( debuglevel, "," );
             for ( String aSplit : split )
             {
-                if (!(aSplit.equalsIgnoreCase("none") || aSplit.equalsIgnoreCase("lines")
-                        || aSplit.equalsIgnoreCase("vars") || aSplit.equalsIgnoreCase("source"))) {
-                    throw new IllegalArgumentException("The specified debug level: '" + aSplit + "' is unsupported. "
-                            + "Legal values are 'none', 'lines', 'vars', and 'source'.");
+                if ( !( aSplit.equalsIgnoreCase( "none" ) || aSplit.equalsIgnoreCase( "lines" )
+                    || aSplit.equalsIgnoreCase( "vars" ) || aSplit.equalsIgnoreCase( "source" ) ) )
+                {
+                    throw new IllegalArgumentException( "The specified debug level: '" + aSplit + "' is unsupported. "
+                        + "Legal values are 'none', 'lines', 'vars', and 'source'." );
                 }
             }
             compilerConfiguration.setDebugLevel( debuglevel );
@@ -546,7 +549,8 @@ public abstract class AbstractCompilerMo
 
         String effectiveCompilerArgument = getCompilerArgument();
 
-        if ( ( effectiveCompilerArguments != null ) || ( effectiveCompilerArgument != null ) || ( compilerArgs != null ) )
+        if ( ( effectiveCompilerArguments != null ) || ( effectiveCompilerArgument != null )
+                        || ( compilerArgs != null ) )
         {
             LinkedHashMap<String, String> cplrArgsCopy = new LinkedHashMap<String, String>();
             if ( effectiveCompilerArguments != null )
@@ -638,7 +642,13 @@ public abstract class AbstractCompilerMo
             {
                 if ( !skipMultiThreadWarning )
                 {
-                    getLog().warn("You are in a multi-thread build and compilerReuseStrategy is set to reuseSame. This can cause issues in some environments (os/jdk)! Consider using reuseCreated strategy." + System.getProperty("line.separator") + "If your env is fine with reuseSame, you can skip this warning with the configuration field skipMultiThreadWarning or -Dmaven.compiler.skipMultiThreadWarning=true");
+                    getLog().warn( "You are in a multi-thread build and compilerReuseStrategy is set to reuseSame."
+                                       + " This can cause issues in some environments (os/jdk)!"
+                                       + " Consider using reuseCreated strategy."
+                                       + System.getProperty( "line.separator" )
+                                       + "If your env is fine with reuseSame, you can skip this warning with the "
+                                       + "configuration field skipMultiThreadWarning "
+                                       + "or -Dmaven.compiler.skipMultiThreadWarning=true" );
                 }
             }
             compilerConfiguration.setCompilerReuseStrategy( CompilerConfiguration.CompilerReuseStrategy.ReuseSame );
@@ -672,8 +682,9 @@ public abstract class AbstractCompilerMo
 
                 incrementalBuildHelperRequest = new IncrementalBuildHelperRequest().inputFiles( sources );
 
-                if ( ( compiler.getCompilerOutputStyle().equals( CompilerOutputStyle.ONE_OUTPUT_FILE_FOR_ALL_INPUT_FILES )
-                    && !canUpdateTarget ) || isDependencyChanged() || isSourceChanged( compilerConfiguration, compiler )
+                if ( ( compiler.getCompilerOutputStyle().equals( CompilerOutputStyle.ONE_OUTPUT_FILE_FOR_ALL_INPUT_FILES ) && !canUpdateTarget )
+                    || isDependencyChanged()
+                    || isSourceChanged( compilerConfiguration, compiler )
                     || incrementalBuildHelper.inputFileTreeChanged( incrementalBuildHelperRequest ) )
                 {
                     getLog().info( "Changes detected - recompiling the module!" );
@@ -847,7 +858,8 @@ public abstract class AbstractCompilerMo
             {
                 errors.add( message );
             }
-            else if ( message.getKind() == CompilerMessage.Kind.WARNING || message.getKind() == CompilerMessage.Kind.MANDATORY_WARNING )
+            else if ( message.getKind() == CompilerMessage.Kind.WARNING
+                || message.getKind() == CompilerMessage.Kind.MANDATORY_WARNING )
             {
                 warnings.add( message );
             }
@@ -861,10 +873,9 @@ public abstract class AbstractCompilerMo
         {
             for ( CompilerMessage message : others )
             {
-                assert
-                    message.getKind() != CompilerMessage.Kind.ERROR &&
-                    message.getKind() != CompilerMessage.Kind.WARNING &&
-                    message.getKind() != CompilerMessage.Kind.MANDATORY_WARNING;
+                assert message.getKind() != CompilerMessage.Kind.ERROR
+                    && message.getKind() != CompilerMessage.Kind.WARNING
+                    && message.getKind() != CompilerMessage.Kind.MANDATORY_WARNING;
                 getLog().info( message.toString() );
             }
             if ( !warnings.isEmpty() )
@@ -906,26 +917,22 @@ public abstract class AbstractCompilerMo
         {
             for ( CompilerMessage message : compilerResult.getCompilerMessages() )
             {
-                switch (message.getKind())
+                switch ( message.getKind() )
                 {
                     case NOTE:
                     case OTHER:
-                    {
                         getLog().info( message.toString() );
                         break;
-                    }
+
                     case ERROR:
-                    {
                         getLog().error( message.toString() );
                         break;
-                    }
+
                     case MANDATORY_WARNING:
                     case WARNING:
                     default:
-                    {
                         getLog().warn( message.toString() );
                         break;
-                    }
                 }
             }
         }
@@ -1026,7 +1033,7 @@ public abstract class AbstractCompilerMo
 
 
     /**
-     * try to get thread count if a Maven 3 build, using reflection as the plugin must not be maven3 api dependant
+     * try to get thread count if a Maven 3 build, using reflection as the plugin must not be maven3 api dependent
      *
      * @return number of thread for this build or 1 if not multi-thread build
      */
@@ -1075,8 +1082,8 @@ public abstract class AbstractCompilerMo
         {
             value = setting + "m";
         }
-        else if ( ( isDigits( setting.substring( 0, setting.length() - 1 ) ) ) && ( setting.toLowerCase().endsWith(
-            "m" ) ) )
+        else if ( ( isDigits( setting.substring( 0, setting.length() - 1 ) ) )
+            && ( setting.toLowerCase().endsWith( "m" ) ) )
         {
             value = setting;
         }
@@ -1243,7 +1250,7 @@ public abstract class AbstractCompilerMo
     /**
      * @param classPathEntry entry to check
      * @param buildStartTime time build start
-     * @return if any changes occured
+     * @return if any changes occurred
      */
     private boolean hasNewFile( File classPathEntry, Date buildStartTime )
     {
@@ -1254,8 +1261,8 @@ public abstract class AbstractCompilerMo
 
         if ( classPathEntry.isFile() )
         {
-            return classPathEntry.lastModified() >= buildStartTime.getTime() && fileExtensions.contains(
-                FileUtils.getExtension( classPathEntry.getName() ) );
+            return classPathEntry.lastModified() >= buildStartTime.getTime()
+                && fileExtensions.contains( FileUtils.getExtension( classPathEntry.getName() ) );
         }
 
         File[] children = classPathEntry.listFiles();

Modified: maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/TestCompilerMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/TestCompilerMojo.java?rev=1629481&r1=1629480&r2=1629481&view=diff
==============================================================================
--- maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/TestCompilerMojo.java (original)
+++ maven/plugins/trunk/maven-compiler-plugin/src/main/java/org/apache/maven/plugin/compiler/TestCompilerMojo.java Sun Oct  5 09:27:03 2014
@@ -21,6 +21,7 @@ package org.apache.maven.plugin.compiler
 
 import org.apache.maven.plugin.MojoExecutionException;
 import org.apache.maven.plugins.annotations.LifecyclePhase;
+import org.apache.maven.plugins.annotations.Mojo;
 import org.apache.maven.plugins.annotations.Parameter;
 import org.apache.maven.plugins.annotations.ResolutionScope;
 import org.codehaus.plexus.compiler.util.scan.SimpleSourceInclusionScanner;
@@ -41,8 +42,8 @@ import java.util.Set;
  * @version $Id$
  * @since 2.0
  */
-@org.apache.maven.plugins.annotations.Mojo ( name = "testCompile", defaultPhase = LifecyclePhase.TEST_COMPILE,
-                                             threadSafe = true, requiresDependencyResolution = ResolutionScope.TEST )
+@Mojo( name = "testCompile", defaultPhase = LifecyclePhase.TEST_COMPILE, threadSafe = true,
+                requiresDependencyResolution = ResolutionScope.TEST )
 public class TestCompilerMojo
     extends AbstractCompilerMojo
 {