Author: asoldano
Date: 2014-06-12 12:03:46 -0400 (Thu, 12 Jun 2014)
New Revision: 18727
Removed:
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentState.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
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Service.java
Log:
[JBWS-3793] More cleanup
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 2014-06-11
15:57:09 UTC (rev 18726)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/ArchiveDeployment.java 2014-06-12
16:03:46 UTC (rev 18727)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * Copyright 2014, 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.
*
@@ -24,10 +24,8 @@
import java.util.List;
/**
- * A general web service deployment dep.
+ * A general web service deployment.
*
- * It has no notion of J2EE deployment packages.
- *
* @author Thomas.Diesler(a)jboss.com
* @since 20-Apr-2007
*/
@@ -36,23 +34,17 @@
/** Get the optional parent of this deployment */
ArchiveDeployment getParent();
- /** Set the optional parent for this deployment */
- void setParent (ArchiveDeployment parent);
-
/** Get the root file for this deployment */
UnifiedVirtualFile getRootFile();
- /** Set the root file for this deployment */
- void setRootFile(UnifiedVirtualFile root);
-
/** The concatenated names including all parents. */
String getCanonicalName();
/** Get additional metadata files attached to the deployment **/
List<UnifiedVirtualFile> getMetadataFiles();
- /** Set additional metadata files for this deployment **/
- void setMetadataFiles(List<UnifiedVirtualFile> metadataFiles);
+ /** Add additional metadata file to the deployment **/
+ void addMetadataFile(UnifiedVirtualFile file);
/** 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 2014-06-11
15:57:09 UTC (rev 18726)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Deployment.java 2014-06-12
16:03:46 UTC (rev 18727)
@@ -22,10 +22,8 @@
package org.jboss.wsf.spi.deployment;
/**
- * A general web service deployment dep.
+ * A general web service deployment.
*
- * It has no notion of J2EE deployment packages.
- *
* @author Thomas.Diesler(a)jboss.com
*/
public interface Deployment extends Extensible
@@ -33,30 +31,9 @@
/** Get the identifier for this deployment */
String getSimpleName();
- /** Set the identifier for this deployment */
- void setSimpleName(String name);
-
/** Get the class loader for this deployment */
- ClassLoader getInitialClassLoader();
+ ClassLoader getClassLoader();
- /** Set the class loader for this deployment */
- void setInitialClassLoader(ClassLoader loader);
-
- /** Get the runtime class loader for this deployment */
- ClassLoader getRuntimeClassLoader();
-
- /** Set the runtime class loader for this deployment */
- void setRuntimeClassLoader(ClassLoader loader);
-
- /** Get the current deployment state */
- DeploymentState getState();
-
- /** Set the current deployment state */
- void setState(DeploymentState type);
-
/** Get the service associated with this deployment */
Service getService();
-
- /** Set the service associated with this deployment */
- void setService(Service service);
}
Modified:
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java
===================================================================
---
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java 2014-06-11
15:57:09 UTC (rev 18726)
+++
spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentModelFactory.java 2014-06-12
16:03:46 UTC (rev 18727)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source.
- * Copyright 2011, Red Hat Middleware LLC, and individual contributors
+ * Copyright 2014, 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.
*
@@ -28,9 +28,9 @@
*/
public abstract class DeploymentModelFactory
{
- public abstract Deployment newDeployment(String simpleName, ClassLoader
initialLoader);
+ public abstract Deployment newDeployment(String simpleName, ClassLoader classLoader,
UnifiedVirtualFile rootFile);
- public abstract Service newService();
+ public abstract Deployment newDeployment(ArchiveDeployment parent, String simpleName,
ClassLoader classLoader, UnifiedVirtualFile rootFile);
public abstract Endpoint newHttpEndpoint(String targetBean);
Deleted: spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentState.java
===================================================================
--- spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentState.java 2014-06-11
15:57:09 UTC (rev 18726)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/DeploymentState.java 2014-06-12
16:03:46 UTC (rev 18727)
@@ -1,33 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2011, Red Hat, Inc., 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;
-
-/**
- * WebService deployment state.
- *
- * @author <a href="mailto:ropalka@redhat.com">Richard Opalka</a>
- */
-public enum DeploymentState
-{
- UNDEFINED, STARTED, STOPPED
-}
\ No newline at end of file
Modified: spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java
===================================================================
--- spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java 2014-06-11 15:57:09
UTC (rev 18726)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Endpoint.java 2014-06-12 16:03:46
UTC (rev 18727)
@@ -84,7 +84,7 @@
void setTargetBeanName(String epImpl);
/** Use the deployment classloader to load the bean */
- Class getTargetBeanClass();
+ Class<?> getTargetBeanClass();
/** Set the request handler for this endpoint */
void setRequestHandler(RequestHandler handler);
Modified: spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Service.java
===================================================================
--- spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Service.java 2014-06-11 15:57:09
UTC (rev 18726)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/deployment/Service.java 2014-06-12 16:03:46
UTC (rev 18727)
@@ -1,6 +1,6 @@
/*
* JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * Copyright 2014, 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.
*
@@ -24,44 +24,86 @@
import java.util.List;
/**
- * A general service deployment.
+ * A service collecting endpoints belonging to the same deployment.
*
- * Maintains a named set of EndpointDeployments
- *
* @author Thomas.Diesler(a)jboss.com
+ * @author alessio.soldano(a)jboss.com
* @since 20-Apr-2007
*/
public interface Service extends Extensible
{
- /** Get the deployment this service belongs to */
+ /**
+ * Get the deployment this service belongs to
+ *
+ * @return the deployment this service belongs to
+ */
Deployment getDeployment();
- /** Set the deployment this service belongs to */
- void setDeployment(Deployment dep);
-
- /** Add an endpoint to the service */
+ /**
+ * Add an endpoint to the service
+ *
+ * @param endpoint the endpoint to be added
+ */
void addEndpoint(Endpoint endpoint);
- /** Get the list of endpoints */
+ /**
+ * Remove an endpoint from the service, returns true if successfull
+ *
+ * @param endpoint the endpoint to remove
+ * @return true if the endpoint was actually removed, false otherwise
+ */
+ boolean removeEndpoint(Endpoint endpoint);
+
+ /**
+ * Get the list of endpoints
+ *
+ * @return a copy of the list of endpoints
+ */
List<Endpoint> getEndpoints();
- /** Get the list of endpoints */
+ /**
+ * Get the list of endpoints
+ *
+ * @param filter a filter for selecting endpoints
+ * @return a list of selected endpoints
+ */
List<Endpoint> getEndpoints(EndpointTypeFilter filter);
- /** Get an endpoint by name */
+ /**
+ * Get an endpoint by name
+ *
+ * @param simpleName the name of the endpoint to get
+ * @return the selected endpoint
+ */
Endpoint getEndpointByName(String simpleName);
- /** Get the context root for this service */
+ /**
+ * Get the context root for this service
+ *
+ * @return the context root for this service
+ */
String getContextRoot();
- /** Set the context root for this service */
+ /**
+ * Set the context root for this service
+ *
+ * @param contextRoot the context root for this service
+ */
void setContextRoot(String contextRoot);
- /** Get the virtual host for this service */
+ /**
+ * Get the virtual host for this service
+ *
+ * @return the virtual host for this service
+ */
String getVirtualHost();
- /** Set the virtual host for this service */
+ /**
+ * Set the virtual host for this service
+ *
+ * @param virtualHost the virtual host for this service
+ */
void setVirtualHost(String virtualHost);
}