commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mben...@apache.org
Subject svn commit: r1471045 - in /commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven: AbstractWeaveMojo.java JavaLoggingToMojoLoggingRedirector.java TestWeaveMojo.java
Date Tue, 23 Apr 2013 17:11:05 GMT
Author: mbenson
Date: Tue Apr 23 17:11:04 2013
New Revision: 1471045

URL: http://svn.apache.org/r1471045
Log:
more consistent formatting

Modified:
    commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/AbstractWeaveMojo.java
    commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/JavaLoggingToMojoLoggingRedirector.java
    commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/TestWeaveMojo.java

Modified: commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/AbstractWeaveMojo.java
URL: http://svn.apache.org/viewvc/commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/AbstractWeaveMojo.java?rev=1471045&r1=1471044&r2=1471045&view=diff
==============================================================================
--- commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/AbstractWeaveMojo.java
(original)
+++ commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/AbstractWeaveMojo.java
Tue Apr 23 17:11:04 2013
@@ -41,21 +41,18 @@ public abstract class AbstractWeaveMojo 
     protected abstract File getTarget();
 
     @Override
-    public void execute() throws MojoExecutionException
-    {
+    public void execute() throws MojoExecutionException {
         Log mojoLog = getLog();
         JavaLoggingToMojoLoggingRedirector logRedirector = new JavaLoggingToMojoLoggingRedirector(mojoLog);
         logRedirector.activate();
 
         try {
-
             WeaveProcessor wp = WeaveProcessor.getInstance();
             configure(wp);
             wp.weave();
         } catch (Exception e) {
             throw new MojoExecutionException("weaving failed", e);
-        }
-        finally {
+        } finally {
             logRedirector.deactivate();
         }
     }

Modified: commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/JavaLoggingToMojoLoggingRedirector.java
URL: http://svn.apache.org/viewvc/commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/JavaLoggingToMojoLoggingRedirector.java?rev=1471045&r1=1471044&r2=1471045&view=diff
==============================================================================
--- commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/JavaLoggingToMojoLoggingRedirector.java
(original)
+++ commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/JavaLoggingToMojoLoggingRedirector.java
Tue Apr 23 17:11:04 2013
@@ -18,7 +18,6 @@
  */
 package org.apache.commons.weaver.maven;
 
-
 import java.text.MessageFormat;
 import java.util.ArrayList;
 import java.util.List;
@@ -32,12 +31,10 @@ import java.util.logging.Logger;
 import org.apache.maven.plugin.MojoExecutionException;
 import org.apache.maven.plugin.logging.Log;
 
-
 /**
  * This class redirects calls to java.util.Logging to Mojo logging.
  */
-public class JavaLoggingToMojoLoggingRedirector
-{
+public class JavaLoggingToMojoLoggingRedirector {
     private JDKLogHandler activeHandler;
     private List<Handler> removedHandlers = new ArrayList<Handler>();
 
@@ -49,8 +46,7 @@ public class JavaLoggingToMojoLoggingRed
     /**
      * @param mojoLogger the Maven mojo logger to delegate messages to.
      */
-    public JavaLoggingToMojoLoggingRedirector(Log mojoLogger)
-    {
+    public JavaLoggingToMojoLoggingRedirector(Log mojoLogger) {
         this.mojoLogger = mojoLogger;
     }
 
@@ -97,7 +93,6 @@ public class JavaLoggingToMojoLoggingRed
         }
     }
 
-
     private class JDKLogHandler extends Handler {
 
         @Override
@@ -106,17 +101,13 @@ public class JavaLoggingToMojoLoggingRed
             Level level = record.getLevel();
             if (level == Level.SEVERE && mojoLogger.isErrorEnabled()) {
                 mojoLogger.error(getMessage(record), exception);
-            }
-            else if (level == Level.WARNING && mojoLogger.isWarnEnabled()) {
+            } else if (level == Level.WARNING && mojoLogger.isWarnEnabled()) {
                 mojoLogger.warn(getMessage(record), exception);
-            }
-            else if (level == Level.INFO && mojoLogger.isInfoEnabled()) {
+            } else if (level == Level.INFO && mojoLogger.isInfoEnabled()) {
                 mojoLogger.info(getMessage(record), exception);
-            }
-            else if (level == Level.CONFIG && mojoLogger.isDebugEnabled()) {
+            } else if (level == Level.CONFIG && mojoLogger.isDebugEnabled()) {
                 mojoLogger.debug(getMessage(record), exception);
-            }
-            else if (mojoLogger.isDebugEnabled()) {
+            } else if (mojoLogger.isDebugEnabled()) {
                 mojoLogger.debug(getMessage(record), exception);
             }
         }

Modified: commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/TestWeaveMojo.java
URL: http://svn.apache.org/viewvc/commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/TestWeaveMojo.java?rev=1471045&r1=1471044&r2=1471045&view=diff
==============================================================================
--- commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/TestWeaveMojo.java
(original)
+++ commons/sandbox/weaver/trunk/maven-plugin/src/main/java/org/apache/commons/weaver/maven/TestWeaveMojo.java
Tue Apr 23 17:11:04 2013
@@ -23,7 +23,6 @@ import org.apache.maven.plugins.annotati
 import org.apache.maven.plugins.annotations.Parameter;
 import org.apache.maven.plugins.annotations.ResolutionScope;
 
-
 /**
  * Goal to weave test classes.
  */
@@ -36,7 +35,6 @@ public class TestWeaveMojo extends Abstr
     @Parameter(readonly = true, required = true, defaultValue = "${project.build.testOutputDirectory}")
     protected File target;
 
-
     @Override
     protected List<String> getClasspath() {
         return classpath;



Mime
View raw message