You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by sl...@apache.org on 2023/10/03 10:06:14 UTC

[maven-wagon] branch WAGON-634 created (now 916c1ea2)

This is an automated email from the ASF dual-hosted git repository.

slachiewicz pushed a change to branch WAGON-634
in repository https://gitbox.apache.org/repos/asf/maven-wagon.git


      at 916c1ea2 [WAGON-634] Apply formatting

This branch includes the following new commits:

     new 73d35208 [WAGON-634] Bump parent pom to 40
     new 916c1ea2 [WAGON-634] Apply formatting

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[maven-wagon] 01/02: [WAGON-634] Bump parent pom to 40

Posted by sl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

slachiewicz pushed a commit to branch WAGON-634
in repository https://gitbox.apache.org/repos/asf/maven-wagon.git

commit 73d352082f8d05ab539f99027dd2ce83725cefd2
Author: Sylwester Lachiewicz <sl...@gmail.com>
AuthorDate: Tue Oct 3 11:28:39 2023 +0200

    [WAGON-634] Bump parent pom to 40
---
 pom.xml                                         | 102 +++++++-----------------
 wagon-providers/pom.xml                         |   1 -
 wagon-providers/wagon-file/pom.xml              |   4 +-
 wagon-providers/wagon-ftp/pom.xml               |   4 +-
 wagon-providers/wagon-http-lightweight/pom.xml  |   4 +-
 wagon-providers/wagon-http-shared/pom.xml       |   6 +-
 wagon-providers/wagon-http/pom.xml              |  10 +--
 wagon-providers/wagon-scm/pom.xml               |   7 +-
 wagon-providers/wagon-ssh-external/pom.xml      |   4 +-
 wagon-providers/wagon-webdav-jackrabbit/pom.xml |  11 ++-
 10 files changed, 47 insertions(+), 106 deletions(-)

diff --git a/pom.xml b/pom.xml
index 94569858..8f7020d4 100644
--- a/pom.xml
+++ b/pom.xml
@@ -23,7 +23,7 @@ under the License.
   <parent>
     <groupId>org.apache.maven</groupId>
     <artifactId>maven-parent</artifactId>
-    <version>34</version>
+    <version>40</version>
   </parent>
 
   <groupId>org.apache.maven.wagon</groupId>
@@ -36,14 +36,6 @@ under the License.
   <url>https://maven.apache.org/wagon</url>
   <inceptionYear>2003</inceptionYear>
 
-  <properties>
-    <maven.test.redirectTestOutputToFile>true</maven.test.redirectTestOutputToFile>
-    <slf4jVersion>1.7.36</slf4jVersion>
-    <maven.site.path>wagon-archives/wagon-LATEST</maven.site.path>
-    <javaVersion>7</javaVersion>
-    <project.build.outputTimestamp>2022-12-18T21:06:44Z</project.build.outputTimestamp>
-  </properties>
-
   <contributors>
     <contributor>
       <name>James William Dumay</name>
@@ -162,9 +154,9 @@ under the License.
 
     <mailingList>
       <name>LEGACY Wagon User List (deprecated)</name>
-      <post>wagon-users@maven.apache.org</post>
       <subscribe>wagon-users-subscribe@maven.apache.org</subscribe>
       <unsubscribe>wagon-users-unsubscribe@maven.apache.org</unsubscribe>
+      <post>wagon-users@maven.apache.org</post>
       <archive>http://mail-archives.apache.org/mod_mbox/maven-wagon-users/</archive>
       <otherArchives>
         <otherArchive>http://www.mail-archive.com/wagon-users@maven.apache.org</otherArchive>
@@ -174,9 +166,9 @@ under the License.
     </mailingList>
     <mailingList>
       <name>LEGACY Wagon Developer List (deprecated)</name>
-      <post>wagon-dev@maven.apache.org</post>
       <subscribe>wagon-dev-subscribe@maven.apache.org</subscribe>
       <unsubscribe>wagon-dev-unsubscribe@maven.apache.org</unsubscribe>
+      <post>wagon-dev@maven.apache.org</post>
       <archive>http://mail-archives.apache.org/mod_mbox/maven-wagon-dev/</archive>
       <otherArchives>
         <otherArchive>http://www.mail-archive.com/wagon-dev@maven.apache.org</otherArchive>
@@ -195,11 +187,18 @@ under the License.
     </mailingList>
   </mailingLists>
 
+  <modules>
+    <module>wagon-provider-api</module>
+    <module>wagon-providers</module>
+    <module>wagon-provider-test</module>
+    <module>wagon-tcks</module>
+  </modules>
+
   <scm>
     <connection>scm:git:https://gitbox.apache.org/repos/asf/maven-wagon.git</connection>
     <developerConnection>scm:git:https://gitbox.apache.org/repos/asf/maven-wagon.git</developerConnection>
-    <url>https://github.com/apache/maven-wagon/tree/${project.scm.tag}</url>
     <tag>wagon-4.0.0-M1</tag>
+    <url>https://github.com/apache/maven-wagon/tree/${project.scm.tag}</url>
   </scm>
 
   <issueManagement>
@@ -218,12 +217,12 @@ under the License.
     </site>
   </distributionManagement>
 
-  <modules>
-    <module>wagon-provider-api</module>
-    <module>wagon-providers</module>
-    <module>wagon-provider-test</module>
-    <module>wagon-tcks</module>
-  </modules>
+  <properties>
+    <maven.test.redirectTestOutputToFile>true</maven.test.redirectTestOutputToFile>
+    <slf4jVersion>1.7.36</slf4jVersion>
+    <maven.site.path>wagon-archives/wagon-LATEST</maven.site.path>
+    <project.build.outputTimestamp>2022-12-18T21:06:44Z</project.build.outputTimestamp>
+  </properties>
 
   <dependencyManagement>
     <dependencies>
@@ -321,22 +320,16 @@ under the License.
         <groupId>javax.servlet</groupId>
         <artifactId>javax.servlet-api</artifactId>
         <version>3.1.0</version>
-    </dependency>
+      </dependency>
     </dependencies>
   </dependencyManagement>
 
   <build>
     <pluginManagement>
       <plugins>
-        <plugin><!-- TODO remove when parent POM upgraded to 35 -->
-          <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-shade-plugin</artifactId>
-          <version>3.2.3</version>
-        </plugin>
         <plugin>
           <groupId>org.apache.maven.plugins</groupId>
           <artifactId>maven-surefire-plugin</artifactId>
-          <version>2.22.2</version>
           <configuration>
             <forkedProcessTimeoutInSeconds>800</forkedProcessTimeoutInSeconds>
             <systemPropertyVariables>
@@ -357,13 +350,16 @@ under the License.
           <configuration>
             <excludes combine.children="append">
               <exclude>.checkstyle</exclude>
+              <exclude>.gitattributes</exclude>
               <exclude>**/*.odg</exclude>
               <exclude>src/test/resources/**</exclude>
               <exclude>src/main/resources/default-server-root/**</exclude>
               <exclude>src/main/resources/ssh-keys/**</exclude>
               <exclude>src/test/ssh-keys/**</exclude>
-              <exclude>.repository/**</exclude><!-- for CI -->
-              <exclude>out/**</exclude> <!-- for intellij -->
+              <!-- for CI -->
+              <exclude>.repository/**</exclude>
+              <!-- for intellij -->
+              <exclude>out/**</exclude>
             </excludes>
           </configuration>
         </plugin>
@@ -392,6 +388,11 @@ under the License.
             </lifecycleMappingMetadata>
           </configuration>
         </plugin>
+        <plugin>
+          <groupId>org.codehaus.plexus</groupId>
+          <artifactId>plexus-component-metadata</artifactId>
+          <version>2.1.1</version>
+        </plugin>
       </plugins>
     </pluginManagement>
     <plugins>
@@ -407,47 +408,6 @@ under the License.
           </execution>
         </executions>
       </plugin>
-
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>animal-sniffer-maven-plugin</artifactId>
-        <version>1.15</version>
-        <configuration>
-          <signature>
-            <groupId>org.codehaus.mojo.signature</groupId>
-            <artifactId>java17</artifactId>
-            <version>1.0</version>
-          </signature>
-        </configuration>
-        <executions>
-          <execution>
-            <id>check-java-1.7-compat</id>
-            <phase>process-classes</phase>
-            <goals>
-              <goal>check</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-enforcer-plugin</artifactId>
-        <version>3.0.0-M2</version>
-        <executions>
-          <execution>
-            <goals>
-              <goal>enforce</goal>
-            </goals>
-            <configuration>
-              <rules>
-                <requireJavaVersion>
-                  <version>1.7.0</version>
-                </requireJavaVersion>
-              </rules>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
     </plugins>
   </build>
 
@@ -525,10 +485,10 @@ under the License.
               </reportSet>
               <reportSet>
                 <id>aggregate</id>
-                <inherited>false</inherited>
                 <reports>
                   <report>aggregate</report>
                 </reports>
+                <inherited>false</inherited>
               </reportSet>
             </reportSets>
           </plugin>
@@ -545,10 +505,10 @@ under the License.
               </reportSet>
               <reportSet>
                 <id>aggregate</id>
-                <inherited>false</inherited>
                 <reports>
                   <report>aggregate</report>
                 </reports>
+                <inherited>false</inherited>
               </reportSet>
             </reportSets>
           </plugin>
@@ -564,10 +524,10 @@ under the License.
               </reportSet>
               <reportSet>
                 <id>aggregate</id>
-                <inherited>false</inherited>
                 <reports>
                   <report>checkstyle-aggregate</report>
                 </reports>
+                <inherited>false</inherited>
               </reportSet>
             </reportSets>
           </plugin>
diff --git a/wagon-providers/pom.xml b/wagon-providers/pom.xml
index 29a36ad5..638f43a5 100644
--- a/wagon-providers/pom.xml
+++ b/wagon-providers/pom.xml
@@ -73,7 +73,6 @@ under the License.
     </dependencies>
   </dependencyManagement>
 
-
   <dependencies>
     <dependency>
       <groupId>org.apache.maven.wagon</groupId>
diff --git a/wagon-providers/wagon-file/pom.xml b/wagon-providers/wagon-file/pom.xml
index 90759063..a076a89d 100644
--- a/wagon-providers/wagon-file/pom.xml
+++ b/wagon-providers/wagon-file/pom.xml
@@ -29,9 +29,7 @@ under the License.
 
   <artifactId>wagon-file</artifactId>
   <name>Apache Maven Wagon :: Providers :: File Provider</name>
-  <description>
-    Wagon provider that gets and puts artifacts using file system protocol
-  </description>
+  <description>Wagon provider that gets and puts artifacts using file system protocol</description>
 
   <dependencies>
     <dependency>
diff --git a/wagon-providers/wagon-ftp/pom.xml b/wagon-providers/wagon-ftp/pom.xml
index f4e54fdb..1b692ada 100644
--- a/wagon-providers/wagon-ftp/pom.xml
+++ b/wagon-providers/wagon-ftp/pom.xml
@@ -29,9 +29,7 @@ under the License.
 
   <artifactId>wagon-ftp</artifactId>
   <name>Apache Maven Wagon :: Providers :: FTP Provider</name>
-  <description>
-    Wagon provider that gets and puts artifacts from and to remote server using FTP protocol
-  </description>
+  <description>Wagon provider that gets and puts artifacts from and to remote server using FTP protocol</description>
 
   <dependencies>
     <dependency>
diff --git a/wagon-providers/wagon-http-lightweight/pom.xml b/wagon-providers/wagon-http-lightweight/pom.xml
index 88334f2e..bca99bbd 100644
--- a/wagon-providers/wagon-http-lightweight/pom.xml
+++ b/wagon-providers/wagon-http-lightweight/pom.xml
@@ -29,9 +29,7 @@ under the License.
 
   <artifactId>wagon-http-lightweight</artifactId>
   <name>Apache Maven Wagon :: Providers :: Lightweight HTTP Provider</name>
-  <description>
-    Wagon provider that gets and puts artifacts through http using standard Java library
-  </description>
+  <description>Wagon provider that gets and puts artifacts through http using standard Java library</description>
 
   <dependencies>
     <dependency>
diff --git a/wagon-providers/wagon-http-shared/pom.xml b/wagon-providers/wagon-http-shared/pom.xml
index aea071d9..7e86dcb4 100644
--- a/wagon-providers/wagon-http-shared/pom.xml
+++ b/wagon-providers/wagon-http-shared/pom.xml
@@ -29,9 +29,7 @@ under the License.
 
   <artifactId>wagon-http-shared</artifactId>
   <name>Apache Maven Wagon :: Providers :: HTTP Shared Library</name>
-  <description>
-    Shared Library for wagon providers supporting HTTP.
-  </description>
+  <description>Shared Library for wagon providers supporting HTTP.</description>
 
   <dependencies>
     <dependency>
@@ -39,8 +37,8 @@ under the License.
       <artifactId>httpclient</artifactId>
       <exclusions>
         <exclusion>
-          <artifactId>commons-logging</artifactId>
           <groupId>commons-logging</groupId>
+          <artifactId>commons-logging</artifactId>
         </exclusion>
       </exclusions>
     </dependency>
diff --git a/wagon-providers/wagon-http/pom.xml b/wagon-providers/wagon-http/pom.xml
index ba6462fb..ea7841fe 100644
--- a/wagon-providers/wagon-http/pom.xml
+++ b/wagon-providers/wagon-http/pom.xml
@@ -29,10 +29,7 @@ under the License.
 
   <artifactId>wagon-http</artifactId>
   <name>Apache Maven Wagon :: Providers :: HTTP Provider</name>
-  <description>
-    Wagon provider that gets and puts artifacts through HTTP(S) using Apache HttpClient-4.x.
-  </description>
-
+  <description>Wagon provider that gets and puts artifacts through HTTP(S) using Apache HttpClient-4.x.</description>
 
   <dependencies>
     <dependency>
@@ -45,8 +42,8 @@ under the License.
       <artifactId>httpclient</artifactId>
       <exclusions>
         <exclusion>
-          <artifactId>commons-logging</artifactId>
           <groupId>commons-logging</groupId>
+          <artifactId>commons-logging</artifactId>
         </exclusion>
       </exclusions>
     </dependency>
@@ -95,7 +92,6 @@ under the License.
 
   </dependencies>
 
-
   <build>
     <plugins>
       <plugin>
@@ -103,10 +99,10 @@ under the License.
         <artifactId>maven-shade-plugin</artifactId>
         <executions>
           <execution>
-            <phase>package</phase>
             <goals>
               <goal>shade</goal>
             </goals>
+            <phase>package</phase>
             <configuration>
               <shadedArtifactAttached>true</shadedArtifactAttached>
               <shadedClassifierName>shaded</shadedClassifierName>
diff --git a/wagon-providers/wagon-scm/pom.xml b/wagon-providers/wagon-scm/pom.xml
index 8645a744..b62be3a7 100644
--- a/wagon-providers/wagon-scm/pom.xml
+++ b/wagon-providers/wagon-scm/pom.xml
@@ -29,9 +29,7 @@ under the License.
 
   <artifactId>wagon-scm</artifactId>
   <name>Apache Maven Wagon :: Providers :: SCM Provider</name>
-  <description>
-    Wagon provider that gets and puts artifacts using a Source Control Management system
-  </description>
+  <description>Wagon provider that gets and puts artifacts using a Source Control Management system</description>
 
   <properties>
     <mavenScmVersion>1.11.1</mavenScmVersion>
@@ -88,8 +86,7 @@ under the License.
       <plugin>
         <artifactId>maven-surefire-plugin</artifactId>
         <configuration>
-          <excludes>
-          </excludes>
+          <excludes />
         </configuration>
       </plugin>
     </plugins>
diff --git a/wagon-providers/wagon-ssh-external/pom.xml b/wagon-providers/wagon-ssh-external/pom.xml
index 16eb7c16..c833bc1a 100644
--- a/wagon-providers/wagon-ssh-external/pom.xml
+++ b/wagon-providers/wagon-ssh-external/pom.xml
@@ -29,9 +29,7 @@ under the License.
 
   <artifactId>wagon-ssh-external</artifactId>
   <name>Apache Maven Wagon :: Providers :: SSH External Provider</name>
-  <description>
-    Wagon provider that gets and puts artifacts using SSH protocol with a preinstalled SSH client
-  </description>
+  <description>Wagon provider that gets and puts artifacts using SSH protocol with a preinstalled SSH client</description>
 
   <properties>
     <sshd.stopImmediatly>false</sshd.stopImmediatly>
diff --git a/wagon-providers/wagon-webdav-jackrabbit/pom.xml b/wagon-providers/wagon-webdav-jackrabbit/pom.xml
index 44410d91..5f8bdd56 100644
--- a/wagon-providers/wagon-webdav-jackrabbit/pom.xml
+++ b/wagon-providers/wagon-webdav-jackrabbit/pom.xml
@@ -29,9 +29,7 @@ under the License.
 
   <artifactId>wagon-webdav-jackrabbit</artifactId>
   <name>Apache Maven Wagon :: Providers :: WebDAV Provider</name>
-  <description>
-    Wagon provider that gets and puts artifacts through WebDAV protocol
-  </description>
+  <description>Wagon provider that gets and puts artifacts through WebDAV protocol</description>
 
   <contributors>
     <contributor>
@@ -57,8 +55,8 @@ under the License.
       <version>2.14.4</version>
       <exclusions>
         <exclusion>
-          <artifactId>commons-logging</artifactId>
           <groupId>commons-logging</groupId>
+          <artifactId>commons-logging</artifactId>
         </exclusion>
         <exclusion>
           <groupId>commons-httpclient</groupId>
@@ -75,7 +73,8 @@ under the License.
       <groupId>org.slf4j</groupId>
       <artifactId>slf4j-api</artifactId>
     </dependency>
-    <dependency> <!-- required for org.apache.httpcomponents:httpclient -->
+    <dependency>
+      <!-- required for org.apache.httpcomponents:httpclient -->
       <groupId>org.slf4j</groupId>
       <artifactId>jcl-over-slf4j</artifactId>
       <scope>runtime</scope>
@@ -86,8 +85,8 @@ under the License.
       <artifactId>httpclient</artifactId>
       <exclusions>
         <exclusion>
-          <artifactId>commons-logging</artifactId>
           <groupId>commons-logging</groupId>
+          <artifactId>commons-logging</artifactId>
         </exclusion>
       </exclusions>
     </dependency>


[maven-wagon] 02/02: [WAGON-634] Apply formatting

Posted by sl...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

slachiewicz pushed a commit to branch WAGON-634
in repository https://gitbox.apache.org/repos/asf/maven-wagon.git

commit 916c1ea28113911bb4c022b25008e729c2465b98
Author: Sylwester Lachiewicz <sl...@gmail.com>
AuthorDate: Tue Oct 3 12:05:58 2023 +0200

    [WAGON-634] Apply formatting
---
 .../java/org/apache/maven/wagon/AbstractWagon.java |  785 +++----
 .../maven/wagon/CommandExecutionException.java     |   18 +-
 .../org/apache/maven/wagon/CommandExecutor.java    |   13 +-
 .../apache/maven/wagon/ConnectionException.java    |   19 +-
 .../java/org/apache/maven/wagon/InputData.java     |   23 +-
 .../apache/maven/wagon/LazyFileOutputStream.java   |   91 +-
 .../java/org/apache/maven/wagon/OutputData.java    |   22 +-
 .../java/org/apache/maven/wagon/PathUtils.java     |  375 ++--
 .../apache/maven/wagon/PermissionModeUtils.java    |   42 +-
 .../maven/wagon/ResourceDoesNotExistException.java |   18 +-
 .../java/org/apache/maven/wagon/StreamWagon.java   |  269 +--
 .../org/apache/maven/wagon/StreamingWagon.java     |   37 +-
 .../main/java/org/apache/maven/wagon/Streams.java  |   20 +-
 .../maven/wagon/TransferFailedException.java       |   18 +-
 .../maven/wagon/UnsupportedProtocolException.java  |   20 +-
 .../main/java/org/apache/maven/wagon/Wagon.java    |   87 +-
 .../org/apache/maven/wagon/WagonConstants.java     |    6 +-
 .../org/apache/maven/wagon/WagonException.java     |   82 +-
 .../java/org/apache/maven/wagon/WagonUtils.java    |   87 +-
 .../authentication/AuthenticationException.java    |   18 +-
 .../wagon/authentication/AuthenticationInfo.java   |   31 +-
 .../authorization/AuthorizationException.java      |   20 +-
 .../apache/maven/wagon/events/SessionEvent.java    |   83 +-
 .../maven/wagon/events/SessionEventSupport.java    |   96 +-
 .../apache/maven/wagon/events/SessionListener.java |   27 +-
 .../apache/maven/wagon/events/TransferEvent.java   |  159 +-
 .../maven/wagon/events/TransferEventSupport.java   |   77 +-
 .../maven/wagon/events/TransferListener.java       |   20 +-
 .../org/apache/maven/wagon/events/WagonEvent.java  |   22 +-
 .../wagon/observers/AbstractTransferListener.java  |   31 +-
 .../maven/wagon/observers/ChecksumObserver.java    |   80 +-
 .../org/apache/maven/wagon/observers/Debug.java    |  119 +-
 .../org/apache/maven/wagon/proxy/ProxyInfo.java    |   64 +-
 .../maven/wagon/proxy/ProxyInfoProvider.java       |   10 +-
 .../org/apache/maven/wagon/proxy/ProxyUtils.java   |   34 +-
 .../apache/maven/wagon/repository/Repository.java  |  196 +-
 .../wagon/repository/RepositoryPermissions.java    |   25 +-
 .../org/apache/maven/wagon/resource/Resource.java  |   78 +-
 .../org/apache/maven/wagon/AbstractWagonTest.java  |  579 +++---
 .../maven/wagon/CannotConnectExceptionTest.java    |   20 +-
 .../org/apache/maven/wagon/InputStreamMock.java    |   30 +-
 .../maven/wagon/LazyFileOutputStreamTest.java      |   33 +-
 .../maven/wagon/NotAuthorizedExceptionTest.java    |   20 +-
 .../org/apache/maven/wagon/OutputStreamMock.java   |   31 +-
 .../java/org/apache/maven/wagon/PathUtilsTest.java |  524 ++---
 .../maven/wagon/PermissionModeUtilsTest.java       |   26 +-
 .../wagon/ResourceDoesNotExistExceptionTest.java   |   20 +-
 .../org/apache/maven/wagon/StreamWagonTest.java    |  573 ++----
 .../maven/wagon/TransferFailedExceptionTest.java   |   20 +-
 .../java/org/apache/maven/wagon/WagonMock.java     |   81 +-
 .../AuthenticationExceptionTest.java               |   35 +-
 .../authentication/AuthenticationInfoTest.java     |   39 +-
 .../wagon/events/SessionEventSupportTest.java      |  228 +--
 .../maven/wagon/events/SessionEventTest.java       |  126 +-
 .../wagon/events/TransferEventSupportTest.java     |  170 +-
 .../maven/wagon/events/TransferEventTest.java      |  133 +-
 .../wagon/observers/ChecksumObserverTest.java      |   77 +-
 .../apache/maven/wagon/proxy/ProxyInfoTest.java    |   43 +-
 .../maven/wagon/proxy/ProxyInfoUtilsTest.java      |   75 +-
 .../repository/RepositoryPermissionsTest.java      |   36 +-
 .../maven/wagon/repository/RepositoryTest.java     |  271 ++-
 .../maven/wagon/CommandExecutorTestCase.java       |   80 +-
 .../java/org/apache/maven/wagon/FileTestUtils.java |   76 +-
 .../apache/maven/wagon/StreamingWagonTestCase.java |  249 +--
 .../java/org/apache/maven/wagon/WagonTestCase.java |  834 +++-----
 .../apache/maven/wagon/http/HttpWagonTestCase.java | 2158 ++++++++------------
 .../maven/wagon/providers/file/FileWagon.java      |  197 +-
 .../maven/wagon/providers/file/FileWagonTest.java  |   52 +-
 .../maven/wagon/providers/ftp/FtpHttpWagon.java    |   21 +-
 .../apache/maven/wagon/providers/ftp/FtpWagon.java |  685 +++----
 .../maven/wagon/providers/ftp/FtpsWagon.java       |   23 +-
 .../maven/wagon/providers/ftp/FtpWagonTest.java    |  134 +-
 .../wagon/providers/http/LightweightHttpWagon.java |  433 ++--
 .../http/LightweightHttpWagonAuthenticator.java    |   30 +-
 .../providers/http/LightweightHttpsWagon.java      |   59 +-
 .../providers/http/LightweightHttpWagonTest.java   |  158 +-
 ...tHttpWagonWithPreemptiveAuthenticationTest.java |   19 +-
 .../providers/http/LightweightHttpsWagonTest.java  |   35 +-
 .../apache/maven/wagon/providers/http/TckTest.java |   10 +-
 .../wagon/shared/http/AbstractHttpClientWagon.java | 1061 +++++-----
 .../maven/wagon/shared/http/BasicAuthScope.java    |   79 +-
 .../wagon/shared/http/ConfigurationUtils.java      |  252 +--
 .../maven/wagon/shared/http/EncodingUtil.java      |   62 +-
 .../maven/wagon/shared/http/HttpConfiguration.java |   63 +-
 .../maven/wagon/shared/http/HttpMessageUtils.java  |   84 +-
 .../wagon/shared/http/HttpMethodConfiguration.java |   96 +-
 .../wagon/shared/http/RelaxedTrustStrategy.java    |   46 +-
 .../StandardServiceUnavailableRetryStrategy.java   |   22 +-
 .../wagon/shared/http/WagonRedirectStrategy.java   |  105 +-
 .../maven/wagon/shared/http/EncodingUtilTest.java  |  115 +-
 .../maven/wagon/providers/http/HttpWagon.java      |    9 +-
 .../http/AbstractHttpClientWagonTest.java          |  264 +--
 .../wagon/providers/http/BasicAuthScopeTest.java   |   71 +-
 .../providers/http/ErrorWithMessageServlet.java    |   57 +-
 .../wagon/providers/http/HttpClientWagonTest.java  |   67 +-
 .../wagon/providers/http/HttpWagonErrorTest.java   |  184 +-
 .../http/HttpWagonHttpServerTestCase.java          |   39 +-
 .../providers/http/HttpWagonPreemptiveTest.java    |   22 +-
 .../maven/wagon/providers/http/HttpWagonTest.java  |   33 +-
 .../wagon/providers/http/HttpWagonTimeoutTest.java |  138 +-
 .../providers/http/HttpsWagonPreemptiveTest.java   |   50 +-
 .../maven/wagon/providers/http/HttpsWagonTest.java |   35 +-
 .../wagon/providers/http/HugeFileDownloadTest.java |  190 +-
 .../apache/maven/wagon/providers/http/TckTest.java |   10 +-
 .../wagon/providers/http/WaitForeverServlet.java   |   27 +-
 .../apache/maven/wagon/providers/scm/ScmWagon.java |  613 +++---
 .../providers/scm/AbstractScmCvsWagonTest.java     |   29 +-
 .../providers/scm/AbstractScmGitWagonTest.java     |   28 +-
 .../providers/scm/AbstractScmSvnWagonTest.java     |   28 +-
 .../wagon/providers/scm/AbstractScmWagonTest.java  |   81 +-
 .../wagon/providers/scm/ScmCvsExeWagonTest.java    |   40 +-
 .../wagon/providers/scm/ScmGitExeWagonTest.java    |   29 +-
 .../wagon/providers/scm/ScmSvnExeWagonTest.java    |   13 +-
 .../providers/scm/UserSafeGitExeScmProvider.java   |   13 +-
 .../ssh/AbstractEmbeddedScpWagonTest.java          |   59 +-
 .../ssh/AbstractEmbeddedScpWagonWithKeyTest.java   |  138 +-
 .../maven/wagon/providers/ssh/ScpCommand.java      |  540 ++---
 .../wagon/providers/ssh/ScpCommandFactory.java     |   73 +-
 .../maven/wagon/providers/ssh/ShellCommand.java    |  205 +-
 .../wagon/providers/ssh/SshServerEmbedded.java     |  155 +-
 .../apache/maven/wagon/providers/ssh/TestData.java |   58 +-
 .../providers/ssh/TestPasswordAuthenticator.java   |   50 +-
 .../providers/ssh/TestPublickeyAuthenticator.java  |  142 +-
 .../ssh/knownhost/KnownHostsProviderTestCase.java  |   78 +-
 .../ssh/CommandExecutorStreamProcessor.java        |   67 +-
 .../apache/maven/wagon/providers/ssh/LSParser.java |   53 +-
 .../maven/wagon/providers/ssh/ScpHelper.java       |  309 ++-
 .../apache/maven/wagon/providers/ssh/SshWagon.java |   11 +-
 .../interactive/ConsoleInteractiveUserInfo.java    |   63 +-
 .../ssh/interactive/InteractiveUserInfo.java       |   14 +-
 .../ssh/interactive/NullInteractiveUserInfo.java   |   27 +-
 .../ssh/knownhost/AbstractKnownHostsProvider.java  |   28 +-
 .../ssh/knownhost/FileKnownHostsProvider.java      |   44 +-
 .../ssh/knownhost/KnownHostChangedException.java   |   12 +-
 .../providers/ssh/knownhost/KnownHostEntry.java    |   85 +-
 .../ssh/knownhost/KnownHostsProvider.java          |   14 +-
 .../ssh/knownhost/NullKnownHostProvider.java       |   10 +-
 .../ssh/knownhost/SingleKnownHostProvider.java     |   18 +-
 .../ssh/knownhost/StreamKnownHostsProvider.java    |   60 +-
 .../ssh/knownhost/UnknownHostException.java        |   12 +-
 .../maven/wagon/providers/ssh/LSParserTest.java    |  138 +-
 .../ssh/knownhost/FileKnownHostsProviderTest.java  |   67 +-
 .../ssh/external/ScpExternalCommandExecutor.java   |   19 +-
 .../providers/ssh/external/ScpExternalWagon.java   |  414 ++--
 .../EmbeddedScpExternalWagonWithKeyTest.java       |   81 +-
 .../ssh/external/ScpExternalWagonTest.java         |   84 +-
 .../ScpWagonWithSshPrivateKeySearchTest.java       |   32 +-
 .../ssh/external/SshCommandExecutorTest.java       |   12 +-
 .../providers/ssh/jsch/AbstractJschWagon.java      |  433 ++--
 .../providers/ssh/jsch/ScpCommandExecutor.java     |   18 +-
 .../maven/wagon/providers/ssh/jsch/ScpWagon.java   |  372 ++--
 .../maven/wagon/providers/ssh/jsch/SftpWagon.java  |  559 ++---
 .../wagon/providers/ssh/jsch/WagonUserInfo.java    |   47 +-
 .../interactive/PrompterUIKeyboardInteractive.java |   51 +-
 .../UserInfoUIKeyboardInteractiveProxy.java        |   47 +-
 .../providers/ssh/jsch/EmbeddedScpWagonTest.java   |   69 +-
 .../ssh/jsch/EmbeddedScpWagonWithKeyTest.java      |   62 +-
 .../providers/ssh/jsch/KnownHostsProviderTest.java |    9 +-
 .../wagon/providers/ssh/jsch/ScpWagonTest.java     |   34 +-
 .../providers/ssh/jsch/ScpWagonWithProxyTest.java  |  175 +-
 .../jsch/ScpWagonWithSshPrivateKeySearchTest.java  |   69 +-
 .../wagon/providers/ssh/jsch/SftpWagonTest.java    |   27 +-
 .../providers/ssh/jsch/SshCommandExecutorTest.java |   12 +-
 .../org/apache/jackrabbit/webdav/MultiStatus.java  |  101 +-
 .../webdav/client/methods/XmlRequestEntity.java    |   77 +-
 .../wagon/providers/webdav/PathNavigator.java      |   41 +-
 .../maven/wagon/providers/webdav/WebDavWagon.java  |  288 +--
 .../providers/webdav/HttpClientWagonTest.java      |  178 +-
 .../wagon/providers/webdav/PathNavigatorTest.java  |   49 +-
 .../webdav/WebDavWagonPreemptiveTest.java          |   22 +-
 .../wagon/providers/webdav/WebDavWagonTest.java    |  485 ++---
 .../webdav/WebDavsWagonPreemptiveTest.java         |   47 +-
 .../wagon/providers/webdav/WebDavsWagonTest.java   |   33 +-
 .../apache/maven/wagon/tck/http/Assertions.java    |  185 +-
 .../apache/maven/wagon/tck/http/GetWagonTests.java |  495 ++---
 .../maven/wagon/tck/http/HttpWagonTests.java       |  229 +--
 .../maven/wagon/tck/http/HttpsGetWagonTests.java   |   13 +-
 .../wagon/tck/http/WagonTestCaseConfigurator.java  |   95 +-
 .../wagon/tck/http/fixture/AuthSnoopFilter.java    |   47 +-
 .../wagon/tck/http/fixture/ErrorCodeServlet.java   |   24 +-
 .../wagon/tck/http/fixture/LatencyServlet.java     |   85 +-
 .../http/fixture/ProxyAuthenticationFilter.java    |   57 +-
 .../fixture/ProxyConnectionVerifierFilter.java     |   54 +-
 .../wagon/tck/http/fixture/RedirectionServlet.java |   56 +-
 .../wagon/tck/http/fixture/ServerFixture.java      |  146 +-
 .../tck/http/fixture/ServletExceptionServlet.java  |   24 +-
 .../apache/maven/wagon/tck/http/util/TestUtil.java |  113 +-
 .../maven/wagon/tck/http/util/ValueHolder.java     |   23 +-
 188 files changed, 9683 insertions(+), 14160 deletions(-)

diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/AbstractWagon.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/AbstractWagon.java
index 25e4a368..10a5acaa 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/AbstractWagon.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/AbstractWagon.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,19 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.nio.Buffer;
+import java.nio.ByteBuffer;
+import java.nio.channels.Channels;
+import java.nio.channels.ReadableByteChannel;
+import java.util.List;
 
 import org.apache.maven.wagon.authentication.AuthenticationException;
 import org.apache.maven.wagon.authentication.AuthenticationInfo;
@@ -36,18 +47,6 @@ import org.apache.maven.wagon.repository.RepositoryPermissions;
 import org.apache.maven.wagon.resource.Resource;
 import org.codehaus.plexus.util.IOUtil;
 
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.nio.Buffer;
-import java.nio.ByteBuffer;
-import java.nio.channels.Channels;
-import java.nio.channels.ReadableByteChannel;
-import java.util.List;
-
 import static java.lang.Math.max;
 import static java.lang.Math.min;
 
@@ -56,9 +55,7 @@ import static java.lang.Math.min;
  *
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  */
-public abstract class AbstractWagon
-    implements Wagon
-{
+public abstract class AbstractWagon implements Wagon {
     protected static final int DEFAULT_BUFFER_SIZE = 4 * 1024;
     protected static final int MAXIMUM_BUFFER_SIZE = 512 * 1024;
 
@@ -88,7 +85,6 @@ public abstract class AbstractWagon
 
     protected boolean interactive = true;
 
-
     private int connectionTimeout = DEFAULT_CONNECTION_TIMEOUT;
 
     /**
@@ -97,7 +93,7 @@ public abstract class AbstractWagon
      * @since 2.2
      */
     private int readTimeout =
-        Integer.parseInt( System.getProperty( "maven.wagon.rto", Integer.toString( Wagon.DEFAULT_READ_TIMEOUT ) ) );
+            Integer.parseInt(System.getProperty("maven.wagon.rto", Integer.toString(Wagon.DEFAULT_READ_TIMEOUT)));
 
     private ProxyInfoProvider proxyInfoProvider;
 
@@ -112,18 +108,15 @@ public abstract class AbstractWagon
     // Accessors
     // ----------------------------------------------------------------------
 
-    public Repository getRepository()
-    {
+    public Repository getRepository() {
         return repository;
     }
 
-    public ProxyInfo getProxyInfo()
-    {
-        return proxyInfoProvider != null ? proxyInfoProvider.getProxyInfo( null ) : null;
+    public ProxyInfo getProxyInfo() {
+        return proxyInfoProvider != null ? proxyInfoProvider.getProxyInfo(null) : null;
     }
 
-    public AuthenticationInfo getAuthenticationInfo()
-    {
+    public AuthenticationInfo getAuthenticationInfo() {
         return authenticationInfo;
     }
 
@@ -131,101 +124,76 @@ public abstract class AbstractWagon
     // Connection
     // ----------------------------------------------------------------------
 
-    public void openConnection()
-        throws ConnectionException, AuthenticationException
-    {
-        try
-        {
+    public void openConnection() throws ConnectionException, AuthenticationException {
+        try {
             openConnectionInternal();
-        }
-        catch ( ConnectionException e )
-        {
+        } catch (ConnectionException e) {
             fireSessionConnectionRefused();
 
             throw e;
-        }
-        catch ( AuthenticationException e )
-        {
+        } catch (AuthenticationException e) {
             fireSessionConnectionRefused();
 
             throw e;
         }
     }
 
-    public void connect( Repository repository )
-        throws ConnectionException, AuthenticationException
-    {
-        connect( repository, null, (ProxyInfoProvider) null );
+    public void connect(Repository repository) throws ConnectionException, AuthenticationException {
+        connect(repository, null, (ProxyInfoProvider) null);
     }
 
-    public void connect( Repository repository, ProxyInfo proxyInfo )
-        throws ConnectionException, AuthenticationException
-    {
-        connect( repository, null, proxyInfo );
+    public void connect(Repository repository, ProxyInfo proxyInfo)
+            throws ConnectionException, AuthenticationException {
+        connect(repository, null, proxyInfo);
     }
 
-    public void connect( Repository repository, ProxyInfoProvider proxyInfoProvider )
-        throws ConnectionException, AuthenticationException
-    {
-        connect( repository, null, proxyInfoProvider );
+    public void connect(Repository repository, ProxyInfoProvider proxyInfoProvider)
+            throws ConnectionException, AuthenticationException {
+        connect(repository, null, proxyInfoProvider);
     }
 
-    public void connect( Repository repository, AuthenticationInfo authenticationInfo )
-        throws ConnectionException, AuthenticationException
-    {
-        connect( repository, authenticationInfo, (ProxyInfoProvider) null );
+    public void connect(Repository repository, AuthenticationInfo authenticationInfo)
+            throws ConnectionException, AuthenticationException {
+        connect(repository, authenticationInfo, (ProxyInfoProvider) null);
     }
 
-    public void connect( Repository repository, AuthenticationInfo authenticationInfo, ProxyInfo proxyInfo )
-        throws ConnectionException, AuthenticationException
-    {
+    public void connect(Repository repository, AuthenticationInfo authenticationInfo, ProxyInfo proxyInfo)
+            throws ConnectionException, AuthenticationException {
         final ProxyInfo proxy = proxyInfo;
-        connect( repository, authenticationInfo, new ProxyInfoProvider()
-        {
-            public ProxyInfo getProxyInfo( String protocol )
-            {
-                if ( protocol == null || proxy == null || protocol.equalsIgnoreCase( proxy.getType() ) )
-                {
+        connect(repository, authenticationInfo, new ProxyInfoProvider() {
+            public ProxyInfo getProxyInfo(String protocol) {
+                if (protocol == null || proxy == null || protocol.equalsIgnoreCase(proxy.getType())) {
                     return proxy;
-                }
-                else
-                {
+                } else {
                     return null;
                 }
             }
-        } );
+        });
     }
 
-    public void connect( Repository repository, AuthenticationInfo authenticationInfo,
-                         ProxyInfoProvider proxyInfoProvider )
-        throws ConnectionException, AuthenticationException
-    {
-        if ( repository == null )
-        {
-            throw new NullPointerException( "repository cannot be null" );
+    public void connect(
+            Repository repository, AuthenticationInfo authenticationInfo, ProxyInfoProvider proxyInfoProvider)
+            throws ConnectionException, AuthenticationException {
+        if (repository == null) {
+            throw new NullPointerException("repository cannot be null");
         }
 
-        if ( permissionsOverride != null )
-        {
-            repository.setPermissions( permissionsOverride );
+        if (permissionsOverride != null) {
+            repository.setPermissions(permissionsOverride);
         }
 
         this.repository = repository;
 
-        if ( authenticationInfo == null )
-        {
+        if (authenticationInfo == null) {
             authenticationInfo = new AuthenticationInfo();
         }
 
-        if ( authenticationInfo.getUserName() == null )
-        {
+        if (authenticationInfo.getUserName() == null) {
             // Get user/pass that were encoded in the URL.
-            if ( repository.getUsername() != null )
-            {
-                authenticationInfo.setUserName( repository.getUsername() );
-                if ( repository.getPassword() != null && authenticationInfo.getPassword() == null )
-                {
-                    authenticationInfo.setPassword( repository.getPassword() );
+            if (repository.getUsername() != null) {
+                authenticationInfo.setUserName(repository.getUsername());
+                if (repository.getPassword() != null && authenticationInfo.getPassword() == null) {
+                    authenticationInfo.setPassword(repository.getPassword());
                 }
             }
         }
@@ -241,60 +209,44 @@ public abstract class AbstractWagon
         fireSessionOpened();
     }
 
-    protected abstract void openConnectionInternal()
-        throws ConnectionException, AuthenticationException;
+    protected abstract void openConnectionInternal() throws ConnectionException, AuthenticationException;
 
-    public void disconnect()
-        throws ConnectionException
-    {
+    public void disconnect() throws ConnectionException {
         fireSessionDisconnecting();
 
-        try
-        {
+        try {
             closeConnection();
-        }
-        catch ( ConnectionException e )
-        {
-            fireSessionError( e );
+        } catch (ConnectionException e) {
+            fireSessionError(e);
             throw e;
         }
 
         fireSessionDisconnected();
     }
 
-    protected abstract void closeConnection()
-        throws ConnectionException;
+    protected abstract void closeConnection() throws ConnectionException;
 
-    protected void createParentDirectories( File destination )
-        throws TransferFailedException
-    {
+    protected void createParentDirectories(File destination) throws TransferFailedException {
         File destinationDirectory = destination.getParentFile();
-        try
-        {
+        try {
             destinationDirectory = destinationDirectory.getCanonicalFile();
-        }
-        catch ( IOException e )
-        {
+        } catch (IOException e) {
             // not essential to have a canonical file
         }
-        if ( destinationDirectory != null && !destinationDirectory.exists() )
-        {
+        if (destinationDirectory != null && !destinationDirectory.exists()) {
             destinationDirectory.mkdirs();
-            if ( !destinationDirectory.exists() )
-            {
+            if (!destinationDirectory.exists()) {
                 throw new TransferFailedException(
-                    "Specified destination directory cannot be created: " + destinationDirectory );
+                        "Specified destination directory cannot be created: " + destinationDirectory);
             }
         }
     }
 
-    public void setTimeout( int timeoutValue )
-    {
+    public void setTimeout(int timeoutValue) {
         connectionTimeout = timeoutValue;
     }
 
-    public int getTimeout()
-    {
+    public int getTimeout() {
         return connectionTimeout;
     }
 
@@ -302,144 +254,112 @@ public abstract class AbstractWagon
     // Stream i/o
     // ----------------------------------------------------------------------
 
-    protected void getTransfer( Resource resource, File destination, InputStream input )
-        throws TransferFailedException
-    {
-        getTransfer( resource, destination, input, true, Long.MAX_VALUE );
+    protected void getTransfer(Resource resource, File destination, InputStream input) throws TransferFailedException {
+        getTransfer(resource, destination, input, true, Long.MAX_VALUE);
     }
 
-    protected void getTransfer( Resource resource, OutputStream output, InputStream input )
-        throws TransferFailedException
-    {
-        getTransfer( resource, output, input, true, Long.MAX_VALUE );
+    protected void getTransfer(Resource resource, OutputStream output, InputStream input)
+            throws TransferFailedException {
+        getTransfer(resource, output, input, true, Long.MAX_VALUE);
     }
 
     @Deprecated
-    protected void getTransfer( Resource resource, File destination, InputStream input, boolean closeInput,
-                                int maxSize )
-        throws TransferFailedException
-    {
-        getTransfer( resource, destination, input, closeInput, (long) maxSize );
+    protected void getTransfer(Resource resource, File destination, InputStream input, boolean closeInput, int maxSize)
+            throws TransferFailedException {
+        getTransfer(resource, destination, input, closeInput, (long) maxSize);
     }
 
-    protected void getTransfer( Resource resource, File destination, InputStream input, boolean closeInput,
-                                long maxSize )
-        throws TransferFailedException
-    {
+    protected void getTransfer(Resource resource, File destination, InputStream input, boolean closeInput, long maxSize)
+            throws TransferFailedException {
         // ensure that the destination is created only when we are ready to transfer
-        fireTransferDebug( "attempting to create parent directories for destination: " + destination.getName() );
-        createParentDirectories( destination );
+        fireTransferDebug("attempting to create parent directories for destination: " + destination.getName());
+        createParentDirectories(destination);
 
-        fireGetStarted( resource, destination );
+        fireGetStarted(resource, destination);
 
         OutputStream output = null;
-        try
-        {
-            output = new LazyFileOutputStream( destination );
-            getTransfer( resource, output, input, closeInput, maxSize );
+        try {
+            output = new LazyFileOutputStream(destination);
+            getTransfer(resource, output, input, closeInput, maxSize);
             output.close();
             output = null;
-        }
-        catch ( final IOException e )
-        {
-            if ( destination.exists() )
-            {
+        } catch (final IOException e) {
+            if (destination.exists()) {
                 boolean deleted = destination.delete();
 
-                if ( !deleted )
-                {
+                if (!deleted) {
                     destination.deleteOnExit();
                 }
             }
 
-            fireTransferError( resource, e, TransferEvent.REQUEST_GET );
+            fireTransferError(resource, e, TransferEvent.REQUEST_GET);
 
             String msg = "GET request of: " + resource.getName() + " from " + repository.getName() + " failed";
 
-            throw new TransferFailedException( msg, e );
-        }
-        catch ( TransferFailedException e )
-        {
-            if ( destination.exists() )
-            {
+            throw new TransferFailedException(msg, e);
+        } catch (TransferFailedException e) {
+            if (destination.exists()) {
                 boolean deleted = destination.delete();
 
-                if ( !deleted )
-                {
+                if (!deleted) {
                     destination.deleteOnExit();
                 }
             }
             throw e;
-        }
-        finally
-        {
-            IOUtil.close( output );
+        } finally {
+            IOUtil.close(output);
         }
 
-        fireGetCompleted( resource, destination );
+        fireGetCompleted(resource, destination);
     }
 
     @Deprecated
-    protected void getTransfer( Resource resource, OutputStream output, InputStream input, boolean closeInput,
-                                int maxSize )
-        throws TransferFailedException
-    {
-        getTransfer( resource, output, input, closeInput, (long) maxSize );
+    protected void getTransfer(
+            Resource resource, OutputStream output, InputStream input, boolean closeInput, int maxSize)
+            throws TransferFailedException {
+        getTransfer(resource, output, input, closeInput, (long) maxSize);
     }
 
-    protected void getTransfer( Resource resource, OutputStream output, InputStream input, boolean closeInput,
-                                long maxSize )
-        throws TransferFailedException
-    {
-        try
-        {
-            transfer( resource, input, output, TransferEvent.REQUEST_GET, maxSize );
+    protected void getTransfer(
+            Resource resource, OutputStream output, InputStream input, boolean closeInput, long maxSize)
+            throws TransferFailedException {
+        try {
+            transfer(resource, input, output, TransferEvent.REQUEST_GET, maxSize);
 
-            finishGetTransfer( resource, input, output );
+            finishGetTransfer(resource, input, output);
 
-            if ( closeInput )
-            {
+            if (closeInput) {
                 input.close();
                 input = null;
             }
 
-        }
-        catch ( IOException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_GET );
+        } catch (IOException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_GET);
 
             String msg = "GET request of: " + resource.getName() + " from " + repository.getName() + " failed";
 
-            throw new TransferFailedException( msg, e );
-        }
-        finally
-        {
-            if ( closeInput )
-            {
-                IOUtil.close( input );
+            throw new TransferFailedException(msg, e);
+        } finally {
+            if (closeInput) {
+                IOUtil.close(input);
             }
 
-            cleanupGetTransfer( resource );
+            cleanupGetTransfer(resource);
         }
     }
 
-    protected void finishGetTransfer( Resource resource, InputStream input, OutputStream output )
-        throws TransferFailedException
-    {
-    }
+    protected void finishGetTransfer(Resource resource, InputStream input, OutputStream output)
+            throws TransferFailedException {}
 
-    protected void cleanupGetTransfer( Resource resource )
-    {
-    }
+    protected void cleanupGetTransfer(Resource resource) {}
 
-    protected void putTransfer( Resource resource, File source, OutputStream output, boolean closeOutput )
-        throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException
-    {
-        firePutStarted( resource, source );
+    protected void putTransfer(Resource resource, File source, OutputStream output, boolean closeOutput)
+            throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException {
+        firePutStarted(resource, source);
 
-        transfer( resource, source, output, closeOutput );
+        transfer(resource, source, output, closeOutput);
 
-        firePutCompleted( resource, source );
+        firePutCompleted(resource, source);
     }
 
     /**
@@ -454,83 +374,67 @@ public abstract class AbstractWagon
      * @throws AuthorizationException
      * @since 1.0-beta-1
      */
-    protected void transfer( Resource resource, File source, OutputStream output, boolean closeOutput )
-        throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException
-    {
+    protected void transfer(Resource resource, File source, OutputStream output, boolean closeOutput)
+            throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException {
         InputStream input = null;
 
-        try
-        {
-            input = new FileInputStream( source );
+        try {
+            input = new FileInputStream(source);
 
-            putTransfer( resource, input, output, closeOutput );
+            putTransfer(resource, input, output, closeOutput);
 
             input.close();
             input = null;
-        }
-        catch ( FileNotFoundException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_PUT );
+        } catch (FileNotFoundException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_PUT);
 
-            throw new TransferFailedException( "Specified source file does not exist: " + source, e );
-        }
-        catch ( final IOException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_PUT );
+            throw new TransferFailedException("Specified source file does not exist: " + source, e);
+        } catch (final IOException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_PUT);
 
-            throw new TransferFailedException( "Failure transferring " + source, e );
-        }
-        finally
-        {
-            IOUtil.close( input );
+            throw new TransferFailedException("Failure transferring " + source, e);
+        } finally {
+            IOUtil.close(input);
         }
     }
 
-    protected void putTransfer( Resource resource, InputStream input, OutputStream output, boolean closeOutput )
-        throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException
-    {
-        try
-        {
-            transfer( resource, input, output, TransferEvent.REQUEST_PUT,
-                      resource.getContentLength() == WagonConstants.UNKNOWN_LENGTH
-                          ? Long.MAX_VALUE
-                          : resource.getContentLength() );
+    protected void putTransfer(Resource resource, InputStream input, OutputStream output, boolean closeOutput)
+            throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException {
+        try {
+            transfer(
+                    resource,
+                    input,
+                    output,
+                    TransferEvent.REQUEST_PUT,
+                    resource.getContentLength() == WagonConstants.UNKNOWN_LENGTH
+                            ? Long.MAX_VALUE
+                            : resource.getContentLength());
 
-            finishPutTransfer( resource, input, output );
+            finishPutTransfer(resource, input, output);
 
-            if ( closeOutput )
-            {
+            if (closeOutput) {
                 output.close();
                 output = null;
             }
-        }
-        catch ( IOException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_PUT );
+        } catch (IOException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_PUT);
 
             String msg = "PUT request to: " + resource.getName() + " in " + repository.getName() + " failed";
 
-            throw new TransferFailedException( msg, e );
-        }
-        finally
-        {
-            if ( closeOutput )
-            {
-                IOUtil.close( output );
+            throw new TransferFailedException(msg, e);
+        } finally {
+            if (closeOutput) {
+                IOUtil.close(output);
             }
 
-            cleanupPutTransfer( resource );
+            cleanupPutTransfer(resource);
         }
     }
 
-    protected void cleanupPutTransfer( Resource resource )
-    {
-    }
+    protected void cleanupPutTransfer(Resource resource) {}
 
-    protected void finishPutTransfer( Resource resource, InputStream input, OutputStream output )
-        throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException
-    {
-    }
+    protected void finishPutTransfer(Resource resource, InputStream input, OutputStream output)
+            throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException {}
 
     /**
      * Write from {@link InputStream} to {@link OutputStream}.
@@ -543,10 +447,9 @@ public abstract class AbstractWagon
      * @param requestType one of {@link TransferEvent#REQUEST_GET} or {@link TransferEvent#REQUEST_PUT}
      * @throws IOException
      */
-    protected void transfer( Resource resource, InputStream input, OutputStream output, int requestType )
-        throws IOException
-    {
-        transfer( resource, input, output, requestType, Long.MAX_VALUE );
+    protected void transfer(Resource resource, InputStream input, OutputStream output, int requestType)
+            throws IOException {
+        transfer(resource, input, output, requestType, Long.MAX_VALUE);
     }
 
     /**
@@ -563,10 +466,9 @@ public abstract class AbstractWagon
      * @deprecated Please use the transfer using long as type of maxSize
      */
     @Deprecated
-    protected void transfer( Resource resource, InputStream input, OutputStream output, int requestType, int maxSize )
-        throws IOException
-    {
-        transfer( resource, input, output, requestType, (long) maxSize );
+    protected void transfer(Resource resource, InputStream input, OutputStream output, int requestType, int maxSize)
+            throws IOException {
+        transfer(resource, input, output, requestType, (long) maxSize);
     }
 
     /**
@@ -581,31 +483,27 @@ public abstract class AbstractWagon
      * @param maxSize     size of the buffer
      * @throws IOException
      */
-    protected void transfer( Resource resource, InputStream input, OutputStream output, int requestType, long maxSize )
-        throws IOException
-    {
-        ByteBuffer buffer = ByteBuffer.allocate( getBufferCapacityForTransfer( resource.getContentLength() ) );
+    protected void transfer(Resource resource, InputStream input, OutputStream output, int requestType, long maxSize)
+            throws IOException {
+        ByteBuffer buffer = ByteBuffer.allocate(getBufferCapacityForTransfer(resource.getContentLength()));
         int halfBufferCapacity = buffer.capacity() / 2;
 
-        TransferEvent transferEvent = new TransferEvent( this, resource, TransferEvent.TRANSFER_PROGRESS, requestType );
-        transferEvent.setTimestamp( System.currentTimeMillis() );
+        TransferEvent transferEvent = new TransferEvent(this, resource, TransferEvent.TRANSFER_PROGRESS, requestType);
+        transferEvent.setTimestamp(System.currentTimeMillis());
 
-        ReadableByteChannel in = Channels.newChannel( input );
+        ReadableByteChannel in = Channels.newChannel(input);
 
         long remaining = maxSize;
-        while ( remaining > 0L )
-        {
-            int read = in.read( buffer );
+        while (remaining > 0L) {
+            int read = in.read(buffer);
 
-            if ( read == -1 )
-            {
+            if (read == -1) {
                 // EOF, but some data has not been written yet.
-                if ( ( (Buffer) buffer ).position() != 0 )
-                {
-                    ( (Buffer) buffer ).flip();
-                    fireTransferProgress( transferEvent, buffer.array(), ( (Buffer) buffer ).limit() );
-                    output.write( buffer.array(), 0, ( (Buffer) buffer ).limit() );
-                    ( (Buffer) buffer ).clear();
+                if (((Buffer) buffer).position() != 0) {
+                    ((Buffer) buffer).flip();
+                    fireTransferProgress(transferEvent, buffer.array(), ((Buffer) buffer).limit());
+                    output.write(buffer.array(), 0, ((Buffer) buffer).limit());
+                    ((Buffer) buffer).clear();
                 }
 
                 break;
@@ -613,16 +511,15 @@ public abstract class AbstractWagon
 
             // Prevent minichunking/fragmentation: when less than half the buffer is utilized,
             // read some more bytes before writing and firing progress.
-            if ( ( (Buffer) buffer ).position() < halfBufferCapacity )
-            {
+            if (((Buffer) buffer).position() < halfBufferCapacity) {
                 continue;
             }
 
-            ( (Buffer) buffer ).flip();
-            fireTransferProgress( transferEvent, buffer.array(), ( (Buffer) buffer ).limit() );
-            output.write( buffer.array(), 0, ( (Buffer) buffer ).limit() );
-            remaining -= ( (Buffer) buffer ).limit();
-            ( (Buffer) buffer ).clear();
+            ((Buffer) buffer).flip();
+            fireTransferProgress(transferEvent, buffer.array(), ((Buffer) buffer).limit());
+            output.write(buffer.array(), 0, ((Buffer) buffer).limit());
+            remaining -= ((Buffer) buffer).limit();
+            ((Buffer) buffer).clear();
         }
         output.flush();
     }
@@ -638,269 +535,235 @@ public abstract class AbstractWagon
      * @param numberOfBytes can be 0 or less, in which case a default buffer size is used.
      * @return a byte buffer suitable for transferring the given amount of bytes without too many chunks.
      */
-    protected int getBufferCapacityForTransfer( long numberOfBytes )
-    {
-        if ( numberOfBytes <= 0L )
-        {
+    protected int getBufferCapacityForTransfer(long numberOfBytes) {
+        if (numberOfBytes <= 0L) {
             return DEFAULT_BUFFER_SIZE;
         }
 
-        final long numberOfBufferSegments =  numberOfBytes
-                / ( BUFFER_SEGMENT_SIZE * MINIMUM_AMOUNT_OF_TRANSFER_CHUNKS );
+        final long numberOfBufferSegments = numberOfBytes / (BUFFER_SEGMENT_SIZE * MINIMUM_AMOUNT_OF_TRANSFER_CHUNKS);
         final long potentialBufferSize = numberOfBufferSegments * BUFFER_SEGMENT_SIZE;
-        if ( potentialBufferSize > Integer.MAX_VALUE )
-        {
+        if (potentialBufferSize > Integer.MAX_VALUE) {
             return MAXIMUM_BUFFER_SIZE;
         }
-        return min( MAXIMUM_BUFFER_SIZE, max( DEFAULT_BUFFER_SIZE, (int) potentialBufferSize ) );
+        return min(MAXIMUM_BUFFER_SIZE, max(DEFAULT_BUFFER_SIZE, (int) potentialBufferSize));
     }
 
     // ----------------------------------------------------------------------
     //
     // ----------------------------------------------------------------------
 
-    protected void fireTransferProgress( TransferEvent transferEvent, byte[] buffer, int n )
-    {
-        transferEventSupport.fireTransferProgress( transferEvent, buffer, n );
+    protected void fireTransferProgress(TransferEvent transferEvent, byte[] buffer, int n) {
+        transferEventSupport.fireTransferProgress(transferEvent, buffer, n);
     }
 
-    protected void fireGetCompleted( Resource resource, File localFile )
-    {
+    protected void fireGetCompleted(Resource resource, File localFile) {
         long timestamp = System.currentTimeMillis();
 
         TransferEvent transferEvent =
-            new TransferEvent( this, resource, TransferEvent.TRANSFER_COMPLETED, TransferEvent.REQUEST_GET );
+                new TransferEvent(this, resource, TransferEvent.TRANSFER_COMPLETED, TransferEvent.REQUEST_GET);
 
-        transferEvent.setTimestamp( timestamp );
+        transferEvent.setTimestamp(timestamp);
 
-        transferEvent.setLocalFile( localFile );
+        transferEvent.setLocalFile(localFile);
 
-        transferEventSupport.fireTransferCompleted( transferEvent );
+        transferEventSupport.fireTransferCompleted(transferEvent);
     }
 
-    protected void fireGetStarted( Resource resource, File localFile )
-    {
+    protected void fireGetStarted(Resource resource, File localFile) {
         long timestamp = System.currentTimeMillis();
 
         TransferEvent transferEvent =
-            new TransferEvent( this, resource, TransferEvent.TRANSFER_STARTED, TransferEvent.REQUEST_GET );
+                new TransferEvent(this, resource, TransferEvent.TRANSFER_STARTED, TransferEvent.REQUEST_GET);
 
-        transferEvent.setTimestamp( timestamp );
+        transferEvent.setTimestamp(timestamp);
 
-        transferEvent.setLocalFile( localFile );
+        transferEvent.setLocalFile(localFile);
 
-        transferEventSupport.fireTransferStarted( transferEvent );
+        transferEventSupport.fireTransferStarted(transferEvent);
     }
 
-    protected void fireGetInitiated( Resource resource, File localFile )
-    {
+    protected void fireGetInitiated(Resource resource, File localFile) {
         long timestamp = System.currentTimeMillis();
 
         TransferEvent transferEvent =
-            new TransferEvent( this, resource, TransferEvent.TRANSFER_INITIATED, TransferEvent.REQUEST_GET );
+                new TransferEvent(this, resource, TransferEvent.TRANSFER_INITIATED, TransferEvent.REQUEST_GET);
 
-        transferEvent.setTimestamp( timestamp );
+        transferEvent.setTimestamp(timestamp);
 
-        transferEvent.setLocalFile( localFile );
+        transferEvent.setLocalFile(localFile);
 
-        transferEventSupport.fireTransferInitiated( transferEvent );
+        transferEventSupport.fireTransferInitiated(transferEvent);
     }
 
-    protected void firePutInitiated( Resource resource, File localFile )
-    {
+    protected void firePutInitiated(Resource resource, File localFile) {
         long timestamp = System.currentTimeMillis();
 
         TransferEvent transferEvent =
-            new TransferEvent( this, resource, TransferEvent.TRANSFER_INITIATED, TransferEvent.REQUEST_PUT );
+                new TransferEvent(this, resource, TransferEvent.TRANSFER_INITIATED, TransferEvent.REQUEST_PUT);
 
-        transferEvent.setTimestamp( timestamp );
+        transferEvent.setTimestamp(timestamp);
 
-        transferEvent.setLocalFile( localFile );
+        transferEvent.setLocalFile(localFile);
 
-        transferEventSupport.fireTransferInitiated( transferEvent );
+        transferEventSupport.fireTransferInitiated(transferEvent);
     }
 
-    protected void firePutCompleted( Resource resource, File localFile )
-    {
+    protected void firePutCompleted(Resource resource, File localFile) {
         long timestamp = System.currentTimeMillis();
 
         TransferEvent transferEvent =
-            new TransferEvent( this, resource, TransferEvent.TRANSFER_COMPLETED, TransferEvent.REQUEST_PUT );
+                new TransferEvent(this, resource, TransferEvent.TRANSFER_COMPLETED, TransferEvent.REQUEST_PUT);
 
-        transferEvent.setTimestamp( timestamp );
+        transferEvent.setTimestamp(timestamp);
 
-        transferEvent.setLocalFile( localFile );
+        transferEvent.setLocalFile(localFile);
 
-        transferEventSupport.fireTransferCompleted( transferEvent );
+        transferEventSupport.fireTransferCompleted(transferEvent);
     }
 
-    protected void firePutStarted( Resource resource, File localFile )
-    {
+    protected void firePutStarted(Resource resource, File localFile) {
         long timestamp = System.currentTimeMillis();
 
         TransferEvent transferEvent =
-            new TransferEvent( this, resource, TransferEvent.TRANSFER_STARTED, TransferEvent.REQUEST_PUT );
+                new TransferEvent(this, resource, TransferEvent.TRANSFER_STARTED, TransferEvent.REQUEST_PUT);
 
-        transferEvent.setTimestamp( timestamp );
+        transferEvent.setTimestamp(timestamp);
 
-        transferEvent.setLocalFile( localFile );
+        transferEvent.setLocalFile(localFile);
 
-        transferEventSupport.fireTransferStarted( transferEvent );
+        transferEventSupport.fireTransferStarted(transferEvent);
     }
 
-    protected void fireSessionDisconnected()
-    {
+    protected void fireSessionDisconnected() {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, SessionEvent.SESSION_DISCONNECTED );
+        SessionEvent sessionEvent = new SessionEvent(this, SessionEvent.SESSION_DISCONNECTED);
 
-        sessionEvent.setTimestamp( timestamp );
+        sessionEvent.setTimestamp(timestamp);
 
-        sessionEventSupport.fireSessionDisconnected( sessionEvent );
+        sessionEventSupport.fireSessionDisconnected(sessionEvent);
     }
 
-    protected void fireSessionDisconnecting()
-    {
+    protected void fireSessionDisconnecting() {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, SessionEvent.SESSION_DISCONNECTING );
+        SessionEvent sessionEvent = new SessionEvent(this, SessionEvent.SESSION_DISCONNECTING);
 
-        sessionEvent.setTimestamp( timestamp );
+        sessionEvent.setTimestamp(timestamp);
 
-        sessionEventSupport.fireSessionDisconnecting( sessionEvent );
+        sessionEventSupport.fireSessionDisconnecting(sessionEvent);
     }
 
-    protected void fireSessionLoggedIn()
-    {
+    protected void fireSessionLoggedIn() {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, SessionEvent.SESSION_LOGGED_IN );
+        SessionEvent sessionEvent = new SessionEvent(this, SessionEvent.SESSION_LOGGED_IN);
 
-        sessionEvent.setTimestamp( timestamp );
+        sessionEvent.setTimestamp(timestamp);
 
-        sessionEventSupport.fireSessionLoggedIn( sessionEvent );
+        sessionEventSupport.fireSessionLoggedIn(sessionEvent);
     }
 
-    protected void fireSessionLoggedOff()
-    {
+    protected void fireSessionLoggedOff() {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, SessionEvent.SESSION_LOGGED_OFF );
+        SessionEvent sessionEvent = new SessionEvent(this, SessionEvent.SESSION_LOGGED_OFF);
 
-        sessionEvent.setTimestamp( timestamp );
+        sessionEvent.setTimestamp(timestamp);
 
-        sessionEventSupport.fireSessionLoggedOff( sessionEvent );
+        sessionEventSupport.fireSessionLoggedOff(sessionEvent);
     }
 
-    protected void fireSessionOpened()
-    {
+    protected void fireSessionOpened() {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, SessionEvent.SESSION_OPENED );
+        SessionEvent sessionEvent = new SessionEvent(this, SessionEvent.SESSION_OPENED);
 
-        sessionEvent.setTimestamp( timestamp );
+        sessionEvent.setTimestamp(timestamp);
 
-        sessionEventSupport.fireSessionOpened( sessionEvent );
+        sessionEventSupport.fireSessionOpened(sessionEvent);
     }
 
-    protected void fireSessionOpening()
-    {
+    protected void fireSessionOpening() {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, SessionEvent.SESSION_OPENING );
+        SessionEvent sessionEvent = new SessionEvent(this, SessionEvent.SESSION_OPENING);
 
-        sessionEvent.setTimestamp( timestamp );
+        sessionEvent.setTimestamp(timestamp);
 
-        sessionEventSupport.fireSessionOpening( sessionEvent );
+        sessionEventSupport.fireSessionOpening(sessionEvent);
     }
 
-    protected void fireSessionConnectionRefused()
-    {
+    protected void fireSessionConnectionRefused() {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, SessionEvent.SESSION_CONNECTION_REFUSED );
+        SessionEvent sessionEvent = new SessionEvent(this, SessionEvent.SESSION_CONNECTION_REFUSED);
 
-        sessionEvent.setTimestamp( timestamp );
+        sessionEvent.setTimestamp(timestamp);
 
-        sessionEventSupport.fireSessionConnectionRefused( sessionEvent );
+        sessionEventSupport.fireSessionConnectionRefused(sessionEvent);
     }
 
-    protected void fireSessionError( Exception exception )
-    {
+    protected void fireSessionError(Exception exception) {
         long timestamp = System.currentTimeMillis();
 
-        SessionEvent sessionEvent = new SessionEvent( this, exception );
-
-        sessionEvent.setTimestamp( timestamp );
+        SessionEvent sessionEvent = new SessionEvent(this, exception);
 
-        sessionEventSupport.fireSessionError( sessionEvent );
+        sessionEvent.setTimestamp(timestamp);
 
+        sessionEventSupport.fireSessionError(sessionEvent);
     }
 
-    protected void fireTransferDebug( String message )
-    {
-        transferEventSupport.fireDebug( message );
+    protected void fireTransferDebug(String message) {
+        transferEventSupport.fireDebug(message);
     }
 
-    protected void fireSessionDebug( String message )
-    {
-        sessionEventSupport.fireDebug( message );
+    protected void fireSessionDebug(String message) {
+        sessionEventSupport.fireDebug(message);
     }
 
-    public boolean hasTransferListener( TransferListener listener )
-    {
-        return transferEventSupport.hasTransferListener( listener );
+    public boolean hasTransferListener(TransferListener listener) {
+        return transferEventSupport.hasTransferListener(listener);
     }
 
-    public void addTransferListener( TransferListener listener )
-    {
-        transferEventSupport.addTransferListener( listener );
+    public void addTransferListener(TransferListener listener) {
+        transferEventSupport.addTransferListener(listener);
     }
 
-    public void removeTransferListener( TransferListener listener )
-    {
-        transferEventSupport.removeTransferListener( listener );
+    public void removeTransferListener(TransferListener listener) {
+        transferEventSupport.removeTransferListener(listener);
     }
 
-    public void addSessionListener( SessionListener listener )
-    {
-        sessionEventSupport.addSessionListener( listener );
+    public void addSessionListener(SessionListener listener) {
+        sessionEventSupport.addSessionListener(listener);
     }
 
-    public boolean hasSessionListener( SessionListener listener )
-    {
-        return sessionEventSupport.hasSessionListener( listener );
+    public boolean hasSessionListener(SessionListener listener) {
+        return sessionEventSupport.hasSessionListener(listener);
     }
 
-    public void removeSessionListener( SessionListener listener )
-    {
-        sessionEventSupport.removeSessionListener( listener );
+    public void removeSessionListener(SessionListener listener) {
+        sessionEventSupport.removeSessionListener(listener);
     }
 
-    protected void fireTransferError( Resource resource, Exception e, int requestType )
-    {
-        TransferEvent transferEvent = new TransferEvent( this, resource, e, requestType );
-        transferEventSupport.fireTransferError( transferEvent );
+    protected void fireTransferError(Resource resource, Exception e, int requestType) {
+        TransferEvent transferEvent = new TransferEvent(this, resource, e, requestType);
+        transferEventSupport.fireTransferError(transferEvent);
     }
 
-
-    public SessionEventSupport getSessionEventSupport()
-    {
+    public SessionEventSupport getSessionEventSupport() {
         return sessionEventSupport;
     }
 
-    public void setSessionEventSupport( SessionEventSupport sessionEventSupport )
-    {
+    public void setSessionEventSupport(SessionEventSupport sessionEventSupport) {
         this.sessionEventSupport = sessionEventSupport;
     }
 
-    public TransferEventSupport getTransferEventSupport()
-    {
+    public TransferEventSupport getTransferEventSupport() {
         return transferEventSupport;
     }
 
-    public void setTransferEventSupport( TransferEventSupport transferEventSupport )
-    {
+    public void setTransferEventSupport(TransferEventSupport transferEventSupport) {
         this.transferEventSupport = transferEventSupport;
     }
 
@@ -908,122 +771,98 @@ public abstract class AbstractWagon
      * This method is used if you are not streaming the transfer, to make sure any listeners dependent on state
      * (eg checksum observers) succeed.
      */
-    protected void postProcessListeners( Resource resource, File source, int requestType )
-        throws TransferFailedException
-    {
+    protected void postProcessListeners(Resource resource, File source, int requestType)
+            throws TransferFailedException {
         byte[] buffer = new byte[DEFAULT_BUFFER_SIZE];
 
-        TransferEvent transferEvent = new TransferEvent( this, resource, TransferEvent.TRANSFER_PROGRESS, requestType );
-        transferEvent.setTimestamp( System.currentTimeMillis() );
-        transferEvent.setLocalFile( source );
+        TransferEvent transferEvent = new TransferEvent(this, resource, TransferEvent.TRANSFER_PROGRESS, requestType);
+        transferEvent.setTimestamp(System.currentTimeMillis());
+        transferEvent.setLocalFile(source);
 
         InputStream input = null;
-        try
-        {
-            input = new FileInputStream( source );
+        try {
+            input = new FileInputStream(source);
 
-            while ( true )
-            {
-                int n = input.read( buffer );
+            while (true) {
+                int n = input.read(buffer);
 
-                if ( n == -1 )
-                {
+                if (n == -1) {
                     break;
                 }
 
-                fireTransferProgress( transferEvent, buffer, n );
+                fireTransferProgress(transferEvent, buffer, n);
             }
 
             input.close();
             input = null;
-        }
-        catch ( IOException e )
-        {
-            fireTransferError( resource, e, requestType );
+        } catch (IOException e) {
+            fireTransferError(resource, e, requestType);
 
-            throw new TransferFailedException( "Failed to post-process the source file", e );
-        }
-        finally
-        {
-            IOUtil.close( input );
+            throw new TransferFailedException("Failed to post-process the source file", e);
+        } finally {
+            IOUtil.close(input);
         }
     }
 
-    public void putDirectory( File sourceDirectory, String destinationDirectory )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
-        throw new UnsupportedOperationException( "The wagon you are using has not implemented putDirectory()" );
+    public void putDirectory(File sourceDirectory, String destinationDirectory)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
+        throw new UnsupportedOperationException("The wagon you are using has not implemented putDirectory()");
     }
 
-    public boolean supportsDirectoryCopy()
-    {
+    public boolean supportsDirectoryCopy() {
         return false;
     }
 
-    protected static String getPath( String basedir, String dir )
-    {
+    protected static String getPath(String basedir, String dir) {
         String path;
         path = basedir;
-        if ( !basedir.endsWith( "/" ) && !dir.startsWith( "/" ) )
-        {
+        if (!basedir.endsWith("/") && !dir.startsWith("/")) {
             path += "/";
         }
         path += dir;
         return path;
     }
 
-    public boolean isInteractive()
-    {
+    public boolean isInteractive() {
         return interactive;
     }
 
-    public void setInteractive( boolean interactive )
-    {
+    public void setInteractive(boolean interactive) {
         this.interactive = interactive;
     }
 
-    public List<String> getFileList( String destinationDirectory )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
-        throw new UnsupportedOperationException( "The wagon you are using has not implemented getFileList()" );
+    public List<String> getFileList(String destinationDirectory)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
+        throw new UnsupportedOperationException("The wagon you are using has not implemented getFileList()");
     }
 
-    public boolean resourceExists( String resourceName )
-        throws TransferFailedException, AuthorizationException
-    {
-        throw new UnsupportedOperationException( "The wagon you are using has not implemented resourceExists()" );
+    public boolean resourceExists(String resourceName) throws TransferFailedException, AuthorizationException {
+        throw new UnsupportedOperationException("The wagon you are using has not implemented resourceExists()");
     }
 
-    protected ProxyInfo getProxyInfo( String protocol, String host )
-    {
-        if ( proxyInfoProvider != null )
-        {
-            ProxyInfo proxyInfo = proxyInfoProvider.getProxyInfo( protocol );
-            if ( !ProxyUtils.validateNonProxyHosts( proxyInfo, host ) )
-            {
+    protected ProxyInfo getProxyInfo(String protocol, String host) {
+        if (proxyInfoProvider != null) {
+            ProxyInfo proxyInfo = proxyInfoProvider.getProxyInfo(protocol);
+            if (!ProxyUtils.validateNonProxyHosts(proxyInfo, host)) {
                 return proxyInfo;
             }
         }
         return null;
     }
 
-    public RepositoryPermissions getPermissionsOverride()
-    {
+    public RepositoryPermissions getPermissionsOverride() {
         return permissionsOverride;
     }
 
-    public void setPermissionsOverride( RepositoryPermissions permissionsOverride )
-    {
+    public void setPermissionsOverride(RepositoryPermissions permissionsOverride) {
         this.permissionsOverride = permissionsOverride;
     }
 
-    public void setReadTimeout( int readTimeout )
-    {
+    public void setReadTimeout(int readTimeout) {
         this.readTimeout = readTimeout;
     }
 
-    public int getReadTimeout()
-    {
+    public int getReadTimeout() {
         return this.readTimeout;
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutionException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutionException.java
index 5568e1d9..9755a538 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutionException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutionException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * Exception which should be thrown when a command fails to execute on the repository.
@@ -25,24 +24,19 @@ package org.apache.maven.wagon;
  * @author <a href="brett@apache.org">Brett Porter</a>
  *
  */
-public class CommandExecutionException
-    extends WagonException
-{
+public class CommandExecutionException extends WagonException {
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public CommandExecutionException( String message )
-    {
-        super( message );
+    public CommandExecutionException(String message) {
+        super(message);
     }
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public CommandExecutionException( String message, Throwable cause )
-    {
-        super( message, cause );
+    public CommandExecutionException(String message, Throwable cause) {
+        super(message, cause);
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutor.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutor.java
index 5476c8fd..d3e501f8 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutor.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/CommandExecutor.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,19 +16,16 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * @author <a href="mailto:brett@apache.org">Brett Porter</a>
  *
  */
-public interface CommandExecutor
-    extends Wagon
-{
+public interface CommandExecutor extends Wagon {
     String ROLE = CommandExecutor.class.getName();
 
-    void executeCommand( String command )
-        throws CommandExecutionException;
+    void executeCommand(String command) throws CommandExecutionException;
 
-    Streams executeCommand( String command, boolean ignoreFailures )
-        throws CommandExecutionException;
+    Streams executeCommand(String command, boolean ignoreFailures) throws CommandExecutionException;
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/ConnectionException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/ConnectionException.java
index ad4a64ed..a2e699a2 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/ConnectionException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/ConnectionException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * The exception is thrown when a connection
@@ -26,25 +25,19 @@ package org.apache.maven.wagon;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class ConnectionException
-    extends WagonException
-{
-
+public class ConnectionException extends WagonException {
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public ConnectionException( final String message )
-    {
-        super( message );
+    public ConnectionException(final String message) {
+        super(message);
     }
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public ConnectionException( final String message, final Throwable cause )
-    {
-        super( message, cause );
+    public ConnectionException(final String message, final Throwable cause) {
+        super(message, cause);
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/InputData.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/InputData.java
index c9b4b6b5..c9fd1edb 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/InputData.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/InputData.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,39 +16,34 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
-
-import org.apache.maven.wagon.resource.Resource;
+package org.apache.maven.wagon;
 
 import java.io.InputStream;
 
+import org.apache.maven.wagon.resource.Resource;
+
 /**
  * @author <a href="mailto:michal@codehaus.org">Michal Maczka</a>
  *
  */
-public class InputData
-{
+public class InputData {
     private InputStream inputStream;
 
     private Resource resource;
 
-    public InputStream getInputStream()
-    {
+    public InputStream getInputStream() {
         return inputStream;
     }
 
-    public void setInputStream( InputStream inputStream )
-    {
+    public void setInputStream(InputStream inputStream) {
         this.inputStream = inputStream;
     }
 
-    public Resource getResource()
-    {
+    public Resource getResource() {
         return resource;
     }
 
-    public void setResource( Resource resource )
-    {
+    public void setResource(Resource resource) {
         this.resource = resource;
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/LazyFileOutputStream.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/LazyFileOutputStream.java
index bb37340d..ca248e36 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/LazyFileOutputStream.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/LazyFileOutputStream.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.File;
 import java.io.FileDescriptor;
@@ -27,7 +26,6 @@ import java.io.IOException;
 import java.io.OutputStream;
 import java.nio.channels.FileChannel;
 
-
 /**
  * Variant of FileOutputStream which creates the file only when first portion
  * of data is written.
@@ -35,122 +33,87 @@ import java.nio.channels.FileChannel;
  * @author <a href="mailto:mmaczka@interia.pl">Michal Maczka</a>
  *
  */
-public class LazyFileOutputStream
-    extends OutputStream
-{
+public class LazyFileOutputStream extends OutputStream {
 
     private File file;
 
     private FileOutputStream delegee;
 
-
-    public LazyFileOutputStream( String filename )
-    {
-        this.file = new File( filename );
+    public LazyFileOutputStream(String filename) {
+        this.file = new File(filename);
     }
 
-    public LazyFileOutputStream( File file )
-    {
+    public LazyFileOutputStream(File file) {
         this.file = file;
     }
 
-
-    public void close()
-        throws IOException
-    {
-        if ( delegee != null )
-        {
+    public void close() throws IOException {
+        if (delegee != null) {
             delegee.close();
         }
     }
 
-
-    public boolean equals( Object obj )
-    {
-        return delegee.equals( obj );
+    public boolean equals(Object obj) {
+        return delegee.equals(obj);
     }
 
-
-    public void flush()
-        throws IOException
-    {
-        if ( delegee != null )
-        {
+    public void flush() throws IOException {
+        if (delegee != null) {
             delegee.flush();
         }
     }
 
-
-    public FileChannel getChannel()
-    {
+    public FileChannel getChannel() {
         return delegee.getChannel();
     }
 
-
-    public FileDescriptor getFD()
-        throws IOException
-    {
+    public FileDescriptor getFD() throws IOException {
         return delegee.getFD();
     }
 
-    public int hashCode()
-    {
+    public int hashCode() {
         return delegee.hashCode();
     }
 
-
-    public String toString()
-    {
+    public String toString() {
         return delegee.toString();
     }
 
-    public void write( byte[] b )
-        throws IOException
-    {
-        if ( delegee == null )
-        {
+    public void write(byte[] b) throws IOException {
+        if (delegee == null) {
             initialize();
         }
 
-        delegee.write( b );
+        delegee.write(b);
     }
 
     /**
      * @see java.io.OutputStream#write(byte[], int, int)
      */
-    public void write( byte[] b, int off, int len )
-        throws IOException
-    {
-        if ( delegee == null )
-        {
+    public void write(byte[] b, int off, int len) throws IOException {
+        if (delegee == null) {
             initialize();
         }
 
-        delegee.write( b, off, len );
+        delegee.write(b, off, len);
     }
 
     /**
      * @param b
      * @throws java.io.IOException
      */
-    public void write( int b )
-        throws IOException
-    {
-        if ( delegee == null )
-        {
+    public void write(int b) throws IOException {
+        if (delegee == null) {
             initialize();
         }
 
-        delegee.write( b );
+        delegee.write(b);
     }
 
-
     /**
-     * 
+     *
      */
-    private void initialize()
-        throws FileNotFoundException
-    {
-        delegee = new FileOutputStream( file );
+    private void initialize() throws FileNotFoundException {
+        delegee = new FileOutputStream(file);
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/OutputData.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/OutputData.java
index 792f7853..92d26eac 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/OutputData.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/OutputData.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,38 +16,34 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
-
-import org.apache.maven.wagon.resource.Resource;
+package org.apache.maven.wagon;
 
 import java.io.OutputStream;
 
+import org.apache.maven.wagon.resource.Resource;
+
 /**
  * @author <a href="mailto:michal@codehaus.org">Michal Maczka</a>
  *
  */
-public class OutputData
-{
+public class OutputData {
     private OutputStream outputStream;
 
     private Resource resource;
 
-    public OutputStream getOutputStream()
-    {
+    public OutputStream getOutputStream() {
         return outputStream;
     }
 
-    public void setOutputStream( OutputStream outputStream )
-    {
+    public void setOutputStream(OutputStream outputStream) {
         this.outputStream = outputStream;
     }
 
-    public Resource getResource()
-    {
+    public Resource getResource() {
         return resource;
     }
 
-    public void setResource( Resource resource )
-    {
+    public void setResource(Resource resource) {
         this.resource = resource;
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/PathUtils.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/PathUtils.java
index bee85b32..998bca05 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/PathUtils.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/PathUtils.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.File;
 import java.util.StringTokenizer;
@@ -28,11 +27,8 @@ import java.util.StringTokenizer;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public final class PathUtils
-{
-    private PathUtils()
-    {
-    }
+public final class PathUtils {
+    private PathUtils() {}
 
     /**
      * Returns the directory path portion of a file specification string.
@@ -40,11 +36,10 @@ public final class PathUtils
      *
      * @return The directory portion excluding the ending file separator.
      */
-    public static String dirname( final String path )
-    {
-        final int i = path.lastIndexOf( "/" );
+    public static String dirname(final String path) {
+        final int i = path.lastIndexOf("/");
 
-        return ( ( i >= 0 ) ? path.substring( 0, i ) : "" );
+        return ((i >= 0) ? path.substring(0, i) : "");
     }
 
     /**
@@ -52,38 +47,30 @@ public final class PathUtils
      *
      * @return The filename string with extension.
      */
-    public static String filename( final String path )
-    {
-        final int i = path.lastIndexOf( "/" );
-        return ( ( i >= 0 ) ? path.substring( i + 1 ) : path );
+    public static String filename(final String path) {
+        final int i = path.lastIndexOf("/");
+        return ((i >= 0) ? path.substring(i + 1) : path);
     }
 
-    public static String[] dirnames( final String path )
-    {
-        final String dirname = PathUtils.dirname( path );
-        return split( dirname, "/", -1 );
-
+    public static String[] dirnames(final String path) {
+        final String dirname = PathUtils.dirname(path);
+        return split(dirname, "/", -1);
     }
 
-    private static String[] split( final String str, final String separator, final int max )
-    {
+    private static String[] split(final String str, final String separator, final int max) {
         final StringTokenizer tok;
 
-        if ( separator == null )
-        {
+        if (separator == null) {
             // Null separator means we're using StringTokenizer's default
             // delimiter, which comprises all whitespace characters.
-            tok = new StringTokenizer( str );
-        }
-        else
-        {
-            tok = new StringTokenizer( str, separator );
+            tok = new StringTokenizer(str);
+        } else {
+            tok = new StringTokenizer(str, separator);
         }
 
         int listSize = tok.countTokens();
 
-        if ( max > 0 && listSize > max )
-        {
+        if (max > 0 && listSize > max) {
             listSize = max;
         }
 
@@ -94,27 +81,23 @@ public final class PathUtils
         int lastTokenBegin;
         int lastTokenEnd = 0;
 
-        while ( tok.hasMoreTokens() )
-        {
-            if ( max > 0 && i == listSize - 1 )
-            {
+        while (tok.hasMoreTokens()) {
+            if (max > 0 && i == listSize - 1) {
                 // In the situation where we hit the max yet have
                 // tokens left over in our input, the last list
                 // element gets all remaining text.
                 final String endToken = tok.nextToken();
 
-                lastTokenBegin = str.indexOf( endToken, lastTokenEnd );
+                lastTokenBegin = str.indexOf(endToken, lastTokenEnd);
 
-                list[i] = str.substring( lastTokenBegin );
+                list[i] = str.substring(lastTokenBegin);
 
                 break;
 
-            }
-            else
-            {
+            } else {
                 list[i] = tok.nextToken();
 
-                lastTokenBegin = str.indexOf( list[i], lastTokenEnd );
+                lastTokenBegin = str.indexOf(list[i], lastTokenEnd);
 
                 lastTokenEnd = lastTokenBegin + list[i].length();
             }
@@ -131,84 +114,73 @@ public final class PathUtils
      * @param url the url
      * @return the host name
      */
-    public static String host( final String url )
-    {
-        if ( url == null || url.length() == 0 )
-        {
+    public static String host(final String url) {
+        if (url == null || url.length() == 0) {
             return "localhost";
         }
-        String authorization = authorization( url );
-        int index = authorization.indexOf( '@' );
-        String host = ( index >= 0 ) ? authorization.substring( index + 1 ) : authorization;
+        String authorization = authorization(url);
+        int index = authorization.indexOf('@');
+        String host = (index >= 0) ? authorization.substring(index + 1) : authorization;
         // In case we have IPv6 in the host portion of url
         // we have to remove brackets '[' and ']'
-        return ( ( host.charAt( 0 ) == '[' ) && ( host.charAt( host.length() - 1 ) == ']' ) )
-                        ? host.substring( 1, host.length() - 1 )
-                        : host;
+        return ((host.charAt(0) == '[') && (host.charAt(host.length() - 1) == ']'))
+                ? host.substring(1, host.length() - 1)
+                : host;
     }
 
     /**
      * This was changed from private to package local so that it can be unit tested.
      */
-    static String authorization( final String url )
-    {
-        if ( url == null )
-        {
+    static String authorization(final String url) {
+        if (url == null) {
             return "localhost";
         }
 
-        String protocol = PathUtils.protocol( url );
+        String protocol = PathUtils.protocol(url);
 
-        if ( protocol == null || protocol.equalsIgnoreCase( "file" ) )
-        {
+        if (protocol == null || protocol.equalsIgnoreCase("file")) {
             return "localhost";
         }
 
         String host = url;
-        if ( protocol.equalsIgnoreCase( "scm" ) )
-        {
+        if (protocol.equalsIgnoreCase("scm")) {
             // skip over type
-            host = host.substring( host.indexOf( ":", 4 ) + 1 ).trim();
+            host = host.substring(host.indexOf(":", 4) + 1).trim();
         }
 
-        protocol = PathUtils.protocol( host );
+        protocol = PathUtils.protocol(host);
 
-        if ( protocol.equalsIgnoreCase( "file" ) )
-        {
+        if (protocol.equalsIgnoreCase("file")) {
             return "localhost";
         }
 
         // skip over protocol
-        host = host.substring( host.indexOf( ":" ) + 1 ).trim();
-        if ( host.startsWith( "//" ) )
-        {
-            host = host.substring( 2 );
+        host = host.substring(host.indexOf(":") + 1).trim();
+        if (host.startsWith("//")) {
+            host = host.substring(2);
         }
 
-        int pos = host.indexOf( "/" );
+        int pos = host.indexOf("/");
 
-        if ( pos > 0 )
-        {
-            host = host.substring( 0, pos );
+        if (pos > 0) {
+            host = host.substring(0, pos);
         }
 
-        pos = host.indexOf( '@' );
+        pos = host.indexOf('@');
 
-        pos = ( pos > 0 ) ? endOfHostPosition( host, pos ) : endOfHostPosition( host, 0 );
+        pos = (pos > 0) ? endOfHostPosition(host, pos) : endOfHostPosition(host, 0);
 
-        if ( pos > 0 )
-        {
-            host = host.substring( 0, pos );
+        if (pos > 0) {
+            host = host.substring(0, pos);
         }
         return host;
     }
 
-    private static int endOfHostPosition( String host, int pos )
-    {
+    private static int endOfHostPosition(String host, int pos) {
         // if this is IPv6 then it will be in IPv6 Literal Addresses in URL's format
         // see: http://www.ietf.org/rfc/rfc2732.txt
-        int endOfIPv6Pos = host.indexOf( ']', pos );
-        return ( endOfIPv6Pos > 0 ) ? endOfIPv6Pos + 1 : host.indexOf( ":", pos );
+        int endOfIPv6Pos = host.indexOf(']', pos);
+        return (endOfIPv6Pos > 0) ? endOfIPv6Pos + 1 : host.indexOf(":", pos);
     }
 
     /**
@@ -221,80 +193,66 @@ public final class PathUtils
      * @param url the url
      * @return the host name
      */
-    public static String protocol( final String url )
-    {
-        final int pos = url.indexOf( ":" );
+    public static String protocol(final String url) {
+        final int pos = url.indexOf(":");
 
-        if ( pos == -1 )
-        {
+        if (pos == -1) {
             return "";
         }
-        return url.substring( 0, pos ).trim();
+        return url.substring(0, pos).trim();
     }
 
     /**
      * @param url
      * @return the port or {@link WagonConstants#UNKNOWN_PORT} if not existent
      */
-    public static int port( String url )
-    {
+    public static int port(String url) {
 
-        final String protocol = PathUtils.protocol( url );
+        final String protocol = PathUtils.protocol(url);
 
-        if ( protocol == null || protocol.equalsIgnoreCase( "file" ) )
-        {
+        if (protocol == null || protocol.equalsIgnoreCase("file")) {
             return WagonConstants.UNKNOWN_PORT;
         }
 
-        final String authorization = PathUtils.authorization( url );
+        final String authorization = PathUtils.authorization(url);
 
-        if ( authorization == null )
-        {
+        if (authorization == null) {
             return WagonConstants.UNKNOWN_PORT;
         }
 
-        if ( protocol.equalsIgnoreCase( "scm" ) )
-        {
+        if (protocol.equalsIgnoreCase("scm")) {
             // skip over type
-            url = url.substring( url.indexOf( ":", 4 ) + 1 ).trim();
+            url = url.substring(url.indexOf(":", 4) + 1).trim();
         }
 
-        if ( url.regionMatches( true, 0, "file:", 0, 5 ) || url.regionMatches( true, 0, "local:", 0, 6 ) )
-        {
+        if (url.regionMatches(true, 0, "file:", 0, 5) || url.regionMatches(true, 0, "local:", 0, 6)) {
             return WagonConstants.UNKNOWN_PORT;
         }
 
         // skip over protocol
-        url = url.substring( url.indexOf( ":" ) + 1 ).trim();
-        if ( url.startsWith( "//" ) )
-        {
-            url = url.substring( 2 );
+        url = url.substring(url.indexOf(":") + 1).trim();
+        if (url.startsWith("//")) {
+            url = url.substring(2);
         }
 
         int start = authorization.length();
 
-        if ( url.length() > start && url.charAt( start ) == ':' )
-        {
-            int end = url.indexOf( '/', start );
+        if (url.length() > start && url.charAt(start) == ':') {
+            int end = url.indexOf('/', start);
 
-            if ( end == start + 1 )
-            {
+            if (end == start + 1) {
                 // it is :/
                 return WagonConstants.UNKNOWN_PORT;
             }
 
-            if ( end == -1 )
-            {
+            if (end == -1) {
                 end = url.length();
             }
 
-            return Integer.parseInt( url.substring( start + 1, end ) );
-        }
-        else
-        {
+            return Integer.parseInt(url.substring(start + 1, end));
+        } else {
             return WagonConstants.UNKNOWN_PORT;
         }
-
     }
 
     /**
@@ -304,52 +262,40 @@ public final class PathUtils
      * @return the basedir of the repository
      * @todo need to URL decode for spaces?
      */
-    public static String basedir( String url )
-    {
-        String protocol = PathUtils.protocol( url );
+    public static String basedir(String url) {
+        String protocol = PathUtils.protocol(url);
 
         String retValue = null;
 
-        if ( protocol.equalsIgnoreCase( "scm" ) )
-        {
+        if (protocol.equalsIgnoreCase("scm")) {
             // skip over SCM bits
-            if ( url.regionMatches( true, 0, "scm:svn:", 0, 8 ) )
-            {
-                url = url.substring( url.indexOf( ":", 4 ) + 1 );
-                protocol = PathUtils.protocol( url );
+            if (url.regionMatches(true, 0, "scm:svn:", 0, 8)) {
+                url = url.substring(url.indexOf(":", 4) + 1);
+                protocol = PathUtils.protocol(url);
             }
         }
 
-        if ( protocol.equalsIgnoreCase( "file" ) )
-        {
-            retValue = url.substring( protocol.length() + 1 );
-            retValue = decode( retValue );
+        if (protocol.equalsIgnoreCase("file")) {
+            retValue = url.substring(protocol.length() + 1);
+            retValue = decode(retValue);
             // special case: if omitted // on protocol, keep path as is
-            if ( retValue.startsWith( "//" ) )
-            {
-                retValue = retValue.substring( 2 );
+            if (retValue.startsWith("//")) {
+                retValue = retValue.substring(2);
 
-                if ( retValue.length() >= 2 && ( retValue.charAt( 1 ) == '|' || retValue.charAt( 1 ) == ':' ) )
-                {
+                if (retValue.length() >= 2 && (retValue.charAt(1) == '|' || retValue.charAt(1) == ':')) {
                     // special case: if there is a windows drive letter, then keep the original return value
-                    retValue = retValue.charAt( 0 ) + ":" + retValue.substring( 2 );
-                }
-                else
-                {
+                    retValue = retValue.charAt(0) + ":" + retValue.substring(2);
+                } else {
                     // Now we expect the host
-                    int index = retValue.indexOf( "/" );
-                    if ( index >= 0 )
-                    {
-                        retValue = retValue.substring( index + 1 );
+                    int index = retValue.indexOf("/");
+                    if (index >= 0) {
+                        retValue = retValue.substring(index + 1);
                     }
 
                     // special case: if there is a windows drive letter, then keep the original return value
-                    if ( retValue.length() >= 2 && ( retValue.charAt( 1 ) == '|' || retValue.charAt( 1 ) == ':' ) )
-                    {
-                        retValue = retValue.charAt( 0 ) + ":" + retValue.substring( 2 );
-                    }
-                    else if ( index >= 0 )
-                    {
+                    if (retValue.length() >= 2 && (retValue.charAt(1) == '|' || retValue.charAt(1) == ':')) {
+                        retValue = retValue.charAt(0) + ":" + retValue.substring(2);
+                    } else if (index >= 0) {
                         // leading / was previously stripped
                         retValue = "/" + retValue;
                     }
@@ -357,56 +303,45 @@ public final class PathUtils
             }
 
             // special case: if there is a windows drive letter using |, switch to :
-            if ( retValue.length() >= 2 && retValue.charAt( 1 ) == '|' )
-            {
-                retValue = retValue.charAt( 0 ) + ":" + retValue.substring( 2 );
+            if (retValue.length() >= 2 && retValue.charAt(1) == '|') {
+                retValue = retValue.charAt(0) + ":" + retValue.substring(2);
             }
-        }
-        else
-        {
-            final String authorization = PathUtils.authorization( url );
+        } else {
+            final String authorization = PathUtils.authorization(url);
 
-            final int port = PathUtils.port( url );
+            final int port = PathUtils.port(url);
 
             int pos = 0;
 
-            if ( protocol.equalsIgnoreCase( "scm" ) )
-            {
-                pos = url.indexOf( ":", 4 ) + 1;
-                pos = url.indexOf( ":", pos ) + 1;
-            }
-            else
-            {
-                int index = url.indexOf( "://" );
-                if ( index != -1 )
-                {
+            if (protocol.equalsIgnoreCase("scm")) {
+                pos = url.indexOf(":", 4) + 1;
+                pos = url.indexOf(":", pos) + 1;
+            } else {
+                int index = url.indexOf("://");
+                if (index != -1) {
                     pos = index + 3;
                 }
             }
 
             pos += authorization.length();
 
-            if ( port != WagonConstants.UNKNOWN_PORT )
-            {
-                pos = pos + Integer.toString( port ).length() + 1;
+            if (port != WagonConstants.UNKNOWN_PORT) {
+                pos = pos + Integer.toString(port).length() + 1;
             }
 
-            if ( url.length() > pos )
-            {
-                retValue = url.substring( pos );
-                if ( retValue.startsWith( ":" ) )
-                {
+            if (url.length() > pos) {
+                retValue = url.substring(pos);
+                if (retValue.startsWith(":")) {
                     // this is for :/ after the host
-                    retValue = retValue.substring( 1 );
+                    retValue = retValue.substring(1);
                 }
 
                 // one module may be allowed in the path in CVS
-                retValue = retValue.replace( ':', '/' );
+                retValue = retValue.replace(':', '/');
             }
         }
 
-        if ( retValue == null )
-        {
+        if (retValue == null) {
             retValue = "/";
         }
         return retValue.trim();
@@ -419,83 +354,65 @@ public final class PathUtils
      * @param url The URL to decode, may be <code>null</code>.
      * @return The decoded URL or <code>null</code> if the input was <code>null</code>.
      */
-    private static String decode( String url )
-    {
+    private static String decode(String url) {
         String decoded = url;
-        if ( url != null )
-        {
+        if (url != null) {
             int pos = -1;
-            while ( ( pos = decoded.indexOf( '%', pos + 1 ) ) >= 0 )
-            {
-                if ( pos + 2 < decoded.length() )
-                {
-                    String hexStr = decoded.substring( pos + 1, pos + 3 );
-                    char ch = (char) Integer.parseInt( hexStr, 16 );
-                    decoded = decoded.substring( 0, pos ) + ch + decoded.substring( pos + 3 );
+            while ((pos = decoded.indexOf('%', pos + 1)) >= 0) {
+                if (pos + 2 < decoded.length()) {
+                    String hexStr = decoded.substring(pos + 1, pos + 3);
+                    char ch = (char) Integer.parseInt(hexStr, 16);
+                    decoded = decoded.substring(0, pos) + ch + decoded.substring(pos + 3);
                 }
             }
         }
         return decoded;
     }
 
-    public static String user( String url )
-    {
-        String host = authorization( url );
-        int index = host.indexOf( '@' );
-        if ( index > 0 )
-        {
-            String userInfo = host.substring( 0, index );
-            index = userInfo.indexOf( ':' );
-            if ( index > 0 )
-            {
-                return userInfo.substring( 0, index );
-            }
-            else if ( index < 0 )
-            {
+    public static String user(String url) {
+        String host = authorization(url);
+        int index = host.indexOf('@');
+        if (index > 0) {
+            String userInfo = host.substring(0, index);
+            index = userInfo.indexOf(':');
+            if (index > 0) {
+                return userInfo.substring(0, index);
+            } else if (index < 0) {
                 return userInfo;
             }
         }
         return null;
     }
 
-    public static String password( String url )
-    {
-        String host = authorization( url );
-        int index = host.indexOf( '@' );
-        if ( index > 0 )
-        {
-            String userInfo = host.substring( 0, index );
-            index = userInfo.indexOf( ':' );
-            if ( index >= 0 )
-            {
-                return userInfo.substring( index + 1 );
+    public static String password(String url) {
+        String host = authorization(url);
+        int index = host.indexOf('@');
+        if (index > 0) {
+            String userInfo = host.substring(0, index);
+            index = userInfo.indexOf(':');
+            if (index >= 0) {
+                return userInfo.substring(index + 1);
             }
         }
         return null;
     }
 
     // TODO: move to plexus-utils or use something appropriate from there
-    public static String toRelative( File basedir, String absolutePath )
-    {
+    public static String toRelative(File basedir, String absolutePath) {
         String relative;
 
-        absolutePath = absolutePath.replace( '\\', '/' );
-        String basedirPath = basedir.getAbsolutePath().replace( '\\', '/' );
+        absolutePath = absolutePath.replace('\\', '/');
+        String basedirPath = basedir.getAbsolutePath().replace('\\', '/');
 
-        if ( absolutePath.startsWith( basedirPath ) )
-        {
-            relative = absolutePath.substring( basedirPath.length() );
-            if ( relative.startsWith( "/" ) )
-            {
-                relative = relative.substring( 1 );
+        if (absolutePath.startsWith(basedirPath)) {
+            relative = absolutePath.substring(basedirPath.length());
+            if (relative.startsWith("/")) {
+                relative = relative.substring(1);
             }
-            if ( relative.length() <= 0 )
-            {
+            if (relative.length() <= 0) {
                 relative = ".";
             }
-        }
-        else
-        {
+        } else {
             relative = absolutePath;
         }
 
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/PermissionModeUtils.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/PermissionModeUtils.java
index bc4c86c1..0bd90b4e 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/PermissionModeUtils.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/PermissionModeUtils.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * Utility class for common operations for file/directory permissions.
@@ -26,47 +25,36 @@ package org.apache.maven.wagon;
  * @see PermissionModeUtils
  * @since Sep 3, 2005
  */
-public final class PermissionModeUtils
-{
-    private PermissionModeUtils()
-    {
-    }
-    
+public final class PermissionModeUtils {
+    private PermissionModeUtils() {}
+
     /**
      * See the System Interfaces volume of IEEE Std 1003.1-2001, umask(1)
      *
      * @param modeStr permission mode (numeric or symbolic)
      * @return the mode that can be used with umask to accomplish modeStr.
      */
-    public static String getUserMaskFor( String modeStr )
-    {
+    public static String getUserMaskFor(String modeStr) {
         String ret = null;
 
-        try
-        {
-            int mode = Integer.valueOf( modeStr, 8 ).intValue();
+        try {
+            int mode = Integer.valueOf(modeStr, 8).intValue();
 
-            mode = mode % 8 + ( ( mode / 8 ) % 8 ) * 8 + ( ( mode / 64 ) % 8 ) * 64;
+            mode = mode % 8 + ((mode / 8) % 8) * 8 + ((mode / 64) % 8) * 64;
 
             // CHECKSTYLE_OFF: MagicNumber
-            ret = Integer.toOctalString( 0777 - mode );
+            ret = Integer.toOctalString(0777 - mode);
             // CHECKSTYLE_ON: MagicNumber
-        }
-        catch ( final NumberFormatException e )
-        {
-            try
-            {
-                Integer.parseInt( modeStr );
-            }
-            catch ( final NumberFormatException e1 )
-            {
+        } catch (final NumberFormatException e) {
+            try {
+                Integer.parseInt(modeStr);
+            } catch (final NumberFormatException e1) {
                 ret = modeStr;
             }
         }
 
-        if ( ret == null )
-        {
-            throw new IllegalArgumentException( "The mode is a number but is not octal" );
+        if (ret == null) {
+            throw new IllegalArgumentException("The mode is a number but is not octal");
         }
 
         return ret;
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/ResourceDoesNotExistException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/ResourceDoesNotExistException.java
index 8e8919bf..f331fb60 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/ResourceDoesNotExistException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/ResourceDoesNotExistException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,30 +16,26 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class ResourceDoesNotExistException
-    extends WagonException
-{
+public class ResourceDoesNotExistException extends WagonException {
 
     /**
      * @param message
      */
-    public ResourceDoesNotExistException( final String message )
-    {
-        super( message );
+    public ResourceDoesNotExistException(final String message) {
+        super(message);
     }
 
     /**
      * @param message
      * @param cause
      */
-    public ResourceDoesNotExistException( final String message, final Throwable cause )
-    {
-        super( message, cause );
+    public ResourceDoesNotExistException(final String message, final Throwable cause) {
+        super(message, cause);
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamWagon.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamWagon.java
index 5773cf0d..071171ad 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamWagon.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamWagon.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.File;
 import java.io.IOException;
@@ -34,120 +33,91 @@ import org.apache.maven.wagon.resource.Resource;
  * @author <a href="mailto:michal@codehaus.org">Michal Maczka</a>
  *
  */
-public abstract class StreamWagon
-    extends AbstractWagon
-    implements StreamingWagon
-{
+public abstract class StreamWagon extends AbstractWagon implements StreamingWagon {
     // ----------------------------------------------------------------------
     //
     // ----------------------------------------------------------------------
 
-    public abstract void fillInputData( InputData inputData )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    public abstract void fillInputData(InputData inputData)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 
-    public abstract void fillOutputData( OutputData outputData )
-        throws TransferFailedException;
+    public abstract void fillOutputData(OutputData outputData) throws TransferFailedException;
 
-    public abstract void closeConnection()
-        throws ConnectionException;
+    public abstract void closeConnection() throws ConnectionException;
 
     // ----------------------------------------------------------------------
     //
     // ----------------------------------------------------------------------
 
-    public void get( String resourceName, File destination )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
-        getIfNewer( resourceName, destination, 0 );
+    public void get(String resourceName, File destination)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
+        getIfNewer(resourceName, destination, 0);
     }
 
-    protected void checkInputStream( InputStream is, Resource resource )
-        throws TransferFailedException
-    {
-        if ( is == null )
-        {
-            TransferFailedException e =
-                new TransferFailedException( getRepository().getUrl()
-                    + " - Could not open input stream for resource: '" + resource + "'" );
-            fireTransferError( resource, e, TransferEvent.REQUEST_GET );
+    protected void checkInputStream(InputStream is, Resource resource) throws TransferFailedException {
+        if (is == null) {
+            TransferFailedException e = new TransferFailedException(
+                    getRepository().getUrl() + " - Could not open input stream for resource: '" + resource + "'");
+            fireTransferError(resource, e, TransferEvent.REQUEST_GET);
             throw e;
         }
     }
 
-    public boolean getIfNewer( String resourceName, File destination, long timestamp )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
+    public boolean getIfNewer(String resourceName, File destination, long timestamp)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
         boolean retValue = false;
 
-        Resource resource = new Resource( resourceName );
+        Resource resource = new Resource(resourceName);
+
+        fireGetInitiated(resource, destination);
 
-        fireGetInitiated( resource, destination );
+        resource.setLastModified(timestamp);
 
-        resource.setLastModified( timestamp );
-        
-        InputStream is = getInputStream( resource );
+        InputStream is = getInputStream(resource);
 
         // always get if timestamp is 0 (ie, target doesn't exist), otherwise only if older than the remote file
-        if ( timestamp == 0 || timestamp < resource.getLastModified() )
-        {
+        if (timestamp == 0 || timestamp < resource.getLastModified()) {
             retValue = true;
 
-            checkInputStream( is, resource );
+            checkInputStream(is, resource);
 
-            getTransfer( resource, destination, is );
-        }
-        else
-        {
-            try
-            {
-                if ( is != null )
-                {
+            getTransfer(resource, destination, is);
+        } else {
+            try {
+                if (is != null) {
                     is.close();
                 }
-            }
-            catch ( final IOException e )
-            {
-                throw new TransferFailedException( "Failure transferring " + resourceName, e );
+            } catch (final IOException e) {
+                throw new TransferFailedException("Failure transferring " + resourceName, e);
             }
         }
 
         return retValue;
     }
 
-    protected InputStream getInputStream( Resource resource )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
+    protected InputStream getInputStream(Resource resource)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
         InputData inputData = new InputData();
 
-        inputData.setResource( resource );
+        inputData.setResource(resource);
 
-        try
-        {
-            fillInputData( inputData );
-        }
-        catch ( TransferFailedException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_GET );
-            cleanupGetTransfer( resource );
+        try {
+            fillInputData(inputData);
+        } catch (TransferFailedException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_GET);
+            cleanupGetTransfer(resource);
             throw e;
-        }
-        catch ( ResourceDoesNotExistException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_GET );
-            cleanupGetTransfer( resource );
+        } catch (ResourceDoesNotExistException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_GET);
+            cleanupGetTransfer(resource);
             throw e;
-        }
-        catch ( AuthorizationException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_GET );
-            cleanupGetTransfer( resource );
+        } catch (AuthorizationException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_GET);
+            cleanupGetTransfer(resource);
             throw e;
-        }
-        finally
-        {
-            if ( inputData.getInputStream() == null )
-            {
-                cleanupGetTransfer( resource );
+        } finally {
+            if (inputData.getInputStream() == null) {
+                cleanupGetTransfer(resource);
             }
         }
 
@@ -155,148 +125,123 @@ public abstract class StreamWagon
     }
 
     // source doesn't exist exception
-    public void put( File source, String resourceName )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
-        Resource resource = new Resource( resourceName );
+    public void put(File source, String resourceName)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
+        Resource resource = new Resource(resourceName);
 
-        firePutInitiated( resource, source );
+        firePutInitiated(resource, source);
 
-        resource.setContentLength( source.length() );
+        resource.setContentLength(source.length());
 
-        resource.setLastModified( source.lastModified() );
+        resource.setLastModified(source.lastModified());
 
-        OutputStream os = getOutputStream( resource );
+        OutputStream os = getOutputStream(resource);
 
-        checkOutputStream( resource, os );
+        checkOutputStream(resource, os);
 
-        putTransfer( resource, source, os, true );
+        putTransfer(resource, source, os, true);
     }
 
-    protected void checkOutputStream( Resource resource, OutputStream os )
-        throws TransferFailedException
-    {
-        if ( os == null )
-        {
-            TransferFailedException e =
-                new TransferFailedException( getRepository().getUrl()
-                    + " - Could not open output stream for resource: '" + resource + "'" );
-            fireTransferError( resource, e, TransferEvent.REQUEST_PUT );
+    protected void checkOutputStream(Resource resource, OutputStream os) throws TransferFailedException {
+        if (os == null) {
+            TransferFailedException e = new TransferFailedException(
+                    getRepository().getUrl() + " - Could not open output stream for resource: '" + resource + "'");
+            fireTransferError(resource, e, TransferEvent.REQUEST_PUT);
             throw e;
         }
     }
 
-    protected OutputStream getOutputStream( Resource resource )
-        throws TransferFailedException
-    {
+    protected OutputStream getOutputStream(Resource resource) throws TransferFailedException {
         OutputData outputData = new OutputData();
 
-        outputData.setResource( resource );
+        outputData.setResource(resource);
 
-        try
-        {
-            fillOutputData( outputData );
-        }
-        catch ( TransferFailedException e )
-        {
-            fireTransferError( resource, e, TransferEvent.REQUEST_PUT );
+        try {
+            fillOutputData(outputData);
+        } catch (TransferFailedException e) {
+            fireTransferError(resource, e, TransferEvent.REQUEST_PUT);
 
             throw e;
-        }
-        finally
-        {
-            if ( outputData.getOutputStream() == null )
-            {
-                cleanupPutTransfer( resource );
+        } finally {
+            if (outputData.getOutputStream() == null) {
+                cleanupPutTransfer(resource);
             }
         }
 
         return outputData.getOutputStream();
     }
 
-    public boolean getIfNewerToStream( String resourceName, OutputStream stream, long timestamp )
-        throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException
-    {
+    public boolean getIfNewerToStream(String resourceName, OutputStream stream, long timestamp)
+            throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException {
         boolean retValue = false;
 
-        Resource resource = new Resource( resourceName );
+        Resource resource = new Resource(resourceName);
 
-        fireGetInitiated( resource, null );
+        fireGetInitiated(resource, null);
 
-        InputStream is = getInputStream( resource );
+        InputStream is = getInputStream(resource);
 
         // always get if timestamp is 0 (ie, target doesn't exist), otherwise only if older than the remote file
-        if ( timestamp == 0 || timestamp < resource.getLastModified() )
-        {
+        if (timestamp == 0 || timestamp < resource.getLastModified()) {
             retValue = true;
 
-            checkInputStream( is, resource );
+            checkInputStream(is, resource);
 
-            fireGetStarted( resource, null );
+            fireGetStarted(resource, null);
 
-            getTransfer( resource, stream, is, true, Integer.MAX_VALUE );
+            getTransfer(resource, stream, is, true, Integer.MAX_VALUE);
 
-            fireGetCompleted( resource, null );
-        }
-        else
-        {
-            try
-            {
-                if ( is != null )
-                {
+            fireGetCompleted(resource, null);
+        } else {
+            try {
+                if (is != null) {
                     is.close();
                 }
-            }
-            catch ( final IOException e )
-            {
-                throw new TransferFailedException( "Failure transferring " + resourceName, e );
+            } catch (final IOException e) {
+                throw new TransferFailedException("Failure transferring " + resourceName, e);
             }
         }
-        
+
         return retValue;
     }
 
-    public void getToStream( String resourceName, OutputStream stream )
-        throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException
-    {
-        getIfNewerToStream( resourceName, stream, 0 );
+    public void getToStream(String resourceName, OutputStream stream)
+            throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException {
+        getIfNewerToStream(resourceName, stream, 0);
     }
 
-    public void putFromStream( InputStream stream, String destination )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
-        Resource resource = new Resource( destination );
+    public void putFromStream(InputStream stream, String destination)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
+        Resource resource = new Resource(destination);
 
-        firePutInitiated( resource, null );
+        firePutInitiated(resource, null);
 
-        putFromStream( stream, resource );
+        putFromStream(stream, resource);
     }
 
-    public void putFromStream( InputStream stream, String destination, long contentLength, long lastModified )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
-        Resource resource = new Resource( destination );
+    public void putFromStream(InputStream stream, String destination, long contentLength, long lastModified)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
+        Resource resource = new Resource(destination);
 
-        firePutInitiated( resource, null );
+        firePutInitiated(resource, null);
 
-        resource.setContentLength( contentLength );
+        resource.setContentLength(contentLength);
 
-        resource.setLastModified( lastModified );
+        resource.setLastModified(lastModified);
 
-        putFromStream( stream, resource );
+        putFromStream(stream, resource);
     }
 
-    protected void putFromStream( InputStream stream, Resource resource )
-        throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException
-    {
-        OutputStream os = getOutputStream( resource );
+    protected void putFromStream(InputStream stream, Resource resource)
+            throws TransferFailedException, AuthorizationException, ResourceDoesNotExistException {
+        OutputStream os = getOutputStream(resource);
 
-        checkOutputStream( resource, os );
+        checkOutputStream(resource, os);
 
-        firePutStarted( resource, null );
+        firePutStarted(resource, null);
 
-        putTransfer( resource, stream, os, true );
+        putTransfer(resource, stream, os, true);
 
-        firePutCompleted( resource, null );
+        firePutCompleted(resource, null);
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamingWagon.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamingWagon.java
index a6208f22..3ddbdbfa 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamingWagon.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/StreamingWagon.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.InputStream;
 import java.io.OutputStream;
@@ -25,28 +24,26 @@ import java.io.OutputStream;
 import org.apache.maven.wagon.authorization.AuthorizationException;
 
 /**
- * 
+ *
  */
-public interface StreamingWagon
-    extends Wagon
-{
+public interface StreamingWagon extends Wagon {
     /**
      * Downloads specified resource from the repository to given output stream.
-     * 
+     *
      * @param resourceName
      * @param stream
      * @throws TransferFailedException
      * @throws ResourceDoesNotExistException
-     * @throws AuthorizationException 
+     * @throws AuthorizationException
      * @throws AuthorizationException
      */
-    void getToStream( String resourceName, OutputStream stream )
-        throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException;
+    void getToStream(String resourceName, OutputStream stream)
+            throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException;
 
     /**
      * Downloads specified resource from the repository if it was modified since specified date. The date is measured in
      * milliseconds, between the current time and midnight, January 1, 1970 UTC and aligned to GMT timezone.
-     * 
+     *
      * @param resourceName
      * @param stream
      * @param timestamp
@@ -54,36 +51,36 @@ public interface StreamingWagon
      *         repository is older or has the same age.
      * @throws TransferFailedException
      * @throws ResourceDoesNotExistException
-     * @throws AuthorizationException 
+     * @throws AuthorizationException
      * @throws AuthorizationException
      */
-    boolean getIfNewerToStream( String resourceName, OutputStream stream, long timestamp )
-        throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException;
+    boolean getIfNewerToStream(String resourceName, OutputStream stream, long timestamp)
+            throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException;
 
     /**
      * @deprecated due to unknown contentLength various http(s) implementation will use a chuncked transfer encoding
      *             mode you must take care you http target server supports that (ngnix don't !).
      *             <b>So in case of http(s) transport layer avoid using this. Will be remove in 3.0</b>
      * Copy from a local input stream to remote.
-     * 
+     *
      * @param stream the local stream
      * @param destination the remote destination
      * @throws TransferFailedException
      * @throws ResourceDoesNotExistException
      * @throws AuthorizationException
      */
-    void putFromStream( InputStream stream, String destination )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    void putFromStream(InputStream stream, String destination)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 
     /**
      * Copy from a local input stream to remote.
-     * 
+     *
      * @param stream the local stream
      * @param destination the remote destination
      * @throws TransferFailedException
      * @throws ResourceDoesNotExistException
      * @throws AuthorizationException
      */
-    void putFromStream( InputStream stream, String destination, long contentLength, long lastModified )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    void putFromStream(InputStream stream, String destination, long contentLength, long lastModified)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/Streams.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/Streams.java
index a3d09d82..e7d06cbb 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/Streams.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/Streams.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,33 +16,29 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
- * 
+ *
  */
-public class Streams
-{
+public class Streams {
     private String out = "";
 
     private String err = "";
 
-    public String getOut()
-    {
+    public String getOut() {
         return out;
     }
 
-    public void setOut( String out )
-    {
+    public void setOut(String out) {
         this.out = out;
     }
 
-    public String getErr()
-    {
+    public String getErr() {
         return err;
     }
 
-    public void setErr( String err )
-    {
+    public void setErr(String err) {
         this.err = err;
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/TransferFailedException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/TransferFailedException.java
index 9f8f9a8b..a5be7bab 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/TransferFailedException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/TransferFailedException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * Exception which should be thrown when IO error occurred during
@@ -26,24 +25,19 @@ package org.apache.maven.wagon;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class TransferFailedException
-    extends WagonException
-{
+public class TransferFailedException extends WagonException {
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public TransferFailedException( final String message )
-    {
-        super( message );
+    public TransferFailedException(final String message) {
+        super(message);
     }
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public TransferFailedException( final String message, final Throwable cause )
-    {
-        super( message, cause );
+    public TransferFailedException(final String message, final Throwable cause) {
+        super(message, cause);
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/UnsupportedProtocolException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/UnsupportedProtocolException.java
index 73b1a880..be5fe2ec 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/UnsupportedProtocolException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/UnsupportedProtocolException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * This exception is thrown when no Wagon provider is supporting protocol required by some repository
@@ -25,26 +24,19 @@ package org.apache.maven.wagon;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class UnsupportedProtocolException
-    extends WagonException
-{
-
+public class UnsupportedProtocolException extends WagonException {
 
     /**
      * @see WagonException
      */
-    public UnsupportedProtocolException( final String message )
-    {
-        super( message );
+    public UnsupportedProtocolException(final String message) {
+        super(message);
     }
 
     /**
      * @see WagonException
      */
-    public UnsupportedProtocolException( final String message, final Throwable cause )
-    {
-        super( message, cause );
+    public UnsupportedProtocolException(final String message, final Throwable cause) {
+        super(message, cause);
     }
-
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/Wagon.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/Wagon.java
index 0b767289..5da75175 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/Wagon.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/Wagon.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,10 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
+
+import java.io.File;
+import java.util.List;
 
 import org.apache.maven.wagon.authentication.AuthenticationException;
 import org.apache.maven.wagon.authentication.AuthenticationInfo;
@@ -28,14 +30,10 @@ import org.apache.maven.wagon.proxy.ProxyInfo;
 import org.apache.maven.wagon.proxy.ProxyInfoProvider;
 import org.apache.maven.wagon.repository.Repository;
 
-import java.io.File;
-import java.util.List;
-
 /**
- * 
+ *
  */
-public interface Wagon
-{
+public interface Wagon {
     String ROLE = Wagon.class.getName();
 
     /**
@@ -63,8 +61,8 @@ public interface Wagon
      * @throws ResourceDoesNotExistException
      * @throws AuthorizationException
      */
-    void get( String resourceName, File destination )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    void get(String resourceName, File destination)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 
     /**
      * Downloads specified resource from the repository
@@ -81,8 +79,8 @@ public interface Wagon
      * @throws ResourceDoesNotExistException
      * @throws AuthorizationException
      */
-    boolean getIfNewer( String resourceName, File destination, long timestamp )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    boolean getIfNewer(String resourceName, File destination, long timestamp)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 
     /**
      * Copy a file from local system to remote
@@ -93,8 +91,8 @@ public interface Wagon
      * @throws ResourceDoesNotExistException
      * @throws AuthorizationException
      */
-    void put( File source, String destination )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    void put(File source, String destination)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 
     /**
      * Copy a directory from local system to remote
@@ -105,8 +103,8 @@ public interface Wagon
      * @throws ResourceDoesNotExistException
      * @throws AuthorizationException
      */
-    void putDirectory( File sourceDirectory, String destinationDirectory )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    void putDirectory(File sourceDirectory, String destinationDirectory)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 
     /**
      * Check if a remote resource exists
@@ -116,8 +114,7 @@ public interface Wagon
      * @throws TransferFailedException if there's an error trying to access the remote side
      * @throws AuthorizationException  if not authorized to verify the existence of the resource
      */
-    boolean resourceExists( String resourceName )
-        throws TransferFailedException, AuthorizationException;
+    boolean resourceExists(String resourceName) throws TransferFailedException, AuthorizationException;
 
     /**
      * <p/>
@@ -143,8 +140,8 @@ public interface Wagon
      * @throws ResourceDoesNotExistException if destinationDirectory does not exist or is not a directory
      * @throws AuthorizationException        if not authorized to list the contents of the directory
      */
-    List<String> getFileList( String destinationDirectory )
-        throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
+    List<String> getFileList(String destinationDirectory)
+            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException;
 
     /**
      * Flag indicating if this wagon supports directory copy operations.
@@ -167,8 +164,7 @@ public interface Wagon
      * @throws org.apache.maven.wagon.authentication.AuthenticationException
      *                             if the credentials for connecting are not sufficient
      */
-    void connect( Repository source )
-        throws ConnectionException, AuthenticationException;
+    void connect(Repository source) throws ConnectionException, AuthenticationException;
 
     /**
      * Initiate the connection to the repository.
@@ -178,8 +174,7 @@ public interface Wagon
      * @throws org.apache.maven.wagon.authentication.AuthenticationException
      *                             if the credentials for connecting are not sufficient
      */
-    void connect( Repository source, ProxyInfo proxyInfo )
-        throws ConnectionException, AuthenticationException;
+    void connect(Repository source, ProxyInfo proxyInfo) throws ConnectionException, AuthenticationException;
 
     /**
      * Initiate the connection to the repository.
@@ -190,8 +185,8 @@ public interface Wagon
      * @throws org.apache.maven.wagon.authentication.AuthenticationException
      *                             if the credentials for connecting are not sufficient
      */
-    void connect( Repository source, ProxyInfoProvider proxyInfoProvider )
-        throws ConnectionException, AuthenticationException;
+    void connect(Repository source, ProxyInfoProvider proxyInfoProvider)
+            throws ConnectionException, AuthenticationException;
 
     /**
      * Initiate the connection to the repository.
@@ -202,8 +197,8 @@ public interface Wagon
      * @throws org.apache.maven.wagon.authentication.AuthenticationException
      *                             if the credentials for connecting are not sufficient
      */
-    void connect( Repository source, AuthenticationInfo authenticationInfo )
-        throws ConnectionException, AuthenticationException;
+    void connect(Repository source, AuthenticationInfo authenticationInfo)
+            throws ConnectionException, AuthenticationException;
 
     /**
      * Initiate the connection to the repository.
@@ -215,8 +210,8 @@ public interface Wagon
      * @throws org.apache.maven.wagon.authentication.AuthenticationException
      *                             if the credentials for connecting are not sufficient
      */
-    void connect( Repository source, AuthenticationInfo authenticationInfo, ProxyInfo proxyInfo )
-        throws ConnectionException, AuthenticationException;
+    void connect(Repository source, AuthenticationInfo authenticationInfo, ProxyInfo proxyInfo)
+            throws ConnectionException, AuthenticationException;
 
     /**
      * Initiate the connection to the repository.
@@ -228,8 +223,8 @@ public interface Wagon
      * @throws org.apache.maven.wagon.authentication.AuthenticationException
      *                             if the credentials for connecting are not sufficient
      */
-    void connect( Repository source, AuthenticationInfo authenticationInfo, ProxyInfoProvider proxyInfoProvider )
-        throws ConnectionException, AuthenticationException;
+    void connect(Repository source, AuthenticationInfo authenticationInfo, ProxyInfoProvider proxyInfoProvider)
+            throws ConnectionException, AuthenticationException;
 
     /**
      * Initiate the connection to the repository.
@@ -241,22 +236,20 @@ public interface Wagon
      * @deprecated connect using the {@link #connect(org.apache.maven.wagon.repository.Repository)} or related methods
      *             - this is an internal method
      */
-    void openConnection()
-        throws ConnectionException, AuthenticationException;
+    void openConnection() throws ConnectionException, AuthenticationException;
 
     /**
      * Disconnect from the repository.
      *
      * @throws ConnectionException if there is a problem disconnecting
      */
-    void disconnect()
-        throws ConnectionException;
-    
+    void disconnect() throws ConnectionException;
+
     /**
      * Set the connection timeout limit in milliseconds
      */
-    void setTimeout( int timeoutValue );
-    
+    void setTimeout(int timeoutValue);
+
     /**
      * Get the connection timeout limit in milliseconds
      */
@@ -266,7 +259,7 @@ public interface Wagon
      * Set the read timeout limit in milliseconds
      * @since 2.2
      */
-    void setReadTimeout( int timeoutValue );
+    void setReadTimeout(int timeoutValue);
 
     /**
      * Get the read timeout limit in milliseconds
@@ -278,23 +271,23 @@ public interface Wagon
     //  Session listener
     // ----------------------------------------------------------------------
 
-    void addSessionListener( SessionListener listener );
+    void addSessionListener(SessionListener listener);
 
-    void removeSessionListener( SessionListener listener );
+    void removeSessionListener(SessionListener listener);
 
-    boolean hasSessionListener( SessionListener listener );
+    boolean hasSessionListener(SessionListener listener);
 
     // ----------------------------------------------------------------------
     // Transfer listener
     // ----------------------------------------------------------------------
 
-    void addTransferListener( TransferListener listener );
+    void addTransferListener(TransferListener listener);
 
-    void removeTransferListener( TransferListener listener );
+    void removeTransferListener(TransferListener listener);
 
-    boolean hasTransferListener( TransferListener listener );
+    boolean hasTransferListener(TransferListener listener);
 
     boolean isInteractive();
 
-    void setInteractive( boolean interactive );
+    void setInteractive(boolean interactive);
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonConstants.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonConstants.java
index 27b66b1d..042b7985 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonConstants.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonConstants.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * This class contains constants used in Wagon API.
@@ -25,8 +24,7 @@ package org.apache.maven.wagon;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public final class WagonConstants
-{
+public final class WagonConstants {
     /**
      * Indicates that port has not been set.
      */
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonException.java
index 25dc053f..23f6c898 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 /**
  * Root class for all exception in Wagon API
@@ -25,15 +24,12 @@ package org.apache.maven.wagon;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public abstract class WagonException
-    extends Exception
-{
+public abstract class WagonException extends Exception {
     /**
      * the throwable that caused this exception to get thrown
      */
     private Throwable cause;
 
-
     /**
      * Constructs a new WagonException with the specified detail message.
      * The cause is not initialized, and may subsequently be initialized by a call to initCause
@@ -42,10 +38,9 @@ public abstract class WagonException
      * @param cause   - the cause (which is saved for later retrieval by the getCause() method).
      *                (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
      */
-    public WagonException( final String message, final Throwable cause )
-    {
-        super( message );
-        initCause( cause );
+    public WagonException(final String message, final Throwable cause) {
+        super(message);
+        initCause(cause);
     }
 
     /**
@@ -53,9 +48,8 @@ public abstract class WagonException
      *
      * @param message - the detail message (which is saved for later retrieval by the getMessage() method).
      */
-    public WagonException( final String message )
-    {
-        super( message );
+    public WagonException(final String message) {
+        super(message);
     }
 
     /**
@@ -64,26 +58,24 @@ public abstract class WagonException
      *
      * @return the cause of this exception or null if the cause is nonexistent or unknown.
      */
-    public Throwable getCause()
-    {
-//        try
-//        {
-//           Class clazz = getClass().getSuperclass();
-//           
-//           Method method = clazz.getMethod( "gatCause" , null );
-//           
-//           Throwable retValue = (Throwable) method.invoke( this, null );
-//         return retValue;
-//        }   
-//        catch( Exception e)
-//        {
-//        
-//        }
-        
+    public Throwable getCause() {
+        //        try
+        //        {
+        //           Class clazz = getClass().getSuperclass();
+        //
+        //           Method method = clazz.getMethod( "gatCause" , null );
+        //
+        //           Throwable retValue = (Throwable) method.invoke( this, null );
+        //         return retValue;
+        //        }
+        //        catch( Exception e)
+        //        {
+        //
+        //        }
+
         return cause;
     }
 
-
     /**
      * Initializes the cause of this throwable to the specified value.
      * (The cause is the throwable that caused this throwable to get thrown.)
@@ -94,23 +86,21 @@ public abstract class WagonException
      *
      * @return a reference to this Throwable instance.
      */
-    public Throwable initCause( final Throwable cause )
-    {
-//        try
-//        {
-//           Class clazz = getClass().getSuperclass();
-//           Class[] parameterTypes = new Class[1];
-//           parameterTypes[0] = Throwable.class;
-//           Method method = clazz.getMethod( "initCause" , parameterTypes);
-//           Object[] params = { cause };
-//           method.invoke( this, params );
-//        }   
-//        catch( Exception e)
-//        {
-//        
-//        }        
+    public Throwable initCause(final Throwable cause) {
+        //        try
+        //        {
+        //           Class clazz = getClass().getSuperclass();
+        //           Class[] parameterTypes = new Class[1];
+        //           parameterTypes[0] = Throwable.class;
+        //           Method method = clazz.getMethod( "initCause" , parameterTypes);
+        //           Object[] params = { cause };
+        //           method.invoke( this, params );
+        //        }
+        //        catch( Exception e)
+        //        {
+        //
+        //        }
         this.cause = cause;
         return this;
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonUtils.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonUtils.java
index 42634404..85ae8855 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonUtils.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/WagonUtils.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,105 +16,80 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
-
-import org.apache.maven.wagon.authorization.AuthorizationException;
-import org.codehaus.plexus.util.FileUtils;
+package org.apache.maven.wagon;
 
 import java.io.File;
 import java.io.IOException;
 import java.util.LinkedList;
 
+import org.apache.maven.wagon.authorization.AuthorizationException;
+import org.codehaus.plexus.util.FileUtils;
+
 /**
  * @author <a href="mailto:mmaczka@interia.pl">Michal Maczka</a>
  *
  * @deprecated
  */
-public final class WagonUtils
-{
-    private WagonUtils()
-    {
-    }
+public final class WagonUtils {
+    private WagonUtils() {}
 
-    public static String toString( String resource, Wagon wagon )
-        throws IOException, TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-    {
+    public static String toString(String resource, Wagon wagon)
+            throws IOException, TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
 
         File file = null;
 
-        try
-        {
-            file = File.createTempFile( "wagon", "tmp" );
+        try {
+            file = File.createTempFile("wagon", "tmp");
 
-            wagon.get( resource, file );
+            wagon.get(resource, file);
 
-            return FileUtils.fileRead( file );
-        }
-        finally
-        {
-            if ( file != null )
-            {
+            return FileUtils.fileRead(file);
+        } finally {
+            if (file != null) {
                 boolean deleted = file.delete();
 
-                if ( !deleted )
-                {
+                if (!deleted) {
                     file.deleteOnExit();
                 }
             }
         }
-
     }
 
-
-    public static void putDirectory( File dir, Wagon wagon, boolean includeBasdir )
-        throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException
-    {
+    public static void putDirectory(File dir, Wagon wagon, boolean includeBasdir)
+            throws ResourceDoesNotExistException, TransferFailedException, AuthorizationException {
 
         LinkedList queue = new LinkedList();
 
-        if ( includeBasdir )
-        {
-            queue.add( dir.getName() );
-        }
-        else
-        {
-            queue.add( "" );
+        if (includeBasdir) {
+            queue.add(dir.getName());
+        } else {
+            queue.add("");
         }
 
-        while ( !queue.isEmpty() )
-        {
+        while (!queue.isEmpty()) {
             String path = (String) queue.removeFirst();
 
-            File currentDir = new File( dir, path );
+            File currentDir = new File(dir, path);
 
             File[] files = currentDir.listFiles();
 
-            for ( int i = 0; i < files.length; i++ )
-            {
+            for (int i = 0; i < files.length; i++) {
                 File file = files[i];
 
                 String resource;
 
-                if ( path.length() > 0 )
-                {
+                if (path.length() > 0) {
                     resource = path + "/" + file.getName();
-                }
-                else
-                {
+                } else {
                     resource = file.getName();
                 }
 
-                if ( file.isDirectory() )
-                {
-                    queue.add( resource );
+                if (file.isDirectory()) {
+                    queue.add(resource);
+                } else {
+                    wagon.put(file, resource);
                 }
-                else
-                {
-                    wagon.put( file, resource );
-                }
-
             }
-
         }
-
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationException.java
index 9094c750..7656352b 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.authentication;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.authentication;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.authentication;
 
 import org.apache.maven.wagon.WagonException;
 
@@ -30,24 +29,19 @@ import org.apache.maven.wagon.WagonException;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class AuthenticationException
-    extends WagonException
-{
+public class AuthenticationException extends WagonException {
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public AuthenticationException( final String message )
-    {
-        super( message );
+    public AuthenticationException(final String message) {
+        super(message);
     }
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public AuthenticationException( final String message, final Throwable cause )
-    {
-        super( message, cause );
+    public AuthenticationException(final String message, final Throwable cause) {
+        super(message, cause);
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationInfo.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationInfo.java
index 6e927177..089f8bfe 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationInfo.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/authentication/AuthenticationInfo.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.authentication;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.authentication;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.authentication;
 
 import java.io.Serializable;
 
@@ -28,9 +27,7 @@ import java.io.Serializable;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class AuthenticationInfo
-    implements Serializable
-{
+public class AuthenticationInfo implements Serializable {
 
     /**
      * Username used to login to the host
@@ -59,8 +56,7 @@ public class AuthenticationInfo
      *
      * @return passphrase of the private key file
      */
-    public String getPassphrase()
-    {
+    public String getPassphrase() {
         return passphrase;
     }
 
@@ -69,8 +65,7 @@ public class AuthenticationInfo
      *
      * @param passphrase passphrase of the private key file
      */
-    public void setPassphrase( final String passphrase )
-    {
+    public void setPassphrase(final String passphrase) {
         this.passphrase = passphrase;
     }
 
@@ -79,8 +74,7 @@ public class AuthenticationInfo
      *
      * @return absolute path to private key
      */
-    public String getPrivateKey()
-    {
+    public String getPrivateKey() {
         return privateKey;
     }
 
@@ -89,8 +83,7 @@ public class AuthenticationInfo
      *
      * @param privateKey path to private key in local file system
      */
-    public void setPrivateKey( final String privateKey )
-    {
+    public void setPrivateKey(final String privateKey) {
         this.privateKey = privateKey;
     }
 
@@ -99,8 +92,7 @@ public class AuthenticationInfo
      *
      * @return password of user
      */
-    public String getPassword()
-    {
+    public String getPassword() {
         return password;
     }
 
@@ -109,8 +101,7 @@ public class AuthenticationInfo
      *
      * @param password password of the user
      */
-    public void setPassword( final String password )
-    {
+    public void setPassword(final String password) {
         this.password = password;
     }
 
@@ -119,8 +110,7 @@ public class AuthenticationInfo
      *
      * @return username at repository
      */
-    public String getUserName()
-    {
+    public String getUserName() {
         return userName;
     }
 
@@ -129,8 +119,7 @@ public class AuthenticationInfo
      *
      * @param userName the username used to access repository
      */
-    public void setUserName( final String userName )
-    {
+    public void setUserName(final String userName) {
         this.userName = userName;
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/authorization/AuthorizationException.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/authorization/AuthorizationException.java
index a3f93104..f0625af2 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/authorization/AuthorizationException.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/authorization/AuthorizationException.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.authorization;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.authorization;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.authorization;
 
 import org.apache.maven.wagon.WagonException;
 
@@ -28,26 +27,19 @@ import org.apache.maven.wagon.WagonException;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class AuthorizationException
-    extends WagonException
-{
-
+public class AuthorizationException extends WagonException {
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public AuthorizationException( final String message )
-    {
-        super( message );
+    public AuthorizationException(final String message) {
+        super(message);
     }
 
     /**
      * @see org.apache.maven.wagon.WagonException
      */
-    public AuthorizationException( final String message, final Throwable cause )
-    {
-        super( message, cause );
+    public AuthorizationException(final String message, final Throwable cause) {
+        super(message, cause);
     }
-
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEvent.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEvent.java
index 712ead61..c123aeda 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEvent.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEvent.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 import org.apache.maven.wagon.Wagon;
 
@@ -39,9 +38,7 @@ import org.apache.maven.wagon.Wagon;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class SessionEvent
-    extends WagonEvent
-{
+public class SessionEvent extends WagonEvent {
 
     /**
      * A SESSION was closed.
@@ -101,11 +98,9 @@ public class SessionEvent
      * @param wagon     <code>Wagon<code> object which created this event
      * @param eventType the type of the event
      */
-    public SessionEvent( final Wagon wagon, final int eventType )
-    {
-        super( wagon );
+    public SessionEvent(final Wagon wagon, final int eventType) {
+        super(wagon);
         this.eventType = eventType;
-
     }
 
     /**
@@ -114,37 +109,31 @@ public class SessionEvent
      * @param wagon     <code>Wagon<code> object which created this event
      * @param exception the exception
      */
-    public SessionEvent( final Wagon wagon, final Exception exception )
-    {
-        super( wagon );
+    public SessionEvent(final Wagon wagon, final Exception exception) {
+        super(wagon);
         this.exception = exception;
         this.eventType = SESSION_ERROR_OCCURRED;
-
     }
 
     /**
      * @return Returns the type.
      */
-    public int getEventType()
-    {
+    public int getEventType() {
         return eventType;
     }
 
     /**
      * @return Returns the exception.
      */
-    public Exception getException()
-    {
+    public Exception getException() {
         return exception;
     }
 
     /**
      * @param eventType The eventType to set.
      */
-    public void setEventType( final int eventType )
-    {
-        switch ( eventType )
-        {
+    public void setEventType(final int eventType) {
+        switch (eventType) {
             case SessionEvent.SESSION_CLOSED:
             case SessionEvent.SESSION_DISCONNECTED:
             case SessionEvent.SESSION_DISCONNECTING:
@@ -155,8 +144,8 @@ public class SessionEvent
             case SessionEvent.SESSION_OPENING:
             case SessionEvent.SESSION_CONNECTION_REFUSED:
                 break;
-            default :
-                throw new IllegalArgumentException( "Illegal event type: " + eventType );
+            default:
+                throw new IllegalArgumentException("Illegal event type: " + eventType);
         }
         this.eventType = eventType;
     }
@@ -164,62 +153,58 @@ public class SessionEvent
     /**
      * @param exception The exception to set.
      */
-    public void setException( final Exception exception )
-    {
+    public void setException(final Exception exception) {
         this.exception = exception;
     }
 
-    public String toString()
-    {
+    public String toString() {
         StringBuilder sb = new StringBuilder();
 
-        sb.append( "SessionEvent[" );
+        sb.append("SessionEvent[");
 
-        switch ( this.eventType )
-        {
+        switch (this.eventType) {
             case SessionEvent.SESSION_CLOSED:
-                sb.append( "CONNECTION_CLOSED" );
+                sb.append("CONNECTION_CLOSED");
                 break;
             case SessionEvent.SESSION_DISCONNECTED:
-                sb.append( "CONNECTION_DISCONNECTED" );
+                sb.append("CONNECTION_DISCONNECTED");
                 break;
             case SessionEvent.SESSION_DISCONNECTING:
-                sb.append( "CONNECTION_DISCONNECTING" );
+                sb.append("CONNECTION_DISCONNECTING");
                 break;
             case SessionEvent.SESSION_ERROR_OCCURRED:
-                sb.append( "CONNECTION_ERROR_OCCURRED" );
+                sb.append("CONNECTION_ERROR_OCCURRED");
                 break;
             case SessionEvent.SESSION_LOGGED_IN:
-                sb.append( "CONNECTION_LOGGED_IN" );
+                sb.append("CONNECTION_LOGGED_IN");
                 break;
             case SessionEvent.SESSION_LOGGED_OFF:
-                sb.append( "CONNECTION_LOGGED_OFF" );
+                sb.append("CONNECTION_LOGGED_OFF");
                 break;
             case SessionEvent.SESSION_OPENED:
-                sb.append( "CONNECTION_OPENED" );
+                sb.append("CONNECTION_OPENED");
                 break;
             case SessionEvent.SESSION_OPENING:
-                sb.append( "CONNECTION_OPENING" );
+                sb.append("CONNECTION_OPENING");
                 break;
             case SessionEvent.SESSION_CONNECTION_REFUSED:
-                sb.append( "CONNECTION_CONNECTION_REFUSED" );
+                sb.append("CONNECTION_CONNECTION_REFUSED");
                 break;
             default:
-                sb.append( eventType );
+                sb.append(eventType);
         }
-        sb.append( "|" );
+        sb.append("|");
 
-        sb.append( this.getWagon().getRepository() ).append( "|" );
-        sb.append( this.source );
+        sb.append(this.getWagon().getRepository()).append("|");
+        sb.append(this.source);
 
-        if ( exception != null )
-        {
-            sb.append( "|" );
-            sb.append( exception.getClass().getName() ).append( ":" );
-            sb.append( exception.getMessage() );
+        if (exception != null) {
+            sb.append("|");
+            sb.append(exception.getClass().getName()).append(":");
+            sb.append(exception.getMessage());
         }
 
-        sb.append( "]" );
+        sb.append("]");
 
         return sb.toString();
     }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEventSupport.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEventSupport.java
index efe95d04..cd2b6640 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEventSupport.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionEventSupport.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -28,8 +27,7 @@ import java.util.List;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public final class SessionEventSupport
-{
+public final class SessionEventSupport {
     /**
      * registered listeners
      */
@@ -46,11 +44,9 @@ public final class SessionEventSupport
      * @see #removeSessionListener(SessionListener)
      * @see TransferListener
      */
-    public void addSessionListener( final SessionListener listener )
-    {
-        if ( listener != null )
-        {
-            listeners.add( listener );
+    public void addSessionListener(final SessionListener listener) {
+        if (listener != null) {
+            listeners.add(listener);
         }
     }
 
@@ -65,9 +61,8 @@ public final class SessionEventSupport
      * @param listener the session listener
      * @see #addSessionListener(org.apache.maven.wagon.events.SessionListener)
      */
-    public void removeSessionListener( final SessionListener listener )
-    {
-        listeners.remove( listener );
+    public void removeSessionListener(final SessionListener listener) {
+        listeners.remove(listener);
     }
 
     /**
@@ -82,9 +77,8 @@ public final class SessionEventSupport
      * @see org.apache.maven.wagon.events.SessionListener
      * @see #addSessionListener(org.apache.maven.wagon.events.SessionListener)
      */
-    public boolean hasSessionListener( final SessionListener listener )
-    {
-        return listeners.contains( listener );
+    public boolean hasSessionListener(final SessionListener listener) {
+        return listeners.contains(listener);
     }
 
     /**
@@ -94,11 +88,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionDisconnected( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionDisconnected( sessionEvent );
+    public void fireSessionDisconnected(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionDisconnected(sessionEvent);
         }
     }
 
@@ -109,11 +101,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionDisconnecting( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionDisconnecting( sessionEvent );
+    public void fireSessionDisconnecting(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionDisconnecting(sessionEvent);
         }
     }
 
@@ -124,11 +114,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionLoggedIn( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionLoggedIn( sessionEvent );
+    public void fireSessionLoggedIn(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionLoggedIn(sessionEvent);
         }
     }
 
@@ -139,11 +127,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionLoggedOff( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionLoggedOff( sessionEvent );
+    public void fireSessionLoggedOff(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionLoggedOff(sessionEvent);
         }
     }
 
@@ -154,11 +140,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionOpened( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionOpened( sessionEvent );
+    public void fireSessionOpened(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionOpened(sessionEvent);
         }
     }
 
@@ -169,11 +153,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionOpening( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionOpening( sessionEvent );
+    public void fireSessionOpening(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionOpening(sessionEvent);
         }
     }
 
@@ -184,11 +166,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionConnectionRefused( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionConnectionRefused( sessionEvent );
+    public void fireSessionConnectionRefused(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionConnectionRefused(sessionEvent);
         }
     }
 
@@ -198,11 +178,9 @@ public final class SessionEventSupport
      *
      * @param message the debug message which will be dispatched to listeners
      */
-    public void fireDebug( final String message )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.debug( message );
+    public void fireDebug(final String message) {
+        for (SessionListener listener : listeners) {
+            listener.debug(message);
         }
     }
 
@@ -214,11 +192,9 @@ public final class SessionEventSupport
      *
      * @param sessionEvent the SessionEvent which will be dispatched to listeners
      */
-    public void fireSessionError( final SessionEvent sessionEvent )
-    {
-        for ( SessionListener listener : listeners )
-        {
-            listener.sessionError( sessionEvent );
+    public void fireSessionError(final SessionEvent sessionEvent) {
+        for (SessionListener listener : listeners) {
+            listener.sessionError(sessionEvent);
         }
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionListener.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionListener.java
index d60c71d3..48e030f3 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionListener.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/SessionListener.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 /**
  * Interface for classes which wants to receive and respond to any session update events.
@@ -25,8 +24,7 @@ package org.apache.maven.wagon.events;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public interface SessionListener
-{
+public interface SessionListener {
 
     /**
      * This method will be called when Wagon is about to open
@@ -36,7 +34,7 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionOpening( SessionEvent sessionEvent );
+    void sessionOpening(SessionEvent sessionEvent);
 
     /**
      * This method will be called when Wagon has successfully connected to
@@ -46,7 +44,7 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionOpened( SessionEvent sessionEvent );
+    void sessionOpened(SessionEvent sessionEvent);
 
     /**
      * This method will be called when Wagon has closed connection to
@@ -56,7 +54,7 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionDisconnecting( SessionEvent sessionEvent );
+    void sessionDisconnecting(SessionEvent sessionEvent);
 
     /**
      * This method will be called when Wagon has closed connection to
@@ -66,7 +64,7 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionDisconnected( SessionEvent sessionEvent );
+    void sessionDisconnected(SessionEvent sessionEvent);
 
     /**
      * This method will be called when Wagon when connection to
@@ -77,7 +75,7 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionConnectionRefused( SessionEvent sessionEvent );
+    void sessionConnectionRefused(SessionEvent sessionEvent);
 
     /**
      * This method will be called by Wagon when Wagon managed
@@ -85,7 +83,7 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionLoggedIn( SessionEvent sessionEvent );
+    void sessionLoggedIn(SessionEvent sessionEvent);
 
     /**
      * This method will be called by Wagon has logged off
@@ -96,7 +94,7 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionLoggedOff( SessionEvent sessionEvent );
+    void sessionLoggedOff(SessionEvent sessionEvent);
 
     /**
      * This method will be called by Wagon when an error occurred.
@@ -106,13 +104,12 @@ public interface SessionListener
      *
      * @param sessionEvent the session event
      */
-    void sessionError( SessionEvent sessionEvent );
+    void sessionError(SessionEvent sessionEvent);
 
     /**
      * This method allows to send arbitrary debug messages.
      *
      * @param message the debug message
      */
-    void debug( String message );
-
-}
\ No newline at end of file
+    void debug(String message);
+}
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEvent.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEvent.java
index ac3a7119..0d1c2076 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEvent.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEvent.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,12 +16,13 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
+
+import java.io.File;
 
 import org.apache.maven.wagon.Wagon;
 import org.apache.maven.wagon.resource.Resource;
 
-import java.io.File;
-
 /**
  * TransferEvent is used to notify TransferListeners about progress
  * in transfer of resources form/to the repository
@@ -31,9 +30,7 @@ import java.io.File;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class TransferEvent
-    extends WagonEvent
-{
+public class TransferEvent extends WagonEvent {
 
     /**
      * A transfer was attempted, but has not yet commenced.
@@ -80,21 +77,18 @@ public class TransferEvent
 
     private File localFile;
 
-    public TransferEvent( final Wagon wagon, final Resource resource, final int eventType, final int requestType )
-    {
-        super( wagon );
+    public TransferEvent(final Wagon wagon, final Resource resource, final int eventType, final int requestType) {
+        super(wagon);
 
         this.resource = resource;
 
-        setEventType( eventType );
-
-        setRequestType( requestType );
+        setEventType(eventType);
 
+        setRequestType(requestType);
     }
 
-    public TransferEvent( final Wagon wagon, final Resource resource, final Exception exception, final int requestType )
-    {
-        this( wagon, resource, TRANSFER_ERROR, requestType );
+    public TransferEvent(final Wagon wagon, final Resource resource, final Exception exception, final int requestType) {
+        this(wagon, resource, TRANSFER_ERROR, requestType);
 
         this.exception = exception;
     }
@@ -102,16 +96,14 @@ public class TransferEvent
     /**
      * @return Returns the resource.
      */
-    public Resource getResource()
-    {
+    public Resource getResource() {
         return resource;
     }
 
     /**
      * @return Returns the exception.
      */
-    public Exception getException()
-    {
+    public Exception getException() {
         return exception;
     }
 
@@ -121,8 +113,7 @@ public class TransferEvent
      * @return Returns the request type. The Request type is one of
      *         <code>TransferEvent.REQUEST_GET<code> or <code>TransferEvent.REQUEST_PUT<code>
      */
-    public int getRequestType()
-    {
+    public int getRequestType() {
         return requestType;
     }
 
@@ -134,17 +125,14 @@ public class TransferEvent
      *                    <code>TransferEvent.REQUEST_GET<code> or <code>TransferEvent.REQUEST_PUT<code>.
      * @throws IllegalArgumentException when
      */
-    public void setRequestType( final int requestType )
-    {
-        switch ( requestType )
-        {
-
+    public void setRequestType(final int requestType) {
+        switch (requestType) {
             case REQUEST_PUT:
             case REQUEST_GET:
                 break;
 
-            default :
-                throw new IllegalArgumentException( "Illegal request type: " + requestType );
+            default:
+                throw new IllegalArgumentException("Illegal request type: " + requestType);
         }
 
         this.requestType = requestType;
@@ -153,27 +141,23 @@ public class TransferEvent
     /**
      * @return Returns the eventType.
      */
-    public int getEventType()
-    {
+    public int getEventType() {
         return eventType;
     }
 
     /**
      * @param eventType The eventType to set.
      */
-    public void setEventType( final int eventType )
-    {
-        switch ( eventType )
-        {
-
+    public void setEventType(final int eventType) {
+        switch (eventType) {
             case TRANSFER_INITIATED:
             case TRANSFER_STARTED:
             case TRANSFER_COMPLETED:
             case TRANSFER_PROGRESS:
             case TRANSFER_ERROR:
                 break;
-            default :
-                throw new IllegalArgumentException( "Illegal event type: " + eventType );
+            default:
+                throw new IllegalArgumentException("Illegal event type: " + eventType);
         }
 
         this.eventType = eventType;
@@ -182,137 +166,114 @@ public class TransferEvent
     /**
      * @param resource The resource to set.
      */
-    public void setResource( final Resource resource )
-    {
+    public void setResource(final Resource resource) {
         this.resource = resource;
     }
 
     /**
      * @return Returns the local file.
      */
-    public File getLocalFile()
-    {
+    public File getLocalFile() {
         return localFile;
     }
 
     /**
      * @param localFile The local file to set.
      */
-    public void setLocalFile( File localFile )
-    {
+    public void setLocalFile(File localFile) {
         this.localFile = localFile;
     }
 
-    public String toString()
-    {
+    public String toString() {
         StringBuilder sb = new StringBuilder();
 
-        sb.append( "TransferEvent[" );
+        sb.append("TransferEvent[");
 
-        switch ( this.getRequestType() )
-        {
+        switch (this.getRequestType()) {
             case REQUEST_GET:
-                sb.append( "GET" );
+                sb.append("GET");
                 break;
             case REQUEST_PUT:
-                sb.append( "PUT" );
+                sb.append("PUT");
                 break;
             default:
-                sb.append( this.getRequestType() );
+                sb.append(this.getRequestType());
                 break;
         }
 
-        sb.append( "|" );
-        switch ( this.getEventType() )
-        {
+        sb.append("|");
+        switch (this.getEventType()) {
             case TRANSFER_COMPLETED:
-                sb.append( "COMPLETED" );
+                sb.append("COMPLETED");
                 break;
             case TRANSFER_ERROR:
-                sb.append( "ERROR" );
+                sb.append("ERROR");
                 break;
             case TRANSFER_INITIATED:
-                sb.append( "INITIATED" );
+                sb.append("INITIATED");
                 break;
             case TRANSFER_PROGRESS:
-                sb.append( "PROGRESS" );
+                sb.append("PROGRESS");
                 break;
             case TRANSFER_STARTED:
-                sb.append( "STARTED" );
+                sb.append("STARTED");
                 break;
             default:
-                sb.append( this.getEventType() );
+                sb.append(this.getEventType());
                 break;
         }
 
-        sb.append( "|" );
+        sb.append("|");
 
-        sb.append( this.getWagon().getRepository() ).append( "|" );
-        sb.append( this.getLocalFile() ).append( "|" );
-        sb.append( this.getResource().inspect() );
-        sb.append( "]" );
+        sb.append(this.getWagon().getRepository()).append("|");
+        sb.append(this.getLocalFile()).append("|");
+        sb.append(this.getResource().inspect());
+        sb.append("]");
 
         return sb.toString();
     }
 
-    public int hashCode()
-    {
+    public int hashCode() {
         final int prime = 31;
         int result = 1;
         result = prime * result + eventType;
-        result = prime * result + ( ( exception == null ) ? 0 : exception.hashCode() );
-        result = prime * result + ( ( localFile == null ) ? 0 : localFile.hashCode() );
+        result = prime * result + ((exception == null) ? 0 : exception.hashCode());
+        result = prime * result + ((localFile == null) ? 0 : localFile.hashCode());
         result = prime * result + requestType;
-        result = prime * result + ( ( resource == null ) ? 0 : resource.hashCode() );
+        result = prime * result + ((resource == null) ? 0 : resource.hashCode());
         return result;
     }
 
-    public boolean equals( Object obj )
-    {
-        if ( this == obj )
-        {
+    public boolean equals(Object obj) {
+        if (this == obj) {
             return true;
         }
-        if ( ( obj == null ) || ( getClass() != obj.getClass() ) )
-        {
+        if ((obj == null) || (getClass() != obj.getClass())) {
             return false;
         }
         final TransferEvent other = (TransferEvent) obj;
-        if ( eventType != other.eventType )
-        {
+        if (eventType != other.eventType) {
             return false;
         }
-        if ( exception == null )
-        {
-            if ( other.exception != null )
-            {
+        if (exception == null) {
+            if (other.exception != null) {
                 return false;
             }
-        }
-        else if ( !exception.getClass().equals( other.exception.getClass() ) )
-        {
+        } else if (!exception.getClass().equals(other.exception.getClass())) {
             return false;
         }
-        if ( requestType != other.requestType )
-        {
+        if (requestType != other.requestType) {
             return false;
         }
-        if ( resource == null )
-        {
-            if ( other.resource != null )
-            {
+        if (resource == null) {
+            if (other.resource != null) {
                 return false;
             }
-        }
-        else if ( !resource.equals( other.resource ) )
-        {
+        } else if (!resource.equals(other.resource)) {
             return false;
-        }
-        else if ( !source.equals( other.source ) )
-        {
+        } else if (!source.equals(other.source)) {
             return false;
         }
         return true;
     }
-    
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEventSupport.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEventSupport.java
index ff5531e0..1132d62d 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEventSupport.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferEventSupport.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -29,8 +28,7 @@ import java.util.List;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public final class TransferEventSupport
-{
+public final class TransferEventSupport {
 
     /**
      * registered listeners
@@ -48,11 +46,9 @@ public final class TransferEventSupport
      * @see #removeTransferListener(org.apache.maven.wagon.events.TransferListener)
      * @see TransferListener
      */
-    public synchronized void addTransferListener( final TransferListener listener )
-    {
-        if ( listener != null )
-        {
-            listeners.add( listener );
+    public synchronized void addTransferListener(final TransferListener listener) {
+        if (listener != null) {
+            listeners.add(listener);
         }
     }
 
@@ -67,9 +63,8 @@ public final class TransferEventSupport
      * @param listener the transfer listener
      * @see #addTransferListener(TransferListener)
      */
-    public synchronized void removeTransferListener( final TransferListener listener )
-    {
-        listeners.remove( listener );
+    public synchronized void removeTransferListener(final TransferListener listener) {
+        listeners.remove(listener);
     }
 
     /**
@@ -84,12 +79,10 @@ public final class TransferEventSupport
      * @see org.apache.maven.wagon.events.TransferEvent
      * @see #addTransferListener(TransferListener)
      */
-    public synchronized boolean hasTransferListener( final TransferListener listener )
-    {
-        return listeners.contains( listener );
+    public synchronized boolean hasTransferListener(final TransferListener listener) {
+        return listeners.contains(listener);
     }
 
-
     /**
      * Dispatches the given <code>TransferEvent</code>
      * to all registered listeners (calls method {@link TransferListener#transferStarted(TransferEvent)} on all of
@@ -97,11 +90,9 @@ public final class TransferEventSupport
      *
      * @param transferEvent the TransferEvent which will be dispatched to listeners
      */
-    public synchronized void fireTransferStarted( final TransferEvent transferEvent )
-    {
-        for ( TransferListener listener : listeners )
-        {
-            listener.transferStarted( transferEvent );
+    public synchronized void fireTransferStarted(final TransferEvent transferEvent) {
+        for (TransferListener listener : listeners) {
+            listener.transferStarted(transferEvent);
         }
     }
 
@@ -114,12 +105,9 @@ public final class TransferEventSupport
      * @param buffer        the buffer containing the additional content
      * @param length        the length of the content in the buffer
      */
-    public synchronized void fireTransferProgress( final TransferEvent transferEvent, byte[] buffer, int length )
-    {
-        for ( TransferListener listener : listeners )
-        {
-            listener.transferProgress( transferEvent, buffer, length );
-
+    public synchronized void fireTransferProgress(final TransferEvent transferEvent, byte[] buffer, int length) {
+        for (TransferListener listener : listeners) {
+            listener.transferProgress(transferEvent, buffer, length);
         }
     }
 
@@ -130,12 +118,9 @@ public final class TransferEventSupport
      *
      * @param transferEvent the TransferEvent which will be dispatched to listeners
      */
-    public synchronized void fireTransferCompleted( final TransferEvent transferEvent )
-    {
-        for ( TransferListener listener : listeners )
-        {
-            listener.transferCompleted( transferEvent );
-
+    public synchronized void fireTransferCompleted(final TransferEvent transferEvent) {
+        for (TransferListener listener : listeners) {
+            listener.transferCompleted(transferEvent);
         }
     }
 
@@ -147,12 +132,9 @@ public final class TransferEventSupport
      *
      * @param transferEvent the TransferEvent which will be dispatched to listeners
      */
-    public synchronized void fireTransferError( final TransferEvent transferEvent )
-    {
-        for ( TransferListener listener : listeners )
-        {
-            listener.transferError( transferEvent );
-
+    public synchronized void fireTransferError(final TransferEvent transferEvent) {
+        for (TransferListener listener : listeners) {
+            listener.transferError(transferEvent);
         }
     }
 
@@ -162,13 +144,10 @@ public final class TransferEventSupport
      *
      * @param message the debug message which will be dispatched to listeners
      */
-    public synchronized void fireDebug( final String message )
-    {
-
-        for ( TransferListener listener : listeners )
-        {
-            listener.debug( message );
+    public synchronized void fireDebug(final String message) {
 
+        for (TransferListener listener : listeners) {
+            listener.debug(message);
         }
     }
 
@@ -179,11 +158,9 @@ public final class TransferEventSupport
      *
      * @param transferEvent the TransferEvent which will be dispatched to listeners
      */
-    public synchronized void fireTransferInitiated( final TransferEvent transferEvent )
-    {
-        for ( TransferListener listener : listeners )
-        {
-            listener.transferInitiated( transferEvent );
+    public synchronized void fireTransferInitiated(final TransferEvent transferEvent) {
+        for (TransferListener listener : listeners) {
+            listener.transferInitiated(transferEvent);
         }
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferListener.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferListener.java
index d254a47c..21e77b5d 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferListener.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/TransferListener.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,41 +16,39 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
-
+package org.apache.maven.wagon.events;
 /**
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public interface TransferListener
-{
+public interface TransferListener {
     /**
      * @param transferEvent
      */
-    void transferInitiated( TransferEvent transferEvent );
+    void transferInitiated(TransferEvent transferEvent);
 
     /**
      * @param transferEvent
      */
-    void transferStarted( TransferEvent transferEvent );
+    void transferStarted(TransferEvent transferEvent);
 
     /**
      * @param transferEvent
      */
-    void transferProgress( TransferEvent transferEvent, byte[] buffer, int length );
+    void transferProgress(TransferEvent transferEvent, byte[] buffer, int length);
 
     /**
      * @param transferEvent
      */
-    void transferCompleted( TransferEvent transferEvent );
+    void transferCompleted(TransferEvent transferEvent);
 
     /**
      * @param transferEvent
      */
-    void transferError( TransferEvent transferEvent );
+    void transferError(TransferEvent transferEvent);
 
     /**
      * @param message
      */
-    void debug( String message );
-
+    void debug(String message);
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/WagonEvent.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/WagonEvent.java
index c23a4ea8..fac786a8 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/WagonEvent.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/events/WagonEvent.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 import java.util.EventObject;
 
@@ -29,9 +28,7 @@ import org.apache.maven.wagon.Wagon;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class WagonEvent
-    extends EventObject
-{
+public class WagonEvent extends EventObject {
     /**
      * The time when event occurred
      */
@@ -40,9 +37,8 @@ public class WagonEvent
     /**
      * @param source The Wagon object on which the WagonEvent initially occurred
      */
-    public WagonEvent( final Wagon source )
-    {
-        super( source );
+    public WagonEvent(final Wagon source) {
+        super(source);
     }
 
     /**
@@ -50,8 +46,7 @@ public class WagonEvent
      *
      * @return The Wagon object on which the WagonEvent initially occurred
      */
-    public Wagon getWagon()
-    {
+    public Wagon getWagon() {
         return (Wagon) getSource();
     }
 
@@ -60,8 +55,7 @@ public class WagonEvent
      *
      * @return Returns the timestamp.
      */
-    public long getTimestamp()
-    {
+    public long getTimestamp() {
         return timestamp;
     }
 
@@ -70,9 +64,7 @@ public class WagonEvent
      *
      * @param timestamp The timestamp to set.
      */
-    public void setTimestamp( final long timestamp )
-    {
+    public void setTimestamp(final long timestamp) {
         this.timestamp = timestamp;
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/AbstractTransferListener.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/AbstractTransferListener.java
index 5a550f6b..14e14847 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/AbstractTransferListener.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/AbstractTransferListener.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.observers;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.observers;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.observers;
 
 import org.apache.maven.wagon.events.TransferEvent;
 import org.apache.maven.wagon.events.TransferListener;
@@ -28,36 +27,22 @@ import org.apache.maven.wagon.events.TransferListener;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public abstract class AbstractTransferListener
-    implements TransferListener
-{
-    public void transferInitiated( TransferEvent transferEvent )
-    {
-    }
+public abstract class AbstractTransferListener implements TransferListener {
+    public void transferInitiated(TransferEvent transferEvent) {}
 
     /**
      * @see org.apache.maven.wagon.events.TransferListener#transferStarted(org.apache.maven.wagon.events.TransferEvent)
      */
-    public void transferStarted( TransferEvent transferEvent )
-    {
-    }
+    public void transferStarted(TransferEvent transferEvent) {}
 
     /**
      * @see org.apache.maven.wagon.events.TransferListener#transferProgress(org.apache.maven.wagon.events.TransferEvent,byte[],int)
      */
-    public void transferProgress( TransferEvent transferEvent, byte[] buffer, int length )
-    {
-    }
+    public void transferProgress(TransferEvent transferEvent, byte[] buffer, int length) {}
 
-    public void transferCompleted( TransferEvent transferEvent )
-    {
-    }
+    public void transferCompleted(TransferEvent transferEvent) {}
 
-    public void transferError( TransferEvent transferEvent )
-    {
-    }
+    public void transferError(TransferEvent transferEvent) {}
 
-    public void debug( String message )
-    {
-    }
+    public void debug(String message) {}
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/ChecksumObserver.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/ChecksumObserver.java
index 07f62ab1..b5a0cb86 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/ChecksumObserver.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/ChecksumObserver.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.observers;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,51 +16,44 @@ package org.apache.maven.wagon.observers;
  * specific language governing permissions and limitations
  * under the License.
  */
-
-import org.apache.maven.wagon.events.TransferEvent;
-import org.apache.maven.wagon.events.TransferListener;
+package org.apache.maven.wagon.observers;
 
 import java.security.MessageDigest;
 import java.security.NoSuchAlgorithmException;
 
+import org.apache.maven.wagon.events.TransferEvent;
+import org.apache.maven.wagon.events.TransferListener;
+
 /**
  * TransferListeners which computes MD5 checksum on the fly when files are transfered.
  *
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class ChecksumObserver
-    implements TransferListener
-{
+public class ChecksumObserver implements TransferListener {
     private MessageDigest digester = null;
 
     private String actualChecksum;
 
-    public ChecksumObserver()
-        throws NoSuchAlgorithmException
-    {
-        this( "MD5" );
+    public ChecksumObserver() throws NoSuchAlgorithmException {
+        this("MD5");
     }
 
     /**
      * @param algorithm One of the algorithms supported by JDK: MD5, MD2 or SHA-1
      */
-    public ChecksumObserver( String algorithm )
-        throws NoSuchAlgorithmException
-    {
-        digester = MessageDigest.getInstance( algorithm );
+    public ChecksumObserver(String algorithm) throws NoSuchAlgorithmException {
+        digester = MessageDigest.getInstance(algorithm);
     }
 
-    public void transferInitiated( TransferEvent transferEvent )
-    {
+    public void transferInitiated(TransferEvent transferEvent) {
         // This space left intentionally blank
     }
 
     /**
      * @see org.apache.maven.wagon.events.TransferListener#transferStarted(org.apache.maven.wagon.events.TransferEvent)
      */
-    public void transferStarted( TransferEvent transferEvent )
-    {
+    public void transferStarted(TransferEvent transferEvent) {
         actualChecksum = null;
 
         digester.reset();
@@ -71,25 +62,21 @@ public class ChecksumObserver
     /**
      * @see org.apache.maven.wagon.events.TransferListener#transferProgress(org.apache.maven.wagon.events.TransferEvent, byte[], int)
      */
-    public void transferProgress( TransferEvent transferEvent, byte[] buffer, int length )
-    {
-        digester.update( buffer, 0, length );
+    public void transferProgress(TransferEvent transferEvent, byte[] buffer, int length) {
+        digester.update(buffer, 0, length);
     }
 
-    public void transferCompleted( TransferEvent transferEvent )
-    {
-        actualChecksum = encode( digester.digest() );
+    public void transferCompleted(TransferEvent transferEvent) {
+        actualChecksum = encode(digester.digest());
     }
 
-    public void transferError( TransferEvent transferEvent )
-    {
+    public void transferError(TransferEvent transferEvent) {
         digester.reset();
 
         actualChecksum = null;
     }
 
-    public void debug( String message )
-    {
+    public void debug(String message) {
         // left intentionally blank
     }
 
@@ -98,8 +85,7 @@ public class ChecksumObserver
      *
      * @return
      */
-    public String getActualChecksum()
-    {
+    public String getActualChecksum() {
         return actualChecksum;
     }
 
@@ -109,34 +95,26 @@ public class ChecksumObserver
      * @param binaryData Array containing the digest
      * @return Encoded hex string, or null if encoding failed
      */
-    @SuppressWarnings( "checkstyle:magicnumber" )
-    protected String encode( byte[] binaryData )
-    {
-        
-        if ( binaryData.length != 16 && binaryData.length != 20 )
-        {
+    @SuppressWarnings("checkstyle:magicnumber")
+    protected String encode(byte[] binaryData) {
+
+        if (binaryData.length != 16 && binaryData.length != 20) {
             int bitLength = binaryData.length * 8;
-            throw new IllegalArgumentException( "Unrecognised length for binary data: " + bitLength + " bits" );
+            throw new IllegalArgumentException("Unrecognised length for binary data: " + bitLength + " bits");
         }
 
         StringBuilder retValue = new StringBuilder();
 
-        for ( byte b : binaryData )
-        {
-            String t = Integer.toHexString( b & 0xff );
+        for (byte b : binaryData) {
+            String t = Integer.toHexString(b & 0xff);
 
-            if ( t.length() == 1 )
-            {
-                retValue.append( '0' ).append( t );
-            }
-            else
-            {
-                retValue.append( t );
+            if (t.length() == 1) {
+                retValue.append('0').append(t);
+            } else {
+                retValue.append(t);
             }
         }
 
         return retValue.toString().trim();
     }
-
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/Debug.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/Debug.java
index fad22870..30b69ece 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/Debug.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/observers/Debug.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.observers;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,185 +16,154 @@ package org.apache.maven.wagon.observers;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.observers;
+
+import java.io.PrintStream;
 
 import org.apache.maven.wagon.events.SessionEvent;
 import org.apache.maven.wagon.events.SessionListener;
 import org.apache.maven.wagon.events.TransferEvent;
 import org.apache.maven.wagon.events.TransferListener;
 
-import java.io.PrintStream;
-
 /**
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class Debug
-    implements SessionListener, TransferListener
-{
+public class Debug implements SessionListener, TransferListener {
     private PrintStream out;
 
     long timestamp;
 
     long transfer;
 
-    public Debug()
-    {
-        this( System.out );
+    public Debug() {
+        this(System.out);
     }
 
-    public Debug( PrintStream out )
-    {
+    public Debug(PrintStream out) {
         this.out = out;
     }
 
     /**
      * @see SessionListener#sessionOpening(SessionEvent)
      */
-    public void sessionOpening( final SessionEvent sessionEvent )
-    {
-        //out.println( .getUrl() + " - Session: Opening  ");
+    public void sessionOpening(final SessionEvent sessionEvent) {
+        // out.println( .getUrl() + " - Session: Opening  ");
     }
 
     /**
      * @see SessionListener#sessionOpened(SessionEvent)
      */
-    public void sessionOpened( final SessionEvent sessionEvent )
-    {
-        out.println( sessionEvent.getWagon().getRepository().getUrl() + " - Session: Opened  " );
+    public void sessionOpened(final SessionEvent sessionEvent) {
+        out.println(sessionEvent.getWagon().getRepository().getUrl() + " - Session: Opened  ");
     }
 
     /**
      * @see SessionListener#sessionDisconnecting(SessionEvent)
      */
-    public void sessionDisconnecting( final SessionEvent sessionEvent )
-    {
-        out.println( sessionEvent.getWagon().getRepository().getUrl() + " - Session: Disconnecting  " );
-
+    public void sessionDisconnecting(final SessionEvent sessionEvent) {
+        out.println(sessionEvent.getWagon().getRepository().getUrl() + " - Session: Disconnecting  ");
     }
 
     /**
      * @see SessionListener#sessionDisconnected(SessionEvent)
      */
-    public void sessionDisconnected( final SessionEvent sessionEvent )
-    {
-        out.println( sessionEvent.getWagon().getRepository().getUrl() + " - Session: Disconnected" );
+    public void sessionDisconnected(final SessionEvent sessionEvent) {
+        out.println(sessionEvent.getWagon().getRepository().getUrl() + " - Session: Disconnected");
     }
 
     /**
      * @see SessionListener#sessionConnectionRefused(SessionEvent)
      */
-    public void sessionConnectionRefused( final SessionEvent sessionEvent )
-    {
-        out.println( sessionEvent.getWagon().getRepository().getUrl() + " - Session: Connection refused" );
-
+    public void sessionConnectionRefused(final SessionEvent sessionEvent) {
+        out.println(sessionEvent.getWagon().getRepository().getUrl() + " - Session: Connection refused");
     }
 
     /**
      * @see SessionListener#sessionLoggedIn(SessionEvent)
      */
-    public void sessionLoggedIn( final SessionEvent sessionEvent )
-    {
-        out.println( sessionEvent.getWagon().getRepository().getUrl() + " - Session: Logged in" );
-
+    public void sessionLoggedIn(final SessionEvent sessionEvent) {
+        out.println(sessionEvent.getWagon().getRepository().getUrl() + " - Session: Logged in");
     }
 
     /**
      * @see SessionListener#sessionLoggedOff(SessionEvent)
      */
-    public void sessionLoggedOff( final SessionEvent sessionEvent )
-    {
-        out.println( sessionEvent.getWagon().getRepository().getUrl() + " - Session: Logged off" );
-
+    public void sessionLoggedOff(final SessionEvent sessionEvent) {
+        out.println(sessionEvent.getWagon().getRepository().getUrl() + " - Session: Logged off");
     }
 
     /**
      * @see TransferListener#debug(String)
      */
-    public void debug( final String message )
-    {
-        out.println( message );
-
+    public void debug(final String message) {
+        out.println(message);
     }
 
-    public void transferInitiated( TransferEvent transferEvent )
-    {
+    public void transferInitiated(TransferEvent transferEvent) {
         // This space left intentionally blank
     }
 
     /**
      * @see TransferListener#transferStarted(TransferEvent)
      */
-    public void transferStarted( final TransferEvent transferEvent )
-    {
+    public void transferStarted(final TransferEvent transferEvent) {
         timestamp = transferEvent.getTimestamp();
 
         transfer = 0;
 
-        if ( transferEvent.getRequestType() == TransferEvent.REQUEST_GET )
-        {
+        if (transferEvent.getRequestType() == TransferEvent.REQUEST_GET) {
             final String message = "Downloading: " + transferEvent.getResource().getName() + " from "
-                + transferEvent.getWagon().getRepository().getUrl();
+                    + transferEvent.getWagon().getRepository().getUrl();
 
-            out.println( message );
-        }
-        else
-        {
+            out.println(message);
+        } else {
             final String message = "Uploading: " + transferEvent.getResource().getName() + " to "
-                + transferEvent.getWagon().getRepository().getUrl();
-
-            out.println( message );
+                    + transferEvent.getWagon().getRepository().getUrl();
 
+            out.println(message);
         }
     }
 
     /**
      * @see TransferListener#transferProgress(TransferEvent,byte[],int)
      */
-    public void transferProgress( final TransferEvent transferEvent, byte[] buffer, int length )
-    {
+    public void transferProgress(final TransferEvent transferEvent, byte[] buffer, int length) {
 
-        out.print( "#" );
-        //String data = new String( transferEvent.getData(),0, transferEvent.getDataLength());
-        //out.println(data);
+        out.print("#");
+        // String data = new String( transferEvent.getData(),0, transferEvent.getDataLength());
+        // out.println(data);
         transfer += length;
     }
 
     /**
      * @see TransferListener#transferCompleted(TransferEvent)
      */
-    public void transferCompleted( final TransferEvent transferEvent )
-    {
-        final double duration = (double) ( transferEvent.getTimestamp() - timestamp ) / 1000;
+    public void transferCompleted(final TransferEvent transferEvent) {
+        final double duration = (double) (transferEvent.getTimestamp() - timestamp) / 1000;
 
         out.println();
 
         final String message = "Transfer finished. " + transfer + " bytes copied in " + duration + " seconds";
 
-        out.println( message );
-
+        out.println(message);
     }
 
     /**
      * @see TransferListener#transferError(TransferEvent)
      */
-    public void transferError( final TransferEvent transferEvent )
-    {
-        out.println( " Transfer error: " + transferEvent.getException() );
-
+    public void transferError(final TransferEvent transferEvent) {
+        out.println(" Transfer error: " + transferEvent.getException());
     }
 
     /**
      * @see SessionListener#sessionError(SessionEvent)
      */
-    public void sessionError( final SessionEvent sessionEvent )
-    {
-        out.println( " Session error: " + sessionEvent.getException() );
-
+    public void sessionError(final SessionEvent sessionEvent) {
+        out.println(" Session error: " + sessionEvent.getException());
     }
 
-    public PrintStream getOut()
-    {
+    public PrintStream getOut() {
         return out;
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfo.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfo.java
index 1b1085ab..50d23892 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfo.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfo.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.proxy;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,11 +16,12 @@ package org.apache.maven.wagon.proxy;
  * specific language governing permissions and limitations
  * under the License.
  */
-
-import org.apache.maven.wagon.WagonConstants;
+package org.apache.maven.wagon.proxy;
 
 import java.io.Serializable;
 
+import org.apache.maven.wagon.WagonConstants;
+
 /**
  * Contains set of properties used by <code>Wagon</code> objects
  * while connection to the repository must go thru a proxy server.
@@ -32,9 +31,7 @@ import java.io.Serializable;
  * @todo Propose standard types of proxy servers (e.g. <i>SOCKSv4</i>),
  * which can be shared between wagon api and providers
  */
-public class ProxyInfo
-    implements Serializable
-{
+public class ProxyInfo implements Serializable {
     public static final String PROXY_SOCKS5 = "SOCKS_5";
 
     public static final String PROXY_SOCKS4 = "SOCKS4";
@@ -86,8 +83,7 @@ public class ProxyInfo
      *
      * @return proxy server host name
      */
-    public String getHost()
-    {
+    public String getHost() {
         return host;
     }
 
@@ -96,8 +92,7 @@ public class ProxyInfo
      *
      * @param host proxy server host name
      */
-    public void setHost( final String host )
-    {
+    public void setHost(final String host) {
         this.host = host;
     }
 
@@ -106,8 +101,7 @@ public class ProxyInfo
      *
      * @return user's password at proxy host
      */
-    public String getPassword()
-    {
+    public String getPassword() {
         return password;
     }
 
@@ -116,8 +110,7 @@ public class ProxyInfo
      *
      * @param password password to use to login to a proxy server
      */
-    public void setPassword( final String password )
-    {
+    public void setPassword(final String password) {
         this.password = password;
     }
 
@@ -126,8 +119,7 @@ public class ProxyInfo
      *
      * @return proxy server port
      */
-    public int getPort()
-    {
+    public int getPort() {
         return port;
     }
 
@@ -136,8 +128,7 @@ public class ProxyInfo
      *
      * @param port proxy server port
      */
-    public void setPort( final int port )
-    {
+    public void setPort(final int port) {
         this.port = port;
     }
 
@@ -146,8 +137,7 @@ public class ProxyInfo
      *
      * @return username for the proxy server
      */
-    public String getUserName()
-    {
+    public String getUserName() {
         return userName;
     }
 
@@ -156,8 +146,7 @@ public class ProxyInfo
      *
      * @param userName username for the proxy server
      */
-    public void setUserName( final String userName )
-    {
+    public void setUserName(final String userName) {
         this.userName = userName;
     }
 
@@ -166,53 +155,44 @@ public class ProxyInfo
      *
      * @return the type of the proxy server
      */
-    public String getType()
-    {
+    public String getType() {
         return type;
     }
 
     /**
      * @param type the type of the proxy server like <i>SOCKSv4</i>
      */
-    public void setType( final String type )
-    {
+    public void setType(final String type) {
         this.type = type;
     }
 
-    public String getNonProxyHosts()
-    {
+    public String getNonProxyHosts() {
         return nonProxyHosts;
     }
 
-    public void setNonProxyHosts( String nonProxyHosts )
-    {
+    public void setNonProxyHosts(String nonProxyHosts) {
         this.nonProxyHosts = nonProxyHosts;
     }
 
-    public String getNtlmHost()
-    {
+    public String getNtlmHost() {
         return ntlmHost;
     }
 
-    public void setNtlmHost( String ntlmHost )
-    {
+    public void setNtlmHost(String ntlmHost) {
         this.ntlmHost = ntlmHost;
     }
 
-    public void setNtlmDomain( String ntlmDomain )
-    {
+    public void setNtlmDomain(String ntlmDomain) {
         this.ntlmDomain = ntlmDomain;
     }
 
-    public String getNtlmDomain()
-    {
+    public String getNtlmDomain() {
         return ntlmDomain;
     }
 
     @Override
-    public String toString()
-    {
+    public String toString() {
         return "ProxyInfo{" + "host='" + host + '\'' + ", userName='" + userName + '\'' + ", port=" + port + ", type='"
-            + type + '\'' + ", nonProxyHosts='" + nonProxyHosts + '\'' + '}';
+                + type + '\'' + ", nonProxyHosts='" + nonProxyHosts + '\'' + '}';
     }
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfoProvider.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfoProvider.java
index f63e251c..608101c9 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfoProvider.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyInfoProvider.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.proxy;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,16 +16,16 @@ package org.apache.maven.wagon.proxy;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.proxy;
 
 /**
  * Interface of an object, which provides the proxy settings. Typically, this is the artifact manager.
  */
-public interface ProxyInfoProvider
-{
+public interface ProxyInfoProvider {
     /**
      * Returns the proxy settings for the given protocol.
-     * 
+     *
      * @return Proxy settings or null, if no proxy is configured for this protocol.
      */
-    ProxyInfo getProxyInfo( String protocol );
+    ProxyInfo getProxyInfo(String protocol);
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyUtils.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyUtils.java
index dbff0525..7d0891f8 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyUtils.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/proxy/ProxyUtils.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.proxy;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,49 +16,41 @@ package org.apache.maven.wagon.proxy;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.proxy;
 
 import java.util.StringTokenizer;
 
 /**
  * @author <a href="mailto:lafeuil@gmail.com">Thomas Champagne</a>
  */
-public final class ProxyUtils
-{
-    private ProxyUtils()
-    {
-    }
+public final class ProxyUtils {
+    private ProxyUtils() {}
 
     /**
      * Check if the specified host is in the list of non proxy hosts.
-     * 
+     *
      * @param proxy the proxy info object contains set of properties.
      * @param targetHost the target hostname
      * @return true if the hostname is in the list of non proxy hosts, false otherwise.
      */
-    public static boolean validateNonProxyHosts( ProxyInfo proxy, String targetHost )
-    {
-        if ( targetHost == null )
-        {
+    public static boolean validateNonProxyHosts(ProxyInfo proxy, String targetHost) {
+        if (targetHost == null) {
             targetHost = new String();
         }
-        if ( proxy == null )
-        {
+        if (proxy == null) {
             return false;
         }
         String nonProxyHosts = proxy.getNonProxyHosts();
-        if ( nonProxyHosts == null )
-        {
+        if (nonProxyHosts == null) {
             return false;
         }
 
-        StringTokenizer tokenizer = new StringTokenizer( nonProxyHosts, "|" );
+        StringTokenizer tokenizer = new StringTokenizer(nonProxyHosts, "|");
 
-        while ( tokenizer.hasMoreTokens() )
-        {
+        while (tokenizer.hasMoreTokens()) {
             String pattern = tokenizer.nextToken();
-            pattern = pattern.replaceAll( "\\.", "\\\\." ).replaceAll( "\\*", ".*" );
-            if ( targetHost.matches( pattern ) )
-            {
+            pattern = pattern.replaceAll("\\.", "\\\\.").replaceAll("\\*", ".*");
+            if (targetHost.matches(pattern)) {
                 return true;
             }
         }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/Repository.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/Repository.java
index 456115a1..8111a13a 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/Repository.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/Repository.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.repository;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,14 +16,15 @@ package org.apache.maven.wagon.repository;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.repository;
+
+import java.io.Serializable;
+import java.util.Properties;
 
 import org.apache.maven.wagon.PathUtils;
 import org.apache.maven.wagon.WagonConstants;
 import org.codehaus.plexus.util.StringUtils;
 
-import java.io.Serializable;
-import java.util.Properties;
-
 /**
  * This class is an abstraction of the location from/to resources
  * can be transfered.
@@ -34,9 +33,7 @@ import java.util.Properties;
  *
  * @todo [BP] some things are specific to certain wagons (eg key stuff in authInfo, permissions)
  */
-public class Repository
-    implements Serializable
-{
+public class Repository implements Serializable {
     private static final long serialVersionUID = 1312227676322136247L;
 
     private String id;
@@ -69,35 +66,27 @@ public class Repository
     /**
      * @deprecated use {@link #Repository(String, String)}
      */
-    public Repository()
-    {
-
-    }
+    public Repository() {}
 
-    public Repository( String id, String url )
-    {
-        if ( id == null )
-        {
-            throw new NullPointerException( "id cannot be null" );
+    public Repository(String id, String url) {
+        if (id == null) {
+            throw new NullPointerException("id cannot be null");
         }
 
-        setId( id );
+        setId(id);
 
-        if ( url == null )
-        {
-            throw new NullPointerException( "url cannot be null" );
+        if (url == null) {
+            throw new NullPointerException("url cannot be null");
         }
 
-        setUrl( url );
+        setUrl(url);
     }
 
-    public String getId()
-    {
+    public String getId() {
         return id;
     }
 
-    public void setId( String id )
-    {
+    public void setId(String id) {
         this.id = id;
     }
 
@@ -107,56 +96,48 @@ public class Repository
      *
      * @return the base directory
      */
-    public String getBasedir()
-    {
+    public String getBasedir() {
         return basedir;
     }
 
-    public void setBasedir( String basedir )
-    {
+    public void setBasedir(String basedir) {
         this.basedir = basedir;
     }
 
-    public void setName( String name )
-    {
+    public void setName(String name) {
         this.name = name;
     }
 
-    public int getPort()
-    {
+    public int getPort() {
         return port;
     }
 
-    public void setPort( int port )
-    {
+    public void setPort(int port) {
         this.port = port;
     }
 
-    public void setUrl( String url )
-    {
+    public void setUrl(String url) {
         this.url = url;
 
         // TODO [BP]: refactor out the PathUtils URL stuff into a class like java.net.URL, so you only parse once
         //  can't use URL class as is because it won't recognise our protocols, though perhaps we could attempt to
         //  register handlers for scp, etc?
 
-        this.protocol = PathUtils.protocol( url );
+        this.protocol = PathUtils.protocol(url);
 
-        this.host = PathUtils.host( url );
+        this.host = PathUtils.host(url);
 
-        this.port = PathUtils.port( url );
+        this.port = PathUtils.port(url);
 
-        this.basedir = PathUtils.basedir( url );
+        this.basedir = PathUtils.basedir(url);
 
-        String username = PathUtils.user( url );
+        String username = PathUtils.user(url);
         this.username = username;
 
-        if ( username != null )
-        {
-            String password = PathUtils.password( url );
+        if (username != null) {
+            String password = PathUtils.password(url);
 
-            if ( password != null )
-            {
+            if (password != null) {
                 this.password = password;
 
                 username += ":" + password;
@@ -164,43 +145,37 @@ public class Repository
 
             username += "@";
 
-            int index = url.indexOf( username );
-            this.url = url.substring( 0, index ) + url.substring( index + username.length() );
+            int index = url.indexOf(username);
+            this.url = url.substring(0, index) + url.substring(index + username.length());
         }
     }
 
-    public String getUrl()
-    {
-        if ( url != null )
-        {
+    public String getUrl() {
+        if (url != null) {
             return url;
         }
 
         StringBuilder sb = new StringBuilder();
 
-        sb.append( protocol );
+        sb.append(protocol);
 
-        sb.append( "://" );
+        sb.append("://");
 
-        if ( isIPv6Address() )
-        {
+        if (isIPv6Address()) {
             // If this is IPv6 then we have to surround it
             // with brackets '[' and ']'
-            sb.append( "[" ).append( getHost() ).append( "]" );
-        }
-        else
-        {
-            sb.append( getHost() );
+            sb.append("[").append(getHost()).append("]");
+        } else {
+            sb.append(getHost());
         }
 
-        if ( port != WagonConstants.UNKNOWN_PORT )
-        {
-            sb.append( ":" );
+        if (port != WagonConstants.UNKNOWN_PORT) {
+            sb.append(":");
 
-            sb.append( port );
+            sb.append(port);
         }
 
-        sb.append( basedir );
+        sb.append(basedir);
 
         return sb.toString();
     }
@@ -210,121 +185,96 @@ public class Repository
      *
      * @return true if provide host part is of IPv6 format
      */
-    private boolean isIPv6Address()
-    {
-        return getHost().contains( ":" );
+    private boolean isIPv6Address() {
+        return getHost().contains(":");
     }
 
-    public String getHost()
-    {
-        if ( host == null )
-        {
+    public String getHost() {
+        if (host == null) {
             return "localhost";
         }
         return host;
     }
 
-    public String getName()
-    {
-        if ( name == null )
-        {
+    public String getName() {
+        if (name == null) {
             return getId();
         }
         return name;
     }
 
-    public String toString()
-    {
+    public String toString() {
         StringBuilder sb = new StringBuilder();
 
-        sb.append( "Repository[" );
+        sb.append("Repository[");
 
-        if ( StringUtils.isNotEmpty( getName() ) )
-        {
-            sb.append( getName() ).append( "|" );
+        if (StringUtils.isNotEmpty(getName())) {
+            sb.append(getName()).append("|");
         }
 
-        sb.append( getUrl() );
-        sb.append( "]" );
+        sb.append(getUrl());
+        sb.append("]");
 
         return sb.toString();
     }
 
-    public String getProtocol()
-    {
+    public String getProtocol() {
         return protocol;
     }
 
-    public RepositoryPermissions getPermissions()
-    {
+    public RepositoryPermissions getPermissions() {
         return permissions;
     }
 
-    public void setPermissions( RepositoryPermissions permissions )
-    {
+    public void setPermissions(RepositoryPermissions permissions) {
         this.permissions = permissions;
     }
 
-    public String getParameter( String key )
-    {
-        return parameters.getProperty( key );
+    public String getParameter(String key) {
+        return parameters.getProperty(key);
     }
 
-    public void setParameters( Properties parameters )
-    {
+    public void setParameters(Properties parameters) {
         this.parameters = parameters;
     }
 
-    public int hashCode()
-    {
+    public int hashCode() {
         final int prime = 31;
         int result = 1;
-        result = prime * result + ( ( id == null ) ? 0 : id.hashCode() );
+        result = prime * result + ((id == null) ? 0 : id.hashCode());
         return result;
     }
 
-    public boolean equals( Object obj )
-    {
-        if ( this == obj )
-        {
+    public boolean equals(Object obj) {
+        if (this == obj) {
             return true;
         }
-        if ( obj == null )
-        {
+        if (obj == null) {
             return false;
         }
-        if ( getClass() != obj.getClass() )
-        {
+        if (getClass() != obj.getClass()) {
             return false;
         }
         final Repository other = (Repository) obj;
-        if ( id == null )
-        {
-            if ( other.id != null )
-            {
+        if (id == null) {
+            if (other.id != null) {
                 return false;
             }
-        }
-        else if ( !id.equals( other.id ) )
-        {
+        } else if (!id.equals(other.id)) {
             return false;
         }
         return true;
     }
 
-    public String getUsername()
-    {
+    public String getUsername() {
         return username;
     }
 
-    public String getPassword()
-    {
+    public String getPassword() {
         return password;
     }
 
-    public void setProtocol( String protocol )
-    {
+    public void setProtocol(String protocol) {
         this.protocol = protocol;
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/RepositoryPermissions.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/RepositoryPermissions.java
index 37caa6f3..76673aa6 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/RepositoryPermissions.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/repository/RepositoryPermissions.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.repository;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.repository;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.repository;
 
 import java.io.Serializable;
 
@@ -27,8 +26,7 @@ import java.io.Serializable;
  * @author Brett Porter
  *
  */
-public class RepositoryPermissions implements Serializable
-{
+public class RepositoryPermissions implements Serializable {
     /**
      * Repository group name.
      */
@@ -50,8 +48,7 @@ public class RepositoryPermissions implements Serializable
      *
      * @return mode
      */
-    public String getDirectoryMode()
-    {
+    public String getDirectoryMode() {
         return directoryMode;
     }
 
@@ -60,8 +57,7 @@ public class RepositoryPermissions implements Serializable
      *
      * @param directoryMode repository directory mode for deployed artifacts
      */
-    public void setDirectoryMode( final String directoryMode )
-    {
+    public void setDirectoryMode(final String directoryMode) {
         this.directoryMode = directoryMode;
     }
 
@@ -71,8 +67,7 @@ public class RepositoryPermissions implements Serializable
      *
      * @return repository group name
      */
-    public String getFileMode()
-    {
+    public String getFileMode() {
         return fileMode;
     }
 
@@ -81,8 +76,7 @@ public class RepositoryPermissions implements Serializable
      *
      * @param fileMode repository file mode for deployed artifacts
      */
-    public void setFileMode( final String fileMode )
-    {
+    public void setFileMode(final String fileMode) {
         this.fileMode = fileMode;
     }
 
@@ -93,8 +87,7 @@ public class RepositoryPermissions implements Serializable
      *
      * @return repository group name
      */
-    public String getGroup()
-    {
+    public String getGroup() {
         return group;
     }
 
@@ -103,9 +96,7 @@ public class RepositoryPermissions implements Serializable
      *
      * @param group repository group for deployed artifacts
      */
-    public void setGroup( final String group )
-    {
+    public void setGroup(final String group) {
         this.group = group;
     }
-
 }
diff --git a/wagon-provider-api/src/main/java/org/apache/maven/wagon/resource/Resource.java b/wagon-provider-api/src/main/java/org/apache/maven/wagon/resource/Resource.java
index f5756192..2dfd083c 100644
--- a/wagon-provider-api/src/main/java/org/apache/maven/wagon/resource/Resource.java
+++ b/wagon-provider-api/src/main/java/org/apache/maven/wagon/resource/Resource.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.resource;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.resource;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.resource;
 
 import org.apache.maven.wagon.WagonConstants;
 
@@ -31,32 +30,24 @@ import org.apache.maven.wagon.WagonConstants;
  * @author <a href="michal@codehaus.org">Michal Maczka</a>
  *
  */
-
-public class Resource
-{
+public class Resource {
     private String name;
 
     private long lastModified;
 
     private long contentLength = WagonConstants.UNKNOWN_LENGTH;
 
-    public Resource()
-    {
+    public Resource() {}
 
-    }
-
-    public Resource( String name )
-    {
+    public Resource(String name) {
         this.name = name;
     }
 
-    public String getName()
-    {
+    public String getName() {
         return name;
     }
 
-    public void setName( String name )
-    {
+    public void setName(String name) {
         this.name = name;
     }
 
@@ -67,78 +58,61 @@ public class Resource
      * @return the date the resource  was last modified, or WagonConstants.UNKNOWN_LENGTH
      *         if not known.
      */
-    public long getLastModified()
-    {
+    public long getLastModified() {
         return lastModified;
     }
 
-    public void setLastModified( long lastModified )
-    {
+    public void setLastModified(long lastModified) {
         this.lastModified = lastModified;
     }
 
-    public long getContentLength()
-    {
+    public long getContentLength() {
         return contentLength;
     }
 
-    public void setContentLength( long contentLength )
-    {
+    public void setContentLength(long contentLength) {
         this.contentLength = contentLength;
     }
 
-    public String toString()
-    {
+    public String toString() {
         return name;
     }
-    
-    public String inspect()
-    {
+
+    public String inspect() {
         return name + "[len = " + contentLength + "; mod = " + lastModified + "]";
     }
 
-    public int hashCode()
-    {
+    public int hashCode() {
         final int prime = 31;
         int result = 1;
-        result = prime * result + (int) ( contentLength ^ ( contentLength >>> 32 ) );
-        result = prime * result + (int) ( lastModified ^ ( lastModified >>> 32 ) );
-        result = prime * result + ( ( name == null ) ? 0 : name.hashCode() );
+        result = prime * result + (int) (contentLength ^ (contentLength >>> 32));
+        result = prime * result + (int) (lastModified ^ (lastModified >>> 32));
+        result = prime * result + ((name == null) ? 0 : name.hashCode());
         return result;
     }
 
-    public boolean equals( Object obj )
-    {
-        if ( this == obj )
-        {
+    public boolean equals(Object obj) {
+        if (this == obj) {
             return true;
         }
-        if ( obj == null )
-        {
+        if (obj == null) {
             return false;
         }
-        if ( getClass() != obj.getClass() )
-        {
+        if (getClass() != obj.getClass()) {
             return false;
         }
         final Resource other = (Resource) obj;
-        if ( contentLength != other.contentLength )
-        {
+        if (contentLength != other.contentLength) {
             return false;
         }
-        if ( lastModified != other.lastModified )
-        {
+        if (lastModified != other.lastModified) {
             return false;
         }
-        if ( name == null )
-        {
-            if ( other.name != null )
-            {
+        if (name == null) {
+            if (other.name != null) {
                 return false;
             }
-        }
-        else if ( !name.equals( other.name ) )
-        {
+        } else if (!name.equals(other.name)) {
             return false;
         }
         return true;
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/AbstractWagonTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/AbstractWagonTest.java
index 81b07dbd..5ae69460 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/AbstractWagonTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/AbstractWagonTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,13 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
+
+import java.io.ByteArrayOutputStream;
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
 
 import junit.framework.TestCase;
 import org.apache.maven.wagon.authentication.AuthenticationException;
@@ -38,46 +43,25 @@ import org.easymock.IAnswer;
 
 import static org.easymock.EasyMock.*;
 
-import java.io.ByteArrayOutputStream;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-
 /**
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  */
-public class AbstractWagonTest
-    extends TestCase
-{
-    private static class TestWagon
-        extends AbstractWagon
-    {
-        protected void closeConnection()
-            throws ConnectionException
-        {
-        }
+public class AbstractWagonTest extends TestCase {
+    private static class TestWagon extends AbstractWagon {
+        protected void closeConnection() throws ConnectionException {}
 
-        protected void openConnectionInternal()
-            throws ConnectionException, AuthenticationException
-        {
-        }
+        protected void openConnectionInternal() throws ConnectionException, AuthenticationException {}
 
-        public void get( String resourceName, File destination )
-            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-        {
-        }
+        public void get(String resourceName, File destination)
+                throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {}
 
-        public boolean getIfNewer( String resourceName, File destination, long timestamp )
-            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-        {
+        public boolean getIfNewer(String resourceName, File destination, long timestamp)
+                throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
             return false;
         }
 
-        public void put( File source, String destination )
-            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-        {
-        }
+        public void put(File source, String destination)
+                throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {}
     }
 
     private String basedir;
@@ -94,140 +78,122 @@ public class AbstractWagonTest
 
     private TransferListener transferListener = null;
 
-    protected void setUp()
-        throws Exception
-    {
+    protected void setUp() throws Exception {
         super.setUp();
 
-        basedir = System.getProperty( "basedir" );
+        basedir = System.getProperty("basedir");
 
-        destination = new File( basedir, "target/folder/subfolder" );
+        destination = new File(basedir, "target/folder/subfolder");
 
-        source = new File( basedir, "pom.xml" );
+        source = new File(basedir, "pom.xml");
 
         wagon = new WagonMock();
 
-        sessionListener = createMock( SessionListener.class );
-
-        wagon.addSessionListener( sessionListener );
+        sessionListener = createMock(SessionListener.class);
 
-        transferListener = createMock( TransferListener.class );
+        wagon.addSessionListener(sessionListener);
 
-        wagon.addTransferListener( transferListener );
+        transferListener = createMock(TransferListener.class);
 
+        wagon.addTransferListener(transferListener);
     }
 
     public void testCalculationOfTransferBufferSize() {
         // 1 KiB -> Default buffer size (4 KiB)
-        assertEquals( 4096, wagon.getBufferCapacityForTransfer(1024L ) );
+        assertEquals(4096, wagon.getBufferCapacityForTransfer(1024L));
 
         // 1 MiB -> Twice the default buffer size (8 KiB)
-        assertEquals( 4096 * 2, wagon.getBufferCapacityForTransfer(1024L * 1024 ) );
+        assertEquals(4096 * 2, wagon.getBufferCapacityForTransfer(1024L * 1024));
 
         // 100 MiB -> Maximum buffer size (512 KiB)
-        assertEquals( 4096 * 128, wagon.getBufferCapacityForTransfer(1024L * 1024  * 100 ) );
+        assertEquals(4096 * 128, wagon.getBufferCapacityForTransfer(1024L * 1024 * 100));
 
         // 1 GiB -> Maximum buffer size (512 KiB)
-        assertEquals( 4096 * 128, wagon.getBufferCapacityForTransfer(1024L * 1024  * 1024 ) );
+        assertEquals(4096 * 128, wagon.getBufferCapacityForTransfer(1024L * 1024 * 1024));
 
         // 100 GiB -> Maximum buffer size (512 KiB)
-        assertEquals( 4096 * 128, wagon.getBufferCapacityForTransfer(1024L * 1024  * 1024 * 100 ) );
+        assertEquals(4096 * 128, wagon.getBufferCapacityForTransfer(1024L * 1024 * 1024 * 100));
     }
 
-    public void testSessionListenerRegistration()
-    {
-        assertTrue( wagon.hasSessionListener( sessionListener ) );
+    public void testSessionListenerRegistration() {
+        assertTrue(wagon.hasSessionListener(sessionListener));
 
-        wagon.removeSessionListener( sessionListener );
+        wagon.removeSessionListener(sessionListener);
 
-        assertFalse( wagon.hasSessionListener( sessionListener ) );
+        assertFalse(wagon.hasSessionListener(sessionListener));
     }
 
-    public void testTransferListenerRegistration()
-    {
-        assertTrue( wagon.hasTransferListener( transferListener ) );
+    public void testTransferListenerRegistration() {
+        assertTrue(wagon.hasTransferListener(transferListener));
 
-        wagon.removeTransferListener( transferListener );
+        wagon.removeTransferListener(transferListener);
 
-        assertFalse( wagon.hasTransferListener( transferListener ) );
+        assertFalse(wagon.hasTransferListener(transferListener));
     }
 
-    public void testNoProxyConfiguration()
-        throws ConnectionException, AuthenticationException
-    {
+    public void testNoProxyConfiguration() throws ConnectionException, AuthenticationException {
         Repository repository = new Repository();
-        wagon.connect( repository );
-        assertNull( wagon.getProxyInfo() );
-        assertNull( wagon.getProxyInfo( "http", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "dav", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "scp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "ftp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "http", "localhost" ) );
+        wagon.connect(repository);
+        assertNull(wagon.getProxyInfo());
+        assertNull(wagon.getProxyInfo("http", "www.example.com"));
+        assertNull(wagon.getProxyInfo("dav", "www.example.com"));
+        assertNull(wagon.getProxyInfo("scp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("ftp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("http", "localhost"));
     }
 
-    public void testNullProxyConfiguration()
-        throws ConnectionException, AuthenticationException
-    {
+    public void testNullProxyConfiguration() throws ConnectionException, AuthenticationException {
         Repository repository = new Repository();
-        wagon.connect( repository, (ProxyInfo) null );
-        assertNull( wagon.getProxyInfo() );
-        assertNull( wagon.getProxyInfo( "http", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "dav", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "scp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "ftp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "http", "localhost" ) );
-
-        wagon.connect( repository );
-        assertNull( wagon.getProxyInfo() );
-        assertNull( wagon.getProxyInfo( "http", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "dav", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "scp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "ftp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "http", "localhost" ) );
-
-        wagon.connect( repository, new AuthenticationInfo() );
-        assertNull( wagon.getProxyInfo() );
-        assertNull( wagon.getProxyInfo( "http", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "dav", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "scp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "ftp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "http", "localhost" ) );
+        wagon.connect(repository, (ProxyInfo) null);
+        assertNull(wagon.getProxyInfo());
+        assertNull(wagon.getProxyInfo("http", "www.example.com"));
+        assertNull(wagon.getProxyInfo("dav", "www.example.com"));
+        assertNull(wagon.getProxyInfo("scp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("ftp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("http", "localhost"));
+
+        wagon.connect(repository);
+        assertNull(wagon.getProxyInfo());
+        assertNull(wagon.getProxyInfo("http", "www.example.com"));
+        assertNull(wagon.getProxyInfo("dav", "www.example.com"));
+        assertNull(wagon.getProxyInfo("scp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("ftp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("http", "localhost"));
+
+        wagon.connect(repository, new AuthenticationInfo());
+        assertNull(wagon.getProxyInfo());
+        assertNull(wagon.getProxyInfo("http", "www.example.com"));
+        assertNull(wagon.getProxyInfo("dav", "www.example.com"));
+        assertNull(wagon.getProxyInfo("scp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("ftp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("http", "localhost"));
     }
 
-    public void testLegacyProxyConfiguration()
-        throws ConnectionException, AuthenticationException
-    {
+    public void testLegacyProxyConfiguration() throws ConnectionException, AuthenticationException {
         ProxyInfo proxyInfo = new ProxyInfo();
-        proxyInfo.setType( "http" );
+        proxyInfo.setType("http");
 
         Repository repository = new Repository();
-        wagon.connect( repository, proxyInfo );
-        assertEquals( proxyInfo, wagon.getProxyInfo() );
-        assertEquals( proxyInfo, wagon.getProxyInfo( "http", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "dav", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "scp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "ftp", "www.example.com" ) );
+        wagon.connect(repository, proxyInfo);
+        assertEquals(proxyInfo, wagon.getProxyInfo());
+        assertEquals(proxyInfo, wagon.getProxyInfo("http", "www.example.com"));
+        assertNull(wagon.getProxyInfo("dav", "www.example.com"));
+        assertNull(wagon.getProxyInfo("scp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("ftp", "www.example.com"));
     }
 
-    public void testProxyConfiguration()
-        throws ConnectionException, AuthenticationException
-    {
+    public void testProxyConfiguration() throws ConnectionException, AuthenticationException {
         final ProxyInfo httpProxyInfo = new ProxyInfo();
-        httpProxyInfo.setType( "http" );
+        httpProxyInfo.setType("http");
 
         final ProxyInfo socksProxyInfo = new ProxyInfo();
-        socksProxyInfo.setType( "http" );
-
-        ProxyInfoProvider proxyInfoProvider = new ProxyInfoProvider()
-        {
-            public ProxyInfo getProxyInfo( String protocol )
-            {
-                if ( "http".equals( protocol ) || "dav".equals( protocol ) )
-                {
+        socksProxyInfo.setType("http");
+
+        ProxyInfoProvider proxyInfoProvider = new ProxyInfoProvider() {
+            public ProxyInfo getProxyInfo(String protocol) {
+                if ("http".equals(protocol) || "dav".equals(protocol)) {
                     return httpProxyInfo;
-                }
-                else if ( "scp".equals( protocol ) )
-                {
+                } else if ("scp".equals(protocol)) {
                     return socksProxyInfo;
                 }
                 return null;
@@ -235,359 +201,300 @@ public class AbstractWagonTest
         };
 
         Repository repository = new Repository();
-        wagon.connect( repository, proxyInfoProvider );
-        assertNull( wagon.getProxyInfo() );
-        assertEquals( httpProxyInfo, wagon.getProxyInfo( "http", "www.example.com" ) );
-        assertEquals( httpProxyInfo, wagon.getProxyInfo( "dav", "www.example.com" ) );
-        assertEquals( socksProxyInfo, wagon.getProxyInfo( "scp", "www.example.com" ) );
-        assertNull( wagon.getProxyInfo( "ftp", "www.example.com" ) );
+        wagon.connect(repository, proxyInfoProvider);
+        assertNull(wagon.getProxyInfo());
+        assertEquals(httpProxyInfo, wagon.getProxyInfo("http", "www.example.com"));
+        assertEquals(httpProxyInfo, wagon.getProxyInfo("dav", "www.example.com"));
+        assertEquals(socksProxyInfo, wagon.getProxyInfo("scp", "www.example.com"));
+        assertNull(wagon.getProxyInfo("ftp", "www.example.com"));
     }
 
-    public void testSessionOpenEvents()
-        throws Exception
-    {
+    public void testSessionOpenEvents() throws Exception {
         Repository repository = new Repository();
 
-        sessionListener.sessionOpening( anyObject( SessionEvent.class ) );
-        sessionListener.sessionOpened( anyObject( SessionEvent.class ) );
-        replay( sessionListener );
+        sessionListener.sessionOpening(anyObject(SessionEvent.class));
+        sessionListener.sessionOpened(anyObject(SessionEvent.class));
+        replay(sessionListener);
 
-        wagon.connect( repository );
+        wagon.connect(repository);
 
-        verify( sessionListener );
+        verify(sessionListener);
 
-        assertEquals( repository, wagon.getRepository() );
+        assertEquals(repository, wagon.getRepository());
     }
 
-    public void testSessionConnectionRefusedEventConnectionException()
-        throws Exception
-    {
-        final WagonException exception = new ConnectionException( "" );
+    public void testSessionConnectionRefusedEventConnectionException() throws Exception {
+        final WagonException exception = new ConnectionException("");
 
-        try
-        {
-            runTestSessionConnectionRefusedEvent( exception );
+        try {
+            runTestSessionConnectionRefusedEvent(exception);
             fail();
-        }
-        catch ( ConnectionException e )
-        {
-            assertTrue( true );
+        } catch (ConnectionException e) {
+            assertTrue(true);
         }
     }
 
-    public void testSessionConnectionRefusedEventAuthenticationException()
-        throws Exception
-    {
-        final WagonException exception = new AuthenticationException( "" );
+    public void testSessionConnectionRefusedEventAuthenticationException() throws Exception {
+        final WagonException exception = new AuthenticationException("");
 
-        try
-        {
-            runTestSessionConnectionRefusedEvent( exception );
+        try {
+            runTestSessionConnectionRefusedEvent(exception);
             fail();
-        }
-        catch ( AuthenticationException e )
-        {
-            assertTrue( true );
+        } catch (AuthenticationException e) {
+            assertTrue(true);
         }
     }
 
-    private void runTestSessionConnectionRefusedEvent( final WagonException exception )
-        throws ConnectionException, AuthenticationException
-    {
+    private void runTestSessionConnectionRefusedEvent(final WagonException exception)
+            throws ConnectionException, AuthenticationException {
         Repository repository = new Repository();
 
-        sessionListener.sessionOpening( anyObject( SessionEvent.class ) );
-        sessionListener.sessionConnectionRefused( anyObject( SessionEvent.class ) );
-        replay( sessionListener );
-
-        Wagon wagon = new TestWagon()
-        {
-            protected void openConnectionInternal()
-                throws ConnectionException, AuthenticationException
-            {
-                if ( exception instanceof ConnectionException )
-                {
+        sessionListener.sessionOpening(anyObject(SessionEvent.class));
+        sessionListener.sessionConnectionRefused(anyObject(SessionEvent.class));
+        replay(sessionListener);
+
+        Wagon wagon = new TestWagon() {
+            protected void openConnectionInternal() throws ConnectionException, AuthenticationException {
+                if (exception instanceof ConnectionException) {
                     throw (ConnectionException) exception;
                 }
-                if ( exception instanceof AuthenticationException )
-                {
+                if (exception instanceof AuthenticationException) {
                     throw (AuthenticationException) exception;
                 }
             }
         };
-        wagon.addSessionListener( sessionListener );
+        wagon.addSessionListener(sessionListener);
 
-        try
-        {
-            wagon.connect( repository );
+        try {
+            wagon.connect(repository);
             fail();
-        }
-        finally
-        {
-            verify( sessionListener );
+        } finally {
+            verify(sessionListener);
 
-            assertEquals( repository, wagon.getRepository() );
+            assertEquals(repository, wagon.getRepository());
         }
     }
 
-    public void testSessionCloseEvents()
-        throws Exception
-    {
-        sessionListener.sessionDisconnecting( anyObject( SessionEvent.class ) );
-        sessionListener.sessionDisconnected( anyObject( SessionEvent.class ) );
-        replay( sessionListener );
+    public void testSessionCloseEvents() throws Exception {
+        sessionListener.sessionDisconnecting(anyObject(SessionEvent.class));
+        sessionListener.sessionDisconnected(anyObject(SessionEvent.class));
+        replay(sessionListener);
 
         wagon.disconnect();
 
-        verify( sessionListener );
+        verify(sessionListener);
     }
 
-    public void testSessionCloseRefusedEventConnectionException()
-        throws Exception
-    {
+    public void testSessionCloseRefusedEventConnectionException() throws Exception {
         Repository repository = new Repository();
 
-        sessionListener.sessionDisconnecting( anyObject( SessionEvent.class ) );
-        sessionListener.sessionError( anyObject( SessionEvent.class ) );
-        replay( sessionListener );
+        sessionListener.sessionDisconnecting(anyObject(SessionEvent.class));
+        sessionListener.sessionError(anyObject(SessionEvent.class));
+        replay(sessionListener);
 
-        Wagon wagon = new TestWagon()
-        {
-            protected void closeConnection()
-                throws ConnectionException
-            {
-                throw new ConnectionException( "" );
+        Wagon wagon = new TestWagon() {
+            protected void closeConnection() throws ConnectionException {
+                throw new ConnectionException("");
             }
         };
-        wagon.addSessionListener( sessionListener );
+        wagon.addSessionListener(sessionListener);
 
-        try
-        {
+        try {
             wagon.disconnect();
             fail();
-        }
-        catch ( ConnectionException e )
-        {
-            assertTrue( true );
-        }
-        finally
-        {
-            verify( sessionListener );
+        } catch (ConnectionException e) {
+            assertTrue(true);
+        } finally {
+            verify(sessionListener);
         }
     }
 
-    public void testGetTransferEvents()
-        throws Exception
-    {
-        transferListener.debug( "fetch debug message" );
-        transferListener.transferInitiated( anyObject( TransferEvent.class ) );
-        transferListener.transferStarted( anyObject( TransferEvent.class ) );
-        transferListener.debug( anyString() );
+    public void testGetTransferEvents() throws Exception {
+        transferListener.debug("fetch debug message");
+        transferListener.transferInitiated(anyObject(TransferEvent.class));
+        transferListener.transferStarted(anyObject(TransferEvent.class));
+        transferListener.debug(anyString());
         expectLastCall().anyTimes();
-        transferListener.transferProgress( anyObject( TransferEvent.class ), anyObject( byte[].class ), anyInt() );
-        expectLastCall().times( 5 );
-        transferListener.transferCompleted( anyObject( TransferEvent.class ) );
-        replay( transferListener );
+        transferListener.transferProgress(anyObject(TransferEvent.class), anyObject(byte[].class), anyInt());
+        expectLastCall().times(5);
+        transferListener.transferCompleted(anyObject(TransferEvent.class));
+        replay(transferListener);
 
-        wagon.fireTransferDebug( "fetch debug message" );
+        wagon.fireTransferDebug("fetch debug message");
 
         Repository repository = new Repository();
-        wagon.connect( repository );
+        wagon.connect(repository);
 
-        wagon.get( artifact, destination );
+        wagon.get(artifact, destination);
 
-        verify( transferListener );
+        verify(transferListener);
     }
 
-    public void testGetError()
-        throws Exception
-    {
-        transferListener.transferInitiated( anyObject( TransferEvent.class ) );
-        transferListener.transferStarted( anyObject( TransferEvent.class ) );
-        transferListener.debug( anyString() );
+    public void testGetError() throws Exception {
+        transferListener.transferInitiated(anyObject(TransferEvent.class));
+        transferListener.transferStarted(anyObject(TransferEvent.class));
+        transferListener.debug(anyString());
         expectLastCall().anyTimes();
-        transferListener.transferError( anyObject( TransferEvent.class ) );
-        replay( transferListener );
+        transferListener.transferError(anyObject(TransferEvent.class));
+        replay(transferListener);
 
-        try
-        {
+        try {
             Repository repository = new Repository();
 
-            WagonMock wagon = new WagonMock( true );
+            WagonMock wagon = new WagonMock(true);
 
-            wagon.addTransferListener( transferListener );
+            wagon.addTransferListener(transferListener);
 
-            wagon.connect( repository );
+            wagon.connect(repository);
 
-            wagon.get( artifact, destination );
+            wagon.get(artifact, destination);
 
-            fail( "Transfer error was expected during deploy" );
-        }
-        catch ( TransferFailedException expected )
-        {
-            assertTrue( true );
+            fail("Transfer error was expected during deploy");
+        } catch (TransferFailedException expected) {
+            assertTrue(true);
         }
 
-        verify( transferListener );
+        verify(transferListener);
     }
 
     public void testPutTransferEvents()
-        throws ConnectionException, AuthenticationException, ResourceDoesNotExistException, TransferFailedException,
-        AuthorizationException
-    {
-        transferListener.debug( "deploy debug message" );
-        transferListener.transferInitiated( anyObject( TransferEvent.class ) );
-        transferListener.transferStarted( anyObject( TransferEvent.class ) );
-        transferListener.transferProgress( anyObject( TransferEvent.class ), anyObject( byte[].class ), anyInt() );
-        transferListener.transferCompleted( anyObject( TransferEvent.class ) );
-        replay( transferListener );
-
-        wagon.fireTransferDebug( "deploy debug message" );
+            throws ConnectionException, AuthenticationException, ResourceDoesNotExistException, TransferFailedException,
+                    AuthorizationException {
+        transferListener.debug("deploy debug message");
+        transferListener.transferInitiated(anyObject(TransferEvent.class));
+        transferListener.transferStarted(anyObject(TransferEvent.class));
+        transferListener.transferProgress(anyObject(TransferEvent.class), anyObject(byte[].class), anyInt());
+        transferListener.transferCompleted(anyObject(TransferEvent.class));
+        replay(transferListener);
+
+        wagon.fireTransferDebug("deploy debug message");
 
         Repository repository = new Repository();
 
-        wagon.connect( repository );
+        wagon.connect(repository);
 
-        wagon.put( source, artifact );
+        wagon.put(source, artifact);
 
-        verify( transferListener );
+        verify(transferListener);
     }
 
-    public void testStreamShutdown()
-    {
-        IOUtil.close( (InputStream) null );
+    public void testStreamShutdown() {
+        IOUtil.close((InputStream) null);
 
-        IOUtil.close( (OutputStream) null );
+        IOUtil.close((OutputStream) null);
 
         InputStreamMock inputStream = new InputStreamMock();
 
-        assertFalse( inputStream.isClosed() );
+        assertFalse(inputStream.isClosed());
 
-        IOUtil.close( inputStream );
+        IOUtil.close(inputStream);
 
-        assertTrue( inputStream.isClosed() );
+        assertTrue(inputStream.isClosed());
 
         OutputStreamMock outputStream = new OutputStreamMock();
 
-        assertFalse( outputStream.isClosed() );
+        assertFalse(outputStream.isClosed());
 
-        IOUtil.close( outputStream );
+        IOUtil.close(outputStream);
 
-        assertTrue( outputStream.isClosed() );
+        assertTrue(outputStream.isClosed());
     }
 
-    public void testRepositoryPermissionsOverride()
-        throws ConnectionException, AuthenticationException
-    {
+    public void testRepositoryPermissionsOverride() throws ConnectionException, AuthenticationException {
         Repository repository = new Repository();
 
         RepositoryPermissions original = new RepositoryPermissions();
-        original.setFileMode( "664" );
-        repository.setPermissions( original );
+        original.setFileMode("664");
+        repository.setPermissions(original);
 
         RepositoryPermissions override = new RepositoryPermissions();
-        override.setFileMode( "644" );
-        wagon.setPermissionsOverride( override );
+        override.setFileMode("644");
+        wagon.setPermissionsOverride(override);
 
-        wagon.connect( repository );
+        wagon.connect(repository);
 
-        assertEquals( override, repository.getPermissions() );
-        assertEquals( "644", repository.getPermissions().getFileMode() );
+        assertEquals(override, repository.getPermissions());
+        assertEquals("644", repository.getPermissions().getFileMode());
     }
 
-    public void testRepositoryUserName()
-        throws ConnectionException, AuthenticationException
-    {
-        Repository repository = new Repository( "id", "http://bporter:password@www.example.com/path/to/resource" );
+    public void testRepositoryUserName() throws ConnectionException, AuthenticationException {
+        Repository repository = new Repository("id", "http://bporter:password@www.example.com/path/to/resource");
 
         AuthenticationInfo authenticationInfo = new AuthenticationInfo();
-        authenticationInfo.setUserName( "brett" );
-        authenticationInfo.setPassword( "pass" );
-        wagon.connect( repository, authenticationInfo );
+        authenticationInfo.setUserName("brett");
+        authenticationInfo.setPassword("pass");
+        wagon.connect(repository, authenticationInfo);
 
-        assertEquals( authenticationInfo, wagon.getAuthenticationInfo() );
-        assertEquals( "brett", authenticationInfo.getUserName() );
-        assertEquals( "pass", authenticationInfo.getPassword() );
+        assertEquals(authenticationInfo, wagon.getAuthenticationInfo());
+        assertEquals("brett", authenticationInfo.getUserName());
+        assertEquals("pass", authenticationInfo.getPassword());
     }
 
-    public void testRepositoryUserNameNotGivenInCredentials()
-        throws ConnectionException, AuthenticationException
-    {
-        Repository repository = new Repository( "id", "http://bporter:password@www.example.com/path/to/resource" );
+    public void testRepositoryUserNameNotGivenInCredentials() throws ConnectionException, AuthenticationException {
+        Repository repository = new Repository("id", "http://bporter:password@www.example.com/path/to/resource");
 
         AuthenticationInfo authenticationInfo = new AuthenticationInfo();
-        wagon.connect( repository, authenticationInfo );
+        wagon.connect(repository, authenticationInfo);
 
-        assertEquals( authenticationInfo, wagon.getAuthenticationInfo() );
-        assertEquals( "bporter", authenticationInfo.getUserName() );
-        assertEquals( "password", authenticationInfo.getPassword() );
+        assertEquals(authenticationInfo, wagon.getAuthenticationInfo());
+        assertEquals("bporter", authenticationInfo.getUserName());
+        assertEquals("password", authenticationInfo.getPassword());
     }
 
-    public void testConnectNullRepository()
-        throws ConnectionException, AuthenticationException
-    {
-        try
-        {
-            wagon.connect( null );
+    public void testConnectNullRepository() throws ConnectionException, AuthenticationException {
+        try {
+            wagon.connect(null);
             fail();
-        }
-        catch ( NullPointerException e )
-        {
-            assertTrue( true );
+        } catch (NullPointerException e) {
+            assertTrue(true);
         }
     }
 
-    public void testPostProcessListeners()
-        throws TransferFailedException, IOException
-    {
-        File tempFile = File.createTempFile( "wagon", "tmp" );
+    public void testPostProcessListeners() throws TransferFailedException, IOException {
+        File tempFile = File.createTempFile("wagon", "tmp");
         tempFile.deleteOnExit();
         String content = "content";
-        FileUtils.fileWrite( tempFile.getAbsolutePath(), content );
+        FileUtils.fileWrite(tempFile.getAbsolutePath(), content);
 
-        Resource resource = new Resource( "resource" );
+        Resource resource = new Resource("resource");
 
-        transferListener.transferInitiated( anyObject( TransferEvent.class ) );
-        transferListener.transferStarted( anyObject( TransferEvent.class ) );
+        transferListener.transferInitiated(anyObject(TransferEvent.class));
+        transferListener.transferStarted(anyObject(TransferEvent.class));
         TransferEvent event =
-            new TransferEvent( wagon, resource, TransferEvent.TRANSFER_PROGRESS, TransferEvent.REQUEST_PUT );
-        event.setLocalFile( tempFile );
-        transferListener.transferProgress( eq( event ), anyObject( byte[].class ), eq( content.length() ) );
+                new TransferEvent(wagon, resource, TransferEvent.TRANSFER_PROGRESS, TransferEvent.REQUEST_PUT);
+        event.setLocalFile(tempFile);
+        transferListener.transferProgress(eq(event), anyObject(byte[].class), eq(content.length()));
         ProgressAnswer answer = new ProgressAnswer();
-        expectLastCall().andAnswer( answer );
-        transferListener.transferCompleted( anyObject( TransferEvent.class ) );
-        replay( transferListener );
+        expectLastCall().andAnswer(answer);
+        transferListener.transferCompleted(anyObject(TransferEvent.class));
+        replay(transferListener);
 
-        wagon.postProcessListeners( resource, tempFile, TransferEvent.REQUEST_PUT );
+        wagon.postProcessListeners(resource, tempFile, TransferEvent.REQUEST_PUT);
 
-        assertEquals( content.length(), answer.getSize() );
-        assertEquals( new String( content.getBytes() ), new String( answer.getBytes() ) );
+        assertEquals(content.length(), answer.getSize());
+        assertEquals(new String(content.getBytes()), new String(answer.getBytes()));
 
         tempFile.delete();
     }
 
-    static final class ProgressAnswer implements IAnswer
-    {
+    static final class ProgressAnswer implements IAnswer {
         private ByteArrayOutputStream baos = new ByteArrayOutputStream();
 
         private int size;
-        
-        public Object answer() throws Throwable
-        {
+
+        public Object answer() throws Throwable {
             byte[] buffer = (byte[]) getCurrentArguments()[1];
             int length = (Integer) getCurrentArguments()[2];
-            baos.write( buffer, 0, length );
+            baos.write(buffer, 0, length);
             size += length;
             return null;
         }
 
-        public int getSize()
-        {
+        public int getSize() {
             return size;
         }
 
-        public byte[] getBytes()
-        {
+        public byte[] getBytes() {
             return baos.toByteArray();
         }
     }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/CannotConnectExceptionTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/CannotConnectExceptionTest.java
index cb798c82..2f31141e 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/CannotConnectExceptionTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/CannotConnectExceptionTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import junit.framework.TestCase;
 
@@ -25,19 +24,16 @@ import junit.framework.TestCase;
  * @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
  *
  */
-public class CannotConnectExceptionTest
-    extends TestCase
-{
-    public void testCannotConnectExceptionTest()
-    {
-        ConnectionException ae = new ConnectionException( "message" );
+public class CannotConnectExceptionTest extends TestCase {
+    public void testCannotConnectExceptionTest() {
+        ConnectionException ae = new ConnectionException("message");
 
-        assertEquals( "message", ae.getMessage() );
+        assertEquals("message", ae.getMessage());
 
-        ae = new ConnectionException( "full-message", new Throwable( "cause" ) );
+        ae = new ConnectionException("full-message", new Throwable("cause"));
 
-        assertEquals( "full-message", ae.getMessage() );
+        assertEquals("full-message", ae.getMessage());
 
-        assertEquals( "cause", ae.getCause().getMessage() );
+        assertEquals("cause", ae.getCause().getMessage());
     }
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/InputStreamMock.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/InputStreamMock.java
index c624764e..d1f2384c 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/InputStreamMock.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/InputStreamMock.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,53 +16,45 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.IOException;
 import java.io.InputStream;
 
-
 /**
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class InputStreamMock
-    extends InputStream
-{
+public class InputStreamMock extends InputStream {
 
     private boolean closed = false;
 
     boolean forcedError = false;
 
-    public void close()
-    {
+    public void close() {
         closed = true;
     }
 
     /**
      * @return Returns the closed.
      */
-    public boolean isClosed()
-    {
+    public boolean isClosed() {
         return closed;
     }
 
     /**
      * @return Returns the forcedError.
      */
-    public boolean isForcedError()
-    {
+    public boolean isForcedError() {
         return forcedError;
     }
 
     /**
      * @see java.io.InputStream#read()
      */
-    public int read()
-        throws IOException
-    {
-        if ( forcedError )
-        {
-            throw new IOException( "Mock exception" );
+    public int read() throws IOException {
+        if (forcedError) {
+            throw new IOException("Mock exception");
         }
         return 0;
     }
@@ -72,9 +62,7 @@ public class InputStreamMock
     /**
      * @param forcedError The forcedError to set.
      */
-    public void setForcedError( final boolean forcedError )
-    {
+    public void setForcedError(final boolean forcedError) {
         this.forcedError = forcedError;
     }
-
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/LazyFileOutputStreamTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/LazyFileOutputStreamTest.java
index 006a5625..d630f035 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/LazyFileOutputStreamTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/LazyFileOutputStreamTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,45 +16,40 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
+
+import java.io.File;
 
 import junit.framework.TestCase;
 import org.codehaus.plexus.util.FileUtils;
 
-import java.io.File;
-
 /**
  * @author <a href="mailto:mmaczka@interia.pl">Michal Maczka</a>
  *
  */
-public class LazyFileOutputStreamTest
-    extends TestCase
-{
+public class LazyFileOutputStreamTest extends TestCase {
 
-    public void testFileCreation()
-        throws Exception
-    {
-        File file = File.createTempFile( getName(), null );
+    public void testFileCreation() throws Exception {
+        File file = File.createTempFile(getName(), null);
 
         file.delete();
 
-        assertFalse( file.exists() );
+        assertFalse(file.exists());
 
-        LazyFileOutputStream stream = new LazyFileOutputStream( file );
+        LazyFileOutputStream stream = new LazyFileOutputStream(file);
 
-        assertFalse( file.exists() );
+        assertFalse(file.exists());
 
         String expected = "michal";
 
-        stream.write( expected.getBytes() );
+        stream.write(expected.getBytes());
 
         stream.close();
 
-        assertTrue( file.exists() );
+        assertTrue(file.exists());
 
-        String actual = FileUtils.fileRead( file );
-
-        assertEquals( expected, actual );
+        String actual = FileUtils.fileRead(file);
 
+        assertEquals(expected, actual);
     }
-
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/NotAuthorizedExceptionTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/NotAuthorizedExceptionTest.java
index c86e5389..99b17313 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/NotAuthorizedExceptionTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/NotAuthorizedExceptionTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import junit.framework.TestCase;
 import org.apache.maven.wagon.authorization.AuthorizationException;
@@ -26,19 +25,16 @@ import org.apache.maven.wagon.authorization.AuthorizationException;
  * @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
  *
  */
-public class NotAuthorizedExceptionTest
-    extends TestCase
-{
-    public void testNotAuthorizedExceptionTest()
-    {
-        AuthorizationException ae = new AuthorizationException( "message" );
+public class NotAuthorizedExceptionTest extends TestCase {
+    public void testNotAuthorizedExceptionTest() {
+        AuthorizationException ae = new AuthorizationException("message");
 
-        assertEquals( "message", ae.getMessage() );
+        assertEquals("message", ae.getMessage());
 
-        ae = new AuthorizationException( "full-message", new Throwable( "cause" ) );
+        ae = new AuthorizationException("full-message", new Throwable("cause"));
 
-        assertEquals( "full-message", ae.getMessage() );
+        assertEquals("full-message", ae.getMessage());
 
-        assertEquals( "cause", ae.getCause().getMessage() );
+        assertEquals("cause", ae.getCause().getMessage());
     }
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/OutputStreamMock.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/OutputStreamMock.java
index 9266b348..cfd10fd5 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/OutputStreamMock.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/OutputStreamMock.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.IOException;
 import java.io.OutputStream;
@@ -26,55 +25,43 @@ import java.io.OutputStream;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class OutputStreamMock
-    extends OutputStream
-{
+public class OutputStreamMock extends OutputStream {
 
     private boolean closed = false;
 
     private boolean forcedError = false;
 
-    public void close()
-    {
+    public void close() {
         closed = true;
     }
 
     /**
      * @see java.io.OutputStream#write(int)
      */
-    public void write( final int b )
-        throws IOException
-    {
-        if ( forcedError )
-        {
-            throw new IOException( "Mock exception" );
+    public void write(final int b) throws IOException {
+        if (forcedError) {
+            throw new IOException("Mock exception");
         }
-
     }
 
     /**
      * @return Returns the closed.
      */
-    public boolean isClosed()
-    {
+    public boolean isClosed() {
         return closed;
     }
 
-
     /**
      * @return Returns the forcedError.
      */
-    public boolean isForcedError()
-    {
+    public boolean isForcedError() {
         return forcedError;
     }
 
     /**
      * @param forcedError The forcedError to set.
      */
-    public void setForcedError( final boolean forcedError )
-    {
+    public void setForcedError(final boolean forcedError) {
         this.forcedError = forcedError;
     }
-
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/PathUtilsTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/PathUtilsTest.java
index 0f092027..c2556eed 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/PathUtilsTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/PathUtilsTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.File;
 
@@ -27,310 +26,377 @@ import junit.framework.TestCase;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class PathUtilsTest
-    extends TestCase
-{
-    public void testFilenameResolving()
-    {
-        assertEquals( "filename", PathUtils.filename( "dir/filename" ) );
+public class PathUtilsTest extends TestCase {
+    public void testFilenameResolving() {
+        assertEquals("filename", PathUtils.filename("dir/filename"));
 
-        assertEquals( "filename", PathUtils.filename( "filename" ) );
+        assertEquals("filename", PathUtils.filename("filename"));
 
-        assertEquals( "filename", PathUtils.filename( "dir1/dir2/filename" ) );
+        assertEquals("filename", PathUtils.filename("dir1/dir2/filename"));
     }
 
-    public void testDirResolving()
-    {
-        assertEquals( "dir", PathUtils.dirname( "dir/filename" ) );
+    public void testDirResolving() {
+        assertEquals("dir", PathUtils.dirname("dir/filename"));
 
-        assertEquals( "", PathUtils.dirname( "filename" ) );
+        assertEquals("", PathUtils.dirname("filename"));
 
-        assertEquals( "dir1/dir2", PathUtils.dirname( "dir1/dir2/filename" ) );
+        assertEquals("dir1/dir2", PathUtils.dirname("dir1/dir2/filename"));
     }
 
-    public void testDirSpliting()
-    {
+    public void testDirSpliting() {
         final String path = "a/b/c";
 
-        final String[] dirs = PathUtils.dirnames( path );
+        final String[] dirs = PathUtils.dirnames(path);
 
-        assertNotNull( dirs );
+        assertNotNull(dirs);
 
-        assertEquals( 2, dirs.length );
+        assertEquals(2, dirs.length);
 
-        assertEquals( "a", dirs[0] );
-
-        assertEquals( "b", dirs[1] );
+        assertEquals("a", dirs[0]);
 
+        assertEquals("b", dirs[1]);
     }
 
-    public void testHostResolving()
-    {
-        assertEquals( "www.codehaus.org", PathUtils.host( "http://www.codehaus.org" ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( "HTTP://www.codehaus.org" ) );
-
-        assertEquals( "localhost", PathUtils.host( null ) );
-        assertEquals( "localhost", PathUtils.host( "file:///c:/temp" ) );
-        assertEquals( "localhost", PathUtils.host( "FILE:///c:/temp" ) );
+    public void testHostResolving() {
+        assertEquals("www.codehaus.org", PathUtils.host("http://www.codehaus.org"));
+        assertEquals("www.codehaus.org", PathUtils.host("HTTP://www.codehaus.org"));
 
+        assertEquals("localhost", PathUtils.host(null));
+        assertEquals("localhost", PathUtils.host("file:///c:/temp"));
+        assertEquals("localhost", PathUtils.host("FILE:///c:/temp"));
     }
 
-    public void testScmHostResolving()
-    {
-        assertEquals( "www.codehaus.org", PathUtils.host( "scm:svn:http://www.codehaus.org" ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( "SCM:SVN:HTTP://www.codehaus.org" ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( "scm:svn:http://www.codehaus.org/repos/module" ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( "SCM:SVN:HTTP://www.codehaus.org/repos/module" ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( "scm:cvs:pserver:anoncvs@www.codehaus.org:/root" ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( "SCM:CVS:pserver:anoncvs@www.codehaus.org:/root" ) );
+    public void testScmHostResolving() {
+        assertEquals("www.codehaus.org", PathUtils.host("scm:svn:http://www.codehaus.org"));
+        assertEquals("www.codehaus.org", PathUtils.host("SCM:SVN:HTTP://www.codehaus.org"));
+        assertEquals("www.codehaus.org", PathUtils.host("scm:svn:http://www.codehaus.org/repos/module"));
+        assertEquals("www.codehaus.org", PathUtils.host("SCM:SVN:HTTP://www.codehaus.org/repos/module"));
+        assertEquals("www.codehaus.org", PathUtils.host("scm:cvs:pserver:anoncvs@www.codehaus.org:/root"));
+        assertEquals("www.codehaus.org", PathUtils.host("SCM:CVS:pserver:anoncvs@www.codehaus.org:/root"));
     }
 
-    public void testProtocolResolving()
-    {
-        assertEquals( "http", PathUtils.protocol( "http://www.codehause.org" ) );
-        assertEquals( "HTTP", PathUtils.protocol( "HTTP://www.codehause.org" ) );
-        assertEquals( "file", PathUtils.protocol( "file:///c:/temp" ) );
-        assertEquals( "scm", PathUtils.protocol( "scm:svn:http://localhost/repos/module" ) );
-        assertEquals( "scm", PathUtils.protocol( "scm:cvs:pserver:anoncvs@cvs.apache.org:/home/cvspublic" ) );
+    public void testProtocolResolving() {
+        assertEquals("http", PathUtils.protocol("http://www.codehause.org"));
+        assertEquals("HTTP", PathUtils.protocol("HTTP://www.codehause.org"));
+        assertEquals("file", PathUtils.protocol("file:///c:/temp"));
+        assertEquals("scm", PathUtils.protocol("scm:svn:http://localhost/repos/module"));
+        assertEquals("scm", PathUtils.protocol("scm:cvs:pserver:anoncvs@cvs.apache.org:/home/cvspublic"));
     }
 
-    public void testUserInfo()
-    {
+    public void testUserInfo() {
         String urlWithUsername = "http://brett@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUsername ) );
-        assertNull( PathUtils.password( urlWithUsername ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUsername ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUsername ) );
+        assertEquals("brett", PathUtils.user(urlWithUsername));
+        assertNull(PathUtils.password(urlWithUsername));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUsername));
+        assertEquals("/", PathUtils.basedir(urlWithUsername));
 
         String urlWithUsernamePassword = "http://brett:porter@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUsernamePassword ) );
-        assertEquals( "porter", PathUtils.password( urlWithUsernamePassword ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUsernamePassword ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUsernamePassword ) );
+        assertEquals("brett", PathUtils.user(urlWithUsernamePassword));
+        assertEquals("porter", PathUtils.password(urlWithUsernamePassword));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUsernamePassword));
+        assertEquals("/", PathUtils.basedir(urlWithUsernamePassword));
     }
 
-    public void testSubversionUserInfo()
-    {
+    public void testSubversionUserInfo() {
         String urlWithUsername = "scm:svn:http://brett@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUsername ) );
-        assertNull( PathUtils.password( urlWithUsername ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUsername ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUsername ) );
+        assertEquals("brett", PathUtils.user(urlWithUsername));
+        assertNull(PathUtils.password(urlWithUsername));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUsername));
+        assertEquals("/", PathUtils.basedir(urlWithUsername));
 
         String urlWithUsernamePassword = "scm:svn:http://brett:porter@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUsernamePassword ) );
-        assertEquals( "porter", PathUtils.password( urlWithUsernamePassword ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUsernamePassword ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUsernamePassword ) );
+        assertEquals("brett", PathUtils.user(urlWithUsernamePassword));
+        assertEquals("porter", PathUtils.password(urlWithUsernamePassword));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUsernamePassword));
+        assertEquals("/", PathUtils.basedir(urlWithUsernamePassword));
 
         String urlWithUpperCaseProtocol = "SCM:SVN:HTTP://brett@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUpperCaseProtocol ) );
-        assertNull( PathUtils.password( urlWithUpperCaseProtocol ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUpperCaseProtocol ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUpperCaseProtocol ) );
+        assertEquals("brett", PathUtils.user(urlWithUpperCaseProtocol));
+        assertNull(PathUtils.password(urlWithUpperCaseProtocol));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUpperCaseProtocol));
+        assertEquals("/", PathUtils.basedir(urlWithUpperCaseProtocol));
     }
 
-    public void testCvsUserInfo()
-    {
+    public void testCvsUserInfo() {
         String urlWithUsername = "scm:cvs:pserver:brett@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUsername ) );
-        assertNull( PathUtils.password( urlWithUsername ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUsername ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUsername ) );
+        assertEquals("brett", PathUtils.user(urlWithUsername));
+        assertNull(PathUtils.password(urlWithUsername));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUsername));
+        assertEquals("/", PathUtils.basedir(urlWithUsername));
 
         String urlWithUsernamePassword = "scm:cvs:pserver:brett:porter@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUsernamePassword ) );
-        assertEquals( "porter", PathUtils.password( urlWithUsernamePassword ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUsernamePassword ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUsernamePassword ) );
+        assertEquals("brett", PathUtils.user(urlWithUsernamePassword));
+        assertEquals("porter", PathUtils.password(urlWithUsernamePassword));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUsernamePassword));
+        assertEquals("/", PathUtils.basedir(urlWithUsernamePassword));
 
         String urlWithUpperCaseProtocol = "SCM:CVS:pserver:brett@www.codehaus.org";
-        assertEquals( "brett", PathUtils.user( urlWithUpperCaseProtocol ) );
-        assertNull( PathUtils.password( urlWithUpperCaseProtocol ) );
-        assertEquals( "www.codehaus.org", PathUtils.host( urlWithUpperCaseProtocol ) );
-        assertEquals( "/", PathUtils.basedir( urlWithUpperCaseProtocol ) );
+        assertEquals("brett", PathUtils.user(urlWithUpperCaseProtocol));
+        assertNull(PathUtils.password(urlWithUpperCaseProtocol));
+        assertEquals("www.codehaus.org", PathUtils.host(urlWithUpperCaseProtocol));
+        assertEquals("/", PathUtils.basedir(urlWithUpperCaseProtocol));
     }
 
-    public void testFileBasedir()
-    {
+    public void testFileBasedir() {
         // see http://www.mozilla.org/quality/networking/testing/filetests.html
 
         // strict forms
-        assertEquals( "c:/temp", PathUtils.basedir( "file:///c|/temp" ) );
-        assertEquals( "localhost", PathUtils.host( "file:///c|/temp" ) );
-        assertEquals( "c:/temp", PathUtils.basedir( "file://localhost/c|/temp" ) );
-        assertEquals( "localhost", PathUtils.host( "file://localhost/c|/temp" ) );
-        assertEquals( "/temp", PathUtils.basedir( "file:///temp" ) );
-        assertEquals( "localhost", PathUtils.host( "file:///temp" ) );
-        assertEquals( "/temp", PathUtils.basedir( "file://localhost/temp" ) );
-        assertEquals( "localhost", PathUtils.host( "file://localhost/temp" ) );
+        assertEquals("c:/temp", PathUtils.basedir("file:///c|/temp"));
+        assertEquals("localhost", PathUtils.host("file:///c|/temp"));
+        assertEquals("c:/temp", PathUtils.basedir("file://localhost/c|/temp"));
+        assertEquals("localhost", PathUtils.host("file://localhost/c|/temp"));
+        assertEquals("/temp", PathUtils.basedir("file:///temp"));
+        assertEquals("localhost", PathUtils.host("file:///temp"));
+        assertEquals("/temp", PathUtils.basedir("file://localhost/temp"));
+        assertEquals("localhost", PathUtils.host("file://localhost/temp"));
 
         // strict form, with : for drive separator
-        assertEquals( "c:/temp", PathUtils.basedir( "file:///c:/temp" ) );
-        assertEquals( "localhost", PathUtils.host( "file:///c:/temp" ) );
-        assertEquals( "c:/temp", PathUtils.basedir( "file://localhost/c:/temp" ) );
-        assertEquals( "localhost", PathUtils.host( "file://localhost/c:/temp" ) );
+        assertEquals("c:/temp", PathUtils.basedir("file:///c:/temp"));
+        assertEquals("localhost", PathUtils.host("file:///c:/temp"));
+        assertEquals("c:/temp", PathUtils.basedir("file://localhost/c:/temp"));
+        assertEquals("localhost", PathUtils.host("file://localhost/c:/temp"));
 
         // convenience forms
-        assertEquals( "c:/temp", PathUtils.basedir( "file://c:/temp" ) );
-        assertEquals( "c:/temp", PathUtils.basedir( "file://c|/temp" ) );
-        assertEquals( "c:/temp", PathUtils.basedir( "file:c:/temp" ) );
-        assertEquals( "c:/temp", PathUtils.basedir( "file:c|/temp" ) );
-        assertEquals( "/temp", PathUtils.basedir( "file:/temp" ) );
+        assertEquals("c:/temp", PathUtils.basedir("file://c:/temp"));
+        assertEquals("c:/temp", PathUtils.basedir("file://c|/temp"));
+        assertEquals("c:/temp", PathUtils.basedir("file:c:/temp"));
+        assertEquals("c:/temp", PathUtils.basedir("file:c|/temp"));
+        assertEquals("/temp", PathUtils.basedir("file:/temp"));
 
         // URL decoding
-        assertEquals( "c:/my docs", PathUtils.basedir( "file:///c:/my docs" ) );
-        assertEquals( "c:/my docs", PathUtils.basedir( "file:///c:/my%20docs" ) );
-        assertEquals( "c:/name #%20?{}[]<>.txt", PathUtils.basedir( "file:///c:/name%20%23%2520%3F%7B%7D%5B%5D%3C%3E.txt" ) );
+        assertEquals("c:/my docs", PathUtils.basedir("file:///c:/my docs"));
+        assertEquals("c:/my docs", PathUtils.basedir("file:///c:/my%20docs"));
+        assertEquals(
+                "c:/name #%20?{}[]<>.txt", PathUtils.basedir("file:///c:/name%20%23%2520%3F%7B%7D%5B%5D%3C%3E.txt"));
 
-        assertEquals( "c:/temp", PathUtils.basedir( "FILE:///c:/temp" ) );
-        assertEquals( "localhost", PathUtils.host( "FILE:///c:/temp" ) );
+        assertEquals("c:/temp", PathUtils.basedir("FILE:///c:/temp"));
+        assertEquals("localhost", PathUtils.host("FILE:///c:/temp"));
     }
 
-    public void testEmptyBasedir()
-    {
-        assertEquals( "/", PathUtils.basedir( "http://www.codehaus.org:80" ) );
-        assertEquals( "/", PathUtils.basedir( "http://www.codehaus.org" ) );
-        assertEquals( "/", PathUtils.basedir( "http://www.codehaus.org:80/" ) );
-        assertEquals( "/", PathUtils.basedir( "http://www.codehaus.org/" ) );
-        assertEquals( "/", PathUtils.basedir( "HTTP://www.codehaus.org/" ) );
+    public void testEmptyBasedir() {
+        assertEquals("/", PathUtils.basedir("http://www.codehaus.org:80"));
+        assertEquals("/", PathUtils.basedir("http://www.codehaus.org"));
+        assertEquals("/", PathUtils.basedir("http://www.codehaus.org:80/"));
+        assertEquals("/", PathUtils.basedir("http://www.codehaus.org/"));
+        assertEquals("/", PathUtils.basedir("HTTP://www.codehaus.org/"));
     }
 
-    public void testEmptyProtocol()
-    {
-        assertEquals( "", PathUtils.protocol( "placeholder-only" ) );
-        assertEquals( "", PathUtils.protocol( "placeholder-only/module-a" ) );
+    public void testEmptyProtocol() {
+        assertEquals("", PathUtils.protocol("placeholder-only"));
+        assertEquals("", PathUtils.protocol("placeholder-only/module-a"));
 
-        assertEquals( "placeholder-only", PathUtils.authorization( "placeholder-only" ) );
-        assertEquals( "placeholder-only", PathUtils.authorization( "placeholder-only/module-a" ) );
+        assertEquals("placeholder-only", PathUtils.authorization("placeholder-only"));
+        assertEquals("placeholder-only", PathUtils.authorization("placeholder-only/module-a"));
 
-        assertEquals( -1, PathUtils.port( "placeholder-only" ) );
-        assertEquals( -1, PathUtils.port( "placeholder-only/module-a" ) );
+        assertEquals(-1, PathUtils.port("placeholder-only"));
+        assertEquals(-1, PathUtils.port("placeholder-only/module-a"));
 
-        assertEquals( "/", PathUtils.basedir( "placeholder-only" ) );
-        assertEquals( "/module-a", PathUtils.basedir( "placeholder-only/module-a" ) );
+        assertEquals("/", PathUtils.basedir("placeholder-only"));
+        assertEquals("/module-a", PathUtils.basedir("placeholder-only/module-a"));
     }
 
-    public void testPortResolving()
-    {
-        assertEquals( 80, PathUtils.port( "http://www.codehause.org:80/maven" ) );
-        assertEquals( 80, PathUtils.port( "HTTP://www.codehause.org:80/maven" ) );
-        assertEquals( WagonConstants.UNKNOWN_PORT, PathUtils.port( "http://localhost/temp" ) );
+    public void testPortResolving() {
+        assertEquals(80, PathUtils.port("http://www.codehause.org:80/maven"));
+        assertEquals(80, PathUtils.port("HTTP://www.codehause.org:80/maven"));
+        assertEquals(WagonConstants.UNKNOWN_PORT, PathUtils.port("http://localhost/temp"));
 
-        assertEquals( 10, PathUtils.port( "ftp://localhost:10" ) );
-        assertEquals( 10, PathUtils.port( "FTP://localhost:10" ) );
+        assertEquals(10, PathUtils.port("ftp://localhost:10"));
+        assertEquals(10, PathUtils.port("FTP://localhost:10"));
     }
 
-    public void testScmPortResolving()
-    {
-        assertEquals( 80, PathUtils.port( "scm:svn:http://www.codehaus.org:80/maven" ) );
-        assertEquals( 80, PathUtils.port( "SCM:SVN:HTTP://www.codehaus.org:80/maven" ) );
-        assertEquals( WagonConstants.UNKNOWN_PORT, PathUtils.port( "scm:cvs:pserver:anoncvs@localhost:/temp:module" ) );
+    public void testScmPortResolving() {
+        assertEquals(80, PathUtils.port("scm:svn:http://www.codehaus.org:80/maven"));
+        assertEquals(80, PathUtils.port("SCM:SVN:HTTP://www.codehaus.org:80/maven"));
+        assertEquals(WagonConstants.UNKNOWN_PORT, PathUtils.port("scm:cvs:pserver:anoncvs@localhost:/temp:module"));
 
-        assertEquals( 2402, PathUtils.port( "scm:cvs:pserver:anoncvs@localhost:2402/temp:module" ) );
-        assertEquals( 2402, PathUtils.port( "SCM:CVS:pserver:anoncvs@localhost:2402/temp:module" ) );
+        assertEquals(2402, PathUtils.port("scm:cvs:pserver:anoncvs@localhost:2402/temp:module"));
+        assertEquals(2402, PathUtils.port("SCM:CVS:pserver:anoncvs@localhost:2402/temp:module"));
     }
 
-    public void testScmBasedir()
-    {
-        assertEquals( "/maven", PathUtils.basedir( "scm:svn:http://www.codehause.org/maven" ) );
-        assertEquals( "/maven", PathUtils.basedir( "SCM:SVN:HTTP://www.codehause.org/maven" ) );
-        assertEquals( "/maven", PathUtils.basedir( "scm:svn:http://www.codehause.org:80/maven" ) );
-        assertEquals( "/maven", PathUtils.basedir( "scm:cvs:pserver:anoncvs@www.codehause.org:80/maven" ) );
-        assertEquals( "/maven", PathUtils.basedir( "scm:cvs:pserver:anoncvs@www.codehause.org:/maven" ) );
-        assertEquals( "/maven/module", PathUtils.basedir( "scm:cvs:pserver:anoncvs@www.codehause.org:80/maven:module" ) );
-        assertEquals( "/maven/module", PathUtils.basedir( "scm:cvs:pserver:anoncvs@www.codehause.org:/maven:module" ) );
-        assertEquals( "/maven/module", PathUtils.basedir( "SCM:CVS:pserver:anoncvs@www.codehause.org:/maven:module" ) );
+    public void testScmBasedir() {
+        assertEquals("/maven", PathUtils.basedir("scm:svn:http://www.codehause.org/maven"));
+        assertEquals("/maven", PathUtils.basedir("SCM:SVN:HTTP://www.codehause.org/maven"));
+        assertEquals("/maven", PathUtils.basedir("scm:svn:http://www.codehause.org:80/maven"));
+        assertEquals("/maven", PathUtils.basedir("scm:cvs:pserver:anoncvs@www.codehause.org:80/maven"));
+        assertEquals("/maven", PathUtils.basedir("scm:cvs:pserver:anoncvs@www.codehause.org:/maven"));
+        assertEquals("/maven/module", PathUtils.basedir("scm:cvs:pserver:anoncvs@www.codehause.org:80/maven:module"));
+        assertEquals("/maven/module", PathUtils.basedir("scm:cvs:pserver:anoncvs@www.codehause.org:/maven:module"));
+        assertEquals("/maven/module", PathUtils.basedir("SCM:CVS:pserver:anoncvs@www.codehause.org:/maven:module"));
     }
 
-    public void testPortBasedir()
-    {
-        assertEquals( "/maven", PathUtils.basedir( "http://www.codehause.org:80/maven" ) );
-        assertEquals( "/temp", PathUtils.basedir( "http://localhost/temp" ) );
+    public void testPortBasedir() {
+        assertEquals("/maven", PathUtils.basedir("http://www.codehause.org:80/maven"));
+        assertEquals("/temp", PathUtils.basedir("http://localhost/temp"));
 
-        assertEquals( "c:/temp", PathUtils.basedir( "file://c:/temp" ) );
-        assertEquals( "/", PathUtils.basedir( "http://localhost:80/" ) );
-        assertEquals( "/", PathUtils.basedir( "http://localhost/" ) );
+        assertEquals("c:/temp", PathUtils.basedir("file://c:/temp"));
+        assertEquals("/", PathUtils.basedir("http://localhost:80/"));
+        assertEquals("/", PathUtils.basedir("http://localhost/"));
     }
 
-    public void testIpV4()
-    {
-        assertUrl( "http://127.0.0.1", "http", null, null, "127.0.0.1", -1, "/" );
-        assertUrl( "http://127.0.0.1:8080", "http", null, null, "127.0.0.1", 8080, "/" );
-        assertUrl( "http://127.0.0.1/oo/rest/users", "http", null, null, "127.0.0.1", -1, "/oo/rest/users" );
-        assertUrl( "http://127.0.0.1:8080/oo/rest/users", "http", null, null, "127.0.0.1", 8080, "/oo/rest/users" );
-
-        assertUrl( "http://user:password@127.0.0.1", "http", "user", "password", "127.0.0.1", -1, "/" );
-        assertUrl( "http://user:password@127.0.0.1:8080", "http", "user", "password", "127.0.0.1", 8080, "/" );
-        assertUrl( "http://user:password@127.0.0.1/oo/rest/users", "http", "user", "password", "127.0.0.1", -1,
-                   "/oo/rest/users" );
-        assertUrl( "http://user:password@127.0.0.1:8080/oo/rest/users", "http", "user", "password", "127.0.0.1", 8080,
-                   "/oo/rest/users" );
-
-        assertUrl( "scm:svn:http://user:password@127.0.0.1:8080/oo/rest/users", "scm", "user", "password", "127.0.0.1",
-                   8080, "/oo/rest/users" );
+    public void testIpV4() {
+        assertUrl("http://127.0.0.1", "http", null, null, "127.0.0.1", -1, "/");
+        assertUrl("http://127.0.0.1:8080", "http", null, null, "127.0.0.1", 8080, "/");
+        assertUrl("http://127.0.0.1/oo/rest/users", "http", null, null, "127.0.0.1", -1, "/oo/rest/users");
+        assertUrl("http://127.0.0.1:8080/oo/rest/users", "http", null, null, "127.0.0.1", 8080, "/oo/rest/users");
+
+        assertUrl("http://user:password@127.0.0.1", "http", "user", "password", "127.0.0.1", -1, "/");
+        assertUrl("http://user:password@127.0.0.1:8080", "http", "user", "password", "127.0.0.1", 8080, "/");
+        assertUrl(
+                "http://user:password@127.0.0.1/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "127.0.0.1",
+                -1,
+                "/oo/rest/users");
+        assertUrl(
+                "http://user:password@127.0.0.1:8080/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "127.0.0.1",
+                8080,
+                "/oo/rest/users");
+
+        assertUrl(
+                "scm:svn:http://user:password@127.0.0.1:8080/oo/rest/users",
+                "scm",
+                "user",
+                "password",
+                "127.0.0.1",
+                8080,
+                "/oo/rest/users");
     }
 
-    public void testIPv6()
-    {
-        assertUrl( "http://user:password@[fff:::1]:7891/oo/rest/users", "http", "user", "password", "fff:::1", 7891,
-                   "/oo/rest/users" );
-        assertUrl( "http://[fff:::1]:7891/oo/rest/users", "http", null, null, "fff:::1", 7891, "/oo/rest/users" );
-        assertUrl( "http://user:password@[fff:::1]/oo/rest/users", "http", "user", "password", "fff:::1", -1,
-                   "/oo/rest/users" );
-        assertUrl( "http://user:password@[fff:::1]:7891", "http", "user", "password", "fff:::1", 7891, "/" );
-
-        assertUrl( "http://user:password@[fff:000::222:1111]:7891/oo/rest/users", "http", "user", "password",
-                   "fff:000::222:1111", 7891, "/oo/rest/users" );
-        assertUrl( "http://[fff:000::222:1111]:7891/oo/rest/users", "http", null, null, "fff:000::222:1111", 7891,
-                   "/oo/rest/users" );
-        assertUrl( "http://user:password@[fff:000::222:1111]/oo/rest/users", "http", "user", "password",
-                   "fff:000::222:1111", -1, "/oo/rest/users" );
-        assertUrl( "http://user:password@[fff:000::222:1111]:7891", "http", "user", "password", "fff:000::222:1111",
-                   7891, "/" );
-
-        assertUrl( "http://user:password@16.60.56.58:7891/oo/rest/users", "http", "user", "password", "16.60.56.58",
-                   7891, "/oo/rest/users" );
-        assertUrl( "http://16.60.56.58:7891/oo/rest/users", "http", null, null, "16.60.56.58", 7891, "/oo/rest/users" );
-        assertUrl( "http://user:password@16.60.56.58/oo/rest/users", "http", "user", "password", "16.60.56.58", -1,
-                   "/oo/rest/users" );
-        assertUrl( "http://user:password@16.60.56.58:7891", "http", "user", "password", "16.60.56.58", 7891, "/" );
-
-        assertUrl( "http://user:password@16.60.56.58:7891/oo/rest/users", "http", "user", "password", "16.60.56.58",
-                   7891, "/oo/rest/users" );
-        assertUrl( "http://16.60.56.58:7891/oo/rest/users", "http", null, null, "16.60.56.58", 7891, "/oo/rest/users" );
-        assertUrl( "http://user:password@16.60.56.58/oo/rest/users", "http", "user", "password", "16.60.56.58", -1,
-                   "/oo/rest/users" );
-        assertUrl( "http://user:password@16.60.56.58:7891", "http", "user", "password", "16.60.56.58", 7891, "/" );
+    public void testIPv6() {
+        assertUrl(
+                "http://user:password@[fff:::1]:7891/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "fff:::1",
+                7891,
+                "/oo/rest/users");
+        assertUrl("http://[fff:::1]:7891/oo/rest/users", "http", null, null, "fff:::1", 7891, "/oo/rest/users");
+        assertUrl(
+                "http://user:password@[fff:::1]/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "fff:::1",
+                -1,
+                "/oo/rest/users");
+        assertUrl("http://user:password@[fff:::1]:7891", "http", "user", "password", "fff:::1", 7891, "/");
+
+        assertUrl(
+                "http://user:password@[fff:000::222:1111]:7891/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "fff:000::222:1111",
+                7891,
+                "/oo/rest/users");
+        assertUrl(
+                "http://[fff:000::222:1111]:7891/oo/rest/users",
+                "http",
+                null,
+                null,
+                "fff:000::222:1111",
+                7891,
+                "/oo/rest/users");
+        assertUrl(
+                "http://user:password@[fff:000::222:1111]/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "fff:000::222:1111",
+                -1,
+                "/oo/rest/users");
+        assertUrl(
+                "http://user:password@[fff:000::222:1111]:7891",
+                "http",
+                "user",
+                "password",
+                "fff:000::222:1111",
+                7891,
+                "/");
+
+        assertUrl(
+                "http://user:password@16.60.56.58:7891/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "16.60.56.58",
+                7891,
+                "/oo/rest/users");
+        assertUrl("http://16.60.56.58:7891/oo/rest/users", "http", null, null, "16.60.56.58", 7891, "/oo/rest/users");
+        assertUrl(
+                "http://user:password@16.60.56.58/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "16.60.56.58",
+                -1,
+                "/oo/rest/users");
+        assertUrl("http://user:password@16.60.56.58:7891", "http", "user", "password", "16.60.56.58", 7891, "/");
+
+        assertUrl(
+                "http://user:password@16.60.56.58:7891/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "16.60.56.58",
+                7891,
+                "/oo/rest/users");
+        assertUrl("http://16.60.56.58:7891/oo/rest/users", "http", null, null, "16.60.56.58", 7891, "/oo/rest/users");
+        assertUrl(
+                "http://user:password@16.60.56.58/oo/rest/users",
+                "http",
+                "user",
+                "password",
+                "16.60.56.58",
+                -1,
+                "/oo/rest/users");
+        assertUrl("http://user:password@16.60.56.58:7891", "http", "user", "password", "16.60.56.58", 7891, "/");
     }
 
-    private void assertUrl( String url, String protocol, String user, String password, String host, int port,
-                            String basedir )
-    {
-        assertEquals( protocol, PathUtils.protocol( url ) );
-        assertEquals( user, PathUtils.user( url ) );
-        assertEquals( password, PathUtils.password( url ) );
-        assertEquals( host, PathUtils.host( url ) );
-        assertEquals( port, PathUtils.port( url ) );
-        assertEquals( basedir, PathUtils.basedir( url ) );
+    private void assertUrl(
+            String url, String protocol, String user, String password, String host, int port, String basedir) {
+        assertEquals(protocol, PathUtils.protocol(url));
+        assertEquals(user, PathUtils.user(url));
+        assertEquals(password, PathUtils.password(url));
+        assertEquals(host, PathUtils.host(url));
+        assertEquals(port, PathUtils.port(url));
+        assertEquals(basedir, PathUtils.basedir(url));
     }
 
-    public void testToRelative()
-    {
-        assertEquals( "dir", PathUtils.toRelative( new File( "/home/user" ).getAbsoluteFile(),
-                                                   new File( "/home/user/dir" ).getAbsolutePath() ) );
-        assertEquals( "dir", PathUtils.toRelative( new File( "C:/home/user" ).getAbsoluteFile(),
-                                                   new File( "C:/home/user/dir" ).getAbsolutePath() ) );
-
-        assertEquals( "dir/subdir", PathUtils.toRelative( new File( "/home/user" ).getAbsoluteFile(),
-                                                          new File( "/home/user/dir/subdir" ).getAbsolutePath() ) );
-        assertEquals( "dir/subdir", PathUtils.toRelative( new File( "C:/home/user" ).getAbsoluteFile(),
-                                                          new File( "C:/home/user/dir/subdir" ).getAbsolutePath() ) );
-
-        assertEquals( ".", PathUtils.toRelative( new File( "/home/user" ).getAbsoluteFile(),
-                                                 new File( "/home/user" ).getAbsolutePath() ) );
-        assertEquals( ".", PathUtils.toRelative( new File( "C:/home/user" ).getAbsoluteFile(),
-                                                 new File( "C:/home/user" ).getAbsolutePath() ) );
+    public void testToRelative() {
+        assertEquals(
+                "dir",
+                PathUtils.toRelative(
+                        new File("/home/user").getAbsoluteFile(), new File("/home/user/dir").getAbsolutePath()));
+        assertEquals(
+                "dir",
+                PathUtils.toRelative(
+                        new File("C:/home/user").getAbsoluteFile(), new File("C:/home/user/dir").getAbsolutePath()));
+
+        assertEquals(
+                "dir/subdir",
+                PathUtils.toRelative(
+                        new File("/home/user").getAbsoluteFile(), new File("/home/user/dir/subdir").getAbsolutePath()));
+        assertEquals(
+                "dir/subdir",
+                PathUtils.toRelative(
+                        new File("C:/home/user").getAbsoluteFile(),
+                        new File("C:/home/user/dir/subdir").getAbsolutePath()));
+
+        assertEquals(
+                ".",
+                PathUtils.toRelative(
+                        new File("/home/user").getAbsoluteFile(), new File("/home/user").getAbsolutePath()));
+        assertEquals(
+                ".",
+                PathUtils.toRelative(
+                        new File("C:/home/user").getAbsoluteFile(), new File("C:/home/user").getAbsolutePath()));
     }
-
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/PermissionModeUtilsTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/PermissionModeUtilsTest.java
index 2dbc36fb..f5314d1a 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/PermissionModeUtilsTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/PermissionModeUtilsTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import junit.framework.TestCase;
 
@@ -28,15 +27,11 @@ import junit.framework.TestCase;
  * @see PermissionModeUtils
  * @since Sep 3, 2005
  */
-public class PermissionModeUtilsTest
-    extends TestCase
-{
+public class PermissionModeUtilsTest extends TestCase {
     /**
      * @throws Exception on error
      */
-    public void testNumeric()
-        throws Exception
-    {
+    public void testNumeric() throws Exception {
         final String[][] tests = {
             {"0", "777"},
             {"0000", "777"},
@@ -48,23 +43,18 @@ public class PermissionModeUtilsTest
             {"ug+rwX,o-rwX", "ug+rwX,o-rwX"},
             {"1770", "7"},
             {"14770", "7"},
-
         };
 
-        for ( String[] test : tests )
-        {
+        for (String[] test : tests) {
             String umask = null;
 
-            try
-            {
-                umask = PermissionModeUtils.getUserMaskFor( test[ 0 ] );
-            }
-            catch ( IllegalArgumentException e )
-            {
+            try {
+                umask = PermissionModeUtils.getUserMaskFor(test[0]);
+            } catch (IllegalArgumentException e) {
                 // nothing to do
             }
 
-            assertEquals( test[ 1 ], umask );
+            assertEquals(test[1], umask);
         }
     }
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/ResourceDoesNotExistExceptionTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/ResourceDoesNotExistExceptionTest.java
index 51231137..ef33f1e1 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/ResourceDoesNotExistExceptionTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/ResourceDoesNotExistExceptionTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import junit.framework.TestCase;
 
@@ -25,19 +24,16 @@ import junit.framework.TestCase;
  * @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
  *
  */
-public class ResourceDoesNotExistExceptionTest
-    extends TestCase
-{
-    public void testResourceDoesNotExistExceptionTest()
-    {
-        ResourceDoesNotExistException ae = new ResourceDoesNotExistException( "message" );
+public class ResourceDoesNotExistExceptionTest extends TestCase {
+    public void testResourceDoesNotExistExceptionTest() {
+        ResourceDoesNotExistException ae = new ResourceDoesNotExistException("message");
 
-        assertEquals( "message", ae.getMessage() );
+        assertEquals("message", ae.getMessage());
 
-        ae = new ResourceDoesNotExistException( "full-message", new Throwable( "cause" ) );
+        ae = new ResourceDoesNotExistException("full-message", new Throwable("cause"));
 
-        assertEquals( "full-message", ae.getMessage() );
+        assertEquals("full-message", ae.getMessage());
 
-        assertEquals( "cause", ae.getCause().getMessage() );
+        assertEquals("cause", ae.getCause().getMessage());
     }
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/StreamWagonTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/StreamWagonTest.java
index 5904cbd6..b4b73572 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/StreamWagonTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/StreamWagonTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,13 +16,13 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.File;
 import java.io.IOException;
 import java.text.SimpleDateFormat;
 
 import junit.framework.TestCase;
-
 import org.apache.maven.wagon.authentication.AuthenticationException;
 import org.apache.maven.wagon.authorization.AuthorizationException;
 import org.apache.maven.wagon.events.TransferEvent;
@@ -37,507 +35,378 @@ import org.codehaus.plexus.util.StringOutputStream;
 
 import static org.easymock.EasyMock.*;
 
-public class StreamWagonTest
-    extends TestCase
-{
-    private static class TestWagon
-        extends StreamWagon
-    {
-        public void closeConnection()
-            throws ConnectionException
-        {
-        }
+public class StreamWagonTest extends TestCase {
+    private static class TestWagon extends StreamWagon {
+        public void closeConnection() throws ConnectionException {}
 
-        public void fillInputData( InputData inputData )
-            throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-        {
-        }
+        public void fillInputData(InputData inputData)
+                throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {}
 
-        public void fillOutputData( OutputData outputData )
-            throws TransferFailedException
-        {
-        }
+        public void fillOutputData(OutputData outputData) throws TransferFailedException {}
 
-        protected void openConnectionInternal()
-            throws ConnectionException, AuthenticationException
-        {
-        }
+        protected void openConnectionInternal() throws ConnectionException, AuthenticationException {}
     }
 
-    private Repository repository = new Repository( "id", "url" );
+    private Repository repository = new Repository("id", "url");
 
-    public void testNullInputStream()
-        throws Exception
-    {
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillInputData( InputData inputData )
-            {
-                inputData.setInputStream( null );
+    public void testNullInputStream() throws Exception {
+        StreamingWagon wagon = new TestWagon() {
+            public void fillInputData(InputData inputData) {
+                inputData.setInputStream(null);
             }
         };
 
-        TransferListener listener = createMock( TransferListener.class );
-        listener.transferInitiated( anyObject( TransferEvent.class ) );
-        TransferEvent transferEvent =
-            new TransferEvent( wagon, new Resource( "resource" ), new TransferFailedException( "" ),
-                               TransferEvent.REQUEST_GET );
-        listener.transferError( transferEvent );
-        replay( listener );
-
-        wagon.connect( repository );
-        wagon.addTransferListener( listener );
-        try
-        {
-            wagon.getToStream( "resource", new StringOutputStream() );
+        TransferListener listener = createMock(TransferListener.class);
+        listener.transferInitiated(anyObject(TransferEvent.class));
+        TransferEvent transferEvent = new TransferEvent(
+                wagon, new Resource("resource"), new TransferFailedException(""), TransferEvent.REQUEST_GET);
+        listener.transferError(transferEvent);
+        replay(listener);
+
+        wagon.connect(repository);
+        wagon.addTransferListener(listener);
+        try {
+            wagon.getToStream("resource", new StringOutputStream());
             fail();
-        }
-        catch ( TransferFailedException e )
-        {
-            assertTrue( true );
-        }
-        finally
-        {
+        } catch (TransferFailedException e) {
+            assertTrue(true);
+        } finally {
             wagon.disconnect();
         }
 
-        verify( listener );
+        verify(listener);
     }
 
-    public void testNullOutputStream()
-        throws Exception
-    {
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillOutputData( OutputData inputData )
-            {
-                inputData.setOutputStream( null );
+    public void testNullOutputStream() throws Exception {
+        StreamingWagon wagon = new TestWagon() {
+            public void fillOutputData(OutputData inputData) {
+                inputData.setOutputStream(null);
             }
         };
 
-        TransferListener listener = createMock( TransferListener.class );
-        listener.transferInitiated( anyObject( TransferEvent.class ) );
-        TransferEvent transferEvent =
-            new TransferEvent( wagon, new Resource( "resource" ), new TransferFailedException( "" ),
-                               TransferEvent.REQUEST_PUT );
-        listener.transferError( transferEvent );
-        replay( listener );
-
-        wagon.connect( repository );
-        wagon.addTransferListener( listener );
-        try
-        {
-            wagon.putFromStream( new StringInputStream( "" ), "resource" );
+        TransferListener listener = createMock(TransferListener.class);
+        listener.transferInitiated(anyObject(TransferEvent.class));
+        TransferEvent transferEvent = new TransferEvent(
+                wagon, new Resource("resource"), new TransferFailedException(""), TransferEvent.REQUEST_PUT);
+        listener.transferError(transferEvent);
+        replay(listener);
+
+        wagon.connect(repository);
+        wagon.addTransferListener(listener);
+        try {
+            wagon.putFromStream(new StringInputStream(""), "resource");
             fail();
-        }
-        catch ( TransferFailedException e )
-        {
-            assertTrue( true );
-        }
-        finally
-        {
+        } catch (TransferFailedException e) {
+            assertTrue(true);
+        } finally {
             wagon.disconnect();
         }
 
-        verify( listener );
+        verify(listener);
     }
 
-    public void testTransferFailedExceptionOnInput()
-        throws Exception
-    {
-        try
-        {
-            runTestTransferError( new TransferFailedException( "" ) );
+    public void testTransferFailedExceptionOnInput() throws Exception {
+        try {
+            runTestTransferError(new TransferFailedException(""));
             fail();
-        }
-        catch ( TransferFailedException e )
-        {
-            assertTrue( true );
+        } catch (TransferFailedException e) {
+            assertTrue(true);
         }
     }
 
-    public void testTransferFailedExceptionOnOutput()
-        throws Exception
-    {
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillOutputData( OutputData inputData )
-                throws TransferFailedException
-            {
-                throw (TransferFailedException) new TransferFailedException( "" );
+    public void testTransferFailedExceptionOnOutput() throws Exception {
+        StreamingWagon wagon = new TestWagon() {
+            public void fillOutputData(OutputData inputData) throws TransferFailedException {
+                throw (TransferFailedException) new TransferFailedException("");
             }
         };
 
-        TransferListener listener = createMock( TransferListener.class );
-        listener.transferInitiated( anyObject( TransferEvent.class ) );
-        TransferEvent transferEvent =
-            new TransferEvent( wagon, new Resource( "resource" ), new TransferFailedException( "" ),
-                               TransferEvent.REQUEST_PUT );
-        listener.transferError( transferEvent );
-        replay( listener );
-
-        wagon.connect( repository );
-        wagon.addTransferListener( listener );
-        try
-        {
-            wagon.putFromStream( new StringInputStream( "" ), "resource" );
+        TransferListener listener = createMock(TransferListener.class);
+        listener.transferInitiated(anyObject(TransferEvent.class));
+        TransferEvent transferEvent = new TransferEvent(
+                wagon, new Resource("resource"), new TransferFailedException(""), TransferEvent.REQUEST_PUT);
+        listener.transferError(transferEvent);
+        replay(listener);
+
+        wagon.connect(repository);
+        wagon.addTransferListener(listener);
+        try {
+            wagon.putFromStream(new StringInputStream(""), "resource");
             fail();
-        }
-        catch ( TransferFailedException e )
-        {
-            assertTrue( true );
-        }
-        finally
-        {
+        } catch (TransferFailedException e) {
+            assertTrue(true);
+        } finally {
             wagon.disconnect();
-            verify( listener );
+            verify(listener);
         }
     }
 
-    public void testResourceDoesNotExistException()
-        throws Exception
-    {
-        try
-        {
-            runTestTransferError( new ResourceDoesNotExistException( "" ) );
+    public void testResourceDoesNotExistException() throws Exception {
+        try {
+            runTestTransferError(new ResourceDoesNotExistException(""));
             fail();
-        }
-        catch ( ResourceDoesNotExistException e )
-        {
-            assertTrue( true );
+        } catch (ResourceDoesNotExistException e) {
+            assertTrue(true);
         }
     }
 
-    public void testAuthorizationException()
-        throws Exception
-    {
-        try
-        {
-            runTestTransferError( new AuthorizationException( "" ) );
+    public void testAuthorizationException() throws Exception {
+        try {
+            runTestTransferError(new AuthorizationException(""));
             fail();
-        }
-        catch ( AuthorizationException e )
-        {
-            assertTrue( true );
+        } catch (AuthorizationException e) {
+            assertTrue(true);
         }
     }
 
-    private void runTestTransferError( final WagonException exception )
-        throws ConnectionException, AuthenticationException, ResourceDoesNotExistException, AuthorizationException,
-        TransferFailedException
-    {
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillInputData( InputData inputData )
-                throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException
-            {
-                if ( exception instanceof TransferFailedException )
-                {
+    private void runTestTransferError(final WagonException exception)
+            throws ConnectionException, AuthenticationException, ResourceDoesNotExistException, AuthorizationException,
+                    TransferFailedException {
+        StreamingWagon wagon = new TestWagon() {
+            public void fillInputData(InputData inputData)
+                    throws TransferFailedException, ResourceDoesNotExistException, AuthorizationException {
+                if (exception instanceof TransferFailedException) {
                     throw (TransferFailedException) exception;
                 }
-                if ( exception instanceof ResourceDoesNotExistException )
-                {
+                if (exception instanceof ResourceDoesNotExistException) {
                     throw (ResourceDoesNotExistException) exception;
                 }
-                if ( exception instanceof AuthorizationException )
-                {
+                if (exception instanceof AuthorizationException) {
                     throw (AuthorizationException) exception;
                 }
             }
         };
 
-        TransferListener listener = createMock( TransferListener.class );
-        listener.transferInitiated( anyObject( TransferEvent.class ) );
+        TransferListener listener = createMock(TransferListener.class);
+        listener.transferInitiated(anyObject(TransferEvent.class));
         TransferEvent transferEvent =
-            new TransferEvent( wagon, new Resource( "resource" ), exception, TransferEvent.REQUEST_GET );
-        listener.transferError( transferEvent );
-        replay( listener );
-
-        wagon.connect( repository );
-        wagon.addTransferListener( listener );
-        try
-        {
-            wagon.getToStream( "resource", new StringOutputStream() );
+                new TransferEvent(wagon, new Resource("resource"), exception, TransferEvent.REQUEST_GET);
+        listener.transferError(transferEvent);
+        replay(listener);
+
+        wagon.connect(repository);
+        wagon.addTransferListener(listener);
+        try {
+            wagon.getToStream("resource", new StringOutputStream());
             fail();
-        }
-        finally
-        {
+        } finally {
             wagon.disconnect();
-            verify( listener );
+            verify(listener);
         }
     }
 
-    public void testGetIfNewerWithNewerResource()
-        throws Exception
-    {
+    public void testGetIfNewerWithNewerResource() throws Exception {
         long resourceTime = System.currentTimeMillis();
-        long comparisonTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        assertTrue( runTestGetIfNewer( resourceTime, comparisonTime ) );
+        long comparisonTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        assertTrue(runTestGetIfNewer(resourceTime, comparisonTime));
     }
 
-    public void testGetIfNewerWithOlderResource()
-        throws Exception
-    {
+    public void testGetIfNewerWithOlderResource() throws Exception {
         long comparisonTime = System.currentTimeMillis();
-        long resourceTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        assertFalse( runTestGetIfNewer( resourceTime, comparisonTime ) );
+        long resourceTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        assertFalse(runTestGetIfNewer(resourceTime, comparisonTime));
     }
 
-    public void testGetIfNewerWithSameTimeResource()
-        throws Exception
-    {
-        long resourceTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        assertFalse( runTestGetIfNewer( resourceTime, resourceTime ) );
+    public void testGetIfNewerWithSameTimeResource() throws Exception {
+        long resourceTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        assertFalse(runTestGetIfNewer(resourceTime, resourceTime));
     }
 
-    private boolean runTestGetIfNewer( final long resourceTime, long comparisonTime )
-        throws IOException, ConnectionException, AuthenticationException, TransferFailedException,
-        ResourceDoesNotExistException, AuthorizationException
-    {
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillInputData( InputData inputData )
-            {
-                inputData.setInputStream( new StringInputStream( "" ) );
-                inputData.getResource().setLastModified( resourceTime );
+    private boolean runTestGetIfNewer(final long resourceTime, long comparisonTime)
+            throws IOException, ConnectionException, AuthenticationException, TransferFailedException,
+                    ResourceDoesNotExistException, AuthorizationException {
+        StreamingWagon wagon = new TestWagon() {
+            public void fillInputData(InputData inputData) {
+                inputData.setInputStream(new StringInputStream(""));
+                inputData.getResource().setLastModified(resourceTime);
             }
         };
 
-        File tempFile = File.createTempFile( "wagon", "tmp" );
+        File tempFile = File.createTempFile("wagon", "tmp");
         tempFile.deleteOnExit();
 
-        wagon.connect( repository );
-        try
-        {
-            return wagon.getIfNewer( "resource", tempFile, comparisonTime );
-        }
-        finally
-        {
+        wagon.connect(repository);
+        try {
+            return wagon.getIfNewer("resource", tempFile, comparisonTime);
+        } finally {
             wagon.disconnect();
             tempFile.delete();
         }
     }
 
-    public void testGetToStream()
-        throws Exception
-    {
+    public void testGetToStream() throws Exception {
         final String content = "the content to return";
-        final long comparisonTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillInputData( InputData inputData )
-            {
-                inputData.setInputStream( new StringInputStream( content ) );
-                inputData.getResource().setLastModified( comparisonTime );
+        final long comparisonTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        StreamingWagon wagon = new TestWagon() {
+            public void fillInputData(InputData inputData) {
+                inputData.setInputStream(new StringInputStream(content));
+                inputData.getResource().setLastModified(comparisonTime);
             }
         };
 
-        wagon.connect( repository );
-        try
-        {
+        wagon.connect(repository);
+        try {
             StringOutputStream out = new StringOutputStream();
-            wagon.getToStream( "resource", out );
-            assertEquals( content, out.toString() );
-        }
-        finally
-        {
+            wagon.getToStream("resource", out);
+            assertEquals(content, out.toString());
+        } finally {
             wagon.disconnect();
         }
     }
 
-    public void testGet()
-        throws Exception
-    {
+    public void testGet() throws Exception {
         final String content = "the content to return";
-        final long comparisonTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillInputData( InputData inputData )
-            {
-                inputData.setInputStream( new StringInputStream( content ) );
-                inputData.getResource().setLastModified( comparisonTime );
+        final long comparisonTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        StreamingWagon wagon = new TestWagon() {
+            public void fillInputData(InputData inputData) {
+                inputData.setInputStream(new StringInputStream(content));
+                inputData.getResource().setLastModified(comparisonTime);
             }
         };
 
-        File tempFile = File.createTempFile( "wagon", "tmp" );
+        File tempFile = File.createTempFile("wagon", "tmp");
         tempFile.deleteOnExit();
 
-        wagon.connect( repository );
-        try
-        {
-            wagon.get( "resource", tempFile );
-            assertEquals( content, FileUtils.fileRead( tempFile ) );
-        }
-        finally
-        {
+        wagon.connect(repository);
+        try {
+            wagon.get("resource", tempFile);
+            assertEquals(content, FileUtils.fileRead(tempFile));
+        } finally {
             wagon.disconnect();
             tempFile.delete();
         }
     }
 
-    public void testGetIfNewerToStreamWithNewerResource()
-        throws Exception
-    {
+    public void testGetIfNewerToStreamWithNewerResource() throws Exception {
         long resourceTime = System.currentTimeMillis();
-        long comparisonTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        assertTrue( runTestGetIfNewerToStream( resourceTime, comparisonTime ) );
+        long comparisonTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        assertTrue(runTestGetIfNewerToStream(resourceTime, comparisonTime));
     }
 
-    public void testGetIfNewerToStreamWithOlderResource()
-        throws Exception
-    {
+    public void testGetIfNewerToStreamWithOlderResource() throws Exception {
         long comparisonTime = System.currentTimeMillis();
-        long resourceTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        assertFalse( runTestGetIfNewerToStream( resourceTime, comparisonTime ) );
+        long resourceTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        assertFalse(runTestGetIfNewerToStream(resourceTime, comparisonTime));
     }
 
-    public void testGetIfNewerToStreamWithSameTimeResource()
-        throws Exception
-    {
-        long resourceTime = new SimpleDateFormat( "yyyy-MM-dd" ).parse( "2008-01-01" ).getTime();
-        assertFalse( runTestGetIfNewerToStream( resourceTime, resourceTime ) );
+    public void testGetIfNewerToStreamWithSameTimeResource() throws Exception {
+        long resourceTime =
+                new SimpleDateFormat("yyyy-MM-dd").parse("2008-01-01").getTime();
+        assertFalse(runTestGetIfNewerToStream(resourceTime, resourceTime));
     }
 
-    private boolean runTestGetIfNewerToStream( final long resourceTime, long comparisonTime )
-        throws IOException, ConnectionException, AuthenticationException, TransferFailedException,
-        ResourceDoesNotExistException, AuthorizationException
-    {
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillInputData( InputData inputData )
-            {
-                inputData.setInputStream( new StringInputStream( "" ) );
-                inputData.getResource().setLastModified( resourceTime );
+    private boolean runTestGetIfNewerToStream(final long resourceTime, long comparisonTime)
+            throws IOException, ConnectionException, AuthenticationException, TransferFailedException,
+                    ResourceDoesNotExistException, AuthorizationException {
+        StreamingWagon wagon = new TestWagon() {
+            public void fillInputData(InputData inputData) {
+                inputData.setInputStream(new StringInputStream(""));
+                inputData.getResource().setLastModified(resourceTime);
             }
         };
 
-        wagon.connect( repository );
-        try
-        {
-            return wagon.getIfNewerToStream( "resource", new StringOutputStream(), comparisonTime );
-        }
-        finally
-        {
+        wagon.connect(repository);
+        try {
+            return wagon.getIfNewerToStream("resource", new StringOutputStream(), comparisonTime);
+        } finally {
             wagon.disconnect();
         }
     }
 
-    public void testPutFromStream()
-        throws Exception
-    {
+    public void testPutFromStream() throws Exception {
         final String content = "the content to return";
 
         final StringOutputStream out = new StringOutputStream();
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillOutputData( OutputData outputData )
-            {
-                assertEquals( "resource", outputData.getResource().getName() );
-                assertEquals( -1, outputData.getResource().getContentLength() );
-                assertEquals( 0, outputData.getResource().getLastModified() );
-                outputData.setOutputStream( out );
+        StreamingWagon wagon = new TestWagon() {
+            public void fillOutputData(OutputData outputData) {
+                assertEquals("resource", outputData.getResource().getName());
+                assertEquals(-1, outputData.getResource().getContentLength());
+                assertEquals(0, outputData.getResource().getLastModified());
+                outputData.setOutputStream(out);
             }
         };
 
-        wagon.connect( repository );
-        try
-        {
-            wagon.putFromStream( new StringInputStream( content ), "resource" );
-            assertEquals( content, out.toString() );
-        }
-        finally
-        {
+        wagon.connect(repository);
+        try {
+            wagon.putFromStream(new StringInputStream(content), "resource");
+            assertEquals(content, out.toString());
+        } finally {
             wagon.disconnect();
         }
     }
 
-    public void testPutFromStreamWithResourceInformation()
-        throws Exception
-    {
+    public void testPutFromStreamWithResourceInformation() throws Exception {
         final String content = "the content to return";
         final long lastModified = System.currentTimeMillis();
 
         final StringOutputStream out = new StringOutputStream();
-        StreamingWagon wagon = new TestWagon()
-        {
-            public void fillOutputData( OutputData outputData )
-            {
-                assertEquals( "resource", outputData.getResource().getName() );
-                assertEquals( content.length(), outputData.getResource().getContentLength() );
-                assertEquals( lastModified, outputData.getResource().getLastModified() );
-                outputData.setOutputStream( out );
+        StreamingWagon wagon = new TestWagon() {
+            public void fillOutputData(OutputData outputData) {
+                assertEquals("resource", outputData.getResource().getName());
+                assertEquals(content.length(), outputData.getResource().getContentLength());
+                assertEquals(lastModified, outputData.getResource().getLastModified());
+                outputData.setOutputStream(out);
             }
         };
 
-        wagon.connect( repository );
-        try
-        {
-            wagon.putFromStream( new StringInputStream( content ), "resource", content.length(), lastModified );
-            assertEquals( content, out.toString() );
-        }
-        finally
-        {
+        wagon.connect(repository);
+        try {
+            wagon.putFromStream(new StringInputStream(content), "resource", content.length(), lastModified);
+            assertEquals(content, out.toString());
+        } finally {
             wagon.disconnect();
         }
     }
 
-    public void testPut()
-        throws Exception
-    {
+    public void testPut() throws Exception {
         final String content = "the content to return";
 
-        final File tempFile = File.createTempFile( "wagon", "tmp" );
-        FileUtils.fileWrite( tempFile.getAbsolutePath(), content );
+        final File tempFile = File.createTempFile("wagon", "tmp");
+        FileUtils.fileWrite(tempFile.getAbsolutePath(), content);
         tempFile.deleteOnExit();
 
         final StringOutputStream out = new StringOutputStream();
-        Wagon wagon = new TestWagon()
-        {
-            public void fillOutputData( OutputData outputData )
-            {
-                assertEquals( "resource", outputData.getResource().getName() );
-                assertEquals( content.length(), outputData.getResource().getContentLength() );
-                assertEquals( tempFile.lastModified(), outputData.getResource().getLastModified() );
-                outputData.setOutputStream( out );
+        Wagon wagon = new TestWagon() {
+            public void fillOutputData(OutputData outputData) {
+                assertEquals("resource", outputData.getResource().getName());
+                assertEquals(content.length(), outputData.getResource().getContentLength());
+                assertEquals(tempFile.lastModified(), outputData.getResource().getLastModified());
+                outputData.setOutputStream(out);
             }
         };
 
-        wagon.connect( repository );
-        try
-        {
-            wagon.put( tempFile, "resource" );
-            assertEquals( content, out.toString() );
-        }
-        finally
-        {
+        wagon.connect(repository);
+        try {
+            wagon.put(tempFile, "resource");
+            assertEquals(content, out.toString());
+        } finally {
             wagon.disconnect();
             tempFile.delete();
         }
     }
 
-    public void testPutFileDoesntExist()
-        throws Exception
-    {
-        final File tempFile = File.createTempFile( "wagon", "tmp" );
+    public void testPutFileDoesntExist() throws Exception {
+        final File tempFile = File.createTempFile("wagon", "tmp");
         tempFile.delete();
-        assertFalse( tempFile.exists() );
+        assertFalse(tempFile.exists());
 
         Wagon wagon = new TestWagon();
 
-        wagon.connect( repository );
-        try
-        {
-            wagon.put( tempFile, "resource" );
+        wagon.connect(repository);
+        try {
+            wagon.put(tempFile, "resource");
             fail();
-        }
-        catch ( TransferFailedException e )
-        {
-            assertTrue( true );
-        }
-        finally
-        {
+        } catch (TransferFailedException e) {
+            assertTrue(true);
+        } finally {
             wagon.disconnect();
         }
     }
-
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/TransferFailedExceptionTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/TransferFailedExceptionTest.java
index dd122187..b3b3d5d0 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/TransferFailedExceptionTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/TransferFailedExceptionTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import junit.framework.TestCase;
 
@@ -25,19 +24,16 @@ import junit.framework.TestCase;
  * @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
  *
  */
-public class TransferFailedExceptionTest
-    extends TestCase
-{
-    public void testTransferFailedExceptionTest()
-    {
-        TransferFailedException ae = new TransferFailedException( "message" );
+public class TransferFailedExceptionTest extends TestCase {
+    public void testTransferFailedExceptionTest() {
+        TransferFailedException ae = new TransferFailedException("message");
 
-        assertEquals( "message", ae.getMessage() );
+        assertEquals("message", ae.getMessage());
 
-        ae = new TransferFailedException( "full-message", new Throwable( "cause" ) );
+        ae = new TransferFailedException("full-message", new Throwable("cause"));
 
-        assertEquals( "full-message", ae.getMessage() );
+        assertEquals("full-message", ae.getMessage());
 
-        assertEquals( "cause", ae.getCause().getMessage() );
+        assertEquals("cause", ae.getCause().getMessage());
     }
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/WagonMock.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/WagonMock.java
index 311b21a1..626bf919 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/WagonMock.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/WagonMock.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon;
 
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
@@ -32,99 +31,71 @@ import org.apache.maven.wagon.authorization.AuthorizationException;
  * @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
  *
  */
-public class WagonMock
-    extends StreamWagon
-{
+public class WagonMock extends StreamWagon {
     private boolean errorInputStream;
     private int timeout = 0;
 
-    public WagonMock()
-    {
-    }
+    public WagonMock() {}
 
-    public WagonMock( boolean errorInputStream )
-    {
+    public WagonMock(boolean errorInputStream) {
         this.errorInputStream = errorInputStream;
     }
 
-
-    public void fillInputData( InputData inputData )
-        throws TransferFailedException
-    {
+    public void fillInputData(InputData inputData) throws TransferFailedException {
 
         InputStream is;
 
-        if ( errorInputStream )
-        {
+        if (errorInputStream) {
             InputStreamMock mockInputStream = new InputStreamMock();
 
-            mockInputStream.setForcedError( true );
+            mockInputStream.setForcedError(true);
 
             is = mockInputStream;
 
-        }
-        else
-        {
+        } else {
             byte[] buffer = new byte[1024 * 4 * 5];
 
-            is = new ByteArrayInputStream( buffer );
+            is = new ByteArrayInputStream(buffer);
         }
 
-        inputData.setInputStream( is );
-
+        inputData.setInputStream(is);
     }
 
-    public void fillOutputData( OutputData outputData )
-        throws TransferFailedException
-    {
+    public void fillOutputData(OutputData outputData) throws TransferFailedException {
 
         OutputStream os;
 
-        if ( errorInputStream )
-        {
+        if (errorInputStream) {
             OutputStreamMock mockOutputStream = new OutputStreamMock();
 
-            mockOutputStream.setForcedError( true );
+            mockOutputStream.setForcedError(true);
 
             os = mockOutputStream;
-        }
-        else
-        {
+        } else {
             os = new ByteArrayOutputStream();
         }
 
-        outputData.setOutputStream( os );
-
+        outputData.setOutputStream(os);
     }
 
-    public void openConnectionInternal()
-    {
-    }
+    public void openConnectionInternal() {}
 
-    public void closeConnection()
-    {
-    }
-    
-    public void setTimeout( int timeoutValue )
-    {
-    	timeout = timeoutValue;
+    public void closeConnection() {}
+
+    public void setTimeout(int timeoutValue) {
+        timeout = timeoutValue;
     }
-    
-    public int getTimeout()
-    {
-    	return timeout;
+
+    public int getTimeout() {
+        return timeout;
     }
 
-    public List<String> getFileList( String destinationDirectory )
-        throws TransferFailedException, AuthorizationException
-    {
+    public List<String> getFileList(String destinationDirectory)
+            throws TransferFailedException, AuthorizationException {
         return Collections.<String>emptyList();
     }
 
-    public boolean resourceExists( String resourceName )
-        throws AuthorizationException
-    {
+    public boolean resourceExists(String resourceName) throws AuthorizationException {
         return false;
     }
-
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationExceptionTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationExceptionTest.java
index a8d7e734..02defbd9 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationExceptionTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationExceptionTest.java
@@ -1,3 +1,21 @@
+/*
+ * 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.
+ */
 package org.apache.maven.wagon.authentication;
 
 /*
@@ -25,19 +43,16 @@ import junit.framework.TestCase;
  * @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
  *
  */
-public class AuthenticationExceptionTest
-    extends TestCase
-{
-    public void testAuthenticationExceptionTest()
-    {
-        AuthenticationException ae = new AuthenticationException( "message" );
+public class AuthenticationExceptionTest extends TestCase {
+    public void testAuthenticationExceptionTest() {
+        AuthenticationException ae = new AuthenticationException("message");
 
-        assertEquals( "message", ae.getMessage() );
+        assertEquals("message", ae.getMessage());
 
-        ae = new AuthenticationException( "full-message", new Throwable( "cause" ) );
+        ae = new AuthenticationException("full-message", new Throwable("cause"));
 
-        assertEquals( "full-message", ae.getMessage() );
+        assertEquals("full-message", ae.getMessage());
 
-        assertEquals( "cause", ae.getCause().getMessage() );
+        assertEquals("cause", ae.getCause().getMessage());
     }
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationInfoTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationInfoTest.java
index d65207de..ff7765b2 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationInfoTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/authentication/AuthenticationInfoTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.authentication;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.authentication;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.authentication;
 
 import junit.framework.TestCase;
 
@@ -26,44 +25,36 @@ import junit.framework.TestCase;
  *
  * @todo test defaults
  */
-public class AuthenticationInfoTest
-    extends TestCase
-{
-    public AuthenticationInfoTest( final String name )
-    {
-        super( name );
+public class AuthenticationInfoTest extends TestCase {
+    public AuthenticationInfoTest(final String name) {
+        super(name);
     }
 
-    public void setUp()
-        throws Exception
-    {
+    public void setUp() throws Exception {
         super.setUp();
     }
 
-    public void tearDown()
-        throws Exception
-    {
+    public void tearDown() throws Exception {
         super.tearDown();
     }
 
-    public void testAuthenticationInfoProperties()
-    {
+    public void testAuthenticationInfoProperties() {
         final AuthenticationInfo authenticationInfo = new AuthenticationInfo();
 
-        authenticationInfo.setUserName( "username" );
+        authenticationInfo.setUserName("username");
 
-        assertEquals( "username", authenticationInfo.getUserName() );
+        assertEquals("username", authenticationInfo.getUserName());
 
-        authenticationInfo.setPassword( "password" );
+        authenticationInfo.setPassword("password");
 
-        assertEquals( "password", authenticationInfo.getPassword() );
+        assertEquals("password", authenticationInfo.getPassword());
 
-        authenticationInfo.setPassphrase( "passphrase" );
+        authenticationInfo.setPassphrase("passphrase");
 
-        assertEquals( "passphrase", authenticationInfo.getPassphrase() );
+        assertEquals("passphrase", authenticationInfo.getPassphrase());
 
-        authenticationInfo.setPrivateKey( "privatekey" );
+        authenticationInfo.setPrivateKey("privatekey");
 
-        assertEquals( "privatekey", authenticationInfo.getPrivateKey() );
+        assertEquals("privatekey", authenticationInfo.getPrivateKey());
     }
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventSupportTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventSupportTest.java
index eca243aa..f554a466 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventSupportTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventSupportTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,9 +16,9 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 import junit.framework.TestCase;
-
 import org.apache.maven.wagon.Wagon;
 
 import static org.easymock.EasyMock.*;
@@ -29,9 +27,7 @@ import static org.easymock.EasyMock.*;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class SessionEventSupportTest
-    extends TestCase
-{
+public class SessionEventSupportTest extends TestCase {
 
     private SessionEventSupport eventSupport;
 
@@ -40,218 +36,206 @@ public class SessionEventSupportTest
     /**
      * @see junit.framework.TestCase#setUp()
      */
-    protected void setUp()
-        throws Exception
-    {
+    protected void setUp() throws Exception {
         super.setUp();
 
         eventSupport = new SessionEventSupport();
-        
+
         // TODO: actually test it gets called?
-        wagon = createNiceMock( Wagon.class );
+        wagon = createNiceMock(Wagon.class);
     }
 
-    public void testSessionListenerRegistration()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testSessionListenerRegistration() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        assertTrue( eventSupport.hasSessionListener( mock1 ) );
+        assertTrue(eventSupport.hasSessionListener(mock1));
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        assertFalse( eventSupport.hasSessionListener( mock2 ) );
+        assertFalse(eventSupport.hasSessionListener(mock2));
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        assertTrue( eventSupport.hasSessionListener( mock1 ) );
+        assertTrue(eventSupport.hasSessionListener(mock1));
 
-        assertTrue( eventSupport.hasSessionListener( mock2 ) );
+        assertTrue(eventSupport.hasSessionListener(mock2));
 
-        eventSupport.removeSessionListener( mock2 );
+        eventSupport.removeSessionListener(mock2);
 
-        assertTrue( eventSupport.hasSessionListener( mock1 ) );
+        assertTrue(eventSupport.hasSessionListener(mock1));
 
-        assertFalse( eventSupport.hasSessionListener( mock2 ) );
+        assertFalse(eventSupport.hasSessionListener(mock2));
 
-        eventSupport.removeSessionListener( mock1 );
+        eventSupport.removeSessionListener(mock1);
 
-        assertFalse( eventSupport.hasSessionListener( mock1 ) );
+        assertFalse(eventSupport.hasSessionListener(mock1));
     }
 
-    public void testFireSessionDisconnected()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireSessionDisconnected() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        final SessionEvent event = new SessionEvent( wagon, 1 );
+        final SessionEvent event = new SessionEvent(wagon, 1);
 
-        mock1.sessionDisconnected( event );
-        mock2.sessionDisconnected( event );
+        mock1.sessionDisconnected(event);
+        mock2.sessionDisconnected(event);
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireSessionDisconnected( event );
+        eventSupport.fireSessionDisconnected(event);
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
 
-    public void testFireSessionDisconneting()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireSessionDisconneting() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        final SessionEvent event = new SessionEvent( wagon, 1 );
+        final SessionEvent event = new SessionEvent(wagon, 1);
 
-        mock1.sessionDisconnecting( event );
-        mock2.sessionDisconnecting( event );
+        mock1.sessionDisconnecting(event);
+        mock2.sessionDisconnecting(event);
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireSessionDisconnecting( event );
+        eventSupport.fireSessionDisconnecting(event);
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
 
-    public void testFireSessionLoggedIn()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireSessionLoggedIn() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        final SessionEvent event = new SessionEvent( wagon, 1 );
+        final SessionEvent event = new SessionEvent(wagon, 1);
 
-        mock1.sessionLoggedIn( event );
-        mock2.sessionLoggedIn( event );
+        mock1.sessionLoggedIn(event);
+        mock2.sessionLoggedIn(event);
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireSessionLoggedIn( event );
+        eventSupport.fireSessionLoggedIn(event);
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
 
-    public void testFireSessionLoggedOff()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireSessionLoggedOff() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        final SessionEvent event = new SessionEvent( wagon, 1 );
+        final SessionEvent event = new SessionEvent(wagon, 1);
 
-        mock1.sessionLoggedOff( event );
-        mock2.sessionLoggedOff( event );
+        mock1.sessionLoggedOff(event);
+        mock2.sessionLoggedOff(event);
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireSessionLoggedOff( event );
+        eventSupport.fireSessionLoggedOff(event);
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
 
-    public void testFireSessionOpened()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireSessionOpened() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        final SessionEvent event = new SessionEvent( wagon, 1 );
+        final SessionEvent event = new SessionEvent(wagon, 1);
 
-        mock1.sessionOpened( event );
-        mock2.sessionOpened( event );
+        mock1.sessionOpened(event);
+        mock2.sessionOpened(event);
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireSessionOpened( event );
+        eventSupport.fireSessionOpened(event);
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
 
-    public void testFireSessionOpenning()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireSessionOpenning() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        final SessionEvent event = new SessionEvent( wagon, 1 );
+        final SessionEvent event = new SessionEvent(wagon, 1);
 
-        mock1.sessionOpening( event );
-        mock2.sessionOpening( event );
+        mock1.sessionOpening(event);
+        mock2.sessionOpening(event);
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireSessionOpening( event );
+        eventSupport.fireSessionOpening(event);
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
 
-    public void testFireSessionRefused()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireSessionRefused() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        final SessionEvent event = new SessionEvent( wagon, 1 );
+        final SessionEvent event = new SessionEvent(wagon, 1);
 
-        mock1.sessionConnectionRefused( event );
-        mock2.sessionConnectionRefused( event );
+        mock1.sessionConnectionRefused(event);
+        mock2.sessionConnectionRefused(event);
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireSessionConnectionRefused( event );
+        eventSupport.fireSessionConnectionRefused(event);
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
 
-    public void testFireDebug()
-    {
-        SessionListener mock1 = createMock( SessionListener.class );
+    public void testFireDebug() {
+        SessionListener mock1 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock1 );
+        eventSupport.addSessionListener(mock1);
 
-        SessionListener mock2 = createMock( SessionListener.class );
+        SessionListener mock2 = createMock(SessionListener.class);
 
-        eventSupport.addSessionListener( mock2 );
+        eventSupport.addSessionListener(mock2);
 
-        mock1.debug( "mm" );
-        mock2.debug( "mm" );
+        mock1.debug("mm");
+        mock2.debug("mm");
 
-        replay( mock1, mock2 );
+        replay(mock1, mock2);
 
-        eventSupport.fireDebug( "mm" );
+        eventSupport.fireDebug("mm");
 
-        verify( mock1, mock2 );
+        verify(mock1, mock2);
     }
-    
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventTest.java
index 88155879..16c95bcf 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/SessionEventTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 import junit.framework.TestCase;
 import org.apache.maven.wagon.ConnectionException;
@@ -30,103 +29,92 @@ import org.easymock.EasyMock;
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  *
  */
-public class SessionEventTest
-    extends TestCase
-{
+public class SessionEventTest extends TestCase {
     /*
-	 * Class to test for void SESSIONEvent(Wagon, Repository, String, int,
-	 * int)
-	 */
-    public void testSessionEventProperties()
-        throws ConnectionException, AuthenticationException
-    {
-
-        final Wagon wagon = EasyMock.createMock( Wagon.class );
+     * Class to test for void SESSIONEvent(Wagon, Repository, String, int,
+     * int)
+     */
+    public void testSessionEventProperties() throws ConnectionException, AuthenticationException {
+
+        final Wagon wagon = EasyMock.createMock(Wagon.class);
         final Repository repo = new Repository();
 
-        wagon.connect( repo );
+        wagon.connect(repo);
 
         final long timestamp = System.currentTimeMillis();
-        final Exception exception = new AuthenticationException( "dummy" );
+        final Exception exception = new AuthenticationException("dummy");
 
-        SessionEvent event = new SessionEvent( wagon, SessionEvent.SESSION_CLOSED );
+        SessionEvent event = new SessionEvent(wagon, SessionEvent.SESSION_CLOSED);
 
-        assertEquals( wagon, event.getWagon() );
+        assertEquals(wagon, event.getWagon());
 
-        assertEquals( SessionEvent.SESSION_CLOSED, event.getEventType() );
+        assertEquals(SessionEvent.SESSION_CLOSED, event.getEventType());
 
-        event = new SessionEvent( wagon, exception );
+        event = new SessionEvent(wagon, exception);
 
-        assertEquals( wagon, event.getWagon() );
-        assertEquals( SessionEvent.SESSION_ERROR_OCCURRED, event.getEventType() );
-        assertEquals( exception, event.getException() );
+        assertEquals(wagon, event.getWagon());
+        assertEquals(SessionEvent.SESSION_ERROR_OCCURRED, event.getEventType());
+        assertEquals(exception, event.getException());
 
-        event.setException( null );
-        assertEquals( null, event.getException() );
+        event.setException(null);
+        assertEquals(null, event.getException());
 
-        event.setException( exception );
-        assertEquals( exception, event.getException() );
+        event.setException(exception);
+        assertEquals(exception, event.getException());
 
-        event.setTimestamp( timestamp );
-        assertEquals( timestamp, event.getTimestamp() );
+        event.setTimestamp(timestamp);
+        assertEquals(timestamp, event.getTimestamp());
 
-        event.setEventType( SessionEvent.SESSION_CLOSED );
-        assertEquals( SessionEvent.SESSION_CLOSED, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_CLOSED);
+        assertEquals(SessionEvent.SESSION_CLOSED, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_DISCONNECTED );
-        assertEquals( SessionEvent.SESSION_DISCONNECTED, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_DISCONNECTED);
+        assertEquals(SessionEvent.SESSION_DISCONNECTED, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_DISCONNECTING );
-        assertEquals( SessionEvent.SESSION_DISCONNECTING, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_DISCONNECTING);
+        assertEquals(SessionEvent.SESSION_DISCONNECTING, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_ERROR_OCCURRED );
-        assertEquals( SessionEvent.SESSION_ERROR_OCCURRED, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_ERROR_OCCURRED);
+        assertEquals(SessionEvent.SESSION_ERROR_OCCURRED, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_LOGGED_IN );
-        assertEquals( SessionEvent.SESSION_LOGGED_IN, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_LOGGED_IN);
+        assertEquals(SessionEvent.SESSION_LOGGED_IN, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_LOGGED_OFF );
-        assertEquals( SessionEvent.SESSION_LOGGED_OFF, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_LOGGED_OFF);
+        assertEquals(SessionEvent.SESSION_LOGGED_OFF, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_OPENED );
-        assertEquals( SessionEvent.SESSION_OPENED, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_OPENED);
+        assertEquals(SessionEvent.SESSION_OPENED, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_OPENING );
-        assertEquals( SessionEvent.SESSION_OPENING, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_OPENING);
+        assertEquals(SessionEvent.SESSION_OPENING, event.getEventType());
 
-        event.setEventType( SessionEvent.SESSION_CONNECTION_REFUSED );
-        assertEquals( SessionEvent.SESSION_CONNECTION_REFUSED, event.getEventType() );
+        event.setEventType(SessionEvent.SESSION_CONNECTION_REFUSED);
+        assertEquals(SessionEvent.SESSION_CONNECTION_REFUSED, event.getEventType());
 
-        try
-        {
-            event.setEventType( -1 );
-            fail( "Exception expected" );
+        try {
+            event.setEventType(-1);
+            fail("Exception expected");
+        } catch (IllegalArgumentException e) {
+            assertTrue(true);
         }
-        catch ( IllegalArgumentException e )
-        {
-            assertTrue( true );
-        }
-
     }
 
-    public void testConstantValueConflict()
-    {
-        final int[] values = {SessionEvent.SESSION_CLOSED, SessionEvent.SESSION_DISCONNECTED,
-                              SessionEvent.SESSION_DISCONNECTING, SessionEvent.SESSION_ERROR_OCCURRED,
-                              SessionEvent.SESSION_LOGGED_IN, SessionEvent.SESSION_LOGGED_OFF,
-                              SessionEvent.SESSION_OPENED, SessionEvent.SESSION_OPENING,
-                              SessionEvent.SESSION_CONNECTION_REFUSED};
+    public void testConstantValueConflict() {
+        final int[] values = {
+            SessionEvent.SESSION_CLOSED, SessionEvent.SESSION_DISCONNECTED,
+            SessionEvent.SESSION_DISCONNECTING, SessionEvent.SESSION_ERROR_OCCURRED,
+            SessionEvent.SESSION_LOGGED_IN, SessionEvent.SESSION_LOGGED_OFF,
+            SessionEvent.SESSION_OPENED, SessionEvent.SESSION_OPENING,
+            SessionEvent.SESSION_CONNECTION_REFUSED
+        };
 
-        for ( int i = 0; i < values.length; i++ )
-        {
-            for ( int j = i + 1; j < values.length; j++ )
-            {
+        for (int i = 0; i < values.length; i++) {
+            for (int j = i + 1; j < values.length; j++) {
 
                 final String msg = "Value confict at [i,j]=[" + i + "," + j + "]";
-                assertTrue( msg, values[i] != values[j] );
+                assertTrue(msg, values[i] != values[j]);
             }
         }
-
     }
-
 }
diff --git a/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/TransferEventSupportTest.java b/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/TransferEventSupportTest.java
index 79f83fa6..147aadf7 100644
--- a/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/TransferEventSupportTest.java
+++ b/wagon-provider-api/src/test/java/org/apache/maven/wagon/events/TransferEventSupportTest.java
@@ -1,5 +1,3 @@
-package org.apache.maven.wagon.events;
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -18,6 +16,7 @@ package org.apache.maven.wagon.events;
  * specific language governing permissions and limitations
  * under the License.
  */
+package org.apache.maven.wagon.events;
 
 import junit.framework.TestCase;
 import org.apache.maven.wagon.Wagon;
@@ -29,9 +28,7 @@ import static org.easymock.EasyMock.*;
 /**
  * @author <a href="michal.maczka@dimatics.com">Michal Maczka</a>
  */
-public class TransferEventSupportTest
-    extends TestCase
-{
+public class TransferEventSupportTest extends TestCase {
     private TransferEventSupport eventSupport;
 
     private Wagon wagon;
@@ -39,152 +36,141 @@ public class TransferEventSupportTest
     /**
      * @see junit.framework.TestCase#setUp()
      */
-    protected void setUp()
-        throws Exception
-    {
+    protected void setUp() throws Exception {
         super.setUp();
-        
+
         eventSupport = new TransferEventSupport();
-        
+
         // TODO: actually test it gets called?
-        wagon = EasyMock.createNiceMock( Wagon.class );
+        wagon = EasyMock.createNiceMock(Wagon.class);
     }
 
-    public void testTransferListenerRegistration()
-    {
-        TransferListener mock1 = createMock( TransferListener.class );
-        eventSupport.addTransferListener( mock1 );
... 29424 lines suppressed ...