maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From csta...@apache.org
Subject svn commit: r1075317 - in /maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact: Gav.java GavCalculator.java IllegalArtifactCoordinateException.java
Date Mon, 28 Feb 2011 13:02:17 GMT
Author: cstamas
Date: Mon Feb 28 13:02:17 2011
New Revision: 1075317

URL: http://svn.apache.org/viewvc?rev=1075317&view=rev
Log:
Returning 4.0.0 backward compatibility. The removed constructor and exception (that is not
used anymore!). Having these, the code remains 4.0.0 compatible even with the changes.

Added:
    maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/IllegalArtifactCoordinateException.java
  (with props)
Modified:
    maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/Gav.java
    maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/GavCalculator.java

Modified: maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/Gav.java
URL: http://svn.apache.org/viewvc/maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/Gav.java?rev=1075317&r1=1075316&r2=1075317&view=diff
==============================================================================
--- maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/Gav.java
(original)
+++ maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/Gav.java
Mon Feb 28 13:02:17 2011
@@ -93,6 +93,33 @@ public class Gav
         this( groupId, artifactId, version, null, null, null, null, null, false, null, false,
null );
     }
 
+    /**
+     * Deprecated constructor, left here for backward compatibility. It simply delegates
to other constructor and
+     * neglects the snapshot redundant parameter.
+     * 
+     * @deprecated The <code>boolean snapshot</code> parameter is simply neglected.
Use the constructor without it.
+     * @param groupId
+     * @param artifactId
+     * @param version
+     * @param classifier
+     * @param extension
+     * @param snapshotBuildNumber
+     * @param snapshotTimeStamp
+     * @param name
+     * @param snapshot
+     * @param hash
+     * @param hashType
+     * @param signature
+     * @param signatureType
+     */
+    public Gav( String groupId, String artifactId, String version, String classifier, String
extension,
+                Integer snapshotBuildNumber, Long snapshotTimeStamp, String name, boolean
snapshot, boolean hash,
+                HashType hashType, boolean signature, SignatureType signatureType )
+    {
+        this( groupId, artifactId, version, classifier, extension, snapshotBuildNumber, snapshotTimeStamp,
name, hash,
+            hashType, signature, signatureType );
+    }
+
     public Gav( String groupId, String artifactId, String version, String classifier, String
extension,
                 Integer snapshotBuildNumber, Long snapshotTimeStamp, String name, boolean
hash, HashType hashType,
                 boolean signature, SignatureType signatureType )

Modified: maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/GavCalculator.java
URL: http://svn.apache.org/viewvc/maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/GavCalculator.java?rev=1075317&r1=1075316&r2=1075317&view=diff
==============================================================================
--- maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/GavCalculator.java
(original)
+++ maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/GavCalculator.java
Mon Feb 28 13:02:17 2011
@@ -35,8 +35,10 @@ public interface GavCalculator
      * 
      * @param path the repository path
      * @return Gav parsed from the path
+     * @throws IllegalArtifactCoordinateException not throwing it anymore, here just for
backward compatibility.
      */
-    Gav pathToGav( String path );
+    Gav pathToGav( String path )
+        throws IllegalArtifactCoordinateException;
 
     /**
      * Reassembles the repository path from the supplied GAV. It will be an absolute path.

Added: maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/IllegalArtifactCoordinateException.java
URL: http://svn.apache.org/viewvc/maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/IllegalArtifactCoordinateException.java?rev=1075317&view=auto
==============================================================================
--- maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/IllegalArtifactCoordinateException.java
(added)
+++ maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/IllegalArtifactCoordinateException.java
Mon Feb 28 13:02:17 2011
@@ -0,0 +1,23 @@
+package org.apache.maven.index.artifact;
+
+/**
+ * Deprecated exception, just made into Runtime exception but NEVER THROWN anymore (since
4.0.1),
+ * 
+ * @author cstamas
+ * @deprecated Not throwed anymore.
+ */
+public class IllegalArtifactCoordinateException
+    extends RuntimeException
+{
+    private static final long serialVersionUID = 7137593998855995199L;
+
+    public IllegalArtifactCoordinateException( String message )
+    {
+        super( message );
+    }
+
+    public IllegalArtifactCoordinateException( String message, Throwable cause )
+    {
+        super( message, cause );
+    }
+}

Propchange: maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/IllegalArtifactCoordinateException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/indexer/trunk/indexer-artifact/src/main/java/org/apache/maven/index/artifact/IllegalArtifactCoordinateException.java
------------------------------------------------------------------------------
    svn:keywords = Author Date Id Revision



Mime
View raw message