Author: thomas.diesler(a)jboss.com
Date: 2007-05-10 03:33:24 -0400 (Thu, 10 May 2007)
New Revision: 3036
Added:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCClientDeployment.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCDeployment.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXWSDeployment.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/UnifiedDeploymentInfo.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/metadata/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/metadata/j2ee/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/DOMUtils.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/ObjectNameFactory.java
Removed:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/ObjectNameFactory.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/AbstractWebServiceDeployer.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/DeployerHook.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerEJB.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerJSE.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceMainDeployer.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHook.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookEJB.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookJSE.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptor.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptorEJB3.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ArchiveDeployerHook.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/DeploymentInfoAdapter.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookEJB21.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookJSE.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookEJB3.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookJSE.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/MainDeployerHook.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/UnifiedDeploymentInfoDeployer.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/VirtualFileAdaptor.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebMetaDataAdaptor.java
Modified:
projects/wsintegration/jbossws-spi/trunk/.classpath
projects/wsintegration/jbossws-spi/trunk/build.xml
projects/wsintegration/jbossws-spi/trunk/src/main/etc/ant-import/build-thirdparty.xml
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/management/BasicServerConfig.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsObjectFactory.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaDataParser.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java
projects/wsintegration/jbossws-spi/trunk/version.properties
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21MBean.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB3MBean.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSEMBean.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/AbstractApplicationMetaDataAdapter.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ArchiveDeployerHook.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/DeploymentInfoAdapter.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB21.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB3.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookEJB21.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookJSE.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookEJB3.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookJSE.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ModifyWebMetaDataDeployer.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB21.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB3.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointInterceptor.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/UnifiedDeploymentInfoDeployer.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppDeployerDeployer.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppGeneratorDeployer.java
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebMetaDataAdapter.java
projects/wsintegration/jbws-jboss50/trunk/src/main/etc/ant-import/build-deploy.xml
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB21.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB3.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB21.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB3.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointInterceptor.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppDeployerDeployer.java
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppGeneratorDeployer.java
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.sar/META-INF/jbossws-beans.xml
Log:
Add sunri-jboss50
Modified: projects/wsintegration/jbossws-spi/trunk/.classpath
===================================================================
--- projects/wsintegration/jbossws-spi/trunk/.classpath 2007-05-10 07:18:41 UTC (rev
3035)
+++ projects/wsintegration/jbossws-spi/trunk/.classpath 2007-05-10 07:33:24 UTC (rev
3036)
@@ -11,5 +11,7 @@
<classpathentry kind="lib"
path="thirdparty/jboss-logging-spi.jar"/>
<classpathentry kind="lib"
path="thirdparty/jboss-microcontainer.jar"/>
<classpathentry kind="lib"
path="thirdparty/jboss-xml-binding.jar"/>
+ <classpathentry kind="lib" path="thirdparty/jaxws-api.jar"/>
+ <classpathentry kind="lib" path="thirdparty/jsr181-api.jar"/>
<classpathentry kind="output" path="output-eclipse"/>
</classpath>
Modified: projects/wsintegration/jbossws-spi/trunk/build.xml
===================================================================
--- projects/wsintegration/jbossws-spi/trunk/build.xml 2007-05-10 07:18:41 UTC (rev 3035)
+++ projects/wsintegration/jbossws-spi/trunk/build.xml 2007-05-10 07:33:24 UTC (rev 3036)
@@ -87,8 +87,8 @@
<mkdir dir="${spi.output.classes.dir}"/>
<javac srcdir="${spi.java.dir}" sourcepath=""
destdir="${spi.output.classes.dir}" encoding="utf-8"
debug="${javac.debug}" verbose="${javac.verbose}"
deprecation="${javac.deprecation}"
failonerror="${javac.fail.onerror}" source="1.5"
target="1.5">
- <include name="org/jboss/ws/integration/**"/>
- <classpath refid="core.classpath"/>
+ <include name="org/jboss/ws/**"/>
+ <classpath refid="spi.classpath"/>
</javac>
</target>
@@ -115,7 +115,7 @@
<mkdir dir="${spi.output.lib.dir}"/>
<jar jarfile="${spi.output.lib.dir}/jbossws-spi.jar"
manifest="${spi.etc.dir}/default.mf">
<fileset dir="${spi.output.classes.dir}">
- <include name="org/jboss/ws/integration/**"/>
+ <include name="org/jboss/ws/**"/>
</fileset>
</jar>
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/etc/ant-import/build-thirdparty.xml
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/etc/ant-import/build-thirdparty.xml 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/etc/ant-import/build-thirdparty.xml 2007-05-10
07:33:24 UTC (rev 3036)
@@ -17,7 +17,7 @@
<!-- Libraries -->
<!-- ========= -->
- <target name="thirdparty"
depends="thirdparty-get,thirdparty-classpath">
+ <target name="thirdparty"
depends="prepare,thirdparty-get,thirdparty-classpath">
</target>
<target name="thirdparty-get" if="force.thirdparty.get"
@@ -37,17 +37,21 @@
<get
src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-deployers-src.zip"
dest="${thirdparty.dir}/jboss-deployers-src.zip" usetimestamp="true"
verbose="true"/>
<get
src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-microcontainer.jar"
dest="${thirdparty.dir}/jboss-microcontainer.jar" usetimestamp="true"
verbose="true"/>
<get
src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-microcontainer-src.zip"
dest="${thirdparty.dir}/jboss-microcontainer-src.zip"
usetimestamp="true" verbose="true"/>
+ <get src="${jboss.repository}/sun-jaxws/${sun-jaxws}/lib/jaxws-api.jar"
dest="${thirdparty.dir}/jaxws-api.jar" usetimestamp="true"
verbose="true"/>
+ <get src="${jboss.repository}/sun-jaxws/${sun-jaxws}/lib/jsr181-api.jar"
dest="${thirdparty.dir}/jsr181-api.jar" usetimestamp="true"
verbose="true"/>
</target>
<target name="thirdparty-classpath" >
- <!-- The compile classpath for jbossws core -->
- <path id="core.classpath">
+ <!-- The compile classpath for jbossws spi -->
+ <path id="spi.classpath">
<pathelement location="${thirdparty.dir}/jboss-common-core.jar"/>
<pathelement location="${thirdparty.dir}/jboss-dependency.jar"/>
<pathelement location="${thirdparty.dir}/jboss-logging-spi.jar"/>
<pathelement
location="${thirdparty.dir}/jboss-microcontainer.jar"/>
<pathelement location="${thirdparty.dir}/jboss-xml-binding.jar"/>
+ <pathelement location="${thirdparty.dir}/jaxws-api.jar"/>
+ <pathelement location="${thirdparty.dir}/jsr181-api.jar"/>
</path>
</target>
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/ObjectNameFactory.java
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/ObjectNameFactory.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/ObjectNameFactory.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,72 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration;
-
-import java.util.Hashtable;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-/**
- * A simple factory for creating safe object names.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 08-May-2006
- */
-public class ObjectNameFactory
-{
- public static ObjectName create(String name)
- {
- try
- {
- return new ObjectName(name);
- }
- catch (MalformedObjectNameException e)
- {
- throw new Error("Invalid ObjectName: " + name + "; " + e);
- }
- }
-
- public static ObjectName create(String domain, String key, String value)
- {
- try
- {
- return new ObjectName(domain, key, value);
- }
- catch (MalformedObjectNameException e)
- {
- throw new Error("Invalid ObjectName: " + domain + "," + key
+ "," + value + "; " + e);
- }
- }
-
- public static ObjectName create(String domain, Hashtable table)
- {
- try
- {
- return new ObjectName(domain, table);
- }
- catch (MalformedObjectNameException e)
- {
- throw new Error("Invalid ObjectName: " + domain + "," +
table + "; " + e);
- }
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCClientDeployment.java
(from rev 3022,
trunk/jbossws-core/src/java/org/jboss/ws/core/deployment/JAXRPCClientDeployment.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCClientDeployment.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCClientDeployment.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.integration.deployment;
+
+//$Id$
+
+import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
+
+/**
+ * The container independent deployment info.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class JAXRPCClientDeployment extends UnifiedDeploymentInfo
+{
+
+ public JAXRPCClientDeployment(DeploymentType type)
+ {
+ super(type);
+ }
+}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCDeployment.java
(from rev 3022,
trunk/jbossws-core/src/java/org/jboss/ws/core/deployment/JAXRPCDeployment.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCDeployment.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXRPCDeployment.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,89 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.integration.deployment;
+
+import java.io.InputStream;
+import java.net.URL;
+
+import javax.xml.ws.WebServiceException;
+
+import org.jboss.ws.integration.UnifiedVirtualFile;
+import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
+import org.jboss.ws.metadata.webservices.WebservicesFactory;
+import org.jboss.ws.metadata.webservices.WebservicesMetaData;
+import org.jboss.xb.binding.ObjectModelFactory;
+import org.jboss.xb.binding.Unmarshaller;
+import org.jboss.xb.binding.UnmarshallerFactory;
+
+// $Id$
+
+/**
+ * The container independent deployment info.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class JAXRPCDeployment extends UnifiedDeploymentInfo
+{
+ private WebservicesMetaData wsMetaData;
+
+ public JAXRPCDeployment(DeploymentType type, WebservicesMetaData wsMetaData)
+ {
+ super(type);
+ this.wsMetaData = wsMetaData;
+ }
+
+ public JAXRPCDeployment(DeploymentType type, UnifiedVirtualFile vfWebservices)
+ {
+ super(type);
+
+ try
+ {
+ // Unmarshall webservices.xml
+ URL webservicesURL = vfWebservices.toURL();
+ InputStream is = webservicesURL.openStream();
+ try
+ {
+ Unmarshaller unmarshaller =
UnmarshallerFactory.newInstance().newUnmarshaller();
+ ObjectModelFactory factory = new WebservicesFactory(webservicesURL);
+ wsMetaData = (WebservicesMetaData)unmarshaller.unmarshal(is, factory, null);
+ }
+ finally
+ {
+ is.close();
+ }
+ }
+ catch (RuntimeException rte)
+ {
+ throw rte;
+ }
+ catch (Exception ex)
+ {
+ throw new IllegalStateException(ex);
+ }
+ }
+
+ public WebservicesMetaData getWebservicesMetaData()
+ {
+ return wsMetaData;
+ }
+}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXWSDeployment.java
(from rev 3022,
trunk/jbossws-core/src/java/org/jboss/ws/core/deployment/JAXWSDeployment.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXWSDeployment.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/JAXWSDeployment.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.integration.deployment;
+
+//$Id$
+
+import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
+
+/**
+ * The container independent deployment info.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 29-Jun-2006
+ */
+public class JAXWSDeployment extends UnifiedDeploymentInfo
+{
+ public JAXWSDeployment(DeploymentType type)
+ {
+ super(type);
+ }
+}
Added:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/UnifiedDeploymentInfo.java
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/UnifiedDeploymentInfo.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/UnifiedDeploymentInfo.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,144 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.integration.deployment;
+
+// $Id$
+
+import java.io.IOException;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.management.ObjectName;
+
+import org.jboss.ws.integration.UnifiedVirtualFile;
+import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
+
+/**
+ * The container independent deployment info.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class UnifiedDeploymentInfo
+{
+ public UnifiedDeploymentInfo(DeploymentType type)
+ {
+ this.type = type;
+ }
+
+ /** The type of this deployment */
+ public DeploymentType type;
+ /** Sub deployments have a parent */
+ public UnifiedDeploymentInfo parent;
+ /** The suffix of the deployment url */
+ public String simpleName;
+ /** The URL for this deployment */
+ public URL url;
+ /** The virtual file for the deployment root */
+ public UnifiedVirtualFile vfRoot;
+ /** The string identifing this deployment **/
+ public String name;
+ /** The URL to the expanded webapp **/
+ public URL webappURL;
+ /** We can hold "typed" metadata */
+ public Object metaData;
+ /** The deployment classloader **/
+ public ClassLoader classLoader;
+ /** An optional ObjectName of the deployed object */
+ public ObjectName deployedObject;
+
+ /** An arbitrary map of state associated with the deployment */
+ private Map<Class, Object> attachments = new HashMap<Class, Object>();
+
+ public <T> T getAttachment(Class<T> key)
+ {
+ return (T)attachments.get(key);
+ }
+
+ public <T> T addAttachment(Class<T> key, T value)
+ {
+ return (T)attachments.put(key, value);
+ }
+
+ /** The sortName concatenated with the canonical names of all parents. */
+ public String getCanonicalName()
+ {
+ String name = simpleName;
+ if (parent != null)
+ name = parent.getCanonicalName() + "/" + name;
+ return name;
+ }
+
+ public URL getMetaDataFileURL(String resourcePath) throws IOException
+ {
+ URL resourceURL = null;
+ if (resourcePath != null && resourcePath.length() > 0)
+ {
+ if (resourcePath.startsWith("/"))
+ resourcePath = resourcePath.substring(1);
+
+ try
+ {
+ // assign an absolute URL
+ resourceURL = new URL(resourcePath);
+ }
+ catch (MalformedURLException ex)
+ {
+ // ignore
+ }
+
+ if (resourceURL == null && vfRoot != null)
+ {
+ UnifiedVirtualFile vfResource = vfRoot.findChild(resourcePath);
+ resourceURL = vfResource.toURL();
+ }
+
+ if (resourceURL == null)
+ {
+ String deploymentPath = url.toExternalForm();
+
+ if (deploymentPath.startsWith("jar:") &&
deploymentPath.endsWith("!/") == false)
+ deploymentPath += "!/";
+
+ if (deploymentPath.endsWith("/") == false)
+ deploymentPath += "/";
+
+ // assign a relative URL
+ resourceURL = new URL(deploymentPath + resourcePath);
+ }
+ }
+ return resourceURL;
+ }
+
+ public String toString()
+ {
+ StringBuilder builder = new StringBuilder();
+ builder.append("[");
+ builder.append("type=" + type);
+ builder.append(",simpleName=" + simpleName);
+ builder.append(",url=" + url);
+ builder.append("]");
+ return builder.toString();
+ }
+}
Property changes on:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/deployment/UnifiedDeploymentInfo.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/management/BasicServerConfig.java
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/management/BasicServerConfig.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/management/BasicServerConfig.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -36,7 +36,7 @@
import javax.management.ObjectName;
import org.jboss.logging.Logger;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* JBoss specific implementation of a ServerConfig
Copied: projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee
(from rev 3022, trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee)
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,129 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
-
-//$Id$
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-/**
- * The container independent top level meta data from the jboss.xml and ejb-jar.xml
descriptor.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class UnifiedApplicationMetaData
-{
- /** ArrayList<BeanMetaData> for the ejbs */
- private List<UnifiedBeanMetaData> beans = new
ArrayList<UnifiedBeanMetaData>();
- /** The optional JBossWS config-name */
- private String configName;
- /** The optional JBossWS config-file */
- private String configFile;
- /** The web context root to use for web services */
- private String webServiceContextRoot;
- /** The security-domain value assigned to the application */
- private String securityDomain;
- /** A HashMap<String, String> for webservice description publish locations */
- private PublishLocationAdapter publishLocationAdapter;
-
- public UnifiedBeanMetaData getBeanByEjbName(String ejbName)
- {
- for (UnifiedBeanMetaData beanMetaData : beans)
- {
- if (beanMetaData.getEjbName().equals(ejbName))
- {
- return beanMetaData;
- }
- }
- return null;
- }
-
- public Iterator<UnifiedBeanMetaData> getEnterpriseBeans()
- {
- return beans.iterator();
- }
-
- public void setEnterpriseBeans(List<UnifiedBeanMetaData> beans)
- {
- this.beans = beans;
- }
-
- public String getConfigName()
- {
- return configName;
- }
-
- public void setConfigName(String configName)
- {
- this.configName = configName;
- }
-
- public String getConfigFile()
- {
- return configFile;
- }
-
- public void setConfigFile(String configFile)
- {
- this.configFile = configFile;
- }
-
- public String getWebServiceContextRoot()
- {
- return webServiceContextRoot;
- }
-
- public void setWebServiceContextRoot(String contextRoot)
- {
- this.webServiceContextRoot = contextRoot;
- }
-
- public String getSecurityDomain()
- {
- return securityDomain;
- }
-
- public void setSecurityDomain(String securityDomain)
- {
- this.securityDomain = securityDomain;
- }
-
- public void setPublishLocationAdapter(PublishLocationAdapter publishLocationAdapter)
- {
- this.publishLocationAdapter = publishLocationAdapter;
- }
-
- public String getWsdlPublishLocationByName(String name)
- {
- String publishLocation = (publishLocationAdapter != null ?
publishLocationAdapter.getWsdlPublishLocationByName(name) : null);
- return publishLocation;
-
- }
-
- public interface PublishLocationAdapter
- {
- String getWsdlPublishLocationByName(String name);
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedApplicationMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,129 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
+
+//$Id$
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+/**
+ * The container independent top level meta data from the jboss.xml and ejb-jar.xml
descriptor.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class UnifiedApplicationMetaData
+{
+ /** ArrayList<BeanMetaData> for the ejbs */
+ private List<UnifiedBeanMetaData> beans = new
ArrayList<UnifiedBeanMetaData>();
+ /** The optional JBossWS config-name */
+ private String configName;
+ /** The optional JBossWS config-file */
+ private String configFile;
+ /** The web context root to use for web services */
+ private String webServiceContextRoot;
+ /** The security-domain value assigned to the application */
+ private String securityDomain;
+ /** A HashMap<String, String> for webservice description publish locations */
+ private PublishLocationAdapter publishLocationAdapter;
+
+ public UnifiedBeanMetaData getBeanByEjbName(String ejbName)
+ {
+ for (UnifiedBeanMetaData beanMetaData : beans)
+ {
+ if (beanMetaData.getEjbName().equals(ejbName))
+ {
+ return beanMetaData;
+ }
+ }
+ return null;
+ }
+
+ public Iterator<UnifiedBeanMetaData> getEnterpriseBeans()
+ {
+ return beans.iterator();
+ }
+
+ public void setEnterpriseBeans(List<UnifiedBeanMetaData> beans)
+ {
+ this.beans = beans;
+ }
+
+ public String getConfigName()
+ {
+ return configName;
+ }
+
+ public void setConfigName(String configName)
+ {
+ this.configName = configName;
+ }
+
+ public String getConfigFile()
+ {
+ return configFile;
+ }
+
+ public void setConfigFile(String configFile)
+ {
+ this.configFile = configFile;
+ }
+
+ public String getWebServiceContextRoot()
+ {
+ return webServiceContextRoot;
+ }
+
+ public void setWebServiceContextRoot(String contextRoot)
+ {
+ this.webServiceContextRoot = contextRoot;
+ }
+
+ public String getSecurityDomain()
+ {
+ return securityDomain;
+ }
+
+ public void setSecurityDomain(String securityDomain)
+ {
+ this.securityDomain = securityDomain;
+ }
+
+ public void setPublishLocationAdapter(PublishLocationAdapter publishLocationAdapter)
+ {
+ this.publishLocationAdapter = publishLocationAdapter;
+ }
+
+ public String getWsdlPublishLocationByName(String name)
+ {
+ String publishLocation = (publishLocationAdapter != null ?
publishLocationAdapter.getWsdlPublishLocationByName(name) : null);
+ return publishLocation;
+
+ }
+
+ public interface PublishLocationAdapter
+ {
+ String getWsdlPublishLocationByName(String name);
+ }
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,138 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
-
-//$Id$
-
-/**
- * The container independent common meta data class for the entity, message-driven and
session beans.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class UnifiedBeanMetaData
-{
- /** The ejb-name element specifies an enterprise bean's name. */
- private String ejbName;
- /** The ejb-class element contains the fully-qualified name of the enterprise
bean's class. */
- private String ejbClass;
- /** The home element contains the fully-qualified name of the enterprise
- bean's home interface. */
- private String homeClass;
- /** The local-home element contains the fully-qualified name of the
- enterprise bean's local home interface. */
- private String localHomeClass;
- /** The service-endpoint element contains the fully-qualified name of the beans
service endpoint interface (SEI) */
- protected String seiName;
- /** The JNDI name under with the home interface should be bound */
- private String jndiName;
- /** The JNDI name under with the local home interface should be bound */
- private String localJndiName;
- /** The jboss port-component binding for a ejb webservice */
- protected UnifiedEjbPortComponentMetaData portComponent;
-
- public String getEjbName()
- {
- return ejbName;
- }
-
- public void setEjbName(String ejbName)
- {
- this.ejbName = ejbName;
- }
-
- public String getEjbClass()
- {
- return ejbClass;
- }
-
- public void setEjbClass(String ejbClass)
- {
- this.ejbClass = ejbClass;
- }
-
- public UnifiedEjbPortComponentMetaData getPortComponent()
- {
- return portComponent;
- }
-
- public void setPortComponent(UnifiedEjbPortComponentMetaData portComponent)
- {
- this.portComponent = portComponent;
- }
-
- public String getServiceEndpointInterface()
- {
- return seiName;
- }
-
- public void setServiceEndpointInterface(String seiName)
- {
- this.seiName = seiName;
- }
-
- public String getContainerObjectNameJndiName()
- {
- return getHome() != null ? getJndiName() : getLocalJndiName();
- }
-
- public String getHome()
- {
- return homeClass;
- }
-
- public void setHome(String homeClass)
- {
- this.homeClass = homeClass;
- }
-
- public String getJndiName()
- {
- return jndiName;
- }
-
- public void setJndiName(String jndiName)
- {
- this.jndiName = jndiName;
- }
-
- public String getLocalHome()
- {
- return localHomeClass;
- }
-
- public void setLocalHome(String localHomeClass)
- {
- this.localHomeClass = localHomeClass;
- }
-
- public String getLocalJndiName()
- {
- return localJndiName;
- }
-
- public void setLocalJndiName(String localJndiName)
- {
- this.localJndiName = localJndiName;
- }
-
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,138 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
+
+//$Id$
+
+/**
+ * The container independent common meta data class for the entity, message-driven and
session beans.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class UnifiedBeanMetaData
+{
+ /** The ejb-name element specifies an enterprise bean's name. */
+ private String ejbName;
+ /** The ejb-class element contains the fully-qualified name of the enterprise
bean's class. */
+ private String ejbClass;
+ /** The home element contains the fully-qualified name of the enterprise
+ bean's home interface. */
+ private String homeClass;
+ /** The local-home element contains the fully-qualified name of the
+ enterprise bean's local home interface. */
+ private String localHomeClass;
+ /** The service-endpoint element contains the fully-qualified name of the beans
service endpoint interface (SEI) */
+ protected String seiName;
+ /** The JNDI name under with the home interface should be bound */
+ private String jndiName;
+ /** The JNDI name under with the local home interface should be bound */
+ private String localJndiName;
+ /** The jboss port-component binding for a ejb webservice */
+ protected UnifiedEjbPortComponentMetaData portComponent;
+
+ public String getEjbName()
+ {
+ return ejbName;
+ }
+
+ public void setEjbName(String ejbName)
+ {
+ this.ejbName = ejbName;
+ }
+
+ public String getEjbClass()
+ {
+ return ejbClass;
+ }
+
+ public void setEjbClass(String ejbClass)
+ {
+ this.ejbClass = ejbClass;
+ }
+
+ public UnifiedEjbPortComponentMetaData getPortComponent()
+ {
+ return portComponent;
+ }
+
+ public void setPortComponent(UnifiedEjbPortComponentMetaData portComponent)
+ {
+ this.portComponent = portComponent;
+ }
+
+ public String getServiceEndpointInterface()
+ {
+ return seiName;
+ }
+
+ public void setServiceEndpointInterface(String seiName)
+ {
+ this.seiName = seiName;
+ }
+
+ public String getContainerObjectNameJndiName()
+ {
+ return getHome() != null ? getJndiName() : getLocalJndiName();
+ }
+
+ public String getHome()
+ {
+ return homeClass;
+ }
+
+ public void setHome(String homeClass)
+ {
+ this.homeClass = homeClass;
+ }
+
+ public String getJndiName()
+ {
+ return jndiName;
+ }
+
+ public void setJndiName(String jndiName)
+ {
+ this.jndiName = jndiName;
+ }
+
+ public String getLocalHome()
+ {
+ return localHomeClass;
+ }
+
+ public void setLocalHome(String localHomeClass)
+ {
+ this.localHomeClass = localHomeClass;
+ }
+
+ public String getLocalJndiName()
+ {
+ return localJndiName;
+ }
+
+ public void setLocalJndiName(String localJndiName)
+ {
+ this.localJndiName = localJndiName;
+ }
+
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,101 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
-
-
-//$Id$
-
-
-/**
- * The container independent metadata for session/port-component element from jboss.xml
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class UnifiedEjbPortComponentMetaData
-{
- private String portComponentName;
- private String portComponentURI;
- private String authMethod;
- private String transportGuarantee;
- private Boolean secureWSDLAccess;
-
- public String getPortComponentName()
- {
- return portComponentName;
- }
-
- public void setPortComponentName(String portComponentName)
- {
- this.portComponentName = portComponentName;
- }
-
- public String getPortComponentURI()
- {
- return portComponentURI;
- }
-
- public void setPortComponentURI(String portComponentURI)
- {
- this.portComponentURI = portComponentURI;
- }
-
- public String getURLPattern()
- {
- String pattern = "/*";
- if (portComponentURI != null)
- {
- return portComponentURI;
- }
- return pattern;
- }
-
- public String getAuthMethod()
- {
- return authMethod;
- }
-
- public void setAuthMethod(String authMethod)
- {
- this.authMethod = authMethod;
- }
-
- public String getTransportGuarantee()
- {
- return transportGuarantee;
- }
-
- public void setTransportGuarantee(String transportGuarantee)
- {
- this.transportGuarantee = transportGuarantee;
- }
-
- public Boolean getSecureWSDLAccess()
- {
- return secureWSDLAccess;
- }
-
- public void setSecureWSDLAccess(Boolean secureWSDLAccess)
- {
- this.secureWSDLAccess = secureWSDLAccess;
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedEjbPortComponentMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,101 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
+
+
+//$Id$
+
+
+/**
+ * The container independent metadata for session/port-component element from jboss.xml
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class UnifiedEjbPortComponentMetaData
+{
+ private String portComponentName;
+ private String portComponentURI;
+ private String authMethod;
+ private String transportGuarantee;
+ private Boolean secureWSDLAccess;
+
+ public String getPortComponentName()
+ {
+ return portComponentName;
+ }
+
+ public void setPortComponentName(String portComponentName)
+ {
+ this.portComponentName = portComponentName;
+ }
+
+ public String getPortComponentURI()
+ {
+ return portComponentURI;
+ }
+
+ public void setPortComponentURI(String portComponentURI)
+ {
+ this.portComponentURI = portComponentURI;
+ }
+
+ public String getURLPattern()
+ {
+ String pattern = "/*";
+ if (portComponentURI != null)
+ {
+ return portComponentURI;
+ }
+ return pattern;
+ }
+
+ public String getAuthMethod()
+ {
+ return authMethod;
+ }
+
+ public void setAuthMethod(String authMethod)
+ {
+ this.authMethod = authMethod;
+ }
+
+ public String getTransportGuarantee()
+ {
+ return transportGuarantee;
+ }
+
+ public void setTransportGuarantee(String transportGuarantee)
+ {
+ this.transportGuarantee = transportGuarantee;
+ }
+
+ public Boolean getSecureWSDLAccess()
+ {
+ return secureWSDLAccess;
+ }
+
+ public void setSecureWSDLAccess(Boolean secureWSDLAccess)
+ {
+ this.secureWSDLAccess = secureWSDLAccess;
+ }
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,47 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
-
-
-// $Id$
-
-
-/**
- * The container independent metadata of a message driven bean.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class UnifiedMessageDrivenMetaData extends UnifiedBeanMetaData
-{
- private String destinationJndiName;
-
- public String getDestinationJndiName()
- {
- return destinationJndiName;
- }
-
- public void setDestinationJndiName(String destinationJndiName)
- {
- this.destinationJndiName = destinationJndiName;
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedMessageDrivenMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,47 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
+
+
+// $Id$
+
+
+/**
+ * The container independent metadata of a message driven bean.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class UnifiedMessageDrivenMetaData extends UnifiedBeanMetaData
+{
+ private String destinationJndiName;
+
+ public String getDestinationJndiName()
+ {
+ return destinationJndiName;
+ }
+
+ public void setDestinationJndiName(String destinationJndiName)
+ {
+ this.destinationJndiName = destinationJndiName;
+ }
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,37 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
-
-
-// $Id$
-
-
-/**
- * The container independent metadata of a message driven bean.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class UnifiedSessionMetaData extends UnifiedBeanMetaData
-{
-
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedSessionMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
+
+
+// $Id$
+
+
+/**
+ * The container independent metadata of a message driven bean.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class UnifiedSessionMetaData extends UnifiedBeanMetaData
+{
+
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,143 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
-
-//$Id$
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-/**
- * The container independent representation of the web.xml and jboss-web.xml deployment
descriptors
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class UnifiedWebMetaData
-{
- /** The war context root as specified at the jboss-web.xml descriptor level. */
- private String contextRoot;
- /** The servlet-mapping <servlet-name, url-pattern> */
- private Map<String, String> servletMappings = new HashMap<String,
String>();
- /** The servlet <servlet-name, servlet-class> */
- private Map<String, String> servletClassNames = new HashMap<String,
String>();
- /** The optional JBossWS config-name */
- private String configName;
- /** The optional JBossWS config-file */
- private String configFile;
- /** The security-domain value assigned to the application */
- private String securityDomain;
- /** A HashMap<String, String> for webservice description publish locations */
- private PublishLocationAdapter publishLocationAdapter;
- /** web.xml security-constraints */
- private List<UnifiedWebSecurityMetaData> securityMetaData;
-
- public String getContextRoot()
- {
- return contextRoot;
- }
-
- public void setContextRoot(String contextRoot)
- {
- this.contextRoot = contextRoot;
- }
-
- public Map<String, String> getServletMappings()
- {
- return servletMappings;
- }
-
- public void setServletMappings(Map<String, String> servletMappings)
- {
- this.servletMappings = servletMappings;
- }
-
- public Map<String, String> getServletClassNames()
- {
- return servletClassNames;
- }
-
- public void setServletClassNames(Map<String, String> servletClassNames)
- {
- this.servletClassNames = servletClassNames;
- }
-
- public String getConfigName()
- {
- return configName;
- }
-
- public void setConfigName(String configName)
- {
- this.configName = configName;
- }
-
- public String getConfigFile()
- {
- return configFile;
- }
-
- public void setConfigFile(String configFile)
- {
- this.configFile = configFile;
- }
-
- public String getSecurityDomain()
- {
- return securityDomain;
- }
-
- public void setSecurityDomain(String securityDomain)
- {
- this.securityDomain = securityDomain;
- }
-
- public List<UnifiedWebSecurityMetaData> getSecurityMetaData()
- {
- return securityMetaData;
- }
-
- public void setSecurityMetaData(List<UnifiedWebSecurityMetaData>
securityMetaData)
- {
- this.securityMetaData = securityMetaData;
- }
-
- public void setPublishLocationAdapter(PublishLocationAdapter publishLocationAdapter)
- {
- this.publishLocationAdapter = publishLocationAdapter;
- }
-
- public String getWsdlPublishLocationByName(String name)
- {
- String publishLocation = null;
- if (publishLocationAdapter != null)
- publishLocation = publishLocationAdapter.getWsdlPublishLocationByName(name);
- return publishLocation;
-
- }
-
- public interface PublishLocationAdapter
- {
- String getWsdlPublishLocationByName(String name);
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,143 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
+
+//$Id$
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * The container independent representation of the web.xml and jboss-web.xml deployment
descriptors
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 05-May-2006
+ */
+public class UnifiedWebMetaData
+{
+ /** The war context root as specified at the jboss-web.xml descriptor level. */
+ private String contextRoot;
+ /** The servlet-mapping <servlet-name, url-pattern> */
+ private Map<String, String> servletMappings = new HashMap<String,
String>();
+ /** The servlet <servlet-name, servlet-class> */
+ private Map<String, String> servletClassNames = new HashMap<String,
String>();
+ /** The optional JBossWS config-name */
+ private String configName;
+ /** The optional JBossWS config-file */
+ private String configFile;
+ /** The security-domain value assigned to the application */
+ private String securityDomain;
+ /** A HashMap<String, String> for webservice description publish locations */
+ private PublishLocationAdapter publishLocationAdapter;
+ /** web.xml security-constraints */
+ private List<UnifiedWebSecurityMetaData> securityMetaData;
+
+ public String getContextRoot()
+ {
+ return contextRoot;
+ }
+
+ public void setContextRoot(String contextRoot)
+ {
+ this.contextRoot = contextRoot;
+ }
+
+ public Map<String, String> getServletMappings()
+ {
+ return servletMappings;
+ }
+
+ public void setServletMappings(Map<String, String> servletMappings)
+ {
+ this.servletMappings = servletMappings;
+ }
+
+ public Map<String, String> getServletClassNames()
+ {
+ return servletClassNames;
+ }
+
+ public void setServletClassNames(Map<String, String> servletClassNames)
+ {
+ this.servletClassNames = servletClassNames;
+ }
+
+ public String getConfigName()
+ {
+ return configName;
+ }
+
+ public void setConfigName(String configName)
+ {
+ this.configName = configName;
+ }
+
+ public String getConfigFile()
+ {
+ return configFile;
+ }
+
+ public void setConfigFile(String configFile)
+ {
+ this.configFile = configFile;
+ }
+
+ public String getSecurityDomain()
+ {
+ return securityDomain;
+ }
+
+ public void setSecurityDomain(String securityDomain)
+ {
+ this.securityDomain = securityDomain;
+ }
+
+ public List<UnifiedWebSecurityMetaData> getSecurityMetaData()
+ {
+ return securityMetaData;
+ }
+
+ public void setSecurityMetaData(List<UnifiedWebSecurityMetaData>
securityMetaData)
+ {
+ this.securityMetaData = securityMetaData;
+ }
+
+ public void setPublishLocationAdapter(PublishLocationAdapter publishLocationAdapter)
+ {
+ this.publishLocationAdapter = publishLocationAdapter;
+ }
+
+ public String getWsdlPublishLocationByName(String name)
+ {
+ String publishLocation = null;
+ if (publishLocationAdapter != null)
+ publishLocation = publishLocationAdapter.getWsdlPublishLocationByName(name);
+ return publishLocation;
+
+ }
+
+ public interface PublishLocationAdapter
+ {
+ String getWsdlPublishLocationByName(String name);
+ }
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,95 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
-
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.HashSet;
-
-/**
- *
- * @author darran.lofthouse(a)jboss.com
- * @since Oct 22, 2006
- */
-public class UnifiedWebSecurityMetaData
-{
-
- /** The optional security-constraint/user-data-constraint/transport-guarantee */
- private String transportGuarantee;
-
- /**
- * The HashMap for the security-constraint/web-resource-collection
- * elements.
- */
- private HashMap<String, UnifiedWebResourceCollection> webResources = new
HashMap<String, UnifiedWebResourceCollection>();
-
- public UnifiedWebResourceCollection addWebResource(final String name)
- {
- UnifiedWebResourceCollection wrc = new UnifiedWebResourceCollection(name);
- webResources.put(name, wrc);
-
- return wrc;
- }
-
- public Collection<UnifiedWebResourceCollection> getWebResources()
- {
- return webResources.values();
- }
-
- public String getTransportGuarantee()
- {
- return transportGuarantee;
- }
-
- public void setTransportGuarantee(String transportGuarantee)
- {
- this.transportGuarantee = transportGuarantee;
- }
-
- public static class UnifiedWebResourceCollection
- {
- private String name;
- /** The required url-pattern element(s) */
- private HashSet<String> urlPatterns = new HashSet<String>();
-
- public UnifiedWebResourceCollection(final String name)
- {
- this.name = name;
- }
-
- public String getName()
- {
- return name;
- }
-
- public void addPattern(String pattern)
- {
- urlPatterns.add(pattern);
- }
-
- public HashSet<String> getUrlPatterns()
- {
- return urlPatterns;
- }
- }
-
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedWebSecurityMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,95 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.j2ee;
+
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.HashSet;
+
+/**
+ *
+ * @author darran.lofthouse(a)jboss.com
+ * @since Oct 22, 2006
+ */
+public class UnifiedWebSecurityMetaData
+{
+
+ /** The optional security-constraint/user-data-constraint/transport-guarantee */
+ private String transportGuarantee;
+
+ /**
+ * The HashMap for the security-constraint/web-resource-collection
+ * elements.
+ */
+ private HashMap<String, UnifiedWebResourceCollection> webResources = new
HashMap<String, UnifiedWebResourceCollection>();
+
+ public UnifiedWebResourceCollection addWebResource(final String name)
+ {
+ UnifiedWebResourceCollection wrc = new UnifiedWebResourceCollection(name);
+ webResources.put(name, wrc);
+
+ return wrc;
+ }
+
+ public Collection<UnifiedWebResourceCollection> getWebResources()
+ {
+ return webResources.values();
+ }
+
+ public String getTransportGuarantee()
+ {
+ return transportGuarantee;
+ }
+
+ public void setTransportGuarantee(String transportGuarantee)
+ {
+ this.transportGuarantee = transportGuarantee;
+ }
+
+ public static class UnifiedWebResourceCollection
+ {
+ private String name;
+ /** The required url-pattern element(s) */
+ private HashSet<String> urlPatterns = new HashSet<String>();
+
+ public UnifiedWebResourceCollection(final String name)
+ {
+ this.name = name;
+ }
+
+ public String getName()
+ {
+ return name;
+ }
+
+ public void addPattern(String pattern)
+ {
+ urlPatterns.add(pattern);
+ }
+
+ public HashSet<String> getUrlPatterns()
+ {
+ return urlPatterns;
+ }
+ }
+
+}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref
(from rev 3033, trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref)
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsObjectFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsObjectFactory.java 2007-05-10
03:28:26 UTC (rev 3033)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsObjectFactory.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -24,7 +24,7 @@
// $Id$
import org.jboss.logging.Logger;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData.HandlerType;
import org.jboss.xb.binding.ObjectModelFactory;
import org.jboss.xb.binding.UnmarshallingContext;
import org.xml.sax.Attributes;
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaDataParser.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaDataParser.java 2007-05-10
03:28:26 UTC (rev 3033)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaDataParser.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -28,7 +28,7 @@
import javax.xml.namespace.QName;
import org.jboss.logging.Logger;
-import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.utils.DOMUtils;
import org.jboss.xb.QNameBuilder;
import org.w3c.dom.Element;
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java 2007-05-10
03:28:26 UTC (rev 3033)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -29,7 +29,6 @@
import javax.xml.namespace.QName;
import javax.xml.ws.handler.PortInfo;
-import org.jboss.ws.core.jaxws.handler.PortInfoImpl;
import org.jboss.ws.integration.ServiceRefElement;
/** The unified metdata data for a handler chain element
@@ -39,13 +38,13 @@
public class UnifiedHandlerChainMetaData extends ServiceRefElement
{
private UnifiedHandlerChainsMetaData handlerChains;
-
+
private QName serviceNamePattern;
private QName portNamePattern;
private String protocolBindings;
private List<UnifiedHandlerMetaData> handlers = new
ArrayList<UnifiedHandlerMetaData>();
private PortInfo portInfo;
-
+
public UnifiedHandlerChainMetaData(UnifiedHandlerChainsMetaData handlerChains)
{
this.handlerChains = handlerChains;
@@ -79,27 +78,19 @@
{
return protocolBindings;
}
-
+
public void setProtocolBindings(String protocolBindings)
{
this.protocolBindings = protocolBindings;
}
-
+
public List<UnifiedHandlerMetaData> getHandlers()
{
return handlers;
}
-
+
public void addHandler(UnifiedHandlerMetaData handler)
{
handlers.add(handler);
}
-
- public PortInfo getPortInfo()
- {
- if (portInfo == null)
- portInfo = new PortInfoImpl(serviceNamePattern, portNamePattern,
protocolBindings);
-
- return portInfo;
- }
}
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java 2007-05-10
03:28:26 UTC (rev 3033)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -27,7 +27,7 @@
import java.util.List;
import org.jboss.ws.integration.ServiceRefElement;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData.HandlerType;
/** The unified metdata data for a handler chains element
*
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java 2007-05-10
03:28:26 UTC (rev 3033)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -31,9 +31,6 @@
import javax.xml.namespace.QName;
import org.jboss.ws.integration.ServiceRefElement;
-import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
-import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXWS;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
import org.w3c.dom.Element;
/** The unified metdata data for a handler element
@@ -43,6 +40,11 @@
*/
public class UnifiedHandlerMetaData extends ServiceRefElement
{
+ public enum HandlerType
+ {
+ PRE, ENDPOINT, POST, ALL
+ }
+
private UnifiedHandlerChainMetaData handlerChain;
// The required <handler-name> element
@@ -67,6 +69,11 @@
{
}
+ public UnifiedHandlerChainMetaData getHandlerChain()
+ {
+ return handlerChain;
+ }
+
public void setHandlerName(String value)
{
this.handlerName = value;
@@ -127,38 +134,11 @@
portNames.add(value);
}
- public HandlerMetaDataJAXRPC getHandlerMetaDataJAXRPC(HandlerType type)
- {
- HandlerMetaDataJAXRPC hmd = new HandlerMetaDataJAXRPC(type);
- hmd.setHandlerName(getHandlerName());
- hmd.setHandlerClassName(getHandlerClass());
- hmd.seiInitParams(getInitParams());
- hmd.setSoapHeaders(getSoapHeaders());
- hmd.setSoapRoles(getSoapRoles());
- hmd.setPortNames(getPortNames());
- return hmd;
- }
-
- public HandlerMetaDataJAXWS getHandlerMetaDataJAXWS(HandlerType type)
- {
- HandlerMetaDataJAXWS hmd = new HandlerMetaDataJAXWS(type);
- hmd.setHandlerName(getHandlerName());
- hmd.setHandlerClassName(getHandlerClass());
- hmd.seiInitParams(getInitParams());
- if (handlerChain != null)
- {
- hmd.setProtocolBindings(handlerChain.getProtocolBindings());
- hmd.setServiceNamePattern(handlerChain.getServiceNamePattern());
- hmd.setPortNamePattern(handlerChain.getPortNamePattern());
- }
- return hmd;
- }
-
public void importStandardXml(Element root)
{
new ServiceRefMetaDataParser().importStandardXml(root, this);
}
-
+
public String toString()
{
StringBuilder str = new StringBuilder();
Modified:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java 2007-05-10
03:28:26 UTC (rev 3033)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -30,9 +30,9 @@
import java.util.List;
import javax.xml.namespace.QName;
+import javax.xml.ws.WebServiceException;
import org.jboss.logging.Logger;
-import org.jboss.ws.WSException;
import org.jboss.ws.integration.ServiceRefMetaData;
import org.jboss.ws.integration.UnifiedVirtualFile;
import org.w3c.dom.Element;
@@ -175,7 +175,7 @@
}
catch (Exception e)
{
- throw new WSException("Cannot find jaxrcp-mapping-file: " +
mappingFile, e);
+ throw new WebServiceException("Cannot find jaxrcp-mapping-file: " +
mappingFile, e);
}
}
return mappingURL;
@@ -284,7 +284,7 @@
}
catch (Exception e)
{
- throw new WSException("Cannot find wsdl-override: " +
wsdlOverride, e);
+ throw new WebServiceException("Cannot find wsdl-override: " +
wsdlOverride, e);
}
}
}
@@ -297,7 +297,7 @@
}
catch (Exception e)
{
- throw new WSException("Cannot find wsdl-file: " + wsdlFile, e);
+ throw new WebServiceException("Cannot find wsdl-file: " + wsdlFile,
e);
}
}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices
(from rev 3022, trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices)
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,242 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.
- */
-// $Id$
-package org.jboss.ws.metadata.webservices;
-
-// $Id$
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
-
-/**
- * XML Binding and ws4ee meta-data element for
- * <code>webservices/webservice-description/port-component</code>
- * <p/>
- * A port component is the equivalent of an ordinary Axis service (and
- * as such it constitutes the building blocks for jaxrpc services).
- * <p/>
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 15-April-2004
- */
-public class PortComponentMetaData
-{
- /**
- * The index of the webservice-description in webservices.xml
- */
- public static final String PARAMETER_WEBSERVICE_ID = "webserviceID";
-
- // provide logging
- private static final Logger log = Logger.getLogger(PortComponentMetaData.class);
-
- // The parent <webservice-description> element
- private WebserviceDescriptionMetaData webserviceDescription;
-
- /** The required <port-component-name> element
- * This name bears no relationship to the WSDL port name.
- * This name must be unique amongst all port component names in a module.
- */
- private String portComponentName;
- // The required <wsdl-port> element
- private QName wsdlPort;
- // The required <service-endpoint-interface> element
- private String serviceEndpointInterface;
- // The required <ejb-link> or <servlet-link> in the
<service-impl-bean> element
- private String ejbLink;
- private String servletLink;
- // The optional <handler> elements
- private List<UnifiedHandlerMetaData> handlers = new
ArrayList<UnifiedHandlerMetaData>();
-
- // The HTTP context root
- private String contextRoot;
- // The optional secure wsdl access
- private Boolean secureWSDLAccess;
-
- // -----------------------------------------
- // JAX-WS additions
-
- private boolean enableMtom;
- private QName wsdlService;
- private String protocolBinding;
- private UnifiedHandlerChainsMetaData handlerChains;
-
-
- /** Construct a new PortComponentMetaData for a given WebserviceDescriptionMetaData
- */
- public PortComponentMetaData(WebserviceDescriptionMetaData webserviceDescription)
- {
- this.webserviceDescription = webserviceDescription;
- }
-
- public WebserviceDescriptionMetaData getWebserviceDescription()
- {
- return webserviceDescription;
- }
-
- public String getPortComponentName()
- {
- return portComponentName;
- }
-
- public void setPortComponentName(String portComponentName)
- {
- this.portComponentName = portComponentName;
- }
-
- public QName getWsdlPort()
- {
- return wsdlPort;
- }
-
- public void setWsdlPort(QName wsdlPort)
- {
- if (wsdlPort.getNamespaceURI().length() == 0)
- log.warn("<wsdl-port> element in webservices.xml not namespace
qualified: " + wsdlPort);
-
- this.wsdlPort = wsdlPort;
- }
-
- public String getEjbLink()
- {
- return ejbLink;
- }
-
- public void setEjbLink(String ejbLink)
- {
- this.ejbLink = ejbLink;
- }
-
- public String getServletLink()
- {
- return servletLink;
- }
-
- public void setServletLink(String servletLink)
- {
- this.servletLink = servletLink;
- }
-
- public String getServiceEndpointInterface()
- {
- return serviceEndpointInterface;
- }
-
- public void setServiceEndpointInterface(String serviceEndpointInterface)
- {
- this.serviceEndpointInterface = serviceEndpointInterface;
- }
-
- public void addHandler(UnifiedHandlerMetaData handler)
- {
- handlers.add(handler);
- }
-
- public UnifiedHandlerMetaData[] getHandlers()
- {
- UnifiedHandlerMetaData[] array = new UnifiedHandlerMetaData[handlers.size()];
- handlers.toArray(array);
- return array;
- }
-
- public String getContextRoot()
- {
- return contextRoot;
- }
-
- public void setContextRoot(String contextRoot)
- {
- this.contextRoot = contextRoot;
- }
-
- public Boolean getSecureWSDLAccess()
- {
- return secureWSDLAccess;
- }
-
- public void setSecureWSDLAccess(Boolean secureWSDLAccess)
- {
- this.secureWSDLAccess = secureWSDLAccess;
- }
-
- public boolean isEnableMtom()
- {
- return enableMtom;
- }
-
- public void setEnableMtom(boolean enableMtom)
- {
- this.enableMtom = enableMtom;
- }
-
- public QName getWsdlService()
- {
- return wsdlService;
- }
-
- public void setWsdlService(QName wsdlService)
- {
- this.wsdlService = wsdlService;
- }
-
- public String getProtocolBinding()
- {
- return protocolBinding;
- }
-
- public void setProtocolBinding(String protocolBinding)
- {
- this.protocolBinding = protocolBinding;
- }
-
- public UnifiedHandlerChainsMetaData getHandlerChains()
- {
- return handlerChains;
- }
-
- public void setHandlerChains(UnifiedHandlerChainsMetaData handlerChains)
- {
- this.handlerChains = handlerChains;
- }
-
- public String serialize()
- {
- StringBuilder builder = new StringBuilder("<port-component>");
-
builder.append("<port-component-name>").append(portComponentName).append("</port-component-name>");
- builder.append("<wsdl-port
xmlns:").append(wsdlPort.getPrefix()).append("='").append(wsdlPort.getNamespaceURI()).append("'>");
-
builder.append(wsdlPort.getPrefix()).append(':').append(wsdlPort.getLocalPart()).append("</wsdl-port>");
-
builder.append("<service-endpoint-interface>").append(serviceEndpointInterface).append("</service-endpoint-interface>");
- builder.append("<service-impl-bean>");
- if (ejbLink != null)
- builder.append("<ejb-link>" + ejbLink +
"</ejb-link>");
- else
- builder.append("<servlet-link>"+ servletLink +
"</servlet-link>");
- builder.append("</service-impl-bean>");
- builder.append("</port-component>");
- return builder.toString();
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/PortComponentMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,242 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.
+ */
+// $Id$
+package org.jboss.ws.metadata.webservices;
+
+// $Id$
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.xml.namespace.QName;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
+
+/**
+ * XML Binding and ws4ee meta-data element for
+ * <code>webservices/webservice-description/port-component</code>
+ * <p/>
+ * A port component is the equivalent of an ordinary Axis service (and
+ * as such it constitutes the building blocks for jaxrpc services).
+ * <p/>
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 15-April-2004
+ */
+public class PortComponentMetaData
+{
+ /**
+ * The index of the webservice-description in webservices.xml
+ */
+ public static final String PARAMETER_WEBSERVICE_ID = "webserviceID";
+
+ // provide logging
+ private static final Logger log = Logger.getLogger(PortComponentMetaData.class);
+
+ // The parent <webservice-description> element
+ private WebserviceDescriptionMetaData webserviceDescription;
+
+ /** The required <port-component-name> element
+ * This name bears no relationship to the WSDL port name.
+ * This name must be unique amongst all port component names in a module.
+ */
+ private String portComponentName;
+ // The required <wsdl-port> element
+ private QName wsdlPort;
+ // The required <service-endpoint-interface> element
+ private String serviceEndpointInterface;
+ // The required <ejb-link> or <servlet-link> in the
<service-impl-bean> element
+ private String ejbLink;
+ private String servletLink;
+ // The optional <handler> elements
+ private List<UnifiedHandlerMetaData> handlers = new
ArrayList<UnifiedHandlerMetaData>();
+
+ // The HTTP context root
+ private String contextRoot;
+ // The optional secure wsdl access
+ private Boolean secureWSDLAccess;
+
+ // -----------------------------------------
+ // JAX-WS additions
+
+ private boolean enableMtom;
+ private QName wsdlService;
+ private String protocolBinding;
+ private UnifiedHandlerChainsMetaData handlerChains;
+
+
+ /** Construct a new PortComponentMetaData for a given WebserviceDescriptionMetaData
+ */
+ public PortComponentMetaData(WebserviceDescriptionMetaData webserviceDescription)
+ {
+ this.webserviceDescription = webserviceDescription;
+ }
+
+ public WebserviceDescriptionMetaData getWebserviceDescription()
+ {
+ return webserviceDescription;
+ }
+
+ public String getPortComponentName()
+ {
+ return portComponentName;
+ }
+
+ public void setPortComponentName(String portComponentName)
+ {
+ this.portComponentName = portComponentName;
+ }
+
+ public QName getWsdlPort()
+ {
+ return wsdlPort;
+ }
+
+ public void setWsdlPort(QName wsdlPort)
+ {
+ if (wsdlPort.getNamespaceURI().length() == 0)
+ log.warn("<wsdl-port> element in webservices.xml not namespace
qualified: " + wsdlPort);
+
+ this.wsdlPort = wsdlPort;
+ }
+
+ public String getEjbLink()
+ {
+ return ejbLink;
+ }
+
+ public void setEjbLink(String ejbLink)
+ {
+ this.ejbLink = ejbLink;
+ }
+
+ public String getServletLink()
+ {
+ return servletLink;
+ }
+
+ public void setServletLink(String servletLink)
+ {
+ this.servletLink = servletLink;
+ }
+
+ public String getServiceEndpointInterface()
+ {
+ return serviceEndpointInterface;
+ }
+
+ public void setServiceEndpointInterface(String serviceEndpointInterface)
+ {
+ this.serviceEndpointInterface = serviceEndpointInterface;
+ }
+
+ public void addHandler(UnifiedHandlerMetaData handler)
+ {
+ handlers.add(handler);
+ }
+
+ public UnifiedHandlerMetaData[] getHandlers()
+ {
+ UnifiedHandlerMetaData[] array = new UnifiedHandlerMetaData[handlers.size()];
+ handlers.toArray(array);
+ return array;
+ }
+
+ public String getContextRoot()
+ {
+ return contextRoot;
+ }
+
+ public void setContextRoot(String contextRoot)
+ {
+ this.contextRoot = contextRoot;
+ }
+
+ public Boolean getSecureWSDLAccess()
+ {
+ return secureWSDLAccess;
+ }
+
+ public void setSecureWSDLAccess(Boolean secureWSDLAccess)
+ {
+ this.secureWSDLAccess = secureWSDLAccess;
+ }
+
+ public boolean isEnableMtom()
+ {
+ return enableMtom;
+ }
+
+ public void setEnableMtom(boolean enableMtom)
+ {
+ this.enableMtom = enableMtom;
+ }
+
+ public QName getWsdlService()
+ {
+ return wsdlService;
+ }
+
+ public void setWsdlService(QName wsdlService)
+ {
+ this.wsdlService = wsdlService;
+ }
+
+ public String getProtocolBinding()
+ {
+ return protocolBinding;
+ }
+
+ public void setProtocolBinding(String protocolBinding)
+ {
+ this.protocolBinding = protocolBinding;
+ }
+
+ public UnifiedHandlerChainsMetaData getHandlerChains()
+ {
+ return handlerChains;
+ }
+
+ public void setHandlerChains(UnifiedHandlerChainsMetaData handlerChains)
+ {
+ this.handlerChains = handlerChains;
+ }
+
+ public String serialize()
+ {
+ StringBuilder builder = new StringBuilder("<port-component>");
+
builder.append("<port-component-name>").append(portComponentName).append("</port-component-name>");
+ builder.append("<wsdl-port
xmlns:").append(wsdlPort.getPrefix()).append("='").append(wsdlPort.getNamespaceURI()).append("'>");
+
builder.append(wsdlPort.getPrefix()).append(':').append(wsdlPort.getLocalPart()).append("</wsdl-port>");
+
builder.append("<service-endpoint-interface>").append(serviceEndpointInterface).append("</service-endpoint-interface>");
+ builder.append("<service-impl-bean>");
+ if (ejbLink != null)
+ builder.append("<ejb-link>" + ejbLink +
"</ejb-link>");
+ else
+ builder.append("<servlet-link>"+ servletLink +
"</servlet-link>");
+ builder.append("</service-impl-bean>");
+ builder.append("</port-component>");
+ return builder.toString();
+ }
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,169 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.webservices;
-
-// $Id$
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.logging.Logger;
-
-/**
- * XML Binding element for <code>webservices/webservice-description</code>
- *
- * @author Thomas.Diesler(a)jboss.org
- * @version $Revision$
- * @since 15-April-2004
- */
-public class WebserviceDescriptionMetaData
-{
- // provide logging
- private static final Logger log =
Logger.getLogger(WebserviceDescriptionMetaData.class);
-
- // The parent <webservices> element
- private WebservicesMetaData webservices;
-
- // The required <webservice-description-name> element
- private String webserviceDescriptionName;
- // The required <wsdl-file> element
- private String wsdlFile;
- // The required <jaxrpc-mapping-file> element
- private String jaxrpcMappingFile;
- // The required <port-component> elements
- private ArrayList<PortComponentMetaData> portComponents = new
ArrayList<PortComponentMetaData>();
-
- public WebserviceDescriptionMetaData(WebservicesMetaData webservices)
- {
- this.webservices = webservices;
- }
-
- public WebservicesMetaData getWebservices()
- {
- return webservices;
- }
-
- public void addPortComponent(PortComponentMetaData portComponent)
- {
- portComponents.add(portComponent);
- }
-
- public PortComponentMetaData[] getPortComponents()
- {
- PortComponentMetaData[] array = new PortComponentMetaData[portComponents.size()];
- portComponents.toArray(array);
- return array;
- }
-
- /**
- * Get the QNames of the port components to be declared
- * in the namespaces
- *
- * @return
- */
- public Collection<QName> getPortComponentQNames()
- {
- //TODO:Check if there is just one QName that drives all portcomponents
- //or each port component can have a distinct QName (namespace/prefix)
- //Maintain uniqueness of the QName
- Map<String, QName> map = new HashMap<String, QName>();
- for (PortComponentMetaData pcm : portComponents)
- {
- QName qname = pcm.getWsdlPort();
- map.put(qname.getPrefix(), qname);
- }
- return map.values();
- }
-
- /**
- * Lookup a PortComponentMetaData by wsdl-port local part
- *
- * @param name - the wsdl-port local part
- * @return PortComponentMetaData if found, null otherwise
- */
- public PortComponentMetaData getPortComponentByWsdlPort(String name)
- {
- ArrayList<String> pcNames = new ArrayList<String>();
- for (PortComponentMetaData pc : portComponents)
- {
- String wsdlPortName = pc.getWsdlPort().getLocalPart();
- if (wsdlPortName.equals(name))
- return pc;
-
- pcNames.add(wsdlPortName);
- }
-
- log.error("Cannot get port component name '" + name + "', we
have: " + pcNames);
- return null;
- }
-
- public String getWebserviceDescriptionName()
- {
- return webserviceDescriptionName;
- }
-
- public void setWebserviceDescriptionName(String webserviceDescriptionName)
- {
- this.webserviceDescriptionName = webserviceDescriptionName;
- }
-
- public String getWsdlFile()
- {
- return wsdlFile;
- }
-
- public void setWsdlFile(String wsdlFile)
- {
- this.wsdlFile = wsdlFile;
- }
-
- public String getJaxrpcMappingFile()
- {
- return jaxrpcMappingFile;
- }
-
- public void setJaxrpcMappingFile(String jaxrpcMappingFile)
- {
- this.jaxrpcMappingFile = jaxrpcMappingFile;
- }
-
- /**
- * Serialize as a String
- *
- * @return
- */
- public String serialize()
- {
- StringBuilder buffer = new
StringBuilder("<webservice-description>");
-
buffer.append("<webservice-description-name>").append(webserviceDescriptionName).append("</webservice-description-name>");
-
buffer.append("<wsdl-file>").append(wsdlFile).append("</wsdl-file>");
-
buffer.append("<jaxrpc-mapping-file>").append(jaxrpcMappingFile).append("</jaxrpc-mapping-file>");
- for (PortComponentMetaData pm : portComponents)
- buffer.append(pm.serialize());
- buffer.append("</webservice-description>");
- return buffer.toString();
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebserviceDescriptionMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,169 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.webservices;
+
+// $Id$
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.xml.namespace.QName;
+
+import org.jboss.logging.Logger;
+
+/**
+ * XML Binding element for <code>webservices/webservice-description</code>
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @version $Revision$
+ * @since 15-April-2004
+ */
+public class WebserviceDescriptionMetaData
+{
+ // provide logging
+ private static final Logger log =
Logger.getLogger(WebserviceDescriptionMetaData.class);
+
+ // The parent <webservices> element
+ private WebservicesMetaData webservices;
+
+ // The required <webservice-description-name> element
+ private String webserviceDescriptionName;
+ // The required <wsdl-file> element
+ private String wsdlFile;
+ // The required <jaxrpc-mapping-file> element
+ private String jaxrpcMappingFile;
+ // The required <port-component> elements
+ private ArrayList<PortComponentMetaData> portComponents = new
ArrayList<PortComponentMetaData>();
+
+ public WebserviceDescriptionMetaData(WebservicesMetaData webservices)
+ {
+ this.webservices = webservices;
+ }
+
+ public WebservicesMetaData getWebservices()
+ {
+ return webservices;
+ }
+
+ public void addPortComponent(PortComponentMetaData portComponent)
+ {
+ portComponents.add(portComponent);
+ }
+
+ public PortComponentMetaData[] getPortComponents()
+ {
+ PortComponentMetaData[] array = new PortComponentMetaData[portComponents.size()];
+ portComponents.toArray(array);
+ return array;
+ }
+
+ /**
+ * Get the QNames of the port components to be declared
+ * in the namespaces
+ *
+ * @return
+ */
+ public Collection<QName> getPortComponentQNames()
+ {
+ //TODO:Check if there is just one QName that drives all portcomponents
+ //or each port component can have a distinct QName (namespace/prefix)
+ //Maintain uniqueness of the QName
+ Map<String, QName> map = new HashMap<String, QName>();
+ for (PortComponentMetaData pcm : portComponents)
+ {
+ QName qname = pcm.getWsdlPort();
+ map.put(qname.getPrefix(), qname);
+ }
+ return map.values();
+ }
+
+ /**
+ * Lookup a PortComponentMetaData by wsdl-port local part
+ *
+ * @param name - the wsdl-port local part
+ * @return PortComponentMetaData if found, null otherwise
+ */
+ public PortComponentMetaData getPortComponentByWsdlPort(String name)
+ {
+ ArrayList<String> pcNames = new ArrayList<String>();
+ for (PortComponentMetaData pc : portComponents)
+ {
+ String wsdlPortName = pc.getWsdlPort().getLocalPart();
+ if (wsdlPortName.equals(name))
+ return pc;
+
+ pcNames.add(wsdlPortName);
+ }
+
+ log.error("Cannot get port component name '" + name + "', we
have: " + pcNames);
+ return null;
+ }
+
+ public String getWebserviceDescriptionName()
+ {
+ return webserviceDescriptionName;
+ }
+
+ public void setWebserviceDescriptionName(String webserviceDescriptionName)
+ {
+ this.webserviceDescriptionName = webserviceDescriptionName;
+ }
+
+ public String getWsdlFile()
+ {
+ return wsdlFile;
+ }
+
+ public void setWsdlFile(String wsdlFile)
+ {
+ this.wsdlFile = wsdlFile;
+ }
+
+ public String getJaxrpcMappingFile()
+ {
+ return jaxrpcMappingFile;
+ }
+
+ public void setJaxrpcMappingFile(String jaxrpcMappingFile)
+ {
+ this.jaxrpcMappingFile = jaxrpcMappingFile;
+ }
+
+ /**
+ * Serialize as a String
+ *
+ * @return
+ */
+ public String serialize()
+ {
+ StringBuilder buffer = new
StringBuilder("<webservice-description>");
+
buffer.append("<webservice-description-name>").append(webserviceDescriptionName).append("</webservice-description-name>");
+
buffer.append("<wsdl-file>").append(wsdlFile).append("</wsdl-file>");
+
buffer.append("<jaxrpc-mapping-file>").append(jaxrpcMappingFile).append("</jaxrpc-mapping-file>");
+ for (PortComponentMetaData pm : portComponents)
+ buffer.append(pm.serialize());
+ buffer.append("</webservice-description>");
+ return buffer.toString();
+ }
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,332 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.metadata.webservices;
-
-// $Id$
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.integration.UnifiedVirtualFile;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
-import org.jboss.ws.WSException;
-import org.jboss.xb.binding.ObjectModelFactory;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URL;
-
-/**
- * A JBossXB factory for {@link WebservicesMetaData}
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 16-Apr-2004
- */
-public class WebservicesFactory implements ObjectModelFactory
-{
- // provide logging
- private static final Logger log = Logger.getLogger(WebservicesFactory.class);
-
- // The URL to the webservices.xml descriptor
- private URL descriptorURL;
-
- public WebservicesFactory(URL descriptorURL)
- {
- this.descriptorURL = descriptorURL;
- }
-
- /**
- * Load webservices.xml from <code>META-INF/webservices.xml</code>
- * or <code>WEB-INF/webservices.xml</code>.
- *
- * @param root virtual file root
- * @return WebservicesMetaData or <code>null</code> if it cannot be found
- */
- public static WebservicesMetaData loadFromVFSRoot(UnifiedVirtualFile root)
- {
- WebservicesMetaData webservices = null;
-
- UnifiedVirtualFile wsdd = null;
- try
- {
- wsdd = root.findChild("META-INF/webservices.xml");
- }
- catch (IOException e)
- {
- //
- }
-
- // Maybe a web application deployment?
- if(null == wsdd)
- {
- try
- {
- wsdd = root.findChild("WEB-INF/webservices.xml");
- }
- catch (IOException e)
- {
- //
- }
- }
-
- // the descriptor is optional
- if(wsdd!=null)
- {
-
- URL wsddUrl = wsdd.toURL();
- try
- {
- InputStream is = wsddUrl.openStream();
- Unmarshaller unmarshaller =
UnmarshallerFactory.newInstance().newUnmarshaller();
- ObjectModelFactory factory = new WebservicesFactory(wsddUrl);
- webservices = (WebservicesMetaData)unmarshaller.unmarshal(is, factory,
null);
- is.close();
- }
- catch(Exception e)
- {
- throw new WSException("Failed to unmarshall webservices.xml:" +
e.getMessage());
- }
- }
-
- return webservices;
- }
-
- /**
- * This method is called on the factory by the object model builder when the parsing
starts.
- *
- * @return the root of the object model.
- */
- public Object newRoot(Object root, UnmarshallingContext navigator, String
namespaceURI, String localName, Attributes attrs)
- {
- WebservicesMetaData webservicesMetaData = new WebservicesMetaData(descriptorURL);
- return webservicesMetaData;
- }
-
- public Object completeRoot(Object root, UnmarshallingContext ctx, String uri, String
name)
- {
- return root;
- }
-
- /**
- * Called when parsing of a new element started.
- */
- public Object newChild(WebservicesMetaData webservices, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
- {
- if ("webservice-description".equals(localName))
- return new WebserviceDescriptionMetaData(webservices);
- else return null;
- }
-
- /**
- * Called when parsing character is complete.
- */
- public void addChild(WebservicesMetaData webservices, WebserviceDescriptionMetaData
webserviceDescription, UnmarshallingContext navigator, String namespaceURI,
- String localName)
- {
- webservices.addWebserviceDescription(webserviceDescription);
- }
-
- /**
- * Called when parsing of a new element started.
- */
- public Object newChild(WebserviceDescriptionMetaData webserviceDescription,
UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- if ("port-component".equals(localName))
- return new PortComponentMetaData(webserviceDescription);
- else return null;
- }
-
- /**
- * Called when parsing character is complete.
- */
- public void addChild(WebserviceDescriptionMetaData webserviceDescription,
PortComponentMetaData portComponent, UnmarshallingContext navigator, String namespaceURI,
- String localName)
- {
- webserviceDescription.addPortComponent(portComponent);
- }
-
- /**
- * Called when parsing of a new element started.
- */
- public Object newChild(PortComponentMetaData portComponent, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
- {
- if ("handler".equals(localName))
- return new UnifiedHandlerMetaData(null);
- else if ("handler-chains".equals(localName))
- return new UnifiedHandlerChainsMetaData();
- else return null;
- }
-
- /**
- * Called when parsing of a new element started.
- */
- public Object newChild(UnifiedHandlerChainsMetaData handlerChains,
UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- if ("handler-chain".equals(localName))
- return new UnifiedHandlerChainMetaData();
- else return null;
- }
-
- /**
- * Called when parsing of a new element started.
- */
- public Object newChild(UnifiedHandlerChainMetaData handlerChains, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
- {
- if ("handler".equals(localName))
- return new UnifiedHandlerMetaData();
- else return null;
- }
-
-
- /**
- * Called when parsing character is complete.
- */
- public void addChild(PortComponentMetaData portComponent, UnifiedHandlerMetaData
handler, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- portComponent.addHandler(handler);
- }
-
- /**
- * Called when parsing character is complete.
- */
- public void addChild(PortComponentMetaData portComponent, UnifiedHandlerChainsMetaData
handlerChains, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- portComponent.setHandlerChains(handlerChains);
- }
-
- /**
- * Called when parsing character is complete.
- */
- public void addChild(UnifiedHandlerChainsMetaData chains, UnifiedHandlerChainMetaData
handlerChain, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- chains.addHandlerChain(handlerChain);
- }
-
- /**
- * Called when parsing character is complete.
- */
- public void addChild(UnifiedHandlerChainMetaData chain, UnifiedHandlerMetaData
handler, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- chain.addHandler(handler);
- }
-
- /**
- * Called when parsing of a new element started.
- */
- public Object newChild(UnifiedHandlerMetaData handler, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
- {
- if ("init-param".equals(localName))
- return new UnifiedInitParamMetaData();
- else return null;
- }
-
- /**
- * Called when parsing character is complete.
- */
- public void addChild(UnifiedHandlerMetaData handler, UnifiedInitParamMetaData param,
UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- handler.addInitParam(param);
- }
-
- /**
- * Called when a new simple child element with text value was read from the XML
content.
- */
- public void setValue(WebserviceDescriptionMetaData webserviceDescription,
UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (log.isTraceEnabled())
- log.trace("WebserviceDescriptionMetaData setValue: nuri=" +
namespaceURI + " localName=" + localName + " value=" + value);
-
- if (localName.equals("webservice-description-name"))
- webserviceDescription.setWebserviceDescriptionName(value);
- else if (localName.equals("wsdl-file"))
- webserviceDescription.setWsdlFile(value);
- else if (localName.equals("jaxrpc-mapping-file"))
- webserviceDescription.setJaxrpcMappingFile(value);
- }
-
- /**
- * Called when a new simple child element with text value was read from the XML
content.
- */
- public void setValue(PortComponentMetaData portComponent, UnmarshallingContext
navigator, String namespaceURI, String localName, String value)
- {
- if (log.isTraceEnabled())
- log.trace("PortComponentMetaData setValue: nuri=" + namespaceURI +
" localName=" + localName + " value=" + value);
-
- if (localName.equals("port-component-name"))
- portComponent.setPortComponentName(value);
- else if (localName.equals("wsdl-port"))
- portComponent.setWsdlPort(navigator.resolveQName(value));
- else if (localName.equals("service-endpoint-interface"))
- portComponent.setServiceEndpointInterface(value);
- else if (localName.equals("ejb-link"))
- portComponent.setEjbLink(value);
- else if (localName.equals("servlet-link"))
- portComponent.setServletLink(value);
- else if (localName.equals("wsdl-service"))
- portComponent.setWsdlService(navigator.resolveQName(value));
- else if (localName.equals("protocol-binding"))
- portComponent.setProtocolBinding(value);
- else if (localName.equals("enable-mtom"))
- portComponent.setEnableMtom(Boolean.valueOf(value));
-
-
- }
-
- /**
- * Called when a new simple child element with text value was read from the XML
content.
- */
- public void setValue(UnifiedHandlerMetaData handler, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (log.isTraceEnabled())
- log.trace("UnifiedHandlerMetaData setValue: nuri=" + namespaceURI +
" localName=" + localName + " value=" + value);
-
- if (localName.equals("handler-name"))
- handler.setHandlerName(value);
- else if (localName.equals("handler-class"))
- handler.setHandlerClass(value);
- else if (localName.equals("soap-header"))
- handler.addSoapHeader(navigator.resolveQName(value));
- else if (localName.equals("soap-role"))
- handler.addSoapRole(value);
- else if (localName.equals("port-name"))
- handler.addPortName(value);
- }
-
- /**
- * Called when a new simple child element with text value was read from the XML
content.
- */
- public void setValue(UnifiedInitParamMetaData param, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (log.isTraceEnabled())
- log.trace("UnifiedInitParamMetaData setValue: nuri=" + namespaceURI +
" localName=" + localName + " value=" + value);
-
- if (localName.equals("param-name"))
- param.setParamName(value);
- else if (localName.equals("param-value"))
- param.setParamValue(value);
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesFactory.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,333 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.metadata.webservices;
+
+// $Id$
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URL;
+
+import javax.xml.ws.WebServiceException;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.integration.UnifiedVirtualFile;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
+import org.jboss.xb.binding.ObjectModelFactory;
+import org.jboss.xb.binding.Unmarshaller;
+import org.jboss.xb.binding.UnmarshallerFactory;
+import org.jboss.xb.binding.UnmarshallingContext;
+import org.xml.sax.Attributes;
+
+/**
+ * A JBossXB factory for {@link WebservicesMetaData}
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 16-Apr-2004
+ */
+public class WebservicesFactory implements ObjectModelFactory
+{
+ // provide logging
+ private static final Logger log = Logger.getLogger(WebservicesFactory.class);
+
+ // The URL to the webservices.xml descriptor
+ private URL descriptorURL;
+
+ public WebservicesFactory(URL descriptorURL)
+ {
+ this.descriptorURL = descriptorURL;
+ }
+
+ /**
+ * Load webservices.xml from <code>META-INF/webservices.xml</code>
+ * or <code>WEB-INF/webservices.xml</code>.
+ *
+ * @param root virtual file root
+ * @return WebservicesMetaData or <code>null</code> if it cannot be found
+ */
+ public static WebservicesMetaData loadFromVFSRoot(UnifiedVirtualFile root)
+ {
+ WebservicesMetaData webservices = null;
+
+ UnifiedVirtualFile wsdd = null;
+ try
+ {
+ wsdd = root.findChild("META-INF/webservices.xml");
+ }
+ catch (IOException e)
+ {
+ //
+ }
+
+ // Maybe a web application deployment?
+ if (null == wsdd)
+ {
+ try
+ {
+ wsdd = root.findChild("WEB-INF/webservices.xml");
+ }
+ catch (IOException e)
+ {
+ //
+ }
+ }
+
+ // the descriptor is optional
+ if (wsdd != null)
+ {
+
+ URL wsddUrl = wsdd.toURL();
+ try
+ {
+ InputStream is = wsddUrl.openStream();
+ Unmarshaller unmarshaller =
UnmarshallerFactory.newInstance().newUnmarshaller();
+ ObjectModelFactory factory = new WebservicesFactory(wsddUrl);
+ webservices = (WebservicesMetaData)unmarshaller.unmarshal(is, factory,
null);
+ is.close();
+ }
+ catch (Exception e)
+ {
+ throw new WebServiceException("Failed to unmarshall
webservices.xml:" + e.getMessage());
+ }
+ }
+
+ return webservices;
+ }
+
+ /**
+ * This method is called on the factory by the object model builder when the parsing
starts.
+ *
+ * @return the root of the object model.
+ */
+ public Object newRoot(Object root, UnmarshallingContext navigator, String
namespaceURI, String localName, Attributes attrs)
+ {
+ WebservicesMetaData webservicesMetaData = new WebservicesMetaData(descriptorURL);
+ return webservicesMetaData;
+ }
+
+ public Object completeRoot(Object root, UnmarshallingContext ctx, String uri, String
name)
+ {
+ return root;
+ }
+
+ /**
+ * Called when parsing of a new element started.
+ */
+ public Object newChild(WebservicesMetaData webservices, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ if ("webservice-description".equals(localName))
+ return new WebserviceDescriptionMetaData(webservices);
+ else return null;
+ }
+
+ /**
+ * Called when parsing character is complete.
+ */
+ public void addChild(WebservicesMetaData webservices, WebserviceDescriptionMetaData
webserviceDescription, UnmarshallingContext navigator, String namespaceURI,
+ String localName)
+ {
+ webservices.addWebserviceDescription(webserviceDescription);
+ }
+
+ /**
+ * Called when parsing of a new element started.
+ */
+ public Object newChild(WebserviceDescriptionMetaData webserviceDescription,
UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ if ("port-component".equals(localName))
+ return new PortComponentMetaData(webserviceDescription);
+ else return null;
+ }
+
+ /**
+ * Called when parsing character is complete.
+ */
+ public void addChild(WebserviceDescriptionMetaData webserviceDescription,
PortComponentMetaData portComponent, UnmarshallingContext navigator, String namespaceURI,
+ String localName)
+ {
+ webserviceDescription.addPortComponent(portComponent);
+ }
+
+ /**
+ * Called when parsing of a new element started.
+ */
+ public Object newChild(PortComponentMetaData portComponent, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ if ("handler".equals(localName))
+ return new UnifiedHandlerMetaData(null);
+ else if ("handler-chains".equals(localName))
+ return new UnifiedHandlerChainsMetaData();
+ else return null;
+ }
+
+ /**
+ * Called when parsing of a new element started.
+ */
+ public Object newChild(UnifiedHandlerChainsMetaData handlerChains,
UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ if ("handler-chain".equals(localName))
+ return new UnifiedHandlerChainMetaData();
+ else return null;
+ }
+
+ /**
+ * Called when parsing of a new element started.
+ */
+ public Object newChild(UnifiedHandlerChainMetaData handlerChains, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ if ("handler".equals(localName))
+ return new UnifiedHandlerMetaData();
+ else return null;
+ }
+
+ /**
+ * Called when parsing character is complete.
+ */
+ public void addChild(PortComponentMetaData portComponent, UnifiedHandlerMetaData
handler, UnmarshallingContext navigator, String namespaceURI, String localName)
+ {
+ portComponent.addHandler(handler);
+ }
+
+ /**
+ * Called when parsing character is complete.
+ */
+ public void addChild(PortComponentMetaData portComponent, UnifiedHandlerChainsMetaData
handlerChains, UnmarshallingContext navigator, String namespaceURI,
+ String localName)
+ {
+ portComponent.setHandlerChains(handlerChains);
+ }
+
+ /**
+ * Called when parsing character is complete.
+ */
+ public void addChild(UnifiedHandlerChainsMetaData chains, UnifiedHandlerChainMetaData
handlerChain, UnmarshallingContext navigator, String namespaceURI,
+ String localName)
+ {
+ chains.addHandlerChain(handlerChain);
+ }
+
+ /**
+ * Called when parsing character is complete.
+ */
+ public void addChild(UnifiedHandlerChainMetaData chain, UnifiedHandlerMetaData
handler, UnmarshallingContext navigator, String namespaceURI, String localName)
+ {
+ chain.addHandler(handler);
+ }
+
+ /**
+ * Called when parsing of a new element started.
+ */
+ public Object newChild(UnifiedHandlerMetaData handler, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
+ {
+ if ("init-param".equals(localName))
+ return new UnifiedInitParamMetaData();
+ else return null;
+ }
+
+ /**
+ * Called when parsing character is complete.
+ */
+ public void addChild(UnifiedHandlerMetaData handler, UnifiedInitParamMetaData param,
UnmarshallingContext navigator, String namespaceURI, String localName)
+ {
+ handler.addInitParam(param);
+ }
+
+ /**
+ * Called when a new simple child element with text value was read from the XML
content.
+ */
+ public void setValue(WebserviceDescriptionMetaData webserviceDescription,
UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (log.isTraceEnabled())
+ log.trace("WebserviceDescriptionMetaData setValue: nuri=" +
namespaceURI + " localName=" + localName + " value=" + value);
+
+ if (localName.equals("webservice-description-name"))
+ webserviceDescription.setWebserviceDescriptionName(value);
+ else if (localName.equals("wsdl-file"))
+ webserviceDescription.setWsdlFile(value);
+ else if (localName.equals("jaxrpc-mapping-file"))
+ webserviceDescription.setJaxrpcMappingFile(value);
+ }
+
+ /**
+ * Called when a new simple child element with text value was read from the XML
content.
+ */
+ public void setValue(PortComponentMetaData portComponent, UnmarshallingContext
navigator, String namespaceURI, String localName, String value)
+ {
+ if (log.isTraceEnabled())
+ log.trace("PortComponentMetaData setValue: nuri=" + namespaceURI +
" localName=" + localName + " value=" + value);
+
+ if (localName.equals("port-component-name"))
+ portComponent.setPortComponentName(value);
+ else if (localName.equals("wsdl-port"))
+ portComponent.setWsdlPort(navigator.resolveQName(value));
+ else if (localName.equals("service-endpoint-interface"))
+ portComponent.setServiceEndpointInterface(value);
+ else if (localName.equals("ejb-link"))
+ portComponent.setEjbLink(value);
+ else if (localName.equals("servlet-link"))
+ portComponent.setServletLink(value);
+ else if (localName.equals("wsdl-service"))
+ portComponent.setWsdlService(navigator.resolveQName(value));
+ else if (localName.equals("protocol-binding"))
+ portComponent.setProtocolBinding(value);
+ else if (localName.equals("enable-mtom"))
+ portComponent.setEnableMtom(Boolean.valueOf(value));
+
+ }
+
+ /**
+ * Called when a new simple child element with text value was read from the XML
content.
+ */
+ public void setValue(UnifiedHandlerMetaData handler, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ if (log.isTraceEnabled())
+ log.trace("UnifiedHandlerMetaData setValue: nuri=" + namespaceURI +
" localName=" + localName + " value=" + value);
+
+ if (localName.equals("handler-name"))
+ handler.setHandlerName(value);
+ else if (localName.equals("handler-class"))
+ handler.setHandlerClass(value);
+ else if (localName.equals("soap-header"))
+ handler.addSoapHeader(navigator.resolveQName(value));
+ else if (localName.equals("soap-role"))
+ handler.addSoapRole(value);
+ else if (localName.equals("port-name"))
+ handler.addPortName(value);
+ }
+
+ /**
+ * Called when a new simple child element with text value was read from the XML
content.
+ */
+ public void setValue(UnifiedInitParamMetaData param, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ if (log.isTraceEnabled())
+ log.trace("UnifiedInitParamMetaData setValue: nuri=" + namespaceURI +
" localName=" + localName + " value=" + value);
+
+ if (localName.equals("param-name"))
+ param.setParamName(value);
+ else if (localName.equals("param-value"))
+ param.setParamValue(value);
+ }
+}
Deleted:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java 2007-05-09
19:05:56 UTC (rev 3022)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,97 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.
- */
-// $Id$
-package org.jboss.ws.metadata.webservices;
-
-import java.net.URL;
-import java.util.ArrayList;
-
-import org.jboss.ws.Constants;
-
-// $Id$
-
-/**
- * XML Binding root element for <code>webservices.xml</code>
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 15-April-2004
- */
-public class WebservicesMetaData
-{
- // The required <webservice-description> elements
- private ArrayList<WebserviceDescriptionMetaData> webserviceDescriptions = new
ArrayList<WebserviceDescriptionMetaData>();
-
- // The URL to the webservices.xml descriptor
- private URL descriptorURL;
-
- public WebservicesMetaData()
- {
- }
-
- public WebservicesMetaData(URL descriptorURL)
- {
- this.descriptorURL = descriptorURL;
- }
-
- public URL getDescriptorURL()
- {
- return descriptorURL;
- }
-
- public void addWebserviceDescription(WebserviceDescriptionMetaData
webserviceDescription)
- {
- webserviceDescriptions.add(webserviceDescription);
- }
-
- public WebserviceDescriptionMetaData[] getWebserviceDescriptions()
- {
- WebserviceDescriptionMetaData[] array = new
WebserviceDescriptionMetaData[webserviceDescriptions.size()];
- webserviceDescriptions.toArray(array);
- return array;
- }
-
- //Serialize as a String
- public String serialize()
- {
- //Construct the webservices.xml definitions
- StringBuilder buffer = new StringBuilder();
-
- // header: opening webservices tag
- createHeader(buffer);
-
- // webservice-description subelements
- for (WebserviceDescriptionMetaData wm : webserviceDescriptions)
- buffer.append(wm.serialize());
-
- // closing webservices tag
- buffer.append("</webservices>");
- return buffer.toString();
- }
-
- private void createHeader(StringBuilder buf)
- {
- buf.append("<webservices
xmlns='http://java.sun.com/xml/ns/j2ee'");
- buf.append("
xmlns:xsi='").append(Constants.NS_SCHEMA_XSI).append('\'');
- buf.append("
xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee
http://www.ibm.com/webservices/xsd/j2ee_web_services_1_1.xsd'");
- buf.append(" version='1.1'>");
- }
-}
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java
(from rev 3033,
trunk/jbossws-core/src/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/metadata/webservices/WebservicesMetaData.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,95 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.
+ */
+// $Id$
+package org.jboss.ws.metadata.webservices;
+
+import java.net.URL;
+import java.util.ArrayList;
+
+// $Id$
+
+/**
+ * XML Binding root element for <code>webservices.xml</code>
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 15-April-2004
+ */
+public class WebservicesMetaData
+{
+ // The required <webservice-description> elements
+ private ArrayList<WebserviceDescriptionMetaData> webserviceDescriptions = new
ArrayList<WebserviceDescriptionMetaData>();
+
+ // The URL to the webservices.xml descriptor
+ private URL descriptorURL;
+
+ public WebservicesMetaData()
+ {
+ }
+
+ public WebservicesMetaData(URL descriptorURL)
+ {
+ this.descriptorURL = descriptorURL;
+ }
+
+ public URL getDescriptorURL()
+ {
+ return descriptorURL;
+ }
+
+ public void addWebserviceDescription(WebserviceDescriptionMetaData
webserviceDescription)
+ {
+ webserviceDescriptions.add(webserviceDescription);
+ }
+
+ public WebserviceDescriptionMetaData[] getWebserviceDescriptions()
+ {
+ WebserviceDescriptionMetaData[] array = new
WebserviceDescriptionMetaData[webserviceDescriptions.size()];
+ webserviceDescriptions.toArray(array);
+ return array;
+ }
+
+ //Serialize as a String
+ public String serialize()
+ {
+ //Construct the webservices.xml definitions
+ StringBuilder buffer = new StringBuilder();
+
+ // header: opening webservices tag
+ createHeader(buffer);
+
+ // webservice-description subelements
+ for (WebserviceDescriptionMetaData wm : webserviceDescriptions)
+ buffer.append(wm.serialize());
+
+ // closing webservices tag
+ buffer.append("</webservices>");
+ return buffer.toString();
+ }
+
+ private void createHeader(StringBuilder buf)
+ {
+ buf.append("<webservices
xmlns='http://java.sun.com/xml/ns/j2ee'");
+ buf.append("
xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'");
+ buf.append("
xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee
http://www.ibm.com/webservices/xsd/j2ee_web_services_1_1.xsd'");
+ buf.append(" version='1.1'>");
+ }
+}
Added:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/DOMUtils.java
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/DOMUtils.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/DOMUtils.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,619 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.utils;
+
+// $Id$
+
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.Reader;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
+import javax.xml.namespace.QName;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+import javax.xml.transform.OutputKeys;
+import javax.xml.transform.Source;
+import javax.xml.transform.Transformer;
+import javax.xml.transform.TransformerException;
+import javax.xml.transform.TransformerFactory;
+import javax.xml.transform.dom.DOMSource;
+import javax.xml.transform.sax.SAXSource;
+import javax.xml.transform.stream.StreamResult;
+import javax.xml.transform.stream.StreamSource;
+
+import org.jboss.logging.Logger;
+import org.w3c.dom.Attr;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.NamedNodeMap;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+import org.w3c.dom.Text;
+import org.xml.sax.EntityResolver;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * DOM2 utilites
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ */
+public final class DOMUtils
+{
+ private static Logger log = Logger.getLogger(DOMUtils.class);
+
+ // All elements created by the same thread are created by the same builder and belong
to the same doc
+ private static ThreadLocal documentThreadLocal = new ThreadLocal();
+ private static ThreadLocal builderThreadLocal = new ThreadLocal()
+ {
+ protected Object initialValue()
+ {
+ try
+ {
+ DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
+ factory.setValidating(false);
+ factory.setNamespaceAware(true);
+ DocumentBuilder builder = factory.newDocumentBuilder();
+ setEntityResolver(builder);
+ return builder;
+ }
+ catch (ParserConfigurationException e)
+ {
+ throw new RuntimeException("Failed to create DocumentBuilder", e);
+ }
+ }
+
+ private void setEntityResolver(DocumentBuilder builder)
+ {
+ String[] resolvers = new String[] {
"org.jboss.ws.core.utils.JBossWSEntityResolver",
"org.jboss.util.xml.JBossEntityResolver" };
+
+ EntityResolver entityResolver = null;
+ ClassLoader loader = Thread.currentThread().getContextClassLoader();
+ for (String resolver : resolvers)
+ {
+ try
+ {
+ Class<?> resolverClass = loader.loadClass(resolver);
+ entityResolver = (EntityResolver)resolverClass.newInstance();
+ }
+ catch (Exception ex)
+ {
+ log.debug("Cannot load: " + resolver);
+ }
+ }
+
+ if (entityResolver != null)
+ builder.setEntityResolver(entityResolver);
+ }
+ };
+
+ // Hide the constructor
+ private DOMUtils()
+ {
+ }
+
+ /** Initialise the the DocumentBuilder
+ */
+ public static DocumentBuilder getDocumentBuilder()
+ {
+ DocumentBuilder builder = (DocumentBuilder)builderThreadLocal.get();
+ return builder;
+ }
+
+ /** Parse the given XML string and return the root Element
+ */
+ public static Element parse(String xmlString) throws IOException
+ {
+ try
+ {
+ return parse(new ByteArrayInputStream(xmlString.getBytes("UTF-8")));
+ }
+ catch (IOException e)
+ {
+ log.error("Cannot parse: " + xmlString);
+ throw e;
+ }
+ }
+
+ /** Parse the given XML stream and return the root Element
+ */
+ public static Element parse(InputStream xmlStream) throws IOException
+ {
+ try
+ {
+ Document doc = getDocumentBuilder().parse(xmlStream);
+ Element root = doc.getDocumentElement();
+ return root;
+ }
+ catch (SAXException e)
+ {
+ throw new IOException(e.toString());
+ }
+ }
+
+ /** Parse the given input source and return the root Element
+ */
+ public static Element parse(InputSource source) throws IOException
+ {
+ try
+ {
+ Document doc = getDocumentBuilder().parse(source);
+ Element root = doc.getDocumentElement();
+ return root;
+ }
+ catch (SAXException e)
+ {
+ throw new IOException(e.toString());
+ }
+ }
+
+ /** Create an Element for a given name
+ */
+ public static Element createElement(String localPart)
+ {
+ Document doc = getOwnerDocument();
+ log.trace("createElement {}" + localPart);
+ return doc.createElement(localPart);
+ }
+
+ /** Create an Element for a given name and prefix
+ */
+ public static Element createElement(String localPart, String prefix)
+ {
+ Document doc = getOwnerDocument();
+ log.trace("createElement {}" + prefix + ":" + localPart);
+ return doc.createElement(prefix + ":" + localPart);
+ }
+
+ /** Create an Element for a given name, prefix and uri
+ */
+ public static Element createElement(String localPart, String prefix, String uri)
+ {
+ Document doc = getOwnerDocument();
+ if (prefix == null || prefix.length() == 0)
+ {
+ log.trace("createElement {" + uri + "}" + localPart);
+ return doc.createElementNS(uri, localPart);
+ }
+ else
+ {
+ log.trace("createElement {" + uri + "}" + prefix +
":" + localPart);
+ return doc.createElementNS(uri, prefix + ":" + localPart);
+ }
+ }
+
+ /** Create an Element for a given QName
+ */
+ public static Element createElement(QName qname)
+ {
+ return createElement(qname.getLocalPart(), qname.getPrefix(),
qname.getNamespaceURI());
+ }
+
+ /** Create a org.w3c.dom.Text node
+ */
+ public static Text createTextNode(String value)
+ {
+ Document doc = getOwnerDocument();
+ return doc.createTextNode(value);
+ }
+
+ /** Get the qname of the given node.
+ */
+ public static QName getElementQName(Element el)
+ {
+ String qualifiedName = el.getNodeName();
+ return resolveQName(el, qualifiedName);
+ }
+
+ /** Transform the given qualified name into a QName
+ */
+ public static QName resolveQName(Element el, String qualifiedName)
+ {
+ QName qname;
+ String prefix = "";
+ String namespaceURI = "";
+ String localPart = qualifiedName;
+
+ int colIndex = qualifiedName.indexOf(":");
+ if (colIndex > 0)
+ {
+ prefix = qualifiedName.substring(0, colIndex);
+ localPart = qualifiedName.substring(colIndex + 1);
+
+ if ("xmlns".equals(prefix))
+ {
+ namespaceURI = "URI:XML_PREDEFINED_NAMESPACE";
+ }
+ else
+ {
+ Element nsElement = el;
+ while (namespaceURI.equals("") && nsElement != null)
+ {
+ namespaceURI = nsElement.getAttribute("xmlns:" + prefix);
+ if (namespaceURI.equals(""))
+ nsElement = getParentElement(nsElement);
+ }
+ }
+
+ if (namespaceURI.equals(""))
+ throw new IllegalArgumentException("Cannot find namespace uri for:
" + qualifiedName);
+ }
+ else
+ {
+ Element nsElement = el;
+ while (namespaceURI.equals("") && nsElement != null)
+ {
+ namespaceURI = nsElement.getAttribute("xmlns");
+ if (namespaceURI.equals(""))
+ nsElement = getParentElement(nsElement);
+ }
+ }
+
+ qname = new QName(namespaceURI, localPart, prefix);
+ return qname;
+ }
+
+ /** Get the value from the given attribute
+ *
+ * @return null if the attribute value is empty or the attribute is not present
+ */
+ public static String getAttributeValue(Element el, String attrName)
+ {
+ return getAttributeValue(el, new QName(attrName));
+ }
+
+ /** Get the value from the given attribute
+ *
+ * @return null if the attribute value is empty or the attribute is not present
+ */
+ public static String getAttributeValue(Element el, QName attrName)
+ {
+ String attr = null;
+ if ("".equals(attrName.getNamespaceURI()))
+ attr = el.getAttribute(attrName.getLocalPart());
+ else attr = el.getAttributeNS(attrName.getNamespaceURI(),
attrName.getLocalPart());
+
+ if ("".equals(attr))
+ attr = null;
+
+ return attr;
+ }
+
+ /** Get the qname value from the given attribute
+ */
+ public static QName getAttributeValueAsQName(Element el, String attrName)
+ {
+ return getAttributeValueAsQName(el, new QName(attrName));
+
+ }
+
+ /** Get the qname value from the given attribute
+ */
+ public static QName getAttributeValueAsQName(Element el, QName attrName)
+ {
+ QName qname = null;
+
+ String qualifiedName = getAttributeValue(el, attrName);
+ if (qualifiedName != null)
+ {
+ qname = resolveQName(el, qualifiedName);
+ }
+
+ return qname;
+ }
+
+ /** Get the boolean value from the given attribute
+ */
+ public static boolean getAttributeValueAsBoolean(Element el, String attrName)
+ {
+ return getAttributeValueAsBoolean(el, new QName(attrName));
+ }
+
+ /** Get the boolean value from the given attribute
+ */
+ public static boolean getAttributeValueAsBoolean(Element el, QName attrName)
+ {
+ String attrVal = getAttributeValue(el, attrName);
+ boolean ret = "true".equalsIgnoreCase(attrVal) ||
"1".equalsIgnoreCase(attrVal);
+ return ret;
+ }
+
+ /** Get the integer value from the given attribute
+ */
+ public static Integer getAttributeValueAsInteger(Element el, String attrName)
+ {
+ return getAttributeValueAsInteger(el, new QName(attrName));
+ }
+
+ /** Get the integer value from the given attribute
+ */
+ public static Integer getAttributeValueAsInteger(Element el, QName attrName)
+ {
+ String attrVal = getAttributeValue(el, attrName);
+ return (attrVal != null ? new Integer(attrVal) : null);
+ }
+
+ /** Get the attributes as Map<QName, String>
+ */
+ public static Map getAttributes(Element el)
+ {
+ Map attmap = new HashMap();
+ NamedNodeMap attribs = el.getAttributes();
+ for (int i = 0; i < attribs.getLength(); i++)
+ {
+ Attr attr = (Attr)attribs.item(i);
+ String name = attr.getName();
+ QName qname = resolveQName(el, name);
+ String value = attr.getNodeValue();
+ attmap.put(qname, value);
+ }
+ return attmap;
+ }
+
+ /** Copy attributes between elements
+ */
+ public static void copyAttributes(Element destElement, Element srcElement)
+ {
+ NamedNodeMap attribs = srcElement.getAttributes();
+ for (int i = 0; i < attribs.getLength(); i++)
+ {
+ Attr attr = (Attr)attribs.item(i);
+ String uri = attr.getNamespaceURI();
+ String qname = attr.getName();
+ String value = attr.getNodeValue();
+
+ // Prevent DOMException: NAMESPACE_ERR: An attempt is made to create or
+ // change an object in a way which is incorrect with regard to namespaces.
+ if (uri == null && qname.startsWith("xmlns"))
+ {
+ log.trace("Ignore attribute: [uri=" + uri + ",qname=" +
qname + ",value=" + value + "]");
+ }
+ else
+ {
+ destElement.setAttributeNS(uri, qname, value);
+ }
+ }
+ }
+
+ /** True if the node has child elements
+ */
+ public static boolean hasChildElements(Node node)
+ {
+ NodeList nlist = node.getChildNodes();
+ for (int i = 0; i < nlist.getLength(); i++)
+ {
+ Node child = nlist.item(i);
+ if (child.getNodeType() == Node.ELEMENT_NODE)
+ return true;
+ }
+ return false;
+ }
+
+ /** Gets child elements
+ */
+ public static Iterator getChildElements(Node node)
+ {
+ ArrayList list = new ArrayList();
+ NodeList nlist = node.getChildNodes();
+ for (int i = 0; i < nlist.getLength(); i++)
+ {
+ Node child = nlist.item(i);
+ if (child.getNodeType() == Node.ELEMENT_NODE)
+ list.add(child);
+ }
+ return list.iterator();
+ }
+
+ /** Get the concatenated text content, or null.
+ */
+ public static String getTextContent(Node node)
+ {
+ boolean hasTextContent = false;
+ StringBuffer buffer = new StringBuffer();
+ NodeList nlist = node.getChildNodes();
+ for (int i = 0; i < nlist.getLength(); i++)
+ {
+ Node child = nlist.item(i);
+ if (child.getNodeType() == Node.TEXT_NODE)
+ {
+ buffer.append(child.getNodeValue());
+ hasTextContent = true;
+ }
+ }
+ return (hasTextContent ? buffer.toString() : null);
+ }
+
+ /** Gets the first child element
+ */
+ public static Element getFirstChildElement(Node node)
+ {
+ return getFirstChildElementIntern(node, null);
+ }
+
+ /** Gets the first child element for a given local name without namespace
+ */
+ public static Element getFirstChildElement(Node node, String nodeName)
+ {
+ return getFirstChildElementIntern(node, new QName(nodeName));
+ }
+
+ /** Gets the first child element for a given qname
+ */
+ public static Element getFirstChildElement(Node node, QName nodeName)
+ {
+ return getFirstChildElementIntern(node, nodeName);
+ }
+
+ private static Element getFirstChildElementIntern(Node node, QName nodeName)
+ {
+ Element childElement = null;
+ Iterator it = getChildElementsIntern(node, nodeName);
+ if (it.hasNext())
+ {
+ childElement = (Element)it.next();
+ }
+ return childElement;
+ }
+
+ /** Gets the child elements for a given local name without namespace
+ */
+ public static Iterator getChildElements(Node node, String nodeName)
+ {
+ return getChildElementsIntern(node, new QName(nodeName));
+ }
+
+ /** Gets the child element for a given qname
+ */
+ public static Iterator getChildElements(Node node, QName nodeName)
+ {
+ return getChildElementsIntern(node, nodeName);
+ }
+
+ private static Iterator getChildElementsIntern(Node node, QName nodeName)
+ {
+ ArrayList list = new ArrayList();
+ NodeList nlist = node.getChildNodes();
+ for (int i = 0; i < nlist.getLength(); i++)
+ {
+ Node child = nlist.item(i);
+ if (child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if (nodeName == null)
+ {
+ list.add(child);
+ }
+ else
+ {
+ QName qname;
+ if (nodeName.getNamespaceURI().length() > 0)
+ {
+ qname = new QName(child.getNamespaceURI(), child.getLocalName());
+ }
+ else
+ {
+ qname = new QName(child.getLocalName());
+ }
+ if (qname.equals(nodeName))
+ {
+ list.add(child);
+ }
+ }
+ }
+ }
+ return list.iterator();
+ }
+
+ /** Gets parent element or null if there is none
+ */
+ public static Element getParentElement(Node node)
+ {
+ Node parent = node.getParentNode();
+ return (parent instanceof Element ? (Element)parent : null);
+ }
+
+ /** Get the owner document that is associated with the current thread */
+ public static Document getOwnerDocument()
+ {
+ Document doc = (Document)documentThreadLocal.get();
+ if (doc == null)
+ {
+ doc = getDocumentBuilder().newDocument();
+ documentThreadLocal.set(doc);
+ }
+ return doc;
+ }
+
+ public static Element sourceToElement(Source source) throws IOException
+ {
+ Element retElement = null;
+
+ try
+ {
+ if (source instanceof StreamSource)
+ {
+ StreamSource streamSource = (StreamSource)source;
+
+ InputStream ins = streamSource.getInputStream();
+ if (ins != null)
+ {
+ retElement = DOMUtils.parse(ins);
+ }
+ else
+ {
+ Reader reader = streamSource.getReader();
+ retElement = DOMUtils.parse(new InputSource(reader));
+ }
+ }
+ else if (source instanceof DOMSource)
+ {
+ DOMSource domSource = (DOMSource)source;
+ Node node = domSource.getNode();
+ if (node instanceof Element)
+ {
+ retElement = (Element)node;
+ }
+ else if (node instanceof Document)
+ {
+ retElement = ((Document)node).getDocumentElement();
+ }
+ else
+ {
+ throw new RuntimeException("Unsupported Node type: " +
node.getClass().getName());
+ }
+ }
+ else if (source instanceof SAXSource)
+ {
+ // The fact that JAXBSource derives from SAXSource is an implementation
detail.
+ // Thus in general applications are strongly discouraged from accessing
methods defined on SAXSource.
+ // The XMLReader object obtained by the getXMLReader method shall be used
only for parsing the InputSource object returned by the getInputSource method.
+
+ TransformerFactory tf = TransformerFactory.newInstance();
+ ByteArrayOutputStream baos = new ByteArrayOutputStream(1024);
+ Transformer transformer = tf.newTransformer();
+ transformer.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION,
"yes");
+ transformer.setOutputProperty(OutputKeys.METHOD, "xml");
+ transformer.transform(source, new StreamResult(baos));
+ retElement = DOMUtils.parse(new ByteArrayInputStream(baos.toByteArray()));
+ }
+ else
+ {
+ throw new RuntimeException("Source type not implemented: " +
source.getClass().getName());
+ }
+
+ }
+ catch (TransformerException ex)
+ {
+ IOException ioex = new IOException();
+ ioex.initCause(ex);
+ throw ioex;
+ }
+
+ return retElement;
+ }
+}
Property changes on:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/DOMUtils.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Copied:
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/ObjectNameFactory.java
(from rev 3013,
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/integration/ObjectNameFactory.java)
===================================================================
---
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/ObjectNameFactory.java
(rev 0)
+++
projects/wsintegration/jbossws-spi/trunk/src/main/java/org/jboss/ws/utils/ObjectNameFactory.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.utils;
+
+import java.util.Hashtable;
+
+import javax.management.MalformedObjectNameException;
+import javax.management.ObjectName;
+
+/**
+ * A simple factory for creating safe object names.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 08-May-2006
+ */
+public class ObjectNameFactory
+{
+ public static ObjectName create(String name)
+ {
+ try
+ {
+ return new ObjectName(name);
+ }
+ catch (MalformedObjectNameException e)
+ {
+ throw new Error("Invalid ObjectName: " + name + "; " + e);
+ }
+ }
+
+ public static ObjectName create(String domain, String key, String value)
+ {
+ try
+ {
+ return new ObjectName(domain, key, value);
+ }
+ catch (MalformedObjectNameException e)
+ {
+ throw new Error("Invalid ObjectName: " + domain + "," + key
+ "," + value + "; " + e);
+ }
+ }
+
+ public static ObjectName create(String domain, Hashtable table)
+ {
+ try
+ {
+ return new ObjectName(domain, table);
+ }
+ catch (MalformedObjectNameException e)
+ {
+ throw new Error("Invalid ObjectName: " + domain + "," +
table + "; " + e);
+ }
+ }
+}
Modified: projects/wsintegration/jbossws-spi/trunk/version.properties
===================================================================
--- projects/wsintegration/jbossws-spi/trunk/version.properties 2007-05-10 07:18:41 UTC
(rev 3035)
+++ projects/wsintegration/jbossws-spi/trunk/version.properties 2007-05-10 07:33:24 UTC
(rev 3036)
@@ -20,6 +20,7 @@
jboss-common-logging-spi=2.0.2.GA
jboss-jbossxb=1.0.0.CR10
jboss-microcontainer=2.0.0.Beta3
+sun-jaxws=2.1.1
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21MBean.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21MBean.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21MBean.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -23,7 +23,7 @@
import javax.management.ObjectName;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* MBean interface.
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB3MBean.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB3MBean.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB3MBean.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -23,7 +23,7 @@
import javax.management.ObjectName;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* MBean interface.
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSEMBean.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSEMBean.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSEMBean.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -24,7 +24,7 @@
import javax.management.ObjectName;
import org.jboss.deployment.SubDeployerInterceptorMBean;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* MBean interface.
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/AbstractApplicationMetaDataAdapter.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/AbstractApplicationMetaDataAdapter.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/AbstractApplicationMetaDataAdapter.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -29,7 +29,7 @@
import org.jboss.metadata.ApplicationMetaData;
import org.jboss.metadata.BeanMetaData;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData.PublishLocationAdapter;
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ArchiveDeployerHook.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ArchiveDeployerHook.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ArchiveDeployerHook.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -28,7 +28,6 @@
import org.jboss.deployment.DeploymentException;
import org.jboss.deployment.DeploymentInfo;
-import org.jboss.ws.core.utils.DOMUtils;
import org.jboss.ws.integration.ResourceLoaderAdapter;
import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.integration.deployment.Deployment;
@@ -36,6 +35,7 @@
import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
import org.jboss.ws.metadata.webservices.WebservicesFactory;
import org.jboss.ws.metadata.webservices.WebservicesMetaData;
+import org.jboss.ws.utils.DOMUtils;
import org.jboss.xb.binding.ObjectModelFactory;
import org.jboss.xb.binding.Unmarshaller;
import org.jboss.xb.binding.UnmarshallerFactory;
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/DeploymentInfoAdapter.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/DeploymentInfoAdapter.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/DeploymentInfoAdapter.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -41,8 +41,8 @@
import org.jboss.mx.util.MBeanProxyCreationException;
import org.jboss.mx.util.MBeanServerLocator;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.ResourceLoaderAdapter;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB21.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB21.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB21.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -42,19 +42,19 @@
import org.jboss.ws.WSException;
import org.jboss.ws.core.CommonMessageContext;
import org.jboss.ws.core.EndpointInvocation;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.jaxrpc.handler.HandlerCallback;
import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
import org.jboss.ws.core.server.AbstractInvocationHandler;
import org.jboss.ws.core.soap.MessageContextAssociation;
import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.invocation.InvocationContext;
import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData.HandlerType;
import org.jboss.ws.metadata.umdm.ServerEndpointMetaData;
import org.jboss.ws.metadata.umdm.EndpointMetaData.Type;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* Handles invocations on EJB21 endpoints.
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB3.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB3.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/InvocationHandlerEJB3.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -40,16 +40,16 @@
import org.jboss.ws.WSException;
import org.jboss.ws.core.CommonMessageContext;
import org.jboss.ws.core.EndpointInvocation;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
import org.jboss.ws.core.jaxws.WebServiceContextEJB;
import org.jboss.ws.core.jaxws.handler.SOAPMessageContextJAXWS;
import org.jboss.ws.core.server.AbstractInvocationHandler;
import org.jboss.ws.core.soap.MessageContextAssociation;
import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.invocation.InvocationContext;
import org.jboss.ws.metadata.umdm.ServerEndpointMetaData;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* Handles invocations on EJB3 endpoints.
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookEJB21.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookEJB21.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookEJB21.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -28,7 +28,6 @@
import org.jboss.metadata.BeanMetaData;
import org.jboss.ws.integration.Endpoint;
import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
import org.jboss.ws.integration.Service;
import org.jboss.ws.integration.deployment.Deployment;
import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
@@ -36,6 +35,7 @@
import org.jboss.ws.metadata.webservices.PortComponentMetaData;
import org.jboss.ws.metadata.webservices.WebserviceDescriptionMetaData;
import org.jboss.ws.metadata.webservices.WebservicesMetaData;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* A deployer JAXRPC EJB21 Endpoints
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookJSE.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookJSE.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXRPCDeployerHookJSE.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -31,7 +31,6 @@
import org.jboss.metadata.WebMetaData;
import org.jboss.ws.integration.Endpoint;
import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
import org.jboss.ws.integration.Service;
import org.jboss.ws.integration.deployment.Deployment;
import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
@@ -39,6 +38,7 @@
import org.jboss.ws.metadata.webservices.PortComponentMetaData;
import org.jboss.ws.metadata.webservices.WebserviceDescriptionMetaData;
import org.jboss.ws.metadata.webservices.WebservicesMetaData;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* A deployer JAXRPC JSE Endpoints
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookEJB3.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookEJB3.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookEJB3.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -32,11 +32,11 @@
import org.jboss.ejb3.stateless.StatelessContainer;
import org.jboss.ws.integration.Endpoint;
import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
import org.jboss.ws.integration.Service;
import org.jboss.ws.integration.deployment.Deployment;
import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* A deployer JAXWS EJB3 Endpoints
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookJSE.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookJSE.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/JAXWSDeployerHookJSE.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -37,13 +37,13 @@
import org.jboss.metadata.WebMetaData;
import org.jboss.ws.integration.Endpoint;
import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
import org.jboss.ws.integration.ResourceLoaderAdapter;
import org.jboss.ws.integration.Service;
import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.integration.deployment.Deployment;
import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* A deployer JAXWS JSE Endpoints
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ModifyWebMetaDataDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ModifyWebMetaDataDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ModifyWebMetaDataDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -24,9 +24,9 @@
//$Id$
import org.jboss.ws.core.deployment.ServiceEndpointPublisher;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.AbstractDeployer;
import org.jboss.ws.integration.deployment.Deployment;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
/**
* A deployer that modifies the web.xml meta data
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB21.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB21.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB21.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -29,9 +29,9 @@
import org.jboss.logging.Logger;
import org.jboss.metadata.ApplicationMetaData;
import org.jboss.metadata.AssemblyDescriptorMetaData;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.ServiceEndpointGeneratorEJB;
-import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
+import org.jboss.ws.utils.DOMUtils;
import org.w3c.dom.Element;
/**
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB3.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB3.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointGeneratorEJB3.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -34,9 +34,9 @@
import org.jboss.mx.util.MBeanProxyCreationException;
import org.jboss.mx.util.MBeanServerLocator;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.ServiceEndpointGeneratorEJB;
-import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
+import org.jboss.ws.utils.DOMUtils;
import org.w3c.dom.Element;
/**
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointInterceptor.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointInterceptor.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/ServiceEndpointInterceptor.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -36,8 +36,8 @@
import org.jboss.ws.core.jaxrpc.SOAPFaultHelperJAXRPC;
import org.jboss.ws.core.jaxrpc.handler.HandlerCallback;
import org.jboss.ws.core.soap.MessageContextAssociation;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData.HandlerType;
import org.jboss.ws.metadata.umdm.OperationMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
/**
* This Interceptor does the ws4ee handler processing.
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/UnifiedDeploymentInfoDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/UnifiedDeploymentInfoDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/UnifiedDeploymentInfoDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -35,11 +35,11 @@
import org.jboss.mx.util.MBeanProxyCreationException;
import org.jboss.mx.util.MBeanServerLocator;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.deployment.JAXRPCDeployment;
-import org.jboss.ws.core.deployment.JAXWSDeployment;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.AbstractDeployer;
import org.jboss.ws.integration.deployment.Deployment;
+import org.jboss.ws.integration.deployment.JAXRPCDeployment;
+import org.jboss.ws.integration.deployment.JAXWSDeployment;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppDeployerDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppDeployerDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppDeployerDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -34,9 +34,9 @@
import org.jboss.mx.util.MBeanProxyCreationException;
import org.jboss.mx.util.MBeanServerLocator;
import org.jboss.ws.core.deployment.ServiceEndpointPublisher;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.Deployer;
import org.jboss.ws.integration.deployment.Deployment;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.WSDeploymentException;
/**
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppGeneratorDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppGeneratorDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebAppGeneratorDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -23,9 +23,9 @@
//$Id$
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.AbstractDeployer;
import org.jboss.ws.integration.deployment.Deployment;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.metadata.umdm.UnifiedMetaData;
/**
Modified:
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebMetaDataAdapter.java
===================================================================
---
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebMetaDataAdapter.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss42/trunk/src/main/java/org/jboss/ws/integration/jboss42/jbossws/WebMetaDataAdapter.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -33,7 +33,7 @@
import org.jboss.metadata.WebMetaData;
import org.jboss.metadata.WebSecurityMetaData;
import org.jboss.metadata.WebSecurityMetaData.WebResourceCollection;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.metadata.j2ee.UnifiedWebMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedWebSecurityMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedWebMetaData.PublishLocationAdapter;
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/etc/ant-import/build-deploy.xml
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/etc/ant-import/build-deploy.xml 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/etc/ant-import/build-deploy.xml 2007-05-10
07:33:24 UTC (rev 3036)
@@ -29,11 +29,13 @@
</fileset>
</copy>
<copy todir="${jboss50.home}/client" overwrite="true">
- <fileset dir="${thirdparty.dir}">
+ <fileset dir="${thirdparty.dir}/jbossws-core">
<include name="jboss-jaxrpc.jar"/>
<include name="jboss-jaxws.jar"/>
<include name="jboss-saaj.jar"/>
<include name="jbossws-client.jar"/>
+ </fileset>
+ <fileset dir="${thirdparty.dir}">
<include name="jaxb-api.jar"/>
<include name="jaxb-impl.jar"/>
<include name="jaxb-xjc.jar"/>
@@ -42,7 +44,10 @@
</fileset>
</copy>
<copy todir="${jboss50.home}/server/${jboss.server.instance}/lib"
overwrite="true">
- <fileset dir="${thirdparty.dir}">
+ <fileset dir="${thirdparty.dir}/jbossws-spi">
+ <include name="jbossws-spi.jar"/>
+ </fileset>
+ <fileset dir="${thirdparty.dir}/jbossws-core">
<include name="jboss-jaxrpc.jar"/>
<include name="jboss-jaxws.jar"/>
<include name="jboss-saaj.jar"/>
Property changes on:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50
___________________________________________________________________
Name: svn:externals
+
common
https://svn.jboss.org/repos/jbossws/projects/wsintegration/sunri-jboss50/...
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/AbstractWebServiceDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/AbstractWebServiceDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/AbstractWebServiceDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,72 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import org.jboss.deployers.plugins.deployer.AbstractSimpleDeployer;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.logging.Logger;
-
-//$Id$
-
-/**
- * This deployer that calls the registered DeployerHooks
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 24-Apr-2007
- */
-public abstract class AbstractWebServiceDeployer extends AbstractSimpleDeployer
-{
- // provide logging
- private static final Logger log = Logger.getLogger(AbstractWebServiceDeployer.class);
-
- private List<DeployerHook> deployerHooks = new
LinkedList<DeployerHook>();
-
- public void addDeployerHook(DeployerHook deployer)
- {
- log.debug("Add deployer hook: " + deployer);
- deployerHooks.add(deployer);
- }
-
- public void removeDeployerHook(DeployerHook deployer)
- {
- log.debug("Remove deployer hook: " + deployer);
- deployerHooks.remove(deployer);
- }
-
- @Override
- public void deploy(DeploymentUnit unit) throws DeploymentException
- {
- for (DeployerHook deployer : deployerHooks)
- deployer.deploy(unit);
- }
-
- @Override
- public void undeploy(DeploymentUnit unit)
- {
- for (DeployerHook deployer : deployerHooks)
- deployer.undeploy(unit);
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/DeployerHook.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/DeployerHook.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/DeployerHook.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,40 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50;
-
-//$Id$
-
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-
-/**
- * An interface for all web service deployer hooks
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 24-Apr-2007
- */
-public interface DeployerHook
-{
- void deploy(DeploymentUnit unit) throws DeploymentException;
-
- void undeploy(DeploymentUnit unit);
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerEJB.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerEJB.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerEJB.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,53 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50;
-
-//$Id$
-
-/**
- * This web service deployer for EJB
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 24-Apr-2007
- */
-public class WebServiceDeployerEJB extends AbstractWebServiceDeployer
-{
- private int relOrderEJB2x;
- private int relOrderEJB3;
-
- public void setRelOrderEJB2x(int relOrderEJB2x)
- {
- this.relOrderEJB2x = relOrderEJB2x;
- }
-
- public void setRelOrderEJB3(int relOrderEJB3)
- {
- this.relOrderEJB3 = relOrderEJB3;
- }
-
- @Override
- public int getRelativeOrder()
- {
- return Math.max(relOrderEJB2x, relOrderEJB3) + 1;
- }
-
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerJSE.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerJSE.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceDeployerJSE.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,46 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50;
-
-//$Id$
-
-/**
- * This web service deployer for JSE
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 24-Apr-2007
- */
-public class WebServiceDeployerJSE extends AbstractWebServiceDeployer
-{
- private int relOrderWar;
-
- public void setRelOrderWar(int relOrderWar)
- {
- this.relOrderWar = relOrderWar;
- }
-
- @Override
- public int getRelativeOrder()
- {
- return relOrderWar - 1;
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceMainDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceMainDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/WebServiceMainDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,52 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50;
-
-//$Id$
-
-/**
- * The main web service deployer
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 24-Apr-2007
- */
-public class WebServiceMainDeployer extends AbstractWebServiceDeployer
-{
- private int relOrderJSE;
- private int relOrderEJB;
-
- public void setRelOrderEJB(int relOrderEJB)
- {
- this.relOrderEJB = relOrderEJB;
- }
-
- public void setRelOrderJSE(int relOrderJSE)
- {
- this.relOrderJSE = relOrderJSE;
- }
-
- @Override
- public int getRelativeOrder()
- {
- return Math.max(relOrderEJB, relOrderJSE) + 1;
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHook.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHook.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHook.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,61 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.logging.Logger;
-import org.jboss.ws.integration.deployment.DeployerManager;
-import org.jboss.ws.integration.jboss50.DeployerHook;
-
-/**
- * An abstract web service deployer.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public abstract class AbstractDeployerHook implements DeployerHook
-{
- // provide logging
- protected final Logger log = Logger.getLogger(getClass());
-
- protected DeployerManager deployerManager;
-
- public DeployerManager getDeployerManager()
- {
- return deployerManager;
- }
-
- public void setDeployerManager(DeployerManager deploymentManager)
- {
- this.deployerManager = deploymentManager;
- }
-
- /** Return true if this deployment should be ignored
- */
- public boolean ignoreDeployment(DeploymentUnit unit)
- {
- String name = unit.getName();
- return (name.startsWith("jboss:id=") &&
name.indexOf("service=jacc") > 0);
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookEJB.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookEJB.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookEJB.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,34 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-/**
- * An abstract deployer for EJB Endpoints
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public abstract class AbstractDeployerHookEJB extends ArchiveDeployerHook
-{
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookJSE.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookJSE.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/AbstractDeployerHookJSE.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,44 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.metadata.WebMetaData;
-
-//$Id$
-
-/**
- * An abstract deployer for JSE Endpoints
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public abstract class AbstractDeployerHookJSE extends ArchiveDeployerHook
-{
- public boolean isWebServiceDeployment(DeploymentUnit unit)
- {
- if (unit.getAttachment(WebMetaData.class) == null)
- return false;
-
- return true;
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptor.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptor.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptor.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,163 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-// $Id$
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.logging.Logger;
-import org.jboss.metadata.ApplicationMetaData;
-import org.jboss.metadata.BeanMetaData;
-import org.jboss.metadata.EjbPortComponentMetaData;
-import org.jboss.metadata.MessageDrivenMetaData;
-import org.jboss.metadata.SessionMetaData;
-import org.jboss.metadata.ApplicationMetaData.WebserviceDescription;
-import org.jboss.metadata.ApplicationMetaData.Webservices;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
-import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedEjbPortComponentMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedMessageDrivenMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedSessionMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData.PublishLocationAdapter;
-
-/**
- * Build container independent application meta data
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class ApplicationMetaDataAdaptor
-{
- // logging support
- private static Logger log = Logger.getLogger(ApplicationMetaDataAdaptor.class);
-
- public static UnifiedApplicationMetaData
buildUnifiedApplicationMetaData(UnifiedDeploymentInfo udi, DeploymentUnit unit)
- {
- ApplicationMetaData appMetaData = unit.getAttachment(ApplicationMetaData.class);
- udi.addAttachment(ApplicationMetaData.class, appMetaData);
-
- UnifiedApplicationMetaData umd = new UnifiedApplicationMetaData();
- buildUnifiedBeanMetaData(umd, appMetaData);
- buildWebservicesMetaData(umd, appMetaData);
- umd.setSecurityDomain(appMetaData.getSecurityDomain());
- return umd;
- }
-
- private static void buildWebservicesMetaData(UnifiedApplicationMetaData umd,
ApplicationMetaData apmd)
- {
- Webservices webservices = apmd.getWebservices();
- if (webservices != null)
- {
- String contextRoot = webservices.getContextRoot();
- umd.setPublishLocationAdapter(getPublishLocationAdpater(webservices));
-
- List<WebserviceDescription> wsDescriptions =
webservices.getWebserviceDescriptions();
- if (wsDescriptions.size() > 1)
- log.warn("Multiple <webservice-description> elements not
supported");
-
- if (wsDescriptions.size() > 0)
- {
- WebserviceDescription wsd = wsDescriptions.get(0);
- umd.setConfigName(wsd.getConfigName());
- umd.setConfigFile(wsd.getConfigFile());
- }
-
- umd.setWebServiceContextRoot(contextRoot);
- }
- }
-
- private static PublishLocationAdapter getPublishLocationAdpater(final Webservices
webservices)
- {
- return new PublishLocationAdapter()
- {
- public String getWsdlPublishLocationByName(String name)
- {
- String wsdlPublishLocation = null;
- for (WebserviceDescription wsd : webservices.getWebserviceDescriptions())
- {
- if (wsd.getDescriptionName().equals(name))
- {
- wsdlPublishLocation = wsd.getWsdlPublishLocation();
- }
- }
- return wsdlPublishLocation;
- }
- };
- }
-
- private static void buildUnifiedBeanMetaData(UnifiedApplicationMetaData umd,
ApplicationMetaData appMetaData)
- {
- List<UnifiedBeanMetaData> beans = new
ArrayList<UnifiedBeanMetaData>();
- Iterator it = appMetaData.getEnterpriseBeans();
- while (it.hasNext())
- {
- BeanMetaData bmd = (BeanMetaData)it.next();
- buildUnifiedBeanMetaData(beans, bmd);
- }
- umd.setEnterpriseBeans(beans);
- }
-
- private static UnifiedBeanMetaData
buildUnifiedBeanMetaData(List<UnifiedBeanMetaData> beans, BeanMetaData bmd)
- {
- UnifiedBeanMetaData ubmd = null;
- if (bmd instanceof SessionMetaData)
- {
- ubmd = new UnifiedSessionMetaData();
- }
- else if (bmd instanceof MessageDrivenMetaData)
- {
- ubmd = new UnifiedMessageDrivenMetaData();
-
((UnifiedMessageDrivenMetaData)ubmd).setDestinationJndiName(((MessageDrivenMetaData)bmd).getDestinationJndiName());
- }
-
- if (ubmd != null)
- {
- ubmd.setEjbName(bmd.getEjbName());
- ubmd.setEjbClass(bmd.getEjbClass());
- ubmd.setServiceEndpointInterface(bmd.getServiceEndpoint());
- ubmd.setHome(bmd.getHome());
- ubmd.setLocalHome(bmd.getLocalHome());
- ubmd.setJndiName(bmd.getJndiName());
- ubmd.setLocalJndiName(bmd.getLocalJndiName());
-
- EjbPortComponentMetaData pcmd = bmd.getPortComponent();
- if (pcmd != null)
- {
- UnifiedEjbPortComponentMetaData upcmd = new
UnifiedEjbPortComponentMetaData();
- upcmd.setPortComponentName(pcmd.getPortComponentName());
- upcmd.setPortComponentURI(pcmd.getPortComponentURI());
- upcmd.setAuthMethod(pcmd.getAuthMethod());
- upcmd.setTransportGuarantee(pcmd.getTransportGuarantee());
- upcmd.setSecureWSDLAccess(pcmd.getSecureWSDLAccess());
- ubmd.setPortComponent(upcmd);
- }
-
- beans.add(ubmd);
- }
- return ubmd;
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptorEJB3.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptorEJB3.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ApplicationMetaDataAdaptorEJB3.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,167 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-// $Id$
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.ejb3.Container;
-import org.jboss.ejb3.EJBContainer;
-import org.jboss.ejb3.Ejb3Deployment;
-import org.jboss.ejb3.SessionContainer;
-import org.jboss.ejb3.mdb.MessagingContainer;
-import org.jboss.ejb3.metamodel.Ejb3PortComponent;
-import org.jboss.ejb3.metamodel.EjbJarDD;
-import org.jboss.ejb3.metamodel.EnterpriseBean;
-import org.jboss.ejb3.metamodel.WebserviceDescription;
-import org.jboss.ejb3.metamodel.Webservices;
-import org.jboss.logging.Logger;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
-import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedEjbPortComponentMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedMessageDrivenMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedSessionMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData.PublishLocationAdapter;
-
-/**
- * Build container independent application meta data
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 14-Apr-2007
- */
-public class ApplicationMetaDataAdaptorEJB3
-{
- // logging support
- private static Logger log = Logger.getLogger(ApplicationMetaDataAdaptorEJB3.class);
-
- public static UnifiedApplicationMetaData
buildUnifiedApplicationMetaData(UnifiedDeploymentInfo udi, DeploymentUnit unit)
- {
- Ejb3Deployment ejb3Deployment = unit.getAttachment(Ejb3Deployment.class);
- udi.addAttachment(Ejb3Deployment.class, ejb3Deployment);
-
- EjbJarDD jarDD = unit.getAttachment(EjbJarDD.class);
- UnifiedApplicationMetaData umd = new UnifiedApplicationMetaData();
- buildUnifiedBeanMetaData(umd, ejb3Deployment);
- buildWebservicesMetaData(umd, jarDD);
- return umd;
- }
-
- private static void buildWebservicesMetaData(UnifiedApplicationMetaData umd, EjbJarDD
jarDD)
- {
- // nothing to do
- if (jarDD == null)
- return;
-
- Webservices webservices = jarDD.getWebservices();
- if (webservices != null)
- {
- String contextRoot = webservices.getContextRoot();
- umd.setPublishLocationAdapter(getPublishLocationAdpater(webservices));
-
- List<WebserviceDescription> wsDescriptions =
webservices.getWebserviceDescriptions();
- if (wsDescriptions.size() > 1)
- log.warn("Multiple <webservice-description> elements not
supported");
-
- if (wsDescriptions.size() > 0)
- {
- WebserviceDescription wsd = wsDescriptions.get(0);
- umd.setConfigName(wsd.getConfigName());
- umd.setConfigFile(wsd.getConfigFile());
-
- // com/sun/ts/tests/webservices12/ejb/annotations/WSEjbWebServiceRefTest1
- // WSEjbWebServiceRefTest1VerifyTargetEndpointAddress
- if (contextRoot == null)
- contextRoot = "/" + wsd.getDescriptionName();
- }
-
- umd.setWebServiceContextRoot(contextRoot);
- }
- }
-
- private static void buildUnifiedBeanMetaData(UnifiedApplicationMetaData umd,
Ejb3Deployment ejb3Deployment)
- {
- List<UnifiedBeanMetaData> ubmdList = new
ArrayList<UnifiedBeanMetaData>();
- Iterator<Container> it =
ejb3Deployment.getEjbContainers().values().iterator();
- while (it.hasNext())
- {
- EJBContainer container = (EJBContainer)it.next();
- UnifiedBeanMetaData ubmd = null;
- if (container instanceof SessionContainer)
- {
- ubmd = new UnifiedSessionMetaData();
- }
- else if (container instanceof MessagingContainer)
- {
- ubmd = new UnifiedMessageDrivenMetaData();
- log.warn("No implemented: initialize MDB destination");
-
//((UnifiedMessageDrivenMetaData)ubmd).setDestinationJndiName(((MessagingContainer)container).getDestination());
- }
-
- if (ubmd != null)
- {
- ubmd.setEjbName(container.getEjbName());
- ubmd.setEjbClass(container.getBeanClassName());
-
- EnterpriseBean bean = container.getXml();
- Ejb3PortComponent pcMetaData = (bean != null ? bean.getPortComponent() :
null);
- if (pcMetaData != null)
- {
- UnifiedEjbPortComponentMetaData ejbPortComp = new
UnifiedEjbPortComponentMetaData();
- ejbPortComp.setPortComponentName(pcMetaData.getPortComponentName());
- ejbPortComp.setPortComponentURI(pcMetaData.getPortComponentURI());
- ejbPortComp.setAuthMethod(pcMetaData.getAuthMethod());
- ejbPortComp.setTransportGuarantee(pcMetaData.getTransportGuarantee());
- ejbPortComp.setSecureWSDLAccess(pcMetaData.getSecureWSDLAccess());
-
- ubmd.setPortComponent(ejbPortComp);
- }
-
- ubmdList.add(ubmd);
- }
- }
- umd.setEnterpriseBeans(ubmdList);
- }
-
- private static PublishLocationAdapter getPublishLocationAdpater(final Webservices
webservices)
- {
- return new PublishLocationAdapter()
- {
- public String getWsdlPublishLocationByName(String name)
- {
- String wsdlPublishLocation = null;
- for (WebserviceDescription wsd : webservices.getWebserviceDescriptions())
- {
- if (wsd.getDescriptionName().equals(name))
- {
- wsdlPublishLocation = wsd.getWsdlPublishLocation();
- }
- }
- return wsdlPublishLocation;
- }
- };
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ArchiveDeployerHook.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ArchiveDeployerHook.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ArchiveDeployerHook.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,149 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import java.net.URL;
-
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.virtual.VirtualFile;
-import org.jboss.ws.core.utils.DOMUtils;
-import org.jboss.ws.integration.UnifiedVirtualFile;
-import org.jboss.ws.integration.deployment.Deployment;
-import org.jboss.ws.integration.deployment.WSDeploymentException;
-import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
-import org.jboss.ws.metadata.webservices.WebservicesFactory;
-import org.jboss.ws.metadata.webservices.WebservicesMetaData;
-import org.jboss.xb.binding.ObjectModelFactory;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.w3c.dom.Element;
-
-/**
- * An abstract web service deployer.
- *
- * deploy(unit)
- * if(isWebServiceDeployment)
- * dep = createDeployment(unit)
- * deploy(dep)
- *
- * undeploy(unit)
- * dep = getDeployment(unit)
- * undeploy(dep)
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public abstract class ArchiveDeployerHook extends AbstractDeployerHook
-{
- /** Get the deployemnt type this deployer can handle
- */
- public abstract DeploymentType getDeploymentType();
-
- /** Depending on the type of deployment, this method should return true
- * if the deployment contains web service endpoints.
- */
- public abstract boolean isWebServiceDeployment(DeploymentUnit unit);
-
- /** Create the Deployment for a given DeploymentUnit
- */
- public abstract Deployment createDeployment(DeploymentUnit unit);
-
- /** Get the Deployment for a given DeploymentUnit
- */
- public Deployment getDeployment(DeploymentUnit unit)
- {
- Deployment dep = unit.getAttachment(Deployment.class);
- return (dep != null && dep.getType() == getDeploymentType() ? dep : null);
- }
-
- public void deploy(DeploymentUnit unit) throws DeploymentException
- {
- if (ignoreDeployment(unit))
- return;
-
- if (isWebServiceDeployment(unit))
- {
- log.debug("deploy: " + unit.getName());
- Deployment dep = getDeployment(unit);
- if (dep == null)
- {
- dep = createDeployment(unit);
- dep.getContext().addAttachment(DeploymentUnit.class, unit);
- }
-
- deployerManager.deploy(dep);
- unit.addAttachment(Deployment.class, dep);
- }
- }
-
- public void undeploy(DeploymentUnit unit)
- {
- if (ignoreDeployment(unit))
- return;
-
- Deployment dep = getDeployment(unit);
- if (dep != null)
- {
- log.debug("undeploy: " + unit.getName());
- deployerManager.undeploy(dep);
- unit.removeAttachment(Deployment.class);
- }
- }
-
- /** Unmrashall the webservices.xml if there is one
- */
- protected WebservicesMetaData getWebservicesMetaData(DeploymentUnit unit)
- {
- WebservicesMetaData wsMetaData = unit.getAttachment(WebservicesMetaData.class);
- UnifiedVirtualFile vfWebservices = getWebservicesFile(unit);
- if (wsMetaData == null && vfWebservices != null)
- {
- try
- {
- URL wsURL = vfWebservices.toURL();
- Element root = DOMUtils.parse(wsURL.openStream());
- String namespaceURI = root.getNamespaceURI();
- if (
namespaceURI.equals("http://java.sun.com/xml/ns/j2ee"))
- {
- Unmarshaller unmarshaller =
UnmarshallerFactory.newInstance().newUnmarshaller();
- ObjectModelFactory factory = new WebservicesFactory(wsURL);
- wsMetaData =
(WebservicesMetaData)unmarshaller.unmarshal(wsURL.openStream(), factory, null);
- unit.addAttachment(WebservicesMetaData.class, wsMetaData);
- }
- }
- catch (Exception ex)
- {
- throw new WSDeploymentException(ex);
- }
- }
- return wsMetaData;
- }
-
- private UnifiedVirtualFile getWebservicesFile(DeploymentUnit unit)
- {
- VirtualFile vf = unit.getMetaDataFile("webservices.xml");
- return (vf != null ? new VirtualFileAdaptor(vf) : null);
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/DeploymentInfoAdapter.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/DeploymentInfoAdapter.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/DeploymentInfoAdapter.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,97 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-import java.net.URL;
-import java.net.URLClassLoader;
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.ejb3.Ejb3Deployment;
-import org.jboss.logging.Logger;
-import org.jboss.metadata.ApplicationMetaData;
-import org.jboss.metadata.WebMetaData;
-import org.jboss.ws.WSException;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
-
-// $Id$
-
-/**
- * Build container independent deployment info.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class DeploymentInfoAdapter
-{
- // logging support
- private static Logger log = Logger.getLogger(DeploymentInfoAdapter.class);
-
- public static void buildDeploymentInfo(UnifiedDeploymentInfo udi, DeploymentUnit
unit)
- {
- udi.addAttachment(DeploymentUnit.class, unit);
-
- try
- {
- if (unit.getDeploymentContext().getParent() != null)
- {
- udi.parent = new UnifiedDeploymentInfo(null);
- buildDeploymentInfo(udi.parent,
unit.getDeploymentContext().getParent().getDeploymentUnit());
- }
-
- udi.vfRoot = new VirtualFileAdaptor(unit.getDeploymentContext().getRoot());
-
- udi.name = unit.getName();
- udi.simpleName = unit.getSimpleName();
- udi.url = udi.vfRoot.toURL();
-
- buildMetaData(udi, unit);
-
- // Since we create temporary classes, we need to create a delegate loader
- // This prevents CCE problems where the parent loader is available at deploy
time,
- // and a child loader is available at start time.
- udi.classLoader = new URLClassLoader(new URL[] {}, unit.getClassLoader());
-
- log.debug("UnifiedDeploymentInfo:\n" + udi);
- }
- catch (Exception ex)
- {
- WSException.rethrow(ex.getMessage(), ex);
- }
- }
-
- private static void buildMetaData(UnifiedDeploymentInfo udi, DeploymentUnit unit)
throws Exception
- {
- if (unit.getAttachment(Ejb3Deployment.class) != null)
- {
- udi.metaData =
ApplicationMetaDataAdaptorEJB3.buildUnifiedApplicationMetaData(udi, unit);
- }
- else if (unit.getAttachment(ApplicationMetaData.class) != null)
- {
- udi.metaData = ApplicationMetaDataAdaptor.buildUnifiedApplicationMetaData(udi,
unit);
- }
- else if (unit.getAttachment(WebMetaData.class) != null)
- {
- udi.metaData = WebMetaDataAdaptor.buildUnifiedWebMetaData(udi, unit);
- udi.webappURL = udi.vfRoot.toURL();
- }
- }
-}
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB21.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB21.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB21.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -42,19 +42,19 @@
import org.jboss.ws.WSException;
import org.jboss.ws.core.CommonMessageContext;
import org.jboss.ws.core.EndpointInvocation;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.jaxrpc.handler.HandlerCallback;
import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
import org.jboss.ws.core.server.AbstractInvocationHandler;
import org.jboss.ws.core.soap.MessageContextAssociation;
import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.invocation.InvocationContext;
import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData.HandlerType;
import org.jboss.ws.metadata.umdm.ServerEndpointMetaData;
import org.jboss.ws.metadata.umdm.EndpointMetaData.Type;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* Handles invocations on EJB21 endpoints.
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB3.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB3.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/InvocationHandlerEJB3.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -40,16 +40,16 @@
import org.jboss.ws.WSException;
import org.jboss.ws.core.CommonMessageContext;
import org.jboss.ws.core.EndpointInvocation;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
import org.jboss.ws.core.jaxws.WebServiceContextEJB;
import org.jboss.ws.core.jaxws.handler.SOAPMessageContextJAXWS;
import org.jboss.ws.core.server.AbstractInvocationHandler;
import org.jboss.ws.core.soap.MessageContextAssociation;
import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.invocation.InvocationContext;
import org.jboss.ws.metadata.umdm.ServerEndpointMetaData;
+import org.jboss.ws.utils.ObjectNameFactory;
/**
* Handles invocations on EJB3 endpoints.
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookEJB21.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookEJB21.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookEJB21.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,116 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.metadata.ApplicationMetaData;
-import org.jboss.metadata.BeanMetaData;
-import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
-import org.jboss.ws.integration.Service;
-import org.jboss.ws.integration.deployment.Deployment;
-import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
-import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
-import org.jboss.ws.metadata.webservices.PortComponentMetaData;
-import org.jboss.ws.metadata.webservices.WebserviceDescriptionMetaData;
-import org.jboss.ws.metadata.webservices.WebservicesMetaData;
-
-/**
- * A deployer JAXRPC EJB21 Endpoints
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public class JAXRPCDeployerHookEJB21 extends AbstractDeployerHookEJB
-{
- /** Get the deployemnt type this deployer can handle
- */
- public DeploymentType getDeploymentType()
- {
- return DeploymentType.JAXRPC_EJB21;
- }
-
- @Override
- public Deployment createDeployment(DeploymentUnit unit)
- {
- Deployment dep = new BasicDeploymentImpl();
- dep.setType(getDeploymentType());
- dep.setClassLoader(unit.getClassLoader());
-
- Service service = dep.getService();
-
- ApplicationMetaData appmd = unit.getAttachment(ApplicationMetaData.class);
- if (appmd == null)
- throw new IllegalStateException("Deployment unit does not contain
application meta data");
-
- WebservicesMetaData wsMetaData = getWebservicesMetaData(unit);
- if (wsMetaData == null)
- throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
-
- // Copy the attachments
- dep.getContext().addAttachment(WebservicesMetaData.class, wsMetaData);
- dep.getContext().addAttachment(ApplicationMetaData.class, appmd);
-
- for (WebserviceDescriptionMetaData wsd : wsMetaData.getWebserviceDescriptions())
- {
- for (PortComponentMetaData pcmd : wsd.getPortComponents())
- {
- String ejbLink = pcmd.getEjbLink();
- if (ejbLink == null)
- throw new IllegalStateException("ejb-link cannot be null");
-
- BeanMetaData beanMetaData = appmd.getBeanByEjbName(ejbLink);
- if (beanMetaData == null)
- throw new IllegalStateException("Cannot obtain bean meta data for:
" + ejbLink);
-
- String ejbClass = beanMetaData.getEjbClass();
- try
- {
- ClassLoader loader = unit.getClassLoader();
- Class<?> epBean = loader.loadClass(ejbClass.trim());
-
- // Create the endpoint
- Endpoint endpoint = new BasicEndpoint(service, epBean);
- String nameStr = Endpoint.SEPID_DOMAIN + ":" +
Endpoint.SEPID_PROPERTY_ENDPOINT + "=" + ejbLink;
- endpoint.setName(ObjectNameFactory.create(nameStr));
-
- service.addEndpoint(endpoint);
- }
- catch (ClassNotFoundException ex)
- {
- log.warn("Cannot load servlet class: " + ejbClass);
- }
- }
- }
- return dep;
- }
-
- @Override
- public boolean isWebServiceDeployment(DeploymentUnit unit)
- {
- WebservicesMetaData wsMetaData = getWebservicesMetaData(unit);
- return wsMetaData != null &&
unit.getAllMetaData(ApplicationMetaData.class).size() > 0;
- }
-}
\ No newline at end of file
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookJSE.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookJSE.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXRPCDeployerHookJSE.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,133 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.metadata.WebMetaData;
-import org.jboss.metadata.web.Servlet;
-import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
-import org.jboss.ws.integration.Service;
-import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
-import org.jboss.ws.integration.deployment.Deployment;
-import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
-import org.jboss.ws.metadata.webservices.PortComponentMetaData;
-import org.jboss.ws.metadata.webservices.WebserviceDescriptionMetaData;
-import org.jboss.ws.metadata.webservices.WebservicesMetaData;
-
-/**
- * A deployer JAXRPC JSE Endpoints
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public class JAXRPCDeployerHookJSE extends AbstractDeployerHookJSE
-{
- /** Get the deployemnt type this deployer can handle
- */
- public DeploymentType getDeploymentType()
- {
- return DeploymentType.JAXRPC_JSE;
- }
-
- /**
- * Create an endpoint for every servlet-link in webservices.xml
- */
- @Override
- public Deployment createDeployment(DeploymentUnit unit)
- {
- Deployment dep = new BasicDeploymentImpl();
- dep.setType(getDeploymentType());
- dep.setClassLoader(unit.getClassLoader());
-
- Service service = dep.getService();
-
- WebMetaData webMetaData = unit.getAttachment(WebMetaData.class);
- if (webMetaData == null)
- throw new IllegalStateException("Deployment unit does not contain web meta
data");
-
- WebservicesMetaData wsMetaData = getWebservicesMetaData(unit);
- if (wsMetaData == null)
- throw new IllegalStateException("Deployment unit does not contain
webservices meta data");
-
- // Copy the attachments
- dep.getContext().addAttachment(WebservicesMetaData.class, wsMetaData);
- dep.getContext().addAttachment(WebMetaData.class, webMetaData);
-
- for (WebserviceDescriptionMetaData wsd : wsMetaData.getWebserviceDescriptions())
- {
- for (PortComponentMetaData pcmd : wsd.getPortComponents())
- {
- String servletLink = pcmd.getServletLink();
- if (servletLink == null)
- throw new IllegalStateException("servlet-link cannot be null");
-
- Servlet servlet = getServletForName(webMetaData, servletLink);
- String servletClass = servlet.getServletClass();
-
- try
- {
- ClassLoader loader = unit.getClassLoader();
- Class<?> epBean = loader.loadClass(servletClass.trim());
-
- // Create the endpoint
- Endpoint endpoint = new BasicEndpoint(service, epBean);
- String nameStr = Endpoint.SEPID_DOMAIN + ":" +
Endpoint.SEPID_PROPERTY_ENDPOINT + "=" + servletLink;
- endpoint.setName(ObjectNameFactory.create(nameStr));
-
- service.addEndpoint(endpoint);
- }
- catch (ClassNotFoundException ex)
- {
- log.warn("Cannot load servlet class: " + servletClass);
- }
- }
- }
-
- return dep;
- }
-
- private Servlet getServletForName(WebMetaData wmd, String servletLink)
- {
- for (Servlet servlet : wmd.getServlets())
- {
- if (servletLink.equals(servlet.getName()))
- {
- return servlet;
- }
- }
- throw new IllegalStateException("Cannot find servlet for link: " +
servletLink);
- }
-
- @Override
- public boolean isWebServiceDeployment(DeploymentUnit unit)
- {
- if (super.isWebServiceDeployment(unit) == false)
- return false;
-
- WebservicesMetaData wsMetaData = getWebservicesMetaData(unit);
- return wsMetaData != null;
- }
-}
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookEJB3.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookEJB3.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookEJB3.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,129 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import java.util.Iterator;
-
-import javax.jws.WebService;
-import javax.xml.ws.WebServiceProvider;
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.ejb3.EJBContainer;
-import org.jboss.ejb3.Ejb3Deployment;
-import org.jboss.ejb3.stateless.StatelessContainer;
-import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
-import org.jboss.ws.integration.Service;
-import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
-import org.jboss.ws.integration.deployment.Deployment;
-import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
-
-/**
- * A deployer JAXWS EJB3 Endpoints
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public class JAXWSDeployerHookEJB3 extends AbstractDeployerHookEJB
-{
- /** Get the deployemnt type this deployer can handle
- */
- public DeploymentType getDeploymentType()
- {
- return DeploymentType.JAXWS_EJB3;
- }
-
- @Override
- public Deployment createDeployment(DeploymentUnit unit)
- {
- Deployment dep = new BasicDeploymentImpl();
- dep.setType(getDeploymentType());
- dep.setClassLoader(unit.getClassLoader());
-
- Service service = dep.getService();
-
- Ejb3Deployment ejb3Deployment = unit.getAttachment(Ejb3Deployment.class);
- if (ejb3Deployment == null)
- throw new IllegalStateException("Deployment unit does not contain ejb3
deployment");
-
- // Copy the attachments
- dep.getContext().addAttachment(Ejb3Deployment.class, ejb3Deployment);
-
- Iterator it = ejb3Deployment.getEjbContainers().values().iterator();
- while (it.hasNext())
- {
- EJBContainer container = (EJBContainer)it.next();
- if (isWebServiceBean(container))
- {
- String ejbName = container.getEjbName();
- Class epBean = container.getBeanClass();
-
- // Create the endpoint
- Endpoint endpoint = new BasicEndpoint(service, epBean);
- String nameStr = Endpoint.SEPID_DOMAIN + ":" +
Endpoint.SEPID_PROPERTY_ENDPOINT + "=" + ejbName;
- endpoint.setName(ObjectNameFactory.create(nameStr));
-
- service.addEndpoint(endpoint);
- }
- }
-
- return dep;
- }
-
- @Override
- public boolean isWebServiceDeployment(DeploymentUnit unit)
- {
- Ejb3Deployment ejb3Deployment = unit.getAttachment(Ejb3Deployment.class);
- if (ejb3Deployment == null)
- return false;
-
- boolean isWebServiceDeployment = false;
-
- Iterator it = ejb3Deployment.getEjbContainers().values().iterator();
- while (it.hasNext())
- {
- EJBContainer container = (EJBContainer)it.next();
- if (isWebServiceBean(container))
- {
- isWebServiceDeployment = true;
- break;
- }
- }
-
- return isWebServiceDeployment;
- }
-
- private boolean isWebServiceBean(EJBContainer container)
- {
- boolean isWebServiceBean = false;
- if (container instanceof StatelessContainer)
- {
- boolean isWebService = container.resolveAnnotation(WebService.class) != null;
- boolean isWebServiceProvider =
container.resolveAnnotation(WebServiceProvider.class) != null;
- isWebServiceBean = isWebService || isWebServiceProvider;
- }
- return isWebServiceBean;
- }
-}
\ No newline at end of file
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookJSE.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookJSE.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/JAXWSDeployerHookJSE.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,150 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.jws.WebService;
-import javax.xml.ws.WebServiceProvider;
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.metadata.WebMetaData;
-import org.jboss.metadata.web.Servlet;
-import org.jboss.ws.integration.BasicEndpoint;
-import org.jboss.ws.integration.Endpoint;
-import org.jboss.ws.integration.ObjectNameFactory;
-import org.jboss.ws.integration.Service;
-import org.jboss.ws.integration.deployment.BasicDeploymentImpl;
-import org.jboss.ws.integration.deployment.Deployment;
-import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
-
-/**
- * A deployer JAXWS JSE Endpoints
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public class JAXWSDeployerHookJSE extends AbstractDeployerHookJSE
-{
- /** Get the deployemnt type this deployer can handle
- */
- public DeploymentType getDeploymentType()
- {
- return DeploymentType.JAXWS_JSE;
- }
-
- @Override
- public Deployment createDeployment(DeploymentUnit unit)
- {
- Deployment dep = new BasicDeploymentImpl();
- dep.setType(getDeploymentType());
- dep.setClassLoader(unit.getClassLoader());
-
- Service service = dep.getService();
-
- WebMetaData webMetaData = unit.getAttachment(WebMetaData.class);
- if (webMetaData == null)
- throw new IllegalStateException("Deployment unit does not contain web meta
data");
-
- // Copy the attachments
- dep.getContext().addAttachment(WebMetaData.class, webMetaData);
-
- List<Servlet> servlets = getRelevantServlets(webMetaData,
unit.getClassLoader());
- for (Servlet servlet : servlets)
- {
- String servletName = servlet.getName();
- String servletClass = servlet.getServletClass();
-
- try
- {
- ClassLoader loader = unit.getClassLoader();
- Class<?> epBean = loader.loadClass(servletClass.trim());
-
- // Create the endpoint
- Endpoint endpoint = new BasicEndpoint(service, epBean);
- String nameStr = Endpoint.SEPID_DOMAIN + ":" +
Endpoint.SEPID_PROPERTY_ENDPOINT + "=" + servletName;
- endpoint.setName(ObjectNameFactory.create(nameStr));
-
- service.addEndpoint(endpoint);
- }
- catch (ClassNotFoundException ex)
- {
- log.warn("Cannot load servlet class: " + servletClass);
- continue;
- }
- }
-
- return dep;
- }
-
- @Override
- public boolean isWebServiceDeployment(DeploymentUnit unit)
- {
- if (super.isWebServiceDeployment(unit) == false)
- return false;
-
- boolean isWebServiceDeployment = false;
- try
- {
- WebMetaData webMetaData = unit.getAttachment(WebMetaData.class);
- List<Servlet> servlets = getRelevantServlets(webMetaData,
unit.getClassLoader());
- isWebServiceDeployment = servlets.size() > 0;
- }
- catch (Exception ex)
- {
- log.error("Cannot process web deployment", ex);
- }
-
- return isWebServiceDeployment;
- }
-
- private List<Servlet> getRelevantServlets(WebMetaData webMetaData, ClassLoader
loader)
- {
- List<Servlet> servlets = new ArrayList<Servlet>();
- for (Servlet servlet : webMetaData.getServlets())
- {
- String servletClassName = servlet.getServletClass();
-
- // Skip JSPs
- if (servletClassName == null || servletClassName.length() == 0)
- continue;
-
- try
- {
- Class<?> servletClass = loader.loadClass(servletClassName.trim());
- boolean isWebService = servletClass.isAnnotationPresent(WebService.class);
- boolean isWebServiceProvider =
servletClass.isAnnotationPresent(WebServiceProvider.class);
- if (isWebService || isWebServiceProvider)
- servlets.add(servlet);
- }
- catch (ClassNotFoundException ex)
- {
- log.warn("Cannot load servlet class: " + servletClassName);
- continue;
- }
- }
- return servlets;
- }
-}
\ No newline at end of file
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/MainDeployerHook.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/MainDeployerHook.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/MainDeployerHook.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,61 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.ws.integration.deployment.Deployment;
-
-/**
- * A basic hook that delegates a deployment manger.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public class MainDeployerHook extends AbstractDeployerHook
-{
- public void deploy(DeploymentUnit unit) throws DeploymentException
- {
- if (ignoreDeployment(unit))
- return;
-
- Deployment dep = unit.getAttachment(Deployment.class);
- if (dep != null)
- {
- deployerManager.deploy(dep);
- }
- }
-
- public void undeploy(DeploymentUnit unit)
- {
- if (ignoreDeployment(unit))
- return;
-
- Deployment dep = unit.getAttachment(Deployment.class);
- if (dep != null)
- {
- deployerManager.undeploy(dep);
- }
- }
-}
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB21.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB21.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB21.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -29,9 +29,9 @@
import org.jboss.logging.Logger;
import org.jboss.metadata.ApplicationMetaData;
import org.jboss.metadata.AssemblyDescriptorMetaData;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.ServiceEndpointGeneratorEJB;
-import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
+import org.jboss.ws.utils.DOMUtils;
import org.w3c.dom.Element;
/**
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB3.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB3.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointGeneratorEJB3.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -30,9 +30,9 @@
import org.jboss.ejb3.EJBContainer;
import org.jboss.ejb3.Ejb3Deployment;
import org.jboss.logging.Logger;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.ServiceEndpointGeneratorEJB;
-import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
+import org.jboss.ws.utils.DOMUtils;
import org.w3c.dom.Element;
/**
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointInterceptor.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointInterceptor.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/ServiceEndpointInterceptor.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -36,8 +36,8 @@
import org.jboss.ws.core.jaxrpc.SOAPFaultHelperJAXRPC;
import org.jboss.ws.core.jaxrpc.handler.HandlerCallback;
import org.jboss.ws.core.soap.MessageContextAssociation;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData.HandlerType;
import org.jboss.ws.metadata.umdm.OperationMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
/**
* This Interceptor does the ws4ee handler processing.
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/UnifiedDeploymentInfoDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/UnifiedDeploymentInfoDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/UnifiedDeploymentInfoDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,69 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-//$Id$
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.ws.core.deployment.JAXRPCDeployment;
-import org.jboss.ws.core.deployment.JAXWSDeployment;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
-import org.jboss.ws.integration.deployment.AbstractDeployer;
-import org.jboss.ws.integration.deployment.Deployment;
-import org.jboss.ws.integration.deployment.Deployment.DeploymentType;
-import org.jboss.ws.metadata.webservices.WebservicesMetaData;
-
-/**
- * A deployer that builds the UnifiedDeploymentInfo
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 25-Apr-2007
- */
-public class UnifiedDeploymentInfoDeployer extends AbstractDeployer
-{
- @Override
- public void create(Deployment dep)
- {
- UnifiedDeploymentInfo udi =
dep.getContext().getAttachment(UnifiedDeploymentInfo.class);
- if (udi == null)
- {
- DeploymentUnit unit = dep.getContext().getAttachment(DeploymentUnit.class);
- if (unit == null)
- throw new IllegalStateException("Cannot obtain deployment unit");
-
- DeploymentType type = dep.getType();
- if (type.toString().startsWith("JAXWS"))
- {
- udi = new JAXWSDeployment(type);
- DeploymentInfoAdapter.buildDeploymentInfo(udi, unit);
- }
- else
- {
- WebservicesMetaData wsMetaData =
dep.getContext().getAttachment(WebservicesMetaData.class);
- udi = new JAXRPCDeployment(type, wsMetaData);
- DeploymentInfoAdapter.buildDeploymentInfo(udi, unit);
- }
-
- dep.getContext().addAttachment(UnifiedDeploymentInfo.class, udi);
- }
- }
-}
\ No newline at end of file
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/VirtualFileAdaptor.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/VirtualFileAdaptor.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/VirtualFileAdaptor.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,66 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-import java.io.IOException;
-import java.net.URL;
-
-import org.jboss.virtual.VirtualFile;
-import org.jboss.ws.integration.UnifiedVirtualFile;
-
-// $Id$
-
-/**
- * A JBoss50 VirtualFile adaptor
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class VirtualFileAdaptor implements UnifiedVirtualFile
-{
- private static final long serialVersionUID = 6547394037548338042L;
-
- private VirtualFile root;
-
- public VirtualFileAdaptor(VirtualFile root)
- {
- this.root = root;
- }
-
- public UnifiedVirtualFile findChild(String child) throws IOException
- {
- VirtualFile vf = root.findChild(child);
- return new VirtualFileAdaptor(vf);
- }
-
- public URL toURL()
- {
- try
- {
- return root.toURL();
- }
- catch (Exception e)
- {
- return null;
- }
- }
-}
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppDeployerDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppDeployerDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppDeployerDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -35,9 +35,9 @@
import org.jboss.virtual.VFS;
import org.jboss.virtual.VirtualFile;
import org.jboss.ws.core.deployment.ServiceEndpointPublisher;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.Deployer;
import org.jboss.ws.integration.deployment.Deployment;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.WSDeploymentException;
/**
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppGeneratorDeployer.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppGeneratorDeployer.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebAppGeneratorDeployer.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -23,9 +23,9 @@
//$Id$
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.integration.deployment.AbstractDeployer;
import org.jboss.ws.integration.deployment.Deployment;
+import org.jboss.ws.integration.deployment.UnifiedDeploymentInfo;
import org.jboss.ws.metadata.umdm.UnifiedMetaData;
/**
Deleted:
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebMetaDataAdaptor.java
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebMetaDataAdaptor.java 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/java/org/jboss/ws/integration/jboss50/jbossws/WebMetaDataAdaptor.java 2007-05-10
07:33:24 UTC (rev 3036)
@@ -1,136 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.integration.jboss50.jbossws;
-
-// $Id$
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.metadata.WebMetaData;
-import org.jboss.metadata.WebSecurityMetaData;
-import org.jboss.metadata.WebSecurityMetaData.WebResourceCollection;
-import org.jboss.metadata.web.Servlet;
-import org.jboss.metadata.web.ServletMapping;
-import org.jboss.ws.core.deployment.UnifiedDeploymentInfo;
-import org.jboss.ws.metadata.j2ee.UnifiedWebMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedWebSecurityMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedWebMetaData.PublishLocationAdapter;
-import
org.jboss.ws.metadata.j2ee.UnifiedWebSecurityMetaData.UnifiedWebResourceCollection;
-
-/**
- * Build container independent web meta data
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public class WebMetaDataAdaptor
-{
- public static UnifiedWebMetaData buildUnifiedWebMetaData(UnifiedDeploymentInfo udi,
DeploymentUnit unit)
- {
- WebMetaData wmd = unit.getAttachment(WebMetaData.class);
- udi.addAttachment(WebMetaData.class, wmd);
-
- UnifiedWebMetaData umd = new UnifiedWebMetaData();
- umd.setContextRoot(wmd.getContextRoot());
- umd.setServletMappings(getServletMappings(wmd));
- umd.setServletClassNames(getServletClassMap(wmd));
- umd.setConfigName(wmd.getConfigName());
- umd.setConfigFile(wmd.getConfigFile());
- umd.setSecurityDomain(wmd.getSecurityDomain());
- umd.setPublishLocationAdapter(getPublishLocationAdpater(wmd));
- umd.setSecurityMetaData(getSecurityMetaData(wmd.getSecurityContraints()));
-
- return umd;
- }
-
- private static PublishLocationAdapter getPublishLocationAdpater(final WebMetaData
wmd)
- {
- return new PublishLocationAdapter()
- {
- public String getWsdlPublishLocationByName(String name)
- {
- return wmd.getWsdlPublishLocationByName(name);
- }
- };
- }
-
- protected static List<UnifiedWebSecurityMetaData> getSecurityMetaData(final
Iterator securityConstraints)
- {
- ArrayList<UnifiedWebSecurityMetaData> unifiedsecurityMetaData = new
ArrayList<UnifiedWebSecurityMetaData>();
-
- while (securityConstraints.hasNext())
- {
- WebSecurityMetaData securityMetaData =
(WebSecurityMetaData)securityConstraints.next();
-
- UnifiedWebSecurityMetaData current = new UnifiedWebSecurityMetaData();
- unifiedsecurityMetaData.add(current);
-
- current.setTransportGuarantee(securityMetaData.getTransportGuarantee());
-
- Map<String, WebResourceCollection> resources =
securityMetaData.getWebResources();
- for (WebResourceCollection webResource : resources.values())
- {
- UnifiedWebResourceCollection currentResource =
current.addWebResource(webResource.getName());
- for (String currentPattern : webResource.getUrlPatterns())
- {
- currentResource.addPattern(currentPattern);
- }
- }
- }
-
- return unifiedsecurityMetaData;
- }
-
- private static Map<String, String> getServletMappings(WebMetaData wmd)
- {
- Map<String, String> mappings = new HashMap<String, String>();
- Iterator it = wmd.getServletMappings().iterator();
- while (it.hasNext())
- {
- ServletMapping sm = (ServletMapping)it.next();
- // FIXME - Add support for multiple mappings
- mappings.put(sm.getName(), sm.getUrlPatterns().get(0));
- }
- return mappings;
- }
-
- private static Map<String, String> getServletClassMap(WebMetaData wmd)
- {
- Map<String, String> mappings = new HashMap<String, String>();
- Iterator it = wmd.getServlets().iterator();
- while (it.hasNext())
- {
- Servlet servlet = (Servlet)it.next();
- // Skip JSPs
- if (servlet.getServletClass() == null || servlet.getServletClass().length() ==
0)
- continue;
-
- mappings.put(servlet.getName(), servlet.getServletClass());
- }
- return mappings;
- }
-}
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml 2007-05-10
07:33:24 UTC (rev 3036)
@@ -5,7 +5,7 @@
<!--
A web service deployer that hooks in after the EJB deployers
-->
- <bean name="WebServiceDeployerEJB"
class="org.jboss.ws.integration.jboss50.WebServiceDeployerEJB">
+ <bean name="WebServiceDeployerEJB"
class="org.jboss.ws.integration.jboss50.common.WebServiceDeployerEJB">
<property name="relOrderEJB2x"><inject
bean="EJB2xDeployer" property="relativeOrder"/></property>
<property name="relOrderEJB3"><inject
bean="EJBRegistrationDeployer"
property="relativeOrder"/></property>
<install bean="MainDeployer" method="addDeployer">
@@ -25,7 +25,7 @@
<!--
A web service deployer that hooks in before the WAR deployer
-->
- <bean name="WebServiceDeployerJSE"
class="org.jboss.ws.integration.jboss50.WebServiceDeployerJSE">
+ <bean name="WebServiceDeployerJSE"
class="org.jboss.ws.integration.jboss50.common.WebServiceDeployerJSE">
<property name="relOrderWar"><inject bean="WarDeployer"
property="relativeOrder"/></property>
<install bean="MainDeployer" method="addDeployer">
<parameter>
@@ -43,7 +43,7 @@
<!--
A web service deployer that hooks in after the web service WAR/EJB deployers
-->
- <bean name="WebServiceMainDeployer"
class="org.jboss.ws.integration.jboss50.WebServiceMainDeployer">
+ <bean name="WebServiceMainDeployer"
class="org.jboss.ws.integration.jboss50.common.WebServiceMainDeployer">
<property name="relOrderJSE"><inject
bean="WebServiceDeployerJSE"
property="relativeOrder"/></property>
<property name="relOrderEJB"><inject
bean="WebServiceDeployerEJB"
property="relativeOrder"/></property>
<install bean="MainDeployer" method="addDeployer">
Modified:
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.sar/META-INF/jbossws-beans.xml
===================================================================
---
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.sar/META-INF/jbossws-beans.xml 2007-05-10
07:18:41 UTC (rev 3035)
+++
projects/wsintegration/jbws-jboss50/trunk/src/main/resources/jbossws.sar/META-INF/jbossws-beans.xml 2007-05-10
07:33:24 UTC (rev 3036)
@@ -150,7 +150,7 @@
<property name="serviceEndpointPublisher"><inject
bean="WSServiceEndpointPublisher"/></property>
</bean>
<bean name="WSPublishContractDeployer"
class="org.jboss.ws.core.deployment.PublishContractDeployer"/>
- <bean name="WSUnifiedDeploymentInfoDeployer"
class="org.jboss.ws.integration.jboss50.jbossws.UnifiedDeploymentInfoDeployer"/>
+ <bean name="WSUnifiedDeploymentInfoDeployer"
class="org.jboss.ws.integration.jboss50.common.UnifiedDeploymentInfoDeployer"/>
<bean name="WSUnifiedMetaDataAssociationDeployer"
class="org.jboss.ws.core.deployment.UnifiedMetaDataAssociationDeployer"/>
<bean name="WSUnifiedMetaDataDeployer"
class="org.jboss.ws.core.deployment.UnifiedMetaDataDeployer"/>
<bean name="WSWebAppGeneratorDeployer"
class="org.jboss.ws.integration.jboss50.jbossws.WebAppGeneratorDeployer"/>
@@ -167,7 +167,7 @@
<!--
Register DeployerHooks with JBoss deployers
-->
- <bean name="WSDeployerHook_JAXRPC_JSE"
class="org.jboss.ws.integration.jboss50.jbossws.JAXRPCDeployerHookJSE">
+ <bean name="WSDeployerHook_JAXRPC_JSE"
class="org.jboss.ws.integration.jboss50.common.JAXRPCDeployerHookJSE">
<property name="deployerManager"><inject
bean="WSDeployerManagerJSE"/></property>
<install bean="WebServiceDeployerJSE"
method="addDeployerHook">
<parameter>
@@ -181,7 +181,7 @@
</uninstall>
<depends>WebServiceDeployerJSE</depends>
</bean>
- <bean name="WSDeployerHook_JAXRPC_EJB21"
class="org.jboss.ws.integration.jboss50.jbossws.JAXRPCDeployerHookEJB21">
+ <bean name="WSDeployerHook_JAXRPC_EJB21"
class="org.jboss.ws.integration.jboss50.common.JAXRPCDeployerHookEJB21">
<property name="deployerManager"><inject
bean="WSDeployerManagerEJB"/></property>
<install bean="WebServiceDeployerEJB"
method="addDeployerHook">
<parameter>
@@ -195,7 +195,7 @@
</uninstall>
<depends>WebServiceDeployerEJB</depends>
</bean>
- <bean name="WSDeployerHook_JAXWS_JSE"
class="org.jboss.ws.integration.jboss50.jbossws.JAXWSDeployerHookJSE">
+ <bean name="WSDeployerHook_JAXWS_JSE"
class="org.jboss.ws.integration.jboss50.common.JAXWSDeployerHookJSE">
<property name="deployerManager"><inject
bean="WSDeployerManagerJSE"/></property>
<install bean="WebServiceDeployerJSE"
method="addDeployerHook">
<parameter>
@@ -209,7 +209,7 @@
</uninstall>
<depends>WebServiceDeployerJSE</depends>
</bean>
- <bean name="WSDeployerHook_JAXWS_EJB3"
class="org.jboss.ws.integration.jboss50.jbossws.JAXWSDeployerHookEJB3">
+ <bean name="WSDeployerHook_JAXWS_EJB3"
class="org.jboss.ws.integration.jboss50.common.JAXWSDeployerHookEJB3">
<property name="deployerManager"><inject
bean="WSDeployerManagerEJB"/></property>
<install bean="WebServiceDeployerEJB"
method="addDeployerHook">
<parameter>
@@ -223,7 +223,7 @@
</uninstall>
<depends>WebServiceDeployerEJB</depends>
</bean>
- <bean name="WSMainDeployerHook"
class="org.jboss.ws.integration.jboss50.jbossws.MainDeployerHook">
+ <bean name="WSMainDeployerHook"
class="org.jboss.ws.integration.jboss50.common.MainDeployerHook">
<property name="deployerManager"><inject
bean="WSMainDeployerManager"/></property>
<install bean="WebServiceMainDeployer"
method="addDeployerHook">
<parameter>