tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rf...@apache.org
Subject svn commit: r526294 - /incubator/tuscany/java/sca/modules/contribution/src/main/java/org/apache/tuscany/services/spi/contribution/extension/ContributionPackageProcessorExtension.java
Date Fri, 06 Apr 2007 21:38:58 GMT
Author: rfeng
Date: Fri Apr  6 14:38:57 2007
New Revision: 526294

URL: http://svn.apache.org/viewvc?view=rev&rev=526294
Log:
Update ContributionPackageProcessor to return List<URI>

Modified:
    incubator/tuscany/java/sca/modules/contribution/src/main/java/org/apache/tuscany/services/spi/contribution/extension/ContributionPackageProcessorExtension.java

Modified: incubator/tuscany/java/sca/modules/contribution/src/main/java/org/apache/tuscany/services/spi/contribution/extension/ContributionPackageProcessorExtension.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/contribution/src/main/java/org/apache/tuscany/services/spi/contribution/extension/ContributionPackageProcessorExtension.java?view=diff&rev=526294&r1=526293&r2=526294
==============================================================================
--- incubator/tuscany/java/sca/modules/contribution/src/main/java/org/apache/tuscany/services/spi/contribution/extension/ContributionPackageProcessorExtension.java
(original)
+++ incubator/tuscany/java/sca/modules/contribution/src/main/java/org/apache/tuscany/services/spi/contribution/extension/ContributionPackageProcessorExtension.java
Fri Apr  6 14:38:57 2007
@@ -19,33 +19,43 @@
 
 package org.apache.tuscany.services.spi.contribution.extension;
 
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+
 import org.apache.tuscany.services.spi.contribution.ContributionPackageProcessor;
 import org.apache.tuscany.services.spi.contribution.ContributionPackageProcessorRegistry;
 
 /**
  * The base class for ContributionPackageProcessor implementations
- *
+ * 
  * @version $Rev$ $Date$
  */
 public abstract class ContributionPackageProcessorExtension implements ContributionPackageProcessor
{
     /**
-     * The ContributionProcessorRegistry that this processor should register with; usually
set by injection. This
-     * registry may also be used to process other sub-artifacts.
+     * The ContributionProcessorRegistry that this processor should register
+     * with; usually set by injection. This registry may also be used to process
+     * other sub-artifacts.
      */
     protected final ContributionPackageProcessorRegistry registry;
 
     /**
      * @param registry the registry to set
      */
-    public ContributionPackageProcessorExtension(ContributionPackageProcessorRegistry registry){
+    public ContributionPackageProcessorExtension(ContributionPackageProcessorRegistry registry)
{
         this.registry = registry;
         this.registry.register(this.getPackageType(), this);
     }
-    
+
+    public URL getArtifactURL(URL packageSourceURL, URI artifact) throws MalformedURLException
{
+        return new URL(packageSourceURL, artifact.toString());
+    }
+
     /**
-     * Returns the type of package handled by this package processor. 
+     * Returns the type of package handled by this package processor.
+     * 
      * @return the type of package handled by this package processor
-     */    
+     */
     public abstract String getPackageType();
 
 }



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org


Mime
View raw message