maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From khmarba...@apache.org
Subject svn commit: r1632861 [1/2] - in /maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly: ./ archive/ archive/archiver/ archive/phase/ archive/phase/wrappers/ archive/task/ artifact/ filter/ format/ interpolation/ io/ m...
Date Sat, 18 Oct 2014 23:23:33 GMT
Author: khmarbaise
Date: Sat Oct 18 23:23:32 2014
New Revision: 1632861

URL: http://svn.apache.org/r1632861
Log:
[MASSEMBLY-720]
 - Cleaning up checkstyle reporting things.

Modified:
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/AssemblerConfigurationSource.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/DefaultAssemblyArchiver.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/AssemblyProxyArchiver.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedArchivedFileSet.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedFileSet.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/AssemblyArchiverPhase.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/DependencySetAssemblyPhase.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/FileItemAssemblyPhase.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/RepositoryAssemblyPhase.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/wrappers/RepoInfoWrapper.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDependencySetsTask.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDirectoryTask.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddFileSetsTask.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/artifact/DefaultDependencyResolver.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/filter/ComponentsXmlArchiverFileFilter.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/filter/MetaInfSpringHandler.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/filter/SimpleAggregatingDescriptorHandler.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/format/FileFormatter.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/format/FileSetFormatter.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/interpolation/AssemblyInterpolator.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/io/DefaultAssemblyReader.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/mojos/UnpackMojo.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/resolved/ResolvedAssembly.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/resolved/ResolvedModuleSet.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/resolved/functions/ResolvedModuleSetConsumer.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/utils/AssemblyFileUtils.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/utils/AssemblyFormatUtils.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/utils/FilterUtils.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/utils/LineEndings.java
    maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/utils/TypeConversionUtils.java

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/AssemblerConfigurationSource.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/AssemblerConfigurationSource.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/AssemblerConfigurationSource.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/AssemblerConfigurationSource.java Sat Oct 18 23:23:32 2014
@@ -34,74 +34,179 @@ import java.util.List;
 public interface AssemblerConfigurationSource
 {
 
+    /**
+     * @return The descriptor.
+     */
     String getDescriptor();
 
+    /**
+     * @return The descriptor id.
+     */
     String getDescriptorId();
 
+    /**
+     * @return The descriptors.
+     */
     String[] getDescriptors();
 
+    /**
+     * @return The descriptor references.
+     */
     String[] getDescriptorReferences();
 
+    /**
+     * @return The descriptor source direcotoy.
+     */
     File getDescriptorSourceDirectory();
 
+    /**
+     * @return The base directory.
+     */
     File getBasedir();
 
+    /**
+     * @return The Maven Project.
+     */
     MavenProject getProject();
 
+    /**
+     * @return Site included.
+     */
     boolean isSiteIncluded();
 
+    /**
+     * @return The site directory.
+     */
     File getSiteDirectory();
 
+    /**
+     * @return The final name.
+     */
     String getFinalName();
 
+    /**
+     * @return append the assembly id.
+     */
     boolean isAssemblyIdAppended();
 
+    /**
+     * @return The classifier.
+     */
     String getClassifier();
 
+    /**
+     * @return Tar long file mode.
+     */
     String getTarLongFileMode();
 
+    /**
+     * @return The output directory.
+     */
     File getOutputDirectory();
 
+    /**
+     * @return The working direcotory.
+     */
     File getWorkingDirectory();
 
+    /**
+     * @return the jar archive configuration.
+     */
     MavenArchiveConfiguration getJarArchiveConfiguration();
 
+    /**
+     * @return The local repository.
+     */
     ArtifactRepository getLocalRepository();
 
+    /**
+     * @return The temporary root directory.
+     */
     File getTemporaryRootDirectory();
 
+    /**
+     * @return The archive base directory.
+     */
     File getArchiveBaseDirectory();
 
+    /**
+     * @return The filters.
+     */
     List<String> getFilters();
 
+    /**
+     * @return include the project build filters or not.
+     */
     boolean isIncludeProjectBuildFilters();
 
+    /**
+     * @return The list of reactor projects.
+     */
     List<MavenProject> getReactorProjects();
 
+    /**
+     * @return The remote repositories.
+     */
     List<ArtifactRepository> getRemoteRepositories();
 
+    /**
+     * @return Is this a test run.
+     */
     boolean isDryRun();
 
+    /**
+     * @return Ignore directory format extensions.
+     */
     boolean isIgnoreDirFormatExtensions();
 
+    /**
+     * @return Ignore missing descriptor.
+     */
     boolean isIgnoreMissingDescriptor();
 
+    /**
+     * @return The maven session.
+     */
     MavenSession getMavenSession();
 
+    /**
+     * @return The archiver configu.
+     */
     String getArchiverConfig();
 
+    /**
+     * @return The maven file filter.
+     */
     MavenFileFilter getMavenFileFilter();
 
+    /**
+     * @return Update only yes/no.
+     */
     boolean isUpdateOnly();
 
+    /**
+     * @return Use JVM chmod yes/no.
+     */
     boolean isUseJvmChmod();
 
+    /**
+     * @return Ignore permissions yes/no.
+     */
     boolean isIgnorePermissions();
 
+    /**
+     * @return The current encoding.
+     */
     String getEncoding();
 
+    /**
+     * @return The escape string.
+     */
     String getEscapeString();
 
+    /**
+     * @return The list of delimiters.
+     */
     List<String> getDelimiters();
 
 }

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/DefaultAssemblyArchiver.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/DefaultAssemblyArchiver.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/DefaultAssemblyArchiver.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/DefaultAssemblyArchiver.java Sat Oct 18 23:23:32 2014
@@ -87,7 +87,7 @@ import org.codehaus.plexus.util.xml.pull
  * 
  * @version $Id$
  */
-@Component( role = AssemblyArchiver.class)
+@Component( role = AssemblyArchiver.class )
 public class DefaultAssemblyArchiver
     extends AbstractLogEnabled
     implements AssemblyArchiver, Contextualizable
@@ -175,23 +175,19 @@ public class DefaultAssemblyArchiver
 
             archiver.setDestFile( destFile );
 
-            List<ResolvedModuleSet> resolvedModuleSets = new ArrayList<ResolvedModuleSet>(  );
+            List<ResolvedModuleSet> resolvedModuleSets = new ArrayList<ResolvedModuleSet>();
             for ( ModuleSet moduleSet : assembly.getModuleSets() )
             {
-                resolvedModuleSets.add( dependencyResolver.resolve( assembly, moduleSet, configSource ));
+                resolvedModuleSets.add( dependencyResolver.resolve( assembly, moduleSet, configSource ) );
             }
 
             // OK, this piece of code contains all the stuff left after I extracted resolvedModuleSets.
             // this can probably be simplified quite a lot, since the module sets now have their
             // own artifact resolution.
-            final Set<Artifact> dependencySetArtifacts =
-                dependencyResolver.resolve( assembly, configSource );
-
-            final ResolvedAssembly resolvedAssembly = ResolvedAssembly
-                .create( assembly )
-                .withResolvedModuleSets( resolvedModuleSets )
-                .withDependencySetArtifacts(dependencySetArtifacts);
+            final Set<Artifact> dependencySetArtifacts = dependencyResolver.resolve( assembly, configSource );
 
+            final ResolvedAssembly resolvedAssembly =
+                ResolvedAssembly.create( assembly ).withResolvedModuleSets( resolvedModuleSets ).withDependencySetArtifacts( dependencySetArtifacts );
 
             for ( AssemblyArchiverPhase phase : assemblyPhases )
             {
@@ -249,29 +245,32 @@ public class DefaultAssemblyArchiver
         final List<ContainerDescriptorHandler> handlers = new ArrayList<ContainerDescriptorHandler>();
         final List<String> hints = new ArrayList<String>();
 
-        if (!requestedContainerDescriptorHandlers.isEmpty())
+        if ( !requestedContainerDescriptorHandlers.isEmpty() )
         {
-            for (final ContainerDescriptorHandlerConfig config : requestedContainerDescriptorHandlers) {
+            for ( final ContainerDescriptorHandlerConfig config : requestedContainerDescriptorHandlers )
+            {
                 final String hint = config.getHandlerName();
-                final ContainerDescriptorHandler handler = containerDescriptorHandlers.get(hint);
+                final ContainerDescriptorHandler handler = containerDescriptorHandlers.get( hint );
 
-                if (handler == null) {
+                if ( handler == null )
+                {
                     throw new InvalidAssemblerConfigurationException(
-                            "Cannot find ContainerDescriptorHandler with hint: "
-                                    + hint);
+                                                                      "Cannot find ContainerDescriptorHandler with hint: "
+                                                                          + hint );
                 }
 
-                getLogger().debug("Found container descriptor handler with hint: " + hint + " (component: " + handler
-                        + ")");
+                getLogger().debug( "Found container descriptor handler with hint: " + hint + " (component: " + handler
+                                       + ")" );
 
-                if (config.getConfiguration() != null) {
-                    getLogger().debug("Configuring handler with:\n\n" + config.getConfiguration() + "\n\n");
+                if ( config.getConfiguration() != null )
+                {
+                    getLogger().debug( "Configuring handler with:\n\n" + config.getConfiguration() + "\n\n" );
 
-                    configureContainerDescriptorHandler(handler, (Xpp3Dom) config.getConfiguration(), configSource);
+                    configureContainerDescriptorHandler( handler, (Xpp3Dom) config.getConfiguration(), configSource );
                 }
 
-                handlers.add(handler);
-                hints.add(hint);
+                handlers.add( handler );
+                hints.add( hint );
             }
         }
 
@@ -305,7 +304,7 @@ public class DefaultAssemblyArchiver
         Archiver archiver;
         if ( "tgz".equals( format ) || "tbz2".equals( format ) || format.startsWith( "tar" ) )
         {
-            archiver = createTarArchiver( format, TarLongFileMode.valueOf( configSource.getTarLongFileMode()) );
+            archiver = createTarArchiver( format, TarLongFileMode.valueOf( configSource.getTarLongFileMode() ) );
         }
         else if ( "war".equals( format ) )
         {
@@ -445,8 +444,8 @@ public class DefaultAssemblyArchiver
                     PlexusConfiguration.class, ExpressionEvaluator.class, (Class<?>) containerRealm[1],
                     ConfigurationListener.class } );
 
-            configureComponent.invoke( configurator, component, configuration, expressionEvaluator,
-                    containerRealm[0], listener);
+            configureComponent.invoke( configurator, component, configuration, expressionEvaluator, containerRealm[0],
+                                       listener );
         }
         catch ( final NoSuchMethodException e )
         {
@@ -507,7 +506,7 @@ public class DefaultAssemblyArchiver
         final int index = format.indexOf( '.' );
         if ( index >= 0 )
         {
-             TarArchiver.TarCompressionMethod tarCompressionMethod;
+            TarArchiver.TarCompressionMethod tarCompressionMethod;
             // TODO: this should accept gz and bz2 as well so we can skip
             // over the switch
             final String compression = format.substring( index + 1 );

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/AssemblyProxyArchiver.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/AssemblyProxyArchiver.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/AssemblyProxyArchiver.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/AssemblyProxyArchiver.java Sat Oct 18 23:23:32 2014
@@ -93,8 +93,7 @@ public class AssemblyProxyArchiver
         this.rootPrefix = rootPrefix;
         this.delegate = delegate;
 
-        assemblyWorkPath = assemblyWorkDir.getAbsolutePath()
-                                          .replace( '\\', '/' );
+        assemblyWorkPath = assemblyWorkDir.getAbsolutePath().replace( '\\', '/' );
 
         this.logger = logger;
         this.dryRun = dryRun;
@@ -143,9 +142,9 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addArchivedFileSet( final File archiveFile, final String prefix, final String[] includes,
                                     final String[] excludes )
-        throws ArchiverException
     {
         final String archiveKey = getArchiveKey( archiveFile, prefix );
         if ( seenPaths.contains( archiveKey ) )
@@ -204,6 +203,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addArchivedFileSet( final File archiveFile, final String prefix )
         throws ArchiverException
     {
@@ -241,6 +241,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addArchivedFileSet( final File archiveFile, final String[] includes, final String[] excludes )
         throws ArchiverException
     {
@@ -280,6 +281,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addArchivedFileSet( final File archiveFile )
         throws ArchiverException
     {
@@ -317,6 +319,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addDirectory( final File directory, final String prefix, final String[] includes,
                               final String[] excludes )
         throws ArchiverException
@@ -349,11 +352,13 @@ public class AssemblyProxyArchiver
         }
     }
 
-    public void addSymlink( String symlinkName, String symlinkDestination)
+    /** {@inheritDoc} */
+    public void addSymlink( String symlinkName, String symlinkDestination )
         throws ArchiverException
     {
         inPublicApi.set( Boolean.TRUE );
-        try {
+        try
+        {
             if ( dryRun )
             {
                 debug( "DRY RUN: Skipping delegated call to: " + getMethodName() );
@@ -362,18 +367,21 @@ public class AssemblyProxyArchiver
             {
                 delegate.addSymlink( symlinkName, symlinkDestination );
             }
-        } finally {
+        }
+        finally
+        {
             inPublicApi.set( null );
         }
 
-
     }
 
-    public void addSymlink(String symlinkName, int permissions, String symlinkDestination )
+    /** {@inheritDoc} */
+    public void addSymlink( String symlinkName, int permissions, String symlinkDestination )
         throws ArchiverException
     {
         inPublicApi.set( Boolean.TRUE );
-        try {
+        try
+        {
             if ( dryRun )
             {
                 debug( "DRY RUN: Skipping delegated call to: " + getMethodName() );
@@ -383,12 +391,15 @@ public class AssemblyProxyArchiver
                 delegate.addSymlink( symlinkName, permissions, symlinkDestination );
             }
 
-        } finally {
+        }
+        finally
+        {
             inPublicApi.set( null );
         }
 
     }
 
+    /** {@inheritDoc} */
     public void addDirectory( final File directory, final String prefix )
         throws ArchiverException
     {
@@ -418,6 +429,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addDirectory( final File directory, final String[] includes, final String[] excludes )
         throws ArchiverException
     {
@@ -449,6 +461,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addDirectory( final File directory )
         throws ArchiverException
     {
@@ -478,6 +491,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addFile( final File inputFile, final String destFileName, final int permissions )
         throws ArchiverException
     {
@@ -504,6 +518,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addFile( final File inputFile, final String destFileName )
         throws ArchiverException
     {
@@ -530,6 +545,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void createArchive()
         throws ArchiverException, IOException
     {
@@ -552,6 +568,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public int getDefaultDirectoryMode()
     {
         inPublicApi.set( Boolean.TRUE );
@@ -565,6 +582,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public int getDefaultFileMode()
     {
         inPublicApi.set( Boolean.TRUE );
@@ -578,6 +596,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public File getDestFile()
     {
         inPublicApi.set( Boolean.TRUE );
@@ -592,6 +611,7 @@ public class AssemblyProxyArchiver
     }
 
     @SuppressWarnings( { "rawtypes", "deprecation" } )
+    /** {@inheritDoc} */
     public Map getFiles()
     {
         inPublicApi.set( Boolean.TRUE );
@@ -605,6 +625,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public boolean getIncludeEmptyDirs()
     {
         inPublicApi.set( Boolean.TRUE );
@@ -618,6 +639,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public boolean isForced()
     {
         inPublicApi.set( Boolean.TRUE );
@@ -631,6 +653,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public boolean isSupportingForced()
     {
         inPublicApi.set( Boolean.TRUE );
@@ -644,6 +667,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void setDefaultDirectoryMode( final int mode )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -657,6 +681,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void setDefaultFileMode( final int mode )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -670,6 +695,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void setDestFile( final File destFile )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -683,6 +709,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void setForced( final boolean forced )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -697,6 +724,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void setIncludeEmptyDirs( final boolean includeEmptyDirs )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -710,11 +738,13 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void setDotFileDirectory( final File dotFileDirectory )
     {
         throw new UnsupportedOperationException( "Undocumented feature of plexus-archiver; this is not yet supported." );
     }
 
+    /** {@inheritDoc} */
     public void addArchivedFileSet( final ArchivedFileSet fileSet )
         throws ArchiverException
     {
@@ -748,6 +778,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addFileSet( final FileSet fileSet )
         throws ArchiverException
     {
@@ -776,9 +807,7 @@ public class AssemblyProxyArchiver
     private void doAddFileSet( final FileSet fs )
         throws ArchiverException
     {
-        final String fsPath = fs.getDirectory()
-                                .getAbsolutePath()
-                                .replace( '\\', '/' );
+        final String fsPath = fs.getDirectory().getAbsolutePath().replace( '\\', '/' );
 
         if ( fsPath.equals( assemblyWorkPath ) )
         {
@@ -795,7 +824,7 @@ public class AssemblyProxyArchiver
             final String workDirExclude = assemblyWorkPath.substring( fsPath.length() + 1 );
 
             logger.debug( "Adding exclude for assembly working-directory: " + workDirExclude
-                            + "\nFile-Set source directory: " + fsPath );
+                + "\nFile-Set source directory: " + fsPath );
 
             newEx.add( workDirExclude );
 
@@ -860,8 +889,8 @@ public class AssemblyProxyArchiver
                     }
                     catch ( final IOException e )
                     {
-                        throw new ArchiverException(
-                            "Error processing file: " + inputFile + " using selector: " + selector, e );
+                        throw new ArchiverException( "Error processing file: " + inputFile + " using selector: "
+                            + selector, e );
                     }
                 }
             }
@@ -908,6 +937,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addResource( final PlexusIoResource resource, final String destFileName, final int permissions )
         throws ArchiverException
     {
@@ -922,6 +952,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void addResources( final PlexusIoResourceCollection resources )
         throws ArchiverException
     {
@@ -936,17 +967,20 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public ResourceIterator getResources()
         throws ArchiverException
     {
         return delegate.getResources();
     }
 
+    /** {@inheritDoc} */
     public String getDuplicateBehavior()
     {
         return delegate.getDuplicateBehavior();
     }
 
+    /** {@inheritDoc} */
     public void setDuplicateBehavior( final String duplicate )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -960,26 +994,31 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public int getDirectoryMode()
     {
         return delegate.getDirectoryMode();
     }
 
+    /** {@inheritDoc} */
     public int getFileMode()
     {
         return delegate.getFileMode();
     }
 
+    /** {@inheritDoc} */
     public int getOverrideDirectoryMode()
     {
         return delegate.getOverrideDirectoryMode();
     }
 
+    /** {@inheritDoc} */
     public int getOverrideFileMode()
     {
         return delegate.getOverrideFileMode();
     }
 
+    /** {@inheritDoc} */
     public void setDirectoryMode( final int mode )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -993,6 +1032,7 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public void setFileMode( final int mode )
     {
         inPublicApi.set( Boolean.TRUE );
@@ -1006,21 +1046,25 @@ public class AssemblyProxyArchiver
         }
     }
 
+    /** {@inheritDoc} */
     public boolean isUseJvmChmod()
     {
         return useJvmChmod;
     }
 
+    /** {@inheritDoc} */
     public void setUseJvmChmod( final boolean useJvmChmod )
     {
         this.useJvmChmod = useJvmChmod;
     }
 
+    /** {@inheritDoc} */
     public boolean isIgnorePermissions()
     {
         return delegate.isIgnorePermissions();
     }
 
+    /** {@inheritDoc} */
     public void setIgnorePermissions( final boolean ignorePermissions )
     {
         delegate.setIgnorePermissions( ignorePermissions );

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedArchivedFileSet.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedArchivedFileSet.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedArchivedFileSet.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedArchivedFileSet.java Sat Oct 18 23:23:32 2014
@@ -34,15 +34,22 @@ public class PrefixedArchivedFileSet
 {
 
     private final String rootPrefix;
+
     private final ArchivedFileSet fileSet;
+
     private final FileSelector[] selectors;
 
+    /**
+     * @param fileSet The archived file set.
+     * @param rootPrefix The root prefix.
+     * @param selectors The file selectors.
+     */
     public PrefixedArchivedFileSet( ArchivedFileSet fileSet, String rootPrefix, FileSelector[] selectors )
     {
         this.fileSet = fileSet;
         this.selectors = selectors;
 
-        if ( rootPrefix.length() > 0 && ! rootPrefix.endsWith( "/" ) )
+        if ( rootPrefix.length() > 0 && !rootPrefix.endsWith( "/" ) )
         {
             this.rootPrefix = rootPrefix + "/";
         }
@@ -52,26 +59,31 @@ public class PrefixedArchivedFileSet
         }
     }
 
+    /** {@inheritDoc} */
     public File getArchive()
     {
         return fileSet.getArchive();
     }
 
+    /** {@inheritDoc} */
     public String[] getExcludes()
     {
         return fileSet.getExcludes();
     }
 
+    /** {@inheritDoc} */
     public FileSelector[] getFileSelectors()
     {
-        return combineSelectors(fileSet.getFileSelectors(), selectors);
+        return combineSelectors( fileSet.getFileSelectors(), selectors );
     }
 
+    /** {@inheritDoc} */
     public String[] getIncludes()
     {
         return fileSet.getIncludes();
     }
 
+    /** {@inheritDoc} */
     public String getPrefix()
     {
         String prefix = fileSet.getPrefix();
@@ -90,16 +102,19 @@ public class PrefixedArchivedFileSet
         return rootPrefix + prefix;
     }
 
+    /** {@inheritDoc} */
     public boolean isCaseSensitive()
     {
         return fileSet.isCaseSensitive();
     }
 
+    /** {@inheritDoc} */
     public boolean isIncludingEmptyDirectories()
     {
         return fileSet.isIncludingEmptyDirectories();
     }
 
+    /** {@inheritDoc} */
     public boolean isUsingDefaultExcludes()
     {
         return fileSet.isUsingDefaultExcludes();

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedFileSet.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedFileSet.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedFileSet.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/archiver/PrefixedFileSet.java Sat Oct 18 23:23:32 2014
@@ -37,6 +37,11 @@ public class PrefixedFileSet
 
     private final FileSelector[] selectors;
 
+    /**
+     * @param fileSet The file set.
+     * @param rootPrefix The root prefix
+     * @param selectors The file selectors.
+     */
     public PrefixedFileSet( final FileSet fileSet, final String rootPrefix, final FileSelector[] selectors )
     {
         this.fileSet = fileSet;
@@ -52,25 +57,29 @@ public class PrefixedFileSet
         }
     }
 
+    /** {@inheritDoc} */
     public String[] getExcludes()
     {
         return fileSet.getExcludes();
     }
 
+    /** {@inheritDoc} */
     public FileSelector[] getFileSelectors()
     {
         FileSelector[] sel = fileSet.getFileSelectors();
         final FileSelector[] selectors1 = selectors;
-        return combineSelectors(sel, selectors1);
+        return combineSelectors( sel, selectors1 );
     }
 
-    static FileSelector[] combineSelectors(FileSelector[] first, FileSelector[] second) {
+    /** {@inheritDoc} */
+    static FileSelector[] combineSelectors( FileSelector[] first, FileSelector[] second )
+    {
         if ( ( first != null ) && ( second != null ) )
         {
             final FileSelector[] temp = new FileSelector[first.length + second.length];
 
             System.arraycopy( first, 0, temp, 0, first.length );
-            System.arraycopy(second, 0, temp, first.length, second.length );
+            System.arraycopy( second, 0, temp, first.length, second.length );
 
             first = temp;
         }
@@ -82,11 +91,13 @@ public class PrefixedFileSet
         return first;
     }
 
+    /** {@inheritDoc} */
     public String[] getIncludes()
     {
         return fileSet.getIncludes();
     }
 
+    /** {@inheritDoc} */
     public String getPrefix()
     {
         String prefix = fileSet.getPrefix();
@@ -110,21 +121,25 @@ public class PrefixedFileSet
         return rootPrefix + prefix;
     }
 
+    /** {@inheritDoc} */
     public boolean isCaseSensitive()
     {
         return fileSet.isCaseSensitive();
     }
 
+    /** {@inheritDoc} */
     public boolean isIncludingEmptyDirectories()
     {
         return fileSet.isIncludingEmptyDirectories();
     }
 
+    /** {@inheritDoc} */
     public boolean isUsingDefaultExcludes()
     {
         return fileSet.isUsingDefaultExcludes();
     }
 
+    /** {@inheritDoc} */
     public File getDirectory()
     {
         return fileSet.getDirectory();

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/AssemblyArchiverPhase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/AssemblyArchiverPhase.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/AssemblyArchiverPhase.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/AssemblyArchiverPhase.java Sat Oct 18 23:23:32 2014
@@ -38,13 +38,14 @@ public interface AssemblyArchiverPhase
 
     /**
      * Handle the associated section of the assembly descriptor.
-     * @param assembly
-     *            The assembly descriptor to use
-     * @param archiver
-     *            The archiver used to create the assembly archive, to which files/directories/artifacts are added
-     * @param configSource
-*            The configuration for this assembly build, normally derived from the plugin that launched the assembly
-*            process.
+     * 
+     * @param assembly The assembly descriptor to use
+     * @param archiver The archiver used to create the assembly archive, to which files/directories/artifacts are added
+     * @param configSource The configuration for this assembly build, normally derived from the plugin that launched the
+     *            assembly process.
+     * @throws ArchiveCreationException
+     * @throws AssemblyFormattingException
+     * @throws InvalidAssemblerConfigurationException
      */
     void execute( ResolvedAssembly assembly, Archiver archiver, AssemblerConfigurationSource configSource )
         throws ArchiveCreationException, AssemblyFormattingException, InvalidAssemblerConfigurationException;

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/DependencySetAssemblyPhase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/DependencySetAssemblyPhase.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/DependencySetAssemblyPhase.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/DependencySetAssemblyPhase.java Sat Oct 18 23:23:32 2014
@@ -50,11 +50,18 @@ public class DependencySetAssemblyPhase
     @Requirement
     private ArchiverManager archiverManager;
 
+    /**
+     * Default constructor.
+     */
     public DependencySetAssemblyPhase()
     {
         // used for plexus init
     }
 
+    /**
+     * @param projectBuilder The Maven Project Builder.
+     * @param logger The Logger.
+     */
     public DependencySetAssemblyPhase( final MavenProjectBuilder projectBuilder, final Logger logger )
     {
         this.projectBuilder = projectBuilder;

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/FileItemAssemblyPhase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/FileItemAssemblyPhase.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/FileItemAssemblyPhase.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/FileItemAssemblyPhase.java Sat Oct 18 23:23:32 2014
@@ -57,49 +57,60 @@ public class FileItemAssemblyPhase
         final File basedir = configSource.getBasedir();
 
         final FileFormatter fileFormatter = new FileFormatter( configSource, getLogger() );
-        for (final FileItem fileItem : fileList) {
+        for ( final FileItem fileItem : fileList )
+        {
             final String sourcePath = fileItem.getSource();
 
             // ensure source file is in absolute path for reactor build to work
-            File source = new File(sourcePath);
+            File source = new File( sourcePath );
 
             // save the original sourcefile's name, because filtration may
             // create a temp file with a different name.
             final String sourceName = source.getName();
 
-            if (!source.isAbsolute()) {
-                source = new File(basedir, sourcePath);
+            if ( !source.isAbsolute() )
+            {
+                source = new File( basedir, sourcePath );
             }
 
             source =
-                    fileFormatter.format(source, fileItem.isFiltered(), fileItem.getLineEnding(),
-                            configSource.getEncoding());
+                fileFormatter.format( source, fileItem.isFiltered(), fileItem.getLineEnding(),
+                                      configSource.getEncoding() );
 
             String destName = fileItem.getDestName();
 
-            if (destName == null) {
+            if ( destName == null )
+            {
                 destName = sourceName;
             }
 
             final String outputDirectory =
-                    AssemblyFormatUtils.getOutputDirectory(fileItem.getOutputDirectory(), configSource.getProject(), null,
-                            configSource.getFinalName(), configSource);
+                AssemblyFormatUtils.getOutputDirectory( fileItem.getOutputDirectory(), configSource.getProject(), null,
+                                                        configSource.getFinalName(), configSource );
 
             String target;
 
             // omit the last char if ends with / or \\
-            if (outputDirectory.endsWith("/") || outputDirectory.endsWith("\\")) {
+            if ( outputDirectory.endsWith( "/" ) || outputDirectory.endsWith( "\\" ) )
+            {
                 target = outputDirectory + destName;
-            } else if (outputDirectory.length() < 1) {
+            }
+            else if ( outputDirectory.length() < 1 )
+            {
                 target = destName;
-            } else {
+            }
+            else
+            {
                 target = outputDirectory + "/" + destName;
             }
 
-            try {
-                archiver.addFile(source, target, TypeConversionUtils.modeToInt(fileItem.getFileMode(), getLogger()));
-            } catch (final ArchiverException e) {
-                throw new ArchiveCreationException("Error adding file to archive: " + e.getMessage(), e);
+            try
+            {
+                archiver.addFile( source, target, TypeConversionUtils.modeToInt( fileItem.getFileMode(), getLogger() ) );
+            }
+            catch ( final ArchiverException e )
+            {
+                throw new ArchiveCreationException( "Error adding file to archive: " + e.getMessage(), e );
             }
         }
     }

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/ModuleSetAssemblyPhase.java Sat Oct 18 23:23:32 2014
@@ -73,8 +73,8 @@ public class ModuleSetAssemblyPhase
     implements AssemblyArchiverPhase
 {
 
-    //TODO: Remove if using something like commons-lang instead.
-    public static final String LINE_SEPARATOR = System.getProperty("line.separator");
+    // TODO: Remove if using something like commons-lang instead.
+    public static final String LINE_SEPARATOR = System.getProperty( "line.separator" );
 
     @Requirement
     private MavenProjectBuilder projectBuilder;
@@ -105,15 +105,16 @@ public class ModuleSetAssemblyPhase
             public void accept( ResolvedModuleSet resolvedModule )
                 throws ArchiveCreationException, AssemblyFormattingException, InvalidAssemblerConfigurationException
             {
-                validate(resolvedModule.getModuleSet(), configSource);
+                validate( resolvedModule.getModuleSet(), configSource );
 
-                final Set<MavenProject> moduleProjects = getModuleProjects(resolvedModule.getModuleSet(), configSource, getLogger());
+                final Set<MavenProject> moduleProjects =
+                    getModuleProjects( resolvedModule.getModuleSet(), configSource, getLogger() );
 
                 final ModuleSources sources = resolvedModule.getModuleSet().getSources();
-                addModuleSourceFileSets(sources, moduleProjects, archiver, configSource);
+                addModuleSourceFileSets( sources, moduleProjects, archiver, configSource );
 
                 final ModuleBinaries binaries = resolvedModule.getModuleSet().getBinaries();
-                addModuleBinaries(resolvedModule, binaries, moduleProjects, archiver, configSource );
+                addModuleBinaries( resolvedModule, binaries, moduleProjects, archiver, configSource );
             }
         } );
     }
@@ -159,8 +160,9 @@ public class ModuleSetAssemblyPhase
         }
     }
 
-    protected void addModuleBinaries( ResolvedModuleSet resolvedModule, final ModuleBinaries binaries, final Set<MavenProject> projects,
-                                      final Archiver archiver, final AssemblerConfigurationSource configSource )
+    protected void addModuleBinaries( ResolvedModuleSet resolvedModule, final ModuleBinaries binaries,
+                                      final Set<MavenProject> projects, final Archiver archiver,
+                                      final AssemblerConfigurationSource configSource )
         throws ArchiveCreationException, AssemblyFormattingException, InvalidAssemblerConfigurationException
     {
         if ( binaries == null )
@@ -188,55 +190,66 @@ public class ModuleSetAssemblyPhase
 
         final Map<MavenProject, Artifact> chosenModuleArtifacts = new HashMap<MavenProject, Artifact>();
 
-        for (final MavenProject project : moduleProjects) {
+        for ( final MavenProject project : moduleProjects )
+        {
             Artifact artifact = null;
 
-            if (classifier == null) {
-                getLogger().debug("Processing binary artifact for module project: " + project.getId());
+            if ( classifier == null )
+            {
+                getLogger().debug( "Processing binary artifact for module project: " + project.getId() );
 
                 artifact = project.getArtifact();
-            } else {
-                getLogger().debug("Processing binary attachment: " + classifier + " for module project: "
-                        + project.getId());
+            }
+            else
+            {
+                getLogger().debug( "Processing binary attachment: " + classifier + " for module project: "
+                                       + project.getId() );
 
-                @SuppressWarnings("unchecked")
+                @SuppressWarnings( "unchecked" )
                 final List<Artifact> attachments = project.getAttachedArtifacts();
-                if ((attachments != null) && !attachments.isEmpty()) {
-                    for (final Artifact attachment : attachments) {
-                        if (classifier.equals(attachment.getClassifier())) {
+                if ( ( attachments != null ) && !attachments.isEmpty() )
+                {
+                    for ( final Artifact attachment : attachments )
+                    {
+                        if ( classifier.equals( attachment.getClassifier() ) )
+                        {
                             artifact = attachment;
                             break;
                         }
                     }
                 }
 
-                if (artifact == null) {
-                    throw new InvalidAssemblerConfigurationException("Cannot find attachment with classifier: "
-                            + classifier + " in module project: " + project.getId()
-                            + ". Please exclude this module from the module-set.");
+                if ( artifact == null )
+                {
+                    throw new InvalidAssemblerConfigurationException( "Cannot find attachment with classifier: "
+                        + classifier + " in module project: " + project.getId()
+                        + ". Please exclude this module from the module-set." );
                 }
             }
 
-            chosenModuleArtifacts.put(project, artifact);
-            addModuleArtifact(artifact, project, archiver, configSource, binaries);
+            chosenModuleArtifacts.put( project, artifact );
+            addModuleArtifact( artifact, project, archiver, configSource, binaries );
         }
 
         final List<DependencySet> depSets = getDependencySets( binaries );
 
         if ( depSets != null )
         {
-            for (final DependencySet ds : depSets) {
+            for ( final DependencySet ds : depSets )
+            {
                 // NOTE: Disabling useProjectArtifact flag, since module artifact has already been handled!
-                ds.setUseProjectArtifact(false);
+                ds.setUseProjectArtifact( false );
             }
 
-            //TODO: The following should be moved into a shared component, cause this
-            //test is the same as in maven-enforce rules ReactorModuleConvergence.
+            // TODO: The following should be moved into a shared component, cause this
+            // test is the same as in maven-enforce rules ReactorModuleConvergence.
             List<MavenProject> validateModuleVersions = validateModuleVersions( moduleProjects );
-            if (!validateModuleVersions.isEmpty()) {
-                
-                StringBuilder sb = new StringBuilder().append( "The current modules seemed to be having different versions.");
-                sb.append (LINE_SEPARATOR);
+            if ( !validateModuleVersions.isEmpty() )
+            {
+
+                StringBuilder sb =
+                    new StringBuilder().append( "The current modules seemed to be having different versions." );
+                sb.append( LINE_SEPARATOR );
                 for ( MavenProject mavenProject : validateModuleVersions )
                 {
                     sb.append( " --> " );
@@ -246,27 +259,30 @@ public class ModuleSetAssemblyPhase
                 getLogger().warn( sb.toString() );
             }
 
-            for (final MavenProject moduleProject : moduleProjects) {
-                getLogger().debug("Processing binary dependencies for module project: " + moduleProject.getId());
+            for ( final MavenProject moduleProject : moduleProjects )
+            {
+                getLogger().debug( "Processing binary dependencies for module project: " + moduleProject.getId() );
 
                 final AddDependencySetsTask task =
-                        new AddDependencySetsTask(depSets, resolvedModule.getArtifacts(), moduleProject, projectBuilder,
-                                archiverManager, getLogger());
+                    new AddDependencySetsTask( depSets, resolvedModule.getArtifacts(), moduleProject, projectBuilder,
+                                               archiverManager, getLogger() );
 
-                task.setModuleProject(moduleProject);
-                task.setModuleArtifact(chosenModuleArtifacts.get(moduleProject));
-                task.setDefaultOutputDirectory(binaries.getOutputDirectory());
-                task.setDefaultOutputFileNameMapping(binaries.getOutputFileNameMapping());
+                task.setModuleProject( moduleProject );
+                task.setModuleArtifact( chosenModuleArtifacts.get( moduleProject ) );
+                task.setDefaultOutputDirectory( binaries.getOutputDirectory() );
+                task.setDefaultOutputFileNameMapping( binaries.getOutputFileNameMapping() );
 
-                task.execute(archiver, configSource);
+                task.execute( archiver, configSource );
             }
         }
     }
 
-    private List<MavenProject> validateModuleVersions (Set<MavenProject> moduleProjects) {
+    private List<MavenProject> validateModuleVersions( Set<MavenProject> moduleProjects )
+    {
         List<MavenProject> result = new ArrayList<MavenProject>();
 
-        if (moduleProjects != null && !moduleProjects.isEmpty()) {
+        if ( moduleProjects != null && !moduleProjects.isEmpty() )
+        {
             String version = moduleProjects.iterator().next().getVersion();
             getLogger().debug( "First version:" + version );
             for ( MavenProject mavenProject : moduleProjects )
@@ -280,7 +296,7 @@ public class ModuleSetAssemblyPhase
         }
         return result;
     }
-    
+
     public static List<DependencySet> getDependencySets( final ModuleBinaries binaries )
     {
         List<DependencySet> depSets = binaries.getDependencySets();
@@ -402,29 +418,32 @@ public class ModuleSetAssemblyPhase
 
         fileSets.addAll( subFileSets );
 
-        for (final MavenProject moduleProject : moduleProjects) {
-            getLogger().info("Processing sources for module project: " + moduleProject.getId());
+        for ( final MavenProject moduleProject : moduleProjects )
+        {
+            getLogger().info( "Processing sources for module project: " + moduleProject.getId() );
 
             final List<FileSet> moduleFileSets = new ArrayList<FileSet>();
 
-            for (final FileSet fileSet : fileSets) {
-                moduleFileSets.add(createFileSet(fileSet, sources, moduleProject, configSource));
+            for ( final FileSet fileSet : fileSets )
+            {
+                moduleFileSets.add( createFileSet( fileSet, sources, moduleProject, configSource ) );
             }
 
-            final AddFileSetsTask task = new AddFileSetsTask(moduleFileSets);
+            final AddFileSetsTask task = new AddFileSetsTask( moduleFileSets );
 
-            task.setProject(moduleProject);
-            task.setModuleProject(moduleProject);
-            task.setLogger(getLogger());
+            task.setProject( moduleProject );
+            task.setModuleProject( moduleProject );
+            task.setLogger( getLogger() );
 
-            task.execute(archiver, configSource);
+            task.execute( archiver, configSource );
         }
     }
 
     /**
      * Determine whether the deprecated file-set configuration directly within the ModuleSources object is present.
      */
-    protected boolean isDeprecatedModuleSourcesConfigPresent( @Nonnull final ModuleSources sources )
+    protected boolean isDeprecatedModuleSourcesConfigPresent( @Nonnull
+    final ModuleSources sources )
     {
         boolean result = false;
 
@@ -444,8 +463,11 @@ public class ModuleSetAssemblyPhase
         return result;
     }
 
-    protected @Nonnull FileSet createFileSet( @Nonnull final FileSet fileSet, @Nonnull final ModuleSources sources,
-                                     @Nonnull final MavenProject moduleProject, @Nonnull final AssemblerConfigurationSource configSource )
+    protected @Nonnull FileSet createFileSet( @Nonnull
+    final FileSet fileSet, @Nonnull
+    final ModuleSources sources, @Nonnull
+    final MavenProject moduleProject, @Nonnull
+    final AssemblerConfigurationSource configSource )
         throws AssemblyFormattingException
     {
         final FileSet fs = new FileSet();
@@ -483,8 +505,9 @@ public class ModuleSetAssemblyPhase
         {
             @SuppressWarnings( "unchecked" )
             final List<String> modules = moduleProject.getModules();
-            for (final String moduleSubPath : modules) {
-                excludes.add(moduleSubPath + "/**");
+            for ( final String moduleSubPath : modules )
+            {
+                excludes.add( moduleSubPath + "/**" );
             }
         }
 
@@ -533,8 +556,8 @@ public class ModuleSetAssemblyPhase
     }
 
     public static @Nonnull Set<MavenProject> getModuleProjects( final ModuleSet moduleSet,
-                                                       final AssemblerConfigurationSource configSource,
-                                                       final Logger logger )
+                                                                final AssemblerConfigurationSource configSource,
+                                                                final Logger logger )
         throws ArchiveCreationException
     {
         MavenProject project = configSource.getProject();

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/RepositoryAssemblyPhase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/RepositoryAssemblyPhase.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/RepositoryAssemblyPhase.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/RepositoryAssemblyPhase.java Sat Oct 18 23:23:32 2014
@@ -76,40 +76,47 @@ public class RepositoryAssemblyPhase
 
         final File tempRoot = configSource.getTemporaryRootDirectory();
 
-        for (final Repository repository : repositoriesList) {
+        for ( final Repository repository : repositoriesList )
+        {
             final String outputDirectory =
-                    AssemblyFormatUtils.getOutputDirectory(repository.getOutputDirectory(), configSource.getProject(),
-                            null, configSource.getFinalName(), configSource);
+                AssemblyFormatUtils.getOutputDirectory( repository.getOutputDirectory(), configSource.getProject(),
+                                                        null, configSource.getFinalName(), configSource );
 
-            final File repositoryDirectory = new File(tempRoot, outputDirectory);
+            final File repositoryDirectory = new File( tempRoot, outputDirectory );
 
-            if (!repositoryDirectory.exists()) {
+            if ( !repositoryDirectory.exists() )
+            {
                 repositoryDirectory.mkdirs();
             }
 
-            try {
-                getLogger().debug("Assembling repository to: " + repositoryDirectory);
-                repositoryAssembler.buildRemoteRepository(repositoryDirectory, wrap(repository), wrap(configSource));
-                getLogger().debug("Finished assembling repository to: " + repositoryDirectory);
-            } catch (final RepositoryAssemblyException e) {
-                throw new ArchiveCreationException("Failed to assemble repository: " + e.getMessage(), e);
+            try
+            {
+                getLogger().debug( "Assembling repository to: " + repositoryDirectory );
+                repositoryAssembler.buildRemoteRepository( repositoryDirectory, wrap( repository ), wrap( configSource ) );
+                getLogger().debug( "Finished assembling repository to: " + repositoryDirectory );
+            }
+            catch ( final RepositoryAssemblyException e )
+            {
+                throw new ArchiveCreationException( "Failed to assemble repository: " + e.getMessage(), e );
             }
 
-            final AddDirectoryTask task = new AddDirectoryTask(repositoryDirectory);
+            final AddDirectoryTask task = new AddDirectoryTask( repositoryDirectory );
 
-            final int dirMode = TypeConversionUtils.modeToInt(repository.getDirectoryMode(), getLogger());
-            if (dirMode != -1) {
-                task.setDirectoryMode(dirMode);
+            final int dirMode = TypeConversionUtils.modeToInt( repository.getDirectoryMode(), getLogger() );
+            if ( dirMode != -1 )
+            {
+                task.setDirectoryMode( dirMode );
             }
 
-            final int fileMode = TypeConversionUtils.modeToInt(repository.getFileMode(), getLogger());
-            if (fileMode != -1) {
-                task.setFileMode(fileMode);
+            final int fileMode = TypeConversionUtils.modeToInt( repository.getFileMode(), getLogger() );
+            if ( fileMode != -1 )
+            {
+                task.setFileMode( fileMode );
             }
 
-            task.setOutputDirectory(outputDirectory);
+            task.setOutputDirectory( outputDirectory );
 
-            task.execute(archiver, configSource);
+            task.execute( archiver, configSource );
         }
     }
 

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/wrappers/RepoInfoWrapper.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/wrappers/RepoInfoWrapper.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/wrappers/RepoInfoWrapper.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/phase/wrappers/RepoInfoWrapper.java Sat Oct 18 23:23:32 2014
@@ -56,8 +56,9 @@ public class RepoInfoWrapper
             final List<GroupVersionAlignmentWrapper> l =
                 new ArrayList<GroupVersionAlignmentWrapper>( alignments.size() );
 
-            for (final GroupVersionAlignment alignment : alignments) {
-                l.add(new GroupVersionAlignmentWrapper(alignment));
+            for ( final GroupVersionAlignment alignment : alignments )
+            {
+                l.add( new GroupVersionAlignmentWrapper( alignment ) );
             }
 
             convertedAlignments = l;

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDependencySetsTask.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDependencySetsTask.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDependencySetsTask.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDependencySetsTask.java Sat Oct 18 23:23:32 2014
@@ -116,8 +116,9 @@ public class AddDependencySetsTask
             logger.debug( "Project " + project.getId() + " has no dependencies. Skipping dependency set addition." );
         }
 
-        for (final DependencySet dependencySet : dependencySets) {
-            addDependencySet(dependencySet, archiver, configSource);
+        for ( final DependencySet dependencySet : dependencySets )
+        {
+            addDependencySet( dependencySet, archiver, configSource );
         }
     }
 
@@ -130,7 +131,7 @@ public class AddDependencySetsTask
         if ( !dependencySet.isUseTransitiveDependencies() && dependencySet.isUseTransitiveFiltering() )
         {
             logger.warn( "DependencySet has nonsensical configuration: useTransitiveDependencies == false "
-                            + "AND useTransitiveFiltering == true. Transitive filtering flag will be ignored." );
+                + "AND useTransitiveFiltering == true. Transitive filtering flag will be ignored." );
         }
 
         final Set<Artifact> dependencyArtifacts = resolveDependencyArtifacts( dependencySet );
@@ -148,26 +149,36 @@ public class AddDependencySetsTask
 
         logger.debug( "Adding " + dependencyArtifacts.size() + " dependency artifacts." );
 
-        for (final Artifact depArtifact : dependencyArtifacts) {
+        for ( final Artifact depArtifact : dependencyArtifacts )
+        {
             MavenProject depProject;
-            try {
+            try
+            {
                 depProject =
-                        projectBuilder.buildFromRepository(depArtifact, configSource.getRemoteRepositories(),
-                                configSource.getLocalRepository());
-            } catch (final ProjectBuildingException e) {
-                logger.debug("Error retrieving POM of module-dependency: " + depArtifact.getId() + "; Reason: "
-                        + e.getMessage() + "\n\nBuilding stub project instance.");
-
-                depProject = buildProjectStub(depArtifact);
-            }
-
-            if (NON_ARCHIVE_DEPENDENCY_TYPES.contains(depArtifact.getType())) {
-                addNonArchiveDependency(depArtifact, depProject, dependencySet, archiver, configSource);
-            } else {
-                if (filterContents) {
-                    addFilteredUnpackedArtifact(dependencySet, depArtifact, depProject, archiver, configSource);
-                } else {
-                    addNormalArtifact(dependencySet, depArtifact, depProject, archiver, configSource);
+                    projectBuilder.buildFromRepository( depArtifact, configSource.getRemoteRepositories(),
+                                                        configSource.getLocalRepository() );
+            }
+            catch ( final ProjectBuildingException e )
+            {
+                logger.debug( "Error retrieving POM of module-dependency: " + depArtifact.getId() + "; Reason: "
+                    + e.getMessage() + "\n\nBuilding stub project instance." );
+
+                depProject = buildProjectStub( depArtifact );
+            }
+
+            if ( NON_ARCHIVE_DEPENDENCY_TYPES.contains( depArtifact.getType() ) )
+            {
+                addNonArchiveDependency( depArtifact, depProject, dependencySet, archiver, configSource );
+            }
+            else
+            {
+                if ( filterContents )
+                {
+                    addFilteredUnpackedArtifact( dependencySet, depArtifact, depProject, archiver, configSource );
+                }
+                else
+                {
+                    addNormalArtifact( dependencySet, depArtifact, depProject, archiver, configSource );
                 }
             }
         }
@@ -187,12 +198,12 @@ public class AddDependencySetsTask
             mapping = defaultOutputFileNameMapping;
         }
 
-        if ( ( dir == null || !dir.contains("${")) && ( mapping == null || !mapping.contains("${")) )
+        if ( ( dir == null || !dir.contains( "${" ) ) && ( mapping == null || !mapping.contains( "${" ) ) )
         {
             logger.warn( "NOTE: Your assembly specifies a dependencySet that matches multiple artifacts, but specifies a concrete output format. "
-                            + "THIS MAY RESULT IN ONE OR MORE ARTIFACTS BEING OBSCURED!\n\nOutput directory: '"
-                            + dir
-                            + "'\nOutput filename mapping: '" + mapping + "'" );
+                + "THIS MAY RESULT IN ONE OR MORE ARTIFACTS BEING OBSCURED!\n\nOutput directory: '"
+                + dir
+                + "'\nOutput filename mapping: '" + mapping + "'" );
         }
     }
 
@@ -204,11 +215,7 @@ public class AddDependencySetsTask
         logger.debug( "Adding dependency artifact " + depArtifact.getId() + " after filtering the unpacked contents." );
 
         final StringBuilder sb =
-            new StringBuilder().append( depArtifact.getGroupId() )
-                               .append( "_" )
-                               .append( depArtifact.getArtifactId() )
-                               .append( "_" )
-                               .append( depArtifact.getVersion() );
+            new StringBuilder().append( depArtifact.getGroupId() ).append( "_" ).append( depArtifact.getArtifactId() ).append( "_" ).append( depArtifact.getVersion() );
 
         final String classifier = depArtifact.getClassifier();
         if ( classifier != null )
@@ -222,7 +229,7 @@ public class AddDependencySetsTask
         if ( dir.exists() )
         {
             logger.debug( "NOT unpacking: " + depArtifact.getId() + ". Directory already exists in workdir:\n\t"
-                            + dir.getAbsolutePath() );
+                + dir.getAbsolutePath() );
         }
         else
         {
@@ -236,7 +243,7 @@ public class AddDependencySetsTask
             catch ( final NoSuchArchiverException e )
             {
                 throw new ArchiveCreationException( "Failed to retrieve un-archiver for: " + depArtifact.getId()
-                                + ". Dependency filtering cannot proceed.", e );
+                    + ". Dependency filtering cannot proceed.", e );
             }
 
             unarchiver.setDestDirectory( dir );
@@ -251,7 +258,7 @@ public class AddDependencySetsTask
             catch ( final ArchiverException e )
             {
                 throw new ArchiveCreationException( "Failed to unpack dependency archive: " + depArtifact.getId()
-                                + ". Dependency filtering cannot proceed.", e );
+                    + ". Dependency filtering cannot proceed.", e );
             }
         }
 
@@ -370,7 +377,7 @@ public class AddDependencySetsTask
             else
             {
                 logger.warn( "Cannot include project artifact: " + projectArtifact
-                                + "; it doesn't have an associated file or directory." );
+                    + "; it doesn't have an associated file or directory." );
             }
         }
 
@@ -380,12 +387,16 @@ public class AddDependencySetsTask
             final List<Artifact> attachments = project.getAttachedArtifacts();
             if ( attachments != null )
             {
-                for (final Artifact attachment : attachments) {
-                    if (attachment.getFile() != null) {
-                        dependencyArtifacts.add(attachment);
-                    } else {
-                        logger.warn("Cannot include attached artifact: " + project.getId() + " for project: "
-                                + project.getId() + "; it doesn't have an associated file or directory.");
+                for ( final Artifact attachment : attachments )
+                {
+                    if ( attachment.getFile() != null )
+                    {
+                        dependencyArtifacts.add( attachment );
+                    }
+                    else
+                    {
+                        logger.warn( "Cannot include attached artifact: " + project.getId() + " for project: "
+                            + project.getId() + "; it doesn't have an associated file or directory." );
                     }
                 }
             }

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDirectoryTask.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDirectoryTask.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDirectoryTask.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddDirectoryTask.java Sat Oct 18 23:23:32 2014
@@ -66,7 +66,7 @@ public class AddDirectoryTask
         else if ( "..".equals( outputDirectory ) )
         {
             throw new ArchiveCreationException( "Cannot add source directory: " + directory + " to archive-path: "
-                            + outputDirectory + ". All paths must be within the archive root directory." );
+                + outputDirectory + ". All paths must be within the archive root directory." );
         }
 
         final int oldDirMode = archiver.getOverrideDirectoryMode();
@@ -111,7 +111,7 @@ public class AddDirectoryTask
                         int i = 0;
                         for ( String include : includes )
                         {
-                            includesArray[i++] = normalize(include);
+                            includesArray[i++] = normalize( include );
                         }
                     }
 
@@ -121,7 +121,7 @@ public class AddDirectoryTask
                     int i = 0;
                     for ( String directoryExclude : directoryExcludes )
                     {
-                        excludesArray[i++] = normalize(directoryExclude);
+                        excludesArray[i++] = normalize( directoryExclude );
                     }
 
                     final DefaultFileSet fs = new DefaultFileSet();
@@ -153,13 +153,14 @@ public class AddDirectoryTask
         }
     }
 
-    private String normalize(String include) {
-        String value = AssemblyFormatUtils.fixRelativeRefs(include);
+    private String normalize( String include )
+    {
+        String value = AssemblyFormatUtils.fixRelativeRefs( include );
 
         if ( value.startsWith( "/" ) || value.startsWith( "\\" ) )
-		{
-			value = value.substring( 1 );
-		}
+        {
+            value = value.substring( 1 );
+        }
         return value;
     }
 

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddFileSetsTask.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddFileSetsTask.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddFileSetsTask.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/archive/task/AddFileSetsTask.java Sat Oct 18 23:23:32 2014
@@ -77,17 +77,18 @@ public class AddFileSetsTask
             if ( !archiveBaseDir.exists() )
             {
                 throw new ArchiveCreationException( "The archive base directory '" + archiveBaseDir.getAbsolutePath()
-                                + "' does not exist" );
+                    + "' does not exist" );
             }
             else if ( !archiveBaseDir.isDirectory() )
             {
                 throw new ArchiveCreationException( "The archive base directory '" + archiveBaseDir.getAbsolutePath()
-                                + "' exists, but it is not a directory" );
+                    + "' exists, but it is not a directory" );
             }
         }
 
-        for (final FileSet fileSet : fileSets) {
-            addFileSet(fileSet, archiver, configSource, archiveBaseDir);
+        for ( final FileSet fileSet : fileSets )
+        {
+            addFileSet( fileSet, archiver, configSource, archiveBaseDir );
         }
     }
 
@@ -121,9 +122,9 @@ public class AddFileSetsTask
         if ( logger.isDebugEnabled() )
         {
             logger.debug( "FileSet[" + destDirectory + "]" + " dir perms: "
-                            + Integer.toString( archiver.getOverrideDirectoryMode(), 8 ) + " file perms: "
-                            + Integer.toString( archiver.getOverrideFileMode(), 8 )
-                            + ( fileSet.getLineEnding() == null ? "" : " lineEndings: " + fileSet.getLineEnding() ) );
+                + Integer.toString( archiver.getOverrideDirectoryMode(), 8 ) + " file perms: "
+                + Integer.toString( archiver.getOverrideFileMode(), 8 )
+                + ( fileSet.getLineEnding() == null ? "" : " lineEndings: " + fileSet.getLineEnding() ) );
         }
 
         logger.debug( "The archive base directory is '" + archiveBaseDir + "'" );
@@ -139,16 +140,17 @@ public class AddFileSetsTask
             catch ( final IOException e )
             {
                 throw new ArchiveCreationException( "Error fixing file-set line endings for assembly: "
-                                + e.getMessage(), e );
+                    + e.getMessage(), e );
             }
 
             logger.debug( "Adding file-set from directory: '" + fileSetDir.getAbsolutePath()
-                            + "'\nassembly output directory is: \'" + destDirectory + "\'" );
+                + "'\nassembly output directory is: \'" + destDirectory + "\'" );
 
-            if (fileSetDir.getPath().equals( File.separator ))
+            if ( fileSetDir.getPath().equals( File.separator ) )
             {
-                throw new AssemblyFormattingException( "Your assembly descriptor specifies a directory of " + File.separator +
-                   ", which is your *entire* file system.\nThese are not the files you are looking for");
+                throw new AssemblyFormattingException( "Your assembly descriptor specifies a directory of "
+                    + File.separator
+                    + ", which is your *entire* file system.\nThese are not the files you are looking for" );
             }
             final AddDirectoryTask task = new AddDirectoryTask( fileSetDir );
 
@@ -183,8 +185,7 @@ public class AddFileSetsTask
     {
         String sourceDirectory = fileSet.getDirectory();
 
-        if ( sourceDirectory == null || sourceDirectory.trim()
-                                                       .length() < 1 )
+        if ( sourceDirectory == null || sourceDirectory.trim().length() < 1 )
         {
             sourceDirectory = basedir.getAbsolutePath();
         }

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/artifact/DefaultDependencyResolver.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/artifact/DefaultDependencyResolver.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/artifact/DefaultDependencyResolver.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/artifact/DefaultDependencyResolver.java Sat Oct 18 23:23:32 2014
@@ -96,11 +96,12 @@ public class DefaultDependencyResolver
 
         final ResolutionManagementInfo info = new ResolutionManagementInfo( currentProject );
         updateRepositoryResolutionRequirements( assembly, info );
-        updateDependencySetResolutionRequirements( assembly.getDependencySets(), info,  AssemblyId.createAssemblyId( assembly), currentProject );
+        updateDependencySetResolutionRequirements( assembly.getDependencySets(), info,
+                                                   AssemblyId.createAssemblyId( assembly ), currentProject );
 
         if ( !info.isResolutionRequired() )
         {
-            return new HashSet<Artifact>() ;
+            return new HashSet<Artifact>();
         }
 
         final List<ArtifactRepository> repos =
@@ -114,15 +115,15 @@ public class DefaultDependencyResolver
         }
         else
         {
-            getLogger().debug(
-                "Resolving project dependencies ONLY. Transitive dependencies WILL NOT be included in the results." );
+            getLogger().debug( "Resolving project dependencies ONLY. Transitive dependencies WILL NOT be included in the results." );
             artifacts = resolveNonTransitively( assembly, artifacts, configSource, repos );
         }
 
         return artifacts;
     }
 
-    public ResolvedModuleSet resolve( final Assembly assembly, ModuleSet moduleSet, final AssemblerConfigurationSource configSource )
+    public ResolvedModuleSet resolve( final Assembly assembly, ModuleSet moduleSet,
+                                      final AssemblerConfigurationSource configSource )
         throws DependencyResolutionException
     {
         final MavenProject currentProject = configSource.getProject();
@@ -136,7 +137,7 @@ public class DefaultDependencyResolver
         ResolvedModuleSet base = ResolvedModuleSet.createResolvedModuleSet( moduleSet );
         if ( !info.isResolutionRequired() )
         {
-            return base.withArtifacts( new HashSet<Artifact>());
+            return base.withArtifacts( new HashSet<Artifact>() );
         }
 
         final List<ArtifactRepository> repos =
@@ -150,12 +151,11 @@ public class DefaultDependencyResolver
         }
         else
         {
-            getLogger().debug(
-                "Resolving project dependencies ONLY. Transitive dependencies WILL NOT be included in the results." );
+            getLogger().debug( "Resolving project dependencies ONLY. Transitive dependencies WILL NOT be included in the results." );
             artifacts = resolveNonTransitively( assembly, artifacts, configSource, repos );
         }
 
-        return base.withArtifacts( artifacts);
+        return base.withArtifacts( artifacts );
     }
 
     protected Set<Artifact> resolveNonTransitively( final Assembly assembly, final Set<Artifact> dependencyArtifacts,
@@ -177,8 +177,8 @@ public class DefaultDependencyResolver
             {
                 if ( getLogger().isDebugEnabled() )
                 {
-                    getLogger().debug(
-                        "Failed to resolve: " + depArtifact.getId() + " for assembly: " + assembly.getId() );
+                    getLogger().debug( "Failed to resolve: " + depArtifact.getId() + " for assembly: "
+                                           + assembly.getId() );
                 }
                 missing.add( depArtifact );
             }
@@ -186,8 +186,8 @@ public class DefaultDependencyResolver
             {
                 if ( getLogger().isDebugEnabled() )
                 {
-                    getLogger().debug(
-                        "Failed to resolve: " + depArtifact.getId() + " for assembly: " + assembly.getId() );
+                    getLogger().debug( "Failed to resolve: " + depArtifact.getId() + " for assembly: "
+                                           + assembly.getId() );
                 }
                 missing.add( depArtifact );
             }
@@ -223,9 +223,10 @@ public class DefaultDependencyResolver
         ArtifactResolutionResult result;
         try
         {
-            result = resolver.resolveTransitively( dependencyArtifacts, project.getArtifact(),
-                                                   project.getManagedVersionMap(), localRepository, repos,
-                                                   metadataSource, filter );
+            result =
+                resolver.resolveTransitively( dependencyArtifacts, project.getArtifact(),
+                                              project.getManagedVersionMap(), localRepository, repos, metadataSource,
+                                              filter );
         }
         catch ( final ArtifactResolutionException e )
         {
@@ -275,7 +276,8 @@ public class DefaultDependencyResolver
         }
     }
 
-    protected void updateModuleSetResolutionRequirements( AssemblyId assemblyId, ModuleSet set, final ResolutionManagementInfo requirements,
+    protected void updateModuleSetResolutionRequirements( AssemblyId assemblyId, ModuleSet set,
+                                                          final ResolutionManagementInfo requirements,
                                                           final AssemblerConfigurationSource configSource )
         throws DependencyResolutionException
     {
@@ -356,13 +358,14 @@ public class DefaultDependencyResolver
                     catch ( final InvalidDependencyVersionException e )
                     {
                         throw new DependencyResolutionException(
-                            "Failed to create dependency artifacts for resolution. Assembly: " + assemblyId, e );
+                                                                 "Failed to create dependency artifacts for resolution. Assembly: "
+                                                                     + assemblyId, e );
                     }
                 }
 
                 requirements.addArtifacts( dependencyArtifacts );
-                getLogger().debug( "Dependencies for project: " + project.getId() + " are:\n" + StringUtils.join(
-                    dependencyArtifacts.iterator(), "\n" ) );
+                getLogger().debug( "Dependencies for project: " + project.getId() + " are:\n"
+                                       + StringUtils.join( dependencyArtifacts.iterator(), "\n" ) );
             }
         }
     }
@@ -392,8 +395,8 @@ public class DefaultDependencyResolver
     }
 
     @SuppressWarnings( "unchecked" )
-    protected List<ArtifactRepository> aggregateRemoteArtifactRepositories(
-        final List<ArtifactRepository> remoteRepositories, final Set<MavenProject> projects )
+    protected List<ArtifactRepository> aggregateRemoteArtifactRepositories( final List<ArtifactRepository> remoteRepositories,
+                                                                            final Set<MavenProject> projects )
     {
         final List<List<ArtifactRepository>> repoLists = new ArrayList<List<ArtifactRepository>>();
 

Modified: maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/filter/ComponentsXmlArchiverFileFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/filter/ComponentsXmlArchiverFileFilter.java?rev=1632861&r1=1632860&r2=1632861&view=diff
==============================================================================
--- maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/filter/ComponentsXmlArchiverFileFilter.java (original)
+++ maven/plugins/trunk/maven-assembly-plugin/src/main/java/org/apache/maven/plugin/assembly/filter/ComponentsXmlArchiverFileFilter.java Sat Oct 18 23:23:32 2014
@@ -64,7 +64,8 @@ public class ComponentsXmlArchiverFileFi
 
     public static final String COMPONENTS_XML_PATH = "META-INF/plexus/components.xml";
 
-    protected void addComponentsXml( final Reader componentsReader ) throws XmlPullParserException, IOException
+    protected void addComponentsXml( final Reader componentsReader )
+        throws XmlPullParserException, IOException
     {
         Xpp3Dom newDom = Xpp3DomBuilder.build( componentsReader );
 
@@ -77,22 +78,26 @@ public class ComponentsXmlArchiverFileFi
         {
             final Xpp3Dom[] children = newDom.getChildren();
 
-            for (final Xpp3Dom component : children) {
-                if (components == null) {
+            for ( final Xpp3Dom component : children )
+            {
+                if ( components == null )
+                {
                     components = new LinkedHashMap<String, Xpp3Dom>();
                 }
 
-                final String role = component.getChild("role")
-                        .getValue();
-                final Xpp3Dom child = component.getChild("role-hint");
+                final String role = component.getChild( "role" ).getValue();
+                final Xpp3Dom child = component.getChild( "role-hint" );
                 final String roleHint = child != null ? child.getValue() : "";
 
                 final String key = role + roleHint;
-                if (!components.containsKey(key)) {
-                    System.out.println("Adding " + key);
-                    components.put(key, component);
-                } else {
-                    System.out.println("Component: " + key + " is already defined. Skipping.");
+                if ( !components.containsKey( key ) )
+                {
+                    System.out.println( "Adding " + key );
+                    components.put( key, component );
+                }
+                else
+                {
+                    System.out.println( "Component: " + key + " is already defined. Skipping." );
                 }
             }
         }
@@ -114,7 +119,8 @@ public class ComponentsXmlArchiverFileFi
     // }
     // }
 
-    private void addToArchive( final Archiver archiver ) throws IOException, ArchiverException
+    private void addToArchive( final Archiver archiver )
+        throws IOException, ArchiverException
     {
         if ( components != null )
         {
@@ -129,8 +135,9 @@ public class ComponentsXmlArchiverFileFi
                 final Xpp3Dom componentDom = new Xpp3Dom( "components" );
                 dom.addChild( componentDom );
 
-                for (final Xpp3Dom component : components.values()) {
-                    componentDom.addChild(component);
+                for ( final Xpp3Dom component : components.values() )
+                {
+                    componentDom.addChild( component );
                 }
 
                 Xpp3DomWriter.write( fileWriter, dom );
@@ -148,7 +155,8 @@ public class ComponentsXmlArchiverFileFi
         }
     }
 
-    public void finalizeArchiveCreation( final Archiver archiver ) throws ArchiverException
+    public void finalizeArchiveCreation( final Archiver archiver )
+        throws ArchiverException
     {
         // this will prompt the isSelected() call, below, for all resources added to the archive.
         // FIXME: This needs to be corrected in the AbstractArchiver, where
@@ -180,7 +188,8 @@ public class ComponentsXmlArchiverFileFi
         return null;
     }
 
-    public boolean isSelected( final FileInfo fileInfo ) throws IOException
+    public boolean isSelected( final FileInfo fileInfo )
+        throws IOException
     {
         if ( fileInfo.isFile() )
         {
@@ -189,8 +198,7 @@ public class ComponentsXmlArchiverFileFi
                 return true;
             }
 
-            String entry = fileInfo.getName()
-                                   .replace( '\\', '/' );
+            String entry = fileInfo.getName().replace( '\\', '/' );
 
             if ( entry.startsWith( "/" ) )
             {
@@ -207,7 +215,7 @@ public class ComponentsXmlArchiverFileFi
                     stream = fileInfo.getContents();
                     // TODO use ReaderFactory.newXmlReader() when plexus-utils is upgraded to 1.4.5+
                     reader = new InputStreamReader( stream, "UTF-8" );
-                    addComponentsXml( new BufferedReader( reader, 8192 ));
+                    addComponentsXml( new BufferedReader( reader, 8192 ) );
                 }
                 catch ( final XmlPullParserException e )
                 {
@@ -236,7 +244,8 @@ public class ComponentsXmlArchiverFileFi
         }
     }
 
-    public void finalizeArchiveExtraction( final UnArchiver unarchiver ) throws ArchiverException
+    public void finalizeArchiveExtraction( final UnArchiver unarchiver )
+        throws ArchiverException
     {
     }
 



Mime
View raw message