Author: alessio.soldano(a)jboss.com
Date: 2009-11-19 07:06:04 -0500 (Thu, 19 Nov 2009)
New Revision: 11130
Added:
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ResourceResolver.java
Modified:
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ArchiveDeployment.java
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java
Log:
[JBWS-2828] Adding ResourceResolver interface
Modified: spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ArchiveDeployment.java
===================================================================
--- spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ArchiveDeployment.java 2009-11-18
18:12:17 UTC (rev 11129)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ArchiveDeployment.java 2009-11-19
12:06:04 UTC (rev 11130)
@@ -50,7 +50,10 @@
/** The concatenated names including all parents. */
String getCanonicalName();
- /** Get the URL for a given resource path */
+ /** Get the URL for a given resource path
+ * Deprecated, use getResourceResolver().resolve(String resourcePath).
+ */
+ @Deprecated
URL getMetaDataFileURL(String resourcePath) throws IOException;
/** Get additional metadata files attached to the deployment **/
@@ -58,4 +61,8 @@
/** Set additional metadata files for this deployment **/
void setMetadataFiles(List<UnifiedVirtualFile> metadataFiles);
+
+ /** Get the resource resolver to be used to access resources from this archive */
+ ResourceResolver getResourceResolver();
+
}
Modified: spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java
===================================================================
--- spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java 2009-11-18
18:12:17 UTC (rev 11129)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java 2009-11-19
12:06:04 UTC (rev 11130)
@@ -70,9 +70,9 @@
/** Set the current deployment state */
void setState(DeploymentState type);
- /** Get the service assiated with this deployment */
+ /** Get the service associated with this deployment */
Service getService();
- /** Set the service assiated with this deployment */
+ /** Set the service associated with this deployment */
void setService(Service service);
}
Added: spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ResourceResolver.java
===================================================================
--- spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ResourceResolver.java
(rev 0)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ResourceResolver.java 2009-11-19
12:06:04 UTC (rev 11130)
@@ -0,0 +1,44 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2009, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.wsf.spi.deployment;
+
+import java.io.IOException;
+import java.net.URL;
+
+/**
+ * A resource resolver
+ *
+ * @author alessio.soldano(a)jboss.com
+ * @since 19-Nov-2009
+ *
+ */
+public interface ResourceResolver
+{
+ /** Get the URL for a given resource path
+ *
+ * @param resourcePath
+ * @return
+ * @throws IOException
+ */
+ public URL resolve(String resourcePath) throws IOException;
+
+}
Property changes on:
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ResourceResolver.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF