You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by br...@apache.org on 2006/12/06 05:13:41 UTC
svn commit: r482886 [1/2] - in /maven/plugins/trunk/maven-dependency-plugin:
./ src/main/java/org/apache/maven/plugin/dependency/
src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/
src/main/java/org/apache/maven/plugin/dependency/resol...
Author: brianf
Date: Tue Dec 5 20:13:36 2006
New Revision: 482886
URL: http://svn.apache.org/viewvc?view=rev&rev=482886
Log:
checkstyle error correction
Modified:
maven/plugins/trunk/maven-dependency-plugin/pom.xml
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyFilterMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractFromDependenciesMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractResolveMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/CopyDependenciesMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/PurgeLocalRepositoryMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/UnpackDependenciesMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/AbstractFromConfigurationMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/ArtifactItem.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/UnpackMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/GoOfflineMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependenciesMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependencySourcesMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolvePluginsMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyStatusSets.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyUtil.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/SilentLog.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactFeatureFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactsFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactItemFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactsFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ClassifierFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/DestFileFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/FilterArtifacts.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/MarkerFileFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ResolveFileFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ScopeFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TransitivityFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TypeFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/DefaultFileMarkerHandler.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/MarkerHandler.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/SourcesFileMarkerHandler.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/ArtifactsResolver.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/DefaultArtifactsResolver.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ArtifactTranslator.java
maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ClassifierTypeTranslator.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/AbstractDependencyMojoTestCase.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/TestCopyDependenciesMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/TestResolveMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/TestUnpackDependenciesMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/fromConfiguration/TestArtifactItem.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/fromConfiguration/TestCopyMojo.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/ArtifactStubFactory.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/DependencyTestUtils.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/DependencyProjectStub.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubArtifactRepository.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubArtifactResolver.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubDefaultFileMarkerHandler.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubMarkerFile.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/testUtils/stubs/StubSourcesFileMarkerHandler.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/TestDependencyStatusSets.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/TestDependencyUtil.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/TestSilentLog.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestClassifierFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestDestFileFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestFilterArtifacts.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestMarkerFileFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestResolveMarkerFileFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestScopeFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestTransitivityFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/filters/TestTypeFilter.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/markers/TestDefaultMarkerFileHandler.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/markers/TestSourcesMarkerFileHandler.java
maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/utils/translators/TestClassifierTypeTranslator.java
Modified: maven/plugins/trunk/maven-dependency-plugin/pom.xml
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/pom.xml?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/pom.xml (original)
+++ maven/plugins/trunk/maven-dependency-plugin/pom.xml Tue Dec 5 20:13:36 2006
@@ -24,7 +24,7 @@
<parent>
<artifactId>maven-plugins</artifactId>
<groupId>org.apache.maven.plugins</groupId>
- <version>4-SNAPSHOT</version>
+ <version>4</version>
</parent>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyFilterMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyFilterMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyFilterMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyFilterMojo.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency;
+
+/*
* 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
@@ -16,7 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.maven.plugin.dependency;
import java.io.File;
import java.util.HashSet;
@@ -45,6 +46,7 @@
{
/**
* If we should exclude transitive dependencies
+ *
* @since 2.0
* @optional
* @parameter expression="${excludeTransitive}" default-value="false"
@@ -54,6 +56,7 @@
/**
* Comma Separated list of Types to include. Empty String indicates include
* everything (default).
+ *
* @since 2.0
* @parameter expression="${includeTypes}" default-value=""
* @optional
@@ -63,6 +66,7 @@
/**
* Comma Separated list of Types to exclude. Empty String indicates don't
* exclude anything (default). Ignored if includeTypes is used.
+ *
* @since 2.0
* @parameter expression="${excludeTypes}" default-value=""
* @optional
@@ -71,6 +75,7 @@
/**
* Scope to include. An Empty string indicates all scopes (default).
+ *
* @since 2.0
* @parameter expression="${includeScope}" default-value=""
* @optional
@@ -79,6 +84,7 @@
/**
* Scope to exclude. An Empty string indicates no scopes (default).
+ *
* @since 2.0
* @parameter expression="${excludeScope}" default-value=""
* @optional
@@ -86,8 +92,9 @@
protected String excludeScope;
/**
- * Comma Separated list of Classifiers to include. Empty String indicates include
- * everything (default).
+ * Comma Separated list of Classifiers to include. Empty String indicates
+ * include everything (default).
+ *
* @since 2.0
* @parameter expression="${includeClassifiers}" default-value=""
* @optional
@@ -95,8 +102,9 @@
protected String includeClassifiers;
/**
- * Comma Separated list of Classifiers to exclude. Empty String indicates don't
- * exclude anything (default). Ignored if includeClassifiers is used.
+ * Comma Separated list of Classifiers to exclude. Empty String indicates
+ * don't exclude anything (default). Ignored if includeClassifiers is used.
+ *
* @since 2.0
* @parameter expression="${excludeClassifiers}" default-value=""
* @optional
@@ -105,6 +113,7 @@
/**
* Specify classifier to look for. Example: sources
+ *
* @optional
* @since 2.0
* @parameter expression="${classifier}" default-value=""
@@ -114,6 +123,7 @@
/**
* Specify type to look for when constructing artifact based on classifier.
* Example: java-source,jar,war
+ *
* @optional
* @since 2.0
* @parameter expression="${type}" default-value="java-source"
@@ -132,6 +142,7 @@
/**
* Overwrite release artifacts
+ *
* @optional
* @since 1.0
* @parameter expression="${overWriteReleases}" default-value="false"
@@ -140,6 +151,7 @@
/**
* Overwrite snapshot artifacts
+ *
* @optional
* @since 1.0
* @parameter expression="${overWriteSnapshots}" default-value="false"
@@ -148,13 +160,14 @@
/**
* Overwrite artifacts that don't exist or are older than the source.
+ *
* @optional
* @since 2.0
* @parameter expression="${overWriteIfNewer}" default-value="true"
*/
protected boolean overWriteIfNewer;
- abstract protected ArtifactsFilter getMarkedArtifactFilter();
+ protected abstract ArtifactsFilter getMarkedArtifactFilter();
/**
* Retrieves dependencies, either direct only or all including transitive.
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,8 +19,6 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency;
-
import java.io.File;
import java.io.IOException;
import java.util.List;
@@ -233,7 +233,8 @@
}
/**
- * @param factory The factory to set.
+ * @param factory
+ * The factory to set.
*/
public void setFactory( org.apache.maven.artifact.factory.ArtifactFactory factory )
{
@@ -257,7 +258,8 @@
}
/**
- * @param local The local to set.
+ * @param local
+ * The local to set.
*/
public void setLocal( org.apache.maven.artifact.repository.ArtifactRepository local )
{
@@ -273,7 +275,8 @@
}
/**
- * @param remoteRepos The remoteRepos to set.
+ * @param remoteRepos
+ * The remoteRepos to set.
*/
public void setRemoteRepos( java.util.List remoteRepos )
{
@@ -289,7 +292,8 @@
}
/**
- * @param resolver The resolver to set.
+ * @param resolver
+ * The resolver to set.
*/
public void setResolver( org.apache.maven.artifact.resolver.ArtifactResolver resolver )
{
@@ -297,7 +301,8 @@
}
/**
- * @param archiverManager The archiverManager to set.
+ * @param archiverManager
+ * The archiverManager to set.
*/
public void setArchiverManager( ArchiverManager archiverManager )
{
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractFromDependenciesMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractFromDependenciesMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractFromDependenciesMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractFromDependenciesMojo.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency;
+
+/*
* 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
@@ -17,8 +19,6 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency;
-
import java.io.File;
/**
@@ -45,6 +45,7 @@
/**
* Place each type of file in a separate subdirectory. (example
* /outputDirectory/jars /outputDirectory/wars etc)
+ *
* @since 2.0
* @parameter expression="${useSubDirectoryPerType}" default-value="false"
* @optional
@@ -54,6 +55,7 @@
/**
* Place each file in a separate subdirectory. (example
* /outputDirectory/junit-junit-3.8.1)
+ *
* @since 2.0
* @parameter expression="${useSubDirectoryPerArtifact}"
* default-value="false"
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractResolveMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractResolveMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractResolveMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/AbstractResolveMojo.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency;
+
+/*
* 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
@@ -16,8 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
-package org.apache.maven.plugin.dependency;
import java.util.Iterator;
import java.util.Set;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/CopyDependenciesMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/CopyDependenciesMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/CopyDependenciesMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/CopyDependenciesMojo.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency;
+
+/*
* 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
@@ -17,8 +19,6 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency;
-
import java.io.File;
import java.util.Iterator;
import java.util.Set;
@@ -29,7 +29,6 @@
import org.apache.maven.plugin.dependency.utils.DependencyUtil;
import org.apache.maven.plugin.dependency.utils.filters.ArtifactsFilter;
import org.apache.maven.plugin.dependency.utils.filters.DestFileFilter;
-import org.apache.maven.plugin.logging.Log;
/**
* Goal that copies the project dependencies from the repository to a defined
@@ -47,6 +46,7 @@
/**
* Strip artifact version during copy
+ *
* @optional
* @parameter expression="${stripVersion}" default-value="false"
* @parameter
@@ -75,12 +75,10 @@
}
artifacts = dss.getSkippedDependencies();
+ for ( Iterator i = artifacts.iterator(); i.hasNext(); )
{
- for ( Iterator i = artifacts.iterator(); i.hasNext(); )
- {
- Artifact artifact = (Artifact) i.next();
- getLog().info( artifact.getFile().getName() + " already exists in destination." );
- }
+ Artifact artifact = (Artifact) i.next();
+ getLog().info( artifact.getFile().getName() + " already exists in destination." );
}
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/PurgeLocalRepositoryMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/PurgeLocalRepositoryMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/PurgeLocalRepositoryMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/PurgeLocalRepositoryMojo.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency;
+
+/*
* 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
@@ -16,8 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
-package org.apache.maven.plugin.dependency;
import java.io.File;
import java.io.IOException;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/UnpackDependenciesMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/UnpackDependenciesMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/UnpackDependenciesMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/UnpackDependenciesMojo.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency;
+
+/*
* 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
@@ -17,8 +19,6 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency;
-
import java.io.File;
import java.util.Iterator;
import java.util.Set;
@@ -30,8 +30,6 @@
import org.apache.maven.plugin.dependency.utils.filters.ArtifactsFilter;
import org.apache.maven.plugin.dependency.utils.filters.MarkerFileFilter;
import org.apache.maven.plugin.dependency.utils.markers.DefaultFileMarkerHandler;
-import org.apache.maven.plugin.logging.Log;
-import org.codehaus.plexus.archiver.manager.ArchiverManager;
/**
* Goal that unpacks the project dependencies from the repository to a defined
@@ -71,20 +69,17 @@
this.useSubDirectoryPerArtifact,
this.outputDirectory, artifact );
- unpack( artifact.getFile(), destDir);
+ unpack( artifact.getFile(), destDir );
DefaultFileMarkerHandler handler = new DefaultFileMarkerHandler( artifact, this.markersDirectory );
handler.setMarker();
}
artifacts = dss.getSkippedDependencies();
+ for ( Iterator i = artifacts.iterator(); i.hasNext(); )
{
- for ( Iterator i = artifacts.iterator(); i.hasNext(); )
- {
- Artifact artifact = (Artifact) i.next();
- getLog().info( artifact.getFile().getName() + " already exists in destination." );
- }
+ Artifact artifact = (Artifact) i.next();
+ getLog().info( artifact.getFile().getName() + " already exists in destination." );
}
-
}
protected ArtifactsFilter getMarkedArtifactFilter()
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/AbstractFromConfigurationMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/AbstractFromConfigurationMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/AbstractFromConfigurationMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/AbstractFromConfigurationMojo.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.fromConfiguration;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,8 +19,6 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.fromConfiguration;
-
import java.io.File;
import java.util.ArrayList;
import java.util.Iterator;
@@ -142,21 +142,22 @@
{
artifactItem.setDestFileName( DependencyUtil.getFormattedFileName( artifactItem.getArtifact(),
removeVersion ) );
- }
-
- artifactItem.setNeedsProcessing(checkIfProcessingNeeded(artifactItem));
+ }
+
+ artifactItem.setNeedsProcessing( checkIfProcessingNeeded( artifactItem ) );
}
return artifactItems;
}
- private boolean checkIfProcessingNeeded(ArtifactItem item) throws MojoExecutionException
+ private boolean checkIfProcessingNeeded( ArtifactItem item )
+ throws MojoExecutionException
{
boolean result = false;
if ( StringUtils.equalsIgnoreCase( item.getOverWrite(), "true" ) )
{
result = true;
}
- else if (StringUtils.equalsIgnoreCase( item.getOverWrite(), "false" ))
+ else if ( StringUtils.equalsIgnoreCase( item.getOverWrite(), "false" ) )
{
result = false;
}
@@ -167,7 +168,7 @@
}
return result;
}
-
+
/**
* Resolves the Artifact from the remote repository if nessessary. If no
* version is specified, it will be retrieved from the dependency list or
@@ -242,7 +243,7 @@
* representing configured file.
* @param list
* list of dependencies to search.
- * @returns the found dependency
+ * @return the found dependency
*/
private boolean findDependencyVersion( ArtifactItem artifact, List list )
{
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/ArtifactItem.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/ArtifactItem.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/ArtifactItem.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/ArtifactItem.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.fromConfiguration;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,8 +19,6 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.fromConfiguration;
-
import java.io.File;
import org.apache.maven.artifact.Artifact;
@@ -107,17 +107,17 @@
public ArtifactItem( Artifact artifact )
{
- this.setArtifact(artifact);
- this.setArtifactId(artifact.getArtifactId());
- this.setClassifier(artifact.getClassifier());
- this.setGroupId(artifact.getGroupId());
- this.setType(artifact.getType());
- this.setVersion(artifact.getVersion());
+ this.setArtifact( artifact );
+ this.setArtifactId( artifact.getArtifactId() );
+ this.setClassifier( artifact.getClassifier() );
+ this.setGroupId( artifact.getGroupId() );
+ this.setType( artifact.getType() );
+ this.setVersion( artifact.getVersion() );
}
- private final String filterEmptyString(String in)
+ private String filterEmptyString( String in )
{
- if (in == null || in.equals(""))
+ if ( in == null || in.equals( "" ) )
{
return null;
}
@@ -126,6 +126,7 @@
return in;
}
}
+
/**
* @return Returns the artifactId.
*/
@@ -140,7 +141,7 @@
*/
public void setArtifactId( String artifact )
{
- this.artifactId = filterEmptyString(artifact);
+ this.artifactId = filterEmptyString( artifact );
}
/**
@@ -157,7 +158,7 @@
*/
public void setGroupId( String groupId )
{
- this.groupId = filterEmptyString(groupId);
+ this.groupId = filterEmptyString( groupId );
}
/**
@@ -174,7 +175,7 @@
*/
public void setType( String type )
{
- this.type = filterEmptyString(type);
+ this.type = filterEmptyString( type );
}
/**
@@ -191,7 +192,7 @@
*/
public void setVersion( String version )
{
- this.version = filterEmptyString(version);
+ this.version = filterEmptyString( version );
}
/**
@@ -208,18 +209,19 @@
*/
public void setClassifier( String classifier )
{
- this.classifier = filterEmptyString(classifier);
+ this.classifier = filterEmptyString( classifier );
}
public String toString()
{
if ( this.classifier == null )
{
- return groupId + ":" + artifactId + ":" + StringUtils.defaultString(version,"?") + ":" + type;
+ return groupId + ":" + artifactId + ":" + StringUtils.defaultString( version, "?" ) + ":" + type;
}
else
{
- return groupId + ":" + artifactId + ":" + classifier + ":" + StringUtils.defaultString(version,"?") + ":" + type;
+ return groupId + ":" + artifactId + ":" + classifier + ":" + StringUtils.defaultString( version, "?" )
+ + ":" + type;
}
}
@@ -254,7 +256,7 @@
*/
public void setDestFileName( String destFileName )
{
- this.destFileName = filterEmptyString(destFileName);
+ this.destFileName = filterEmptyString( destFileName );
}
/**
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.fromConfiguration;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,18 +19,13 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.fromConfiguration;
-
import java.io.File;
import java.util.ArrayList;
import java.util.Iterator;
-import org.apache.maven.artifact.Artifact;
import org.apache.maven.plugin.MojoExecutionException;
-import org.apache.maven.plugin.dependency.utils.DependencyUtil;
-import org.apache.maven.plugin.dependency.utils.filters.DestFileFilter;
import org.apache.maven.plugin.dependency.utils.filters.ArtifactItemFilter;
-import org.apache.maven.plugin.logging.Log;
+import org.apache.maven.plugin.dependency.utils.filters.DestFileFilter;
/**
* Goal that copies a list of artifacts from the repository to defined
@@ -70,13 +67,13 @@
while ( iter.hasNext() )
{
ArtifactItem artifactItem = (ArtifactItem) iter.next();
- if (artifactItem.isNeedsProcessing())
+ if ( artifactItem.isNeedsProcessing() )
{
- copyArtifact( artifactItem);
+ copyArtifact( artifactItem );
}
else
{
- this.getLog().info(artifactItem+" already exists in "+ artifactItem.getOutputDirectory());
+ this.getLog().info( artifactItem + " already exists in " + artifactItem.getOutputDirectory() );
}
}
}
@@ -101,14 +98,16 @@
copyFile( artifactItem.getArtifact().getFile(), destFile );
}
- protected ArtifactItemFilter getMarkedArtifactFilter(ArtifactItem item)
+ protected ArtifactItemFilter getMarkedArtifactFilter( ArtifactItem item )
{
- ArtifactItemFilter destinationNameOverrideFilter = new DestFileFilter( this.overWriteReleases, this.overWriteSnapshots, this.overWriteIfNewer,
- false, false, this.stripVersion,
- item.getOutputDirectory() );
+ ArtifactItemFilter destinationNameOverrideFilter = new DestFileFilter( this.overWriteReleases,
+ this.overWriteSnapshots,
+ this.overWriteIfNewer, false, false,
+ this.stripVersion, item
+ .getOutputDirectory() );
return destinationNameOverrideFilter;
}
-
+
/**
* @return Returns the stripVersion.
*/
@@ -118,7 +117,8 @@
}
/**
- * @param stripVersion The stripVersion to set.
+ * @param stripVersion
+ * The stripVersion to set.
*/
public void setStripVersion( boolean stripVersion )
{
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/UnpackMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/UnpackMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/UnpackMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/UnpackMojo.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.fromConfiguration;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,22 +19,16 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.fromConfiguration;
-
import java.io.File;
import java.util.ArrayList;
import java.util.Iterator;
import org.apache.maven.artifact.Artifact;
import org.apache.maven.plugin.MojoExecutionException;
-import org.apache.maven.plugin.dependency.utils.DependencyUtil;
-import org.apache.maven.plugin.dependency.utils.filters.ArtifactsFilter;
import org.apache.maven.plugin.dependency.utils.filters.ArtifactItemFilter;
import org.apache.maven.plugin.dependency.utils.filters.MarkerFileFilter;
import org.apache.maven.plugin.dependency.utils.markers.DefaultFileMarkerHandler;
import org.apache.maven.plugin.dependency.utils.markers.MarkerHandler;
-import org.apache.maven.plugin.logging.Log;
-import org.codehaus.plexus.archiver.manager.ArchiverManager;
/**
* Goal that retrieves a list of artifacts from the repository and unpacks them
@@ -68,14 +64,14 @@
public void execute()
throws MojoExecutionException
{
- ArrayList artifactItems = getArtifactItems( false );
- Iterator iter = artifactItems.iterator();
+ ArrayList processedItems = getArtifactItems( false );
+ Iterator iter = processedItems.iterator();
while ( iter.hasNext() )
{
ArtifactItem artifactItem = (ArtifactItem) iter.next();
- if (artifactItem.isNeedsProcessing())
+ if ( artifactItem.isNeedsProcessing() )
{
- unpackArtifact( artifactItem );
+ unpackArtifact( artifactItem );
}
else
{
@@ -112,7 +108,7 @@
ArtifactItemFilter getMarkedArtifactFilter( ArtifactItem item )
{
MarkerHandler handler = new DefaultFileMarkerHandler( item.getArtifact(), this.markersDirectory );
-
- return new MarkerFileFilter(this.overWriteReleases,this.overWriteSnapshots,this.overWriteIfNewer,handler);
+
+ return new MarkerFileFilter( this.overWriteReleases, this.overWriteSnapshots, this.overWriteIfNewer, handler );
}
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/GoOfflineMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/GoOfflineMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/GoOfflineMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/GoOfflineMojo.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.resolvers;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -16,9 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
-
-package org.apache.maven.plugin.dependency.resolvers;
import java.util.Iterator;
import java.util.Set;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependenciesMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependenciesMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependenciesMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependenciesMojo.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.resolvers;
+
+/*
* 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
@@ -17,8 +19,6 @@
* under the License.
*/
-
-package org.apache.maven.plugin.dependency.resolvers;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.dependency.AbstractResolveMojo;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependencySourcesMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependencySourcesMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependencySourcesMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolveDependencySourcesMojo.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.resolvers;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,10 +19,6 @@
* under the License.
*/
-
-package org.apache.maven.plugin.dependency.resolvers;
-
-import java.io.File;
import java.util.Iterator;
import java.util.Set;
@@ -42,9 +40,9 @@
extends AbstractResolveMojo
{
- private static final String SOURCE_TYPE = "java-source";
+ // private static final String SOURCE_TYPE = "java-source";
- private static final String SOURCE_CLASSIFIER = "sources";
+ // private static final String SOURCE_CLASSIFIER = "sources";
/**
* If the plugin should exclude Transitive dependencies.
@@ -68,14 +66,14 @@
* default-value="${project.build.directory}/dependency-maven-plugin-markers"
* @required
*/
- private File markersDirectory;
+// private File markersDirectory;
/**
* Use Marker Files
*
* @parameter expression="${dependency.useMarkers}" default-value="false"
*/
- private boolean useMarkers;
+// private boolean useMarkers;
/**
* Main entry into mojo. Gets the list of dependencies and iterates through
@@ -116,7 +114,6 @@
protected ArtifactsFilter getMarkedArtifactFilter()
{
- // TODO Auto-generated method stub
return null;
}
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolvePluginsMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolvePluginsMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolvePluginsMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/resolvers/ResolvePluginsMojo.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.resolvers;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,9 +19,6 @@
* under the License.
*/
-
-package org.apache.maven.plugin.dependency.resolvers;
-
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
@@ -86,7 +85,7 @@
}
if ( !excludeTransitive )
{
- Set transitiveDependencies = this.resolveArtifactDependencies( plugin);
+ Set transitiveDependencies = this.resolveArtifactDependencies( plugin );
if ( !silent )
{
for ( Iterator transIter = transitiveDependencies.iterator(); transIter.hasNext(); )
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyStatusSets.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyStatusSets.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyStatusSets.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyStatusSets.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils;
+
+/*
* 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
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils;
import java.util.Iterator;
import java.util.Set;
@@ -154,12 +155,13 @@
{
try
{
- //we want to print the absolute file name here
+ // we want to print the absolute file name here
artifactFilename = artifact.getFile().getAbsoluteFile().getPath();
}
catch ( NullPointerException e )
{
// ignore the null pointer, we'll output a null string
+ artifactFilename = null;
}
}
log.info( " " + artifact.getId() + ( outputAbsoluteArtifactFilename ? ":" + artifactFilename : "" ) );
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyUtil.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyUtil.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyUtil.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/DependencyUtil.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils;
+
+/*
* 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
@@ -16,8 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
-package org.apache.maven.plugin.dependency.utils;
import java.io.File;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/SilentLog.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/SilentLog.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/SilentLog.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/SilentLog.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils;
+
+/*
* 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
@@ -17,8 +19,6 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.utils;
-
import org.apache.maven.plugin.logging.Log;
import org.codehaus.plexus.logging.Logger;
@@ -97,61 +97,61 @@
public void debug( String message )
{
// TODO Auto-generated method stub
-
+
}
public void debug( String message, Throwable throwable )
{
// TODO Auto-generated method stub
-
+
}
public void info( String message )
{
// TODO Auto-generated method stub
-
+
}
public void info( String message, Throwable throwable )
{
// TODO Auto-generated method stub
-
+
}
public void warn( String message )
{
// TODO Auto-generated method stub
-
+
}
public void warn( String message, Throwable throwable )
{
// TODO Auto-generated method stub
-
+
}
public void error( String message )
{
// TODO Auto-generated method stub
-
+
}
public void error( String message, Throwable throwable )
{
// TODO Auto-generated method stub
-
+
}
public void fatalError( String message )
{
// TODO Auto-generated method stub
-
+
}
public void fatalError( String message, Throwable throwable )
{
// TODO Auto-generated method stub
-
+
}
public boolean isFatalErrorEnabled()
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactFeatureFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactFeatureFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactFeatureFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactFeatureFilter.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.filters;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,19 +19,16 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.utils.filters;
-
-import org.apache.maven.artifact.Artifact;
-import org.apache.maven.plugin.MojoExecutionException;
-import org.apache.maven.plugin.logging.Log;
-import org.codehaus.plexus.util.StringUtils;
-
import java.util.Arrays;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Set;
+import org.apache.maven.artifact.Artifact;
+import org.apache.maven.plugin.logging.Log;
+import org.codehaus.plexus.util.StringUtils;
+
/**
* This is the common base class of ClassifierFilter and TypeFilter
*
@@ -56,11 +55,11 @@
*/
private String featureName;
- public AbstractArtifactFeatureFilter( String include, String exclude, String featureName )
+ public AbstractArtifactFeatureFilter( String include, String exclude, String theFeatureName )
{
setExcludes( exclude );
setIncludes( include );
- this.featureName = featureName;
+ featureName = theFeatureName;
}
/**
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactsFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactsFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactsFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/AbstractArtifactsFilter.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.filters;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -16,7 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.maven.plugin.dependency.utils.filters;
import java.util.HashSet;
import java.util.Set;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactItemFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactItemFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactItemFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactItemFilter.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.filters;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -16,10 +18,10 @@
* specific language governing permissions and limitations
* under the License.
*/
+
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.filters;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.dependency.fromConfiguration.ArtifactItem;
@@ -31,6 +33,6 @@
public interface ArtifactItemFilter
{
- public boolean okToProcess( ArtifactItem item )
+ boolean okToProcess( ArtifactItem item )
throws MojoExecutionException;
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactsFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactsFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactsFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ArtifactsFilter.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.filters;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.filters;
import java.util.Set;
@@ -34,9 +35,9 @@
*/
public interface ArtifactsFilter
{
- public Set filter( Set artifacts, Log log )
+ Set filter( Set artifacts, Log log )
throws MojoExecutionException;
- public boolean okToProcess( Artifact artifact, Log log )
+ boolean okToProcess( Artifact artifact, Log log )
throws MojoExecutionException;
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ClassifierFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ClassifierFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ClassifierFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ClassifierFilter.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.filters;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -17,21 +19,23 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.utils.filters;
-
import org.apache.maven.artifact.Artifact;
-public class ClassifierFilter extends AbstractArtifactFeatureFilter
+public class ClassifierFilter
+ extends AbstractArtifactFeatureFilter
{
public ClassifierFilter( String include, String exclude )
{
- super(include,exclude,"Classifiers");
+ super( include, exclude, "Classifiers" );
}
- /* (non-Javadoc)
+ /*
+ * (non-Javadoc)
+ *
* @see org.apache.maven.plugin.dependency.utils.filters.AbstractArtifactFeatureFilter#getArtifactFeature(org.apache.maven.artifact.Artifact)
*/
- protected String getArtifactFeature(Artifact artifact) {
+ protected String getArtifactFeature( Artifact artifact )
+ {
return artifact.getClassifier();
}
- }
+}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/DestFileFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/DestFileFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/DestFileFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/DestFileFilter.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.filters;
+
+/*
* 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
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.filters;
import java.io.File;
import java.util.HashSet;
@@ -97,7 +98,7 @@
while ( iter.hasNext() )
{
Artifact artifact = (Artifact) iter.next();
- if (okToProcess( new ArtifactItem(artifact) ) )
+ if ( okToProcess( new ArtifactItem( artifact ) ) )
{
result.add( artifact );
}
@@ -224,12 +225,13 @@
this.useSubDirectoryPerType = useSubDirectoryPerType;
}
- public boolean okToProcess( ArtifactItem item ) throws MojoExecutionException
+ public boolean okToProcess( ArtifactItem item )
+ throws MojoExecutionException
{
boolean overWrite = false;
boolean result = false;
Artifact artifact = item.getArtifact();
-
+
if ( ( artifact.isSnapshot() && this.overWriteSnapshots )
|| ( !artifact.isSnapshot() && this.overWriteReleases ) )
{
@@ -239,20 +241,21 @@
File destFolder = item.getOutputDirectory();
if ( destFolder == null )
{
- destFolder = DependencyUtil.getFormattedOutputDirectory( this.useSubDirectoryPerType, this.useSubDirectoryPerArtifact,
- this.outputFileDirectory, artifact );
+ destFolder = DependencyUtil.getFormattedOutputDirectory( this.useSubDirectoryPerType,
+ this.useSubDirectoryPerArtifact,
+ this.outputFileDirectory, artifact );
}
-
+
File destFile = null;
- if (StringUtils.isEmpty(item.getDestFileName()))
+ if ( StringUtils.isEmpty( item.getDestFileName() ) )
{
destFile = new File( destFolder, DependencyUtil.getFormattedFileName( artifact, this.removeVersion ) );
}
else
{
- destFile = new File (destFolder,item.getDestFileName());
- }
-
+ destFile = new File( destFolder, item.getDestFileName() );
+ }
+
if ( overWrite
|| ( !destFile.exists() || ( overWriteIfNewer && artifact.getFile().lastModified() > destFile
.lastModified() ) ) )
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/FilterArtifacts.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/FilterArtifacts.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/FilterArtifacts.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/FilterArtifacts.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.filters;
+
+/*
* 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
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.filters;
import java.util.ArrayList;
import java.util.Iterator;
@@ -54,13 +55,15 @@
/**
* Appends the specified element to the end of this list.
*
- * @param o
+ * @param filter
* element to be appended to this list.
- * @return <tt>true</tt> (as per the general contract of Collection.add).
*/
public void addFilter( ArtifactsFilter filter )
{
- filters.add( filter );
+ if ( filter != null )
+ {
+ filters.add( filter );
+ }
}
/**
@@ -78,7 +81,10 @@
*/
public void addFilter( int index, ArtifactsFilter filter )
{
- filters.add( index, filter );
+ if ( filter != null )
+ {
+ filters.add( index, filter );
+ }
}
public Set filter( Set artifacts, Log log )
@@ -90,7 +96,15 @@
{
// log(artifacts,log);
ArtifactsFilter filter = (ArtifactsFilter) filterIterator.next();
- artifacts = filter.filter( artifacts, log );
+ try
+ {
+ artifacts = filter.filter( artifacts, log );
+ }
+ catch ( NullPointerException e )
+ {
+ // don't do anything, just skip this.
+ continue;
+ }
}
return artifacts;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/MarkerFileFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/MarkerFileFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/MarkerFileFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/MarkerFileFilter.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.filters;
+
+/*
* 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
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.filters;
import java.util.HashSet;
import java.util.Iterator;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ResolveFileFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ResolveFileFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ResolveFileFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ResolveFileFilter.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.filters;
+
+/*
* 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
@@ -20,9 +22,7 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.filters;
-import org.apache.maven.artifact.Artifact;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.dependency.fromConfiguration.ArtifactItem;
import org.apache.maven.plugin.dependency.utils.markers.MarkerHandler;
@@ -41,8 +41,8 @@
}
public boolean okToProcess( ArtifactItem item )
- throws MojoExecutionException
- {
+ throws MojoExecutionException
+ {
handler.setArtifact( item.getArtifact() );
return ( !handler.isMarkerSet() );
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ScopeFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ScopeFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ScopeFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/ScopeFilter.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.filters;
+
+/*
* 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
@@ -16,8 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
-package org.apache.maven.plugin.dependency.utils.filters;
import java.util.HashSet;
import java.util.Iterator;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TransitivityFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TransitivityFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TransitivityFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TransitivityFilter.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.filters;
+
+/*
* 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
@@ -16,8 +18,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
-package org.apache.maven.plugin.dependency.utils.filters;
import java.util.HashSet;
import java.util.Iterator;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TypeFilter.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TypeFilter.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TypeFilter.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/filters/TypeFilter.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.filters;
+
+/*
* 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
@@ -17,21 +19,23 @@
* under the License.
*/
-package org.apache.maven.plugin.dependency.utils.filters;
-
import org.apache.maven.artifact.Artifact;
-public class TypeFilter extends AbstractArtifactFeatureFilter
+public class TypeFilter
+ extends AbstractArtifactFeatureFilter
{
public TypeFilter( String include, String exclude )
{
- super(include, exclude, "Types");
+ super( include, exclude, "Types" );
}
- /* (non-Javadoc)
+ /*
+ * (non-Javadoc)
+ *
* @see org.apache.maven.plugin.dependency.utils.filters.AbstractArtifactFeatureFilter#getArtifactFeature(org.apache.maven.artifact.Artifact)
*/
- protected String getArtifactFeature(Artifact artifact) {
+ protected String getArtifactFeature( Artifact artifact )
+ {
return artifact.getType();
}
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/DefaultFileMarkerHandler.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/DefaultFileMarkerHandler.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/DefaultFileMarkerHandler.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/DefaultFileMarkerHandler.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.markers;
+
+/*
* 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
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.markers;
import java.io.File;
import java.io.IOException;
@@ -39,15 +40,15 @@
protected File markerFilesDirectory;
- public DefaultFileMarkerHandler( File markerFilesDirectory )
+ public DefaultFileMarkerHandler( File theMarkerFilesDirectory )
{
- this.markerFilesDirectory = markerFilesDirectory;
+ this.markerFilesDirectory = theMarkerFilesDirectory;
}
- public DefaultFileMarkerHandler( Artifact artifact, File markerFilesDirectory )
+ public DefaultFileMarkerHandler( Artifact theArtifact, File theMarkerFilesDirectory )
{
- this.artifact = artifact;
- this.markerFilesDirectory = markerFilesDirectory;
+ this.artifact = theArtifact;
+ this.markerFilesDirectory = theMarkerFilesDirectory;
}
/**
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/MarkerHandler.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/MarkerHandler.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/MarkerHandler.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/MarkerHandler.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.markers;
+
+/*
* 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
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.markers;
import org.apache.maven.artifact.Artifact;
import org.apache.maven.plugin.MojoExecutionException;
@@ -31,18 +32,18 @@
*/
public interface MarkerHandler
{
- public boolean isMarkerSet()
+ boolean isMarkerSet()
throws MojoExecutionException;
- public void setMarker()
+ void setMarker()
throws MojoExecutionException;
- public boolean clearMarker()
+ boolean clearMarker()
throws MojoExecutionException;
- public boolean isMarkerOlder( Artifact artifact )
+ boolean isMarkerOlder( Artifact artifact )
throws MojoExecutionException;
- public void setArtifact( Artifact artifact );
+ void setArtifact( Artifact artifact );
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/SourcesFileMarkerHandler.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/SourcesFileMarkerHandler.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/SourcesFileMarkerHandler.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/markers/SourcesFileMarkerHandler.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.markers;
+
+/*
* 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
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.markers;
import java.io.File;
import java.io.IOException;
@@ -43,10 +44,10 @@
super( markerFilesDirectory );
}
- public SourcesFileMarkerHandler( Artifact artifact, File markerFilesDirectory, boolean resolved )
+ public SourcesFileMarkerHandler( Artifact artifact, File markerFilesDirectory, boolean isResolved )
{
super( artifact, markerFilesDirectory );
- this.resolved = resolved;
+ this.resolved = isResolved;
}
/**
@@ -62,8 +63,8 @@
/**
* Get MarkerFile, exposed for unit testing purposes
*
- * @param res
- * @return
+ * @param is resolved or not.
+ * @return marker file for this artifact.
*/
protected File getMarkerFile( boolean res )
{
@@ -185,8 +186,8 @@
* @param resolved
* The resolved to set.
*/
- public void setResolved( boolean resolved )
+ public void setResolved( boolean isResolved )
{
- this.resolved = resolved;
+ this.resolved = isResolved;
}
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/ArtifactsResolver.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/ArtifactsResolver.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/ArtifactsResolver.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/ArtifactsResolver.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.resolvers;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -20,7 +22,6 @@
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.resolvers;
import java.util.Set;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/DefaultArtifactsResolver.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/DefaultArtifactsResolver.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/DefaultArtifactsResolver.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/resolvers/DefaultArtifactsResolver.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.resolvers;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -19,8 +21,8 @@
/**
*
+ *
*/
-package org.apache.maven.plugin.dependency.utils.resolvers;
import java.util.HashSet;
import java.util.Iterator;
@@ -50,13 +52,13 @@
boolean stopOnFailure;
- public DefaultArtifactsResolver( ArtifactResolver resolver, ArtifactRepository local, List remoteRepositories,
- boolean stopOnFailure )
+ public DefaultArtifactsResolver( ArtifactResolver theResolver, ArtifactRepository theLocal,
+ List theRemoteRepositories, boolean theStopOnFailure )
{
- this.resolver = resolver;
- this.local = local;
- this.remoteRepositories = remoteRepositories;
- this.stopOnFailure = stopOnFailure;
+ this.resolver = theResolver;
+ this.local = theLocal;
+ this.remoteRepositories = theRemoteRepositories;
+ this.stopOnFailure = theStopOnFailure;
}
/*
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ArtifactTranslator.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ArtifactTranslator.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ArtifactTranslator.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ArtifactTranslator.java Tue Dec 5 20:13:36 2006
@@ -1,3 +1,5 @@
+package org.apache.maven.plugin.dependency.utils.translators;
+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
@@ -19,8 +21,8 @@
/**
*
+ *
*/
-package org.apache.maven.plugin.dependency.utils.translators;
import java.util.Set;
@@ -32,5 +34,5 @@
*/
public interface ArtifactTranslator
{
- public Set translate( Set artifacts, Log log );
+ Set translate( Set artifacts, Log log );
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ClassifierTypeTranslator.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ClassifierTypeTranslator.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ClassifierTypeTranslator.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/main/java/org/apache/maven/plugin/dependency/utils/translators/ClassifierTypeTranslator.java Tue Dec 5 20:13:36 2006
@@ -1,4 +1,6 @@
-/*
+package org.apache.maven.plugin.dependency.utils.translators;
+
+/*
* 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
@@ -14,13 +16,12 @@
* "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.
+ * under the License.
*/
/**
*
*/
-package org.apache.maven.plugin.dependency.utils.translators;
import java.util.HashSet;
import java.util.Iterator;
@@ -45,11 +46,11 @@
private ArtifactFactory factory;
- public ClassifierTypeTranslator( String classifier, String type, ArtifactFactory factory )
+ public ClassifierTypeTranslator( String theClassifier, String theType, ArtifactFactory theFactory )
{
- this.classifier = classifier;
- this.type = type;
- this.factory = factory;
+ this.classifier = theClassifier;
+ this.type = theType;
+ this.factory = theFactory;
}
/*
@@ -106,38 +107,38 @@
return results;
}
+
/**
- * @return Returns the classifier.
+ * @return Returns the type.
*/
- public String getClassifier()
+ public String getType()
{
- return this.classifier;
+ return this.type;
}
/**
- * @param classifier
- * The classifier to set.
+ * @param type
+ * The type to set.
*/
- public void setClassifier( String classifier )
+ public void setType( String theType )
{
- this.classifier = classifier;
+ this.type = theType;
}
/**
- * @return Returns the type.
+ * @return Returns the classifier.
*/
- public String getType()
+ public String getClassifier()
{
- return this.type;
+ return this.classifier;
}
/**
- * @param type
- * The type to set.
+ * @param theClassifier The classifier to set.
*/
- public void setType( String type )
+ public void setClassifier( String theClassifier )
{
- this.type = type;
+ this.classifier = theClassifier;
}
}
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/AbstractDependencyMojoTestCase.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/AbstractDependencyMojoTestCase.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/AbstractDependencyMojoTestCase.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/AbstractDependencyMojoTestCase.java Tue Dec 5 20:13:36 2006
@@ -18,24 +18,6 @@
* under the License.
*/
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
import java.io.File;
import java.io.IOException;
Modified: maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/TestCopyDependenciesMojo.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/TestCopyDependenciesMojo.java?view=diff&rev=482886&r1=482885&r2=482886
==============================================================================
--- maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/TestCopyDependenciesMojo.java (original)
+++ maven/plugins/trunk/maven-dependency-plugin/src/test/java/org/apache/maven/plugin/dependency/TestCopyDependenciesMojo.java Tue Dec 5 20:13:36 2006
@@ -18,24 +18,6 @@
* under the License.
*/
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
import java.io.File;
import java.io.IOException;
import java.util.HashSet;
@@ -226,7 +208,7 @@
}
public void testCopyDependenciesMojoExcludeClassifier()
- throws Exception
+ throws Exception
{
mojo.project.setArtifacts( stubFactory.getClassifiedArtifacts() );
mojo.project.setDependencyArtifacts( new HashSet() );
@@ -249,9 +231,9 @@
// assumes you can't delete a folder that has files.
assertTrue( mojo.outputDirectory.delete() );
}
-
+
public void testCopyDependenciesMojoIncludeClassifier()
- throws Exception
+ throws Exception
{
mojo.project.setArtifacts( stubFactory.getClassifiedArtifacts() );
mojo.project.setDependencyArtifacts( new HashSet() );
@@ -278,7 +260,7 @@
// assumes you can't delete a folder that has files.
assertTrue( mojo.outputDirectory.delete() );
}
-
+
public void testCopyDependenciesMojoSubPerType()
throws Exception
{
@@ -599,7 +581,6 @@
mojo.execute();
- long f = copiedFile.lastModified();
assertTrue( time < copiedFile.lastModified() );
}