[jboss-svn-commits] JBossWS SVN: r680 - in trunk: . src/main/java/javax/jws src/main/java/javax/jws/soap src/main/java/org/jboss/ws/addressing src/main/java/org/jboss/ws/addressing/jaxrpc src/main/java/org/jboss/ws/addressing/jaxws src/main/java/org/jboss/ws/addressing/soap src/main/java/org/jboss/ws/binding/soap src/main/java/org/jboss/ws/common src/main/java/org/jboss/ws/deployment src/main/java/org/jboss/ws/jaxrpc src/main/java/org/jboss/ws/jaxws src/main/java/org/jboss/ws/jaxws/client src/main/java/org/jboss/ws/jaxws/handler src/main/java/org/jboss/ws/jbossxb src/main/java/org/jboss/ws/metadata src/main/java/org/jboss/ws/metadata/config src/main/java/org/jboss/ws/metadata/config/jaxrpc src/main/java/org/jboss/ws/metadata/config/jaxws src/main/java/org/jboss/ws/metadata/jsr181 src/main/java/org/jboss/ws/metadata/wsdl src/main/java/org/jboss/ws/metadata/wsdl/xmlschema src/main/java/org/jboss/ws/server src/main/java/org/jboss/ws/tools src/main/java/org/jboss/ws/transport/jms src/main! /java/org/jboss/ws/utils src/main/java/org/jboss/ws/wsse src/main/java/org/jboss/ws/wsse/jaxrpc src/main/java/org/jboss/ws/wsse/jaxws src/main/resources/jbossws.sar/META-INF src/main/resources/schema src/test/ant src/test/java/org/jboss/test/ws src/test/java/org/jboss/test/ws/addressing/action src/test/java/org/jboss/test/ws/addressing/replyto src/test/java/org/jboss/test/ws/config src/test/java/org/jboss/test/ws/eventing src/test/java/org/jboss/test/ws/jbws860 src/test/java/org/jboss/test/ws/jsr181/handlerchain src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers src/test/java/org/jboss/test/ws/samples/jsr181ejb src/test/java/org/jboss/test/ws/samples/wsaddressing src/test/java/org/jboss/test/ws/samples/wseventing src/test/java/org/jboss/test/ws/samples/wssecurity src/test/java/org/jboss/test/ws/tools/xmlschema src/test/resources/addressing/action/Doc-META-INF src/test/resources/addressing/action/Rpc-META-INF src/test/resources/addressing/replyto/Initial-WEB-INF src/! test/resources/config src/test/resources/eventing/META-INF src/test/resources/eventing/WEB-INF src/test/resources/interop/microsoft/addressing/wsa10/META-INF src/test/resources/interop/microsoft/addressing/wsaTestService/WEB-INF src/test/resources/jsr181/handlerchain/WEB-INF src/test/resources/jsr181/handlerchain/config src/

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Thu Aug 3 17:07:24 EDT 2006


Author: thomas.diesler at jboss.com
Date: 2006-08-03 17:04:42 -0400 (Thu, 03 Aug 2006)
New Revision: 680

Added:
   trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/
   trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingClientHandler.java
   trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingServerHandler.java
   trunk/src/main/java/org/jboss/ws/addressing/jaxws/
   trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingClientHandler.java
   trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingServerHandler.java
   trunk/src/main/java/org/jboss/ws/jaxrpc/ServletEndpointContextImpl.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSClientConfigJAXRPC.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSCommonConfigJAXRPC.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigFactoryJAXRPC.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigRootJAXRPC.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSEndpointConfigJAXRPC.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSHandlerChainConfigJAXRPC.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSClientConfigJAXWS.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSCommonConfigJAXWS.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigFactoryJAXWS.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigRootJAXWS.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSEndpointConfigJAXWS.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainConfigJAXWS.java
   trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainsConfigJAXWS.java
   trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerChainsMetaData.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLLocatorImpl.java
   trunk/src/main/java/org/jboss/ws/server/EndpointContext.java
   trunk/src/main/java/org/jboss/ws/utils/JBossWSEntityResolver.java
   trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/
   trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandler.java
   trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerInbound.java
   trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerOutbound.java
   trunk/src/main/java/org/jboss/ws/wsse/jaxws/
   trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandler.java
   trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerInbound.java
   trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerOutbound.java
   trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxrpc-client-config.xml
   trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxrpc-endpoint-config.xml
   trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-client-config.xml
   trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-endpoint-config.xml
   trunk/src/main/resources/schema/handler-chain.xsd
   trunk/src/main/resources/schema/javaee_5.xsd
   trunk/src/main/resources/schema/jaxrpc-config_2_0.xsd
   trunk/src/main/resources/schema/jaxws-config_2_0.xsd
   trunk/src/test/resources/addressing/action/Doc-META-INF/jaxrpc-client-config.xml
   trunk/src/test/resources/addressing/action/Doc-META-INF/jaxws-handlers.xml
   trunk/src/test/resources/addressing/action/Doc-META-INF/wstools-config.xml
   trunk/src/test/resources/addressing/action/Rpc-META-INF/jaxrpc-client-config.xml
   trunk/src/test/resources/addressing/action/Rpc-META-INF/wstools-config.xml
   trunk/src/test/resources/addressing/replyto/Initial-WEB-INF/jaxws-handlers.xml
   trunk/src/test/resources/config/jaxrpc-endpoint-config.xml
   trunk/src/test/resources/config/jaxws-endpoint-config.xml
   trunk/src/test/resources/jsr181/handlerchain/WEB-INF/jaxws-handlers.xml
   trunk/src/test/resources/samples/jsr181ejb/META-INF/jaxws-handlers.xml
   trunk/src/test/resources/samples/jsr181ejb/WEB-INF/
   trunk/src/test/resources/samples/wsaddressing/WEB-INF/jaxws-handlers.xml
Removed:
   trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPClientHandler.java
   trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPServerHandler.java
   trunk/src/main/java/org/jboss/ws/metadata/config/WSClientConfig.java
   trunk/src/main/java/org/jboss/ws/metadata/config/WSCommonConfig.java
   trunk/src/main/java/org/jboss/ws/metadata/config/WSConfig.java
   trunk/src/main/java/org/jboss/ws/metadata/config/WSEndpointConfig.java
   trunk/src/main/java/org/jboss/ws/metadata/config/WSHandlerChainConfig.java
   trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigMetaData.java
   trunk/src/main/java/org/jboss/ws/server/ServletEndpointContextImpl.java
   trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandler.java
   trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerInbound.java
   trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerOutbound.java
   trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-client-config.xml
   trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-endpoint-config.xml
   trunk/src/main/resources/schema/handler-config_1_0.xsd
   trunk/src/main/resources/schema/jbossws-config_1_0.xsd
   trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/JSR181SOAPMessageHandlersTestCase.java
   trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/MyWebService.java
   trunk/src/test/resources/addressing/action/Doc-META-INF/config.xml
   trunk/src/test/resources/addressing/action/Doc-META-INF/jbossws-client-config.xml
   trunk/src/test/resources/addressing/action/Rpc-META-INF/config.xml
   trunk/src/test/resources/addressing/action/Rpc-META-INF/jbossws-client-config.xml
   trunk/src/test/resources/config/jbossws-endpoint-config.xml
   trunk/src/test/resources/jsr181/handlerchain/config/ProjectHandlers.xml
   trunk/src/test/resources/jsr181/soapmessagehandlers/WEB-INF/web.xml
   trunk/src/test/resources/samples/jsr181ejb/WEB-INF/ServerHandlers.xml
   trunk/src/test/resources/samples/jsr181ejb/config/
Modified:
   trunk/.classpath
   trunk/build-thirdparty.xml
   trunk/build.xml
   trunk/src/main/java/javax/jws/HandlerChain.java
   trunk/src/main/java/javax/jws/soap/SOAPMessageHandler.java
   trunk/src/main/java/javax/jws/soap/SOAPMessageHandlers.java
   trunk/src/main/java/org/jboss/ws/binding/soap/JAXWSBindingProviderPayload.java
   trunk/src/main/java/org/jboss/ws/common/CommonClient.java
   trunk/src/main/java/org/jboss/ws/deployment/JSR181MetaDataBuilder.java
   trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointDeployer.java
   trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointPublisher.java
   trunk/src/main/java/org/jboss/ws/jaxrpc/InvokerDelegateJAXRPC.java
   trunk/src/main/java/org/jboss/ws/jaxws/InvokerDelegateJAXWS.java
   trunk/src/main/java/org/jboss/ws/jaxws/client/JAXWSClient.java
   trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerChainBaseImpl.java
   trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerWrapper.java
   trunk/src/main/java/org/jboss/ws/jbossxb/JBossXBSupport.java
   trunk/src/main/java/org/jboss/ws/jbossxb/SchemaBindingBuilder.java
   trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java
   trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java
   trunk/src/main/java/org/jboss/ws/metadata/config/WSConfigFactory.java
   trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerChainMetaData.java
   trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigFactory.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/DOMTypes.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11DefinitionFactory.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11Reader.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLDefinitionsFactory.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/XSModelTypes.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSEntityResolver.java
   trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSStringList.java
   trunk/src/main/java/org/jboss/ws/server/ServiceEndpoint.java
   trunk/src/main/java/org/jboss/ws/server/ServiceEndpointInvokerJSE.java
   trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java
   trunk/src/main/java/org/jboss/ws/server/ServletHeaderSource.java
   trunk/src/main/java/org/jboss/ws/server/StandardEndpointServlet.java
   trunk/src/main/java/org/jboss/ws/tools/JavaToXSD.java
   trunk/src/main/java/org/jboss/ws/transport/jms/JMSMessageDispatcher.java
   trunk/src/main/java/org/jboss/ws/wsse/WSSecurityDispatcher.java
   trunk/src/test/ant/build-jars.xml
   trunk/src/test/java/org/jboss/test/ws/JBossWSTestDeployer.java
   trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionDocEndpointImpl.java
   trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionRpcEndpointImpl.java
   trunk/src/test/java/org/jboss/test/ws/addressing/replyto/AddressingReplyToTestCase.java
   trunk/src/test/java/org/jboss/test/ws/addressing/replyto/InitialEndpointImpl.java
   trunk/src/test/java/org/jboss/test/ws/config/WSConfigTestCase.java
   trunk/src/test/java/org/jboss/test/ws/eventing/DIIClientTestCase.java
   trunk/src/test/java/org/jboss/test/ws/jbws860/TestServlet.java
   trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/AuthorizationHandler.java
   trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/LogHandler.java
   trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/MyWebService.java
   trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/RoutingHandler.java
   trunk/src/test/java/org/jboss/test/ws/samples/jsr181ejb/EJB3Bean01.java
   trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/AddressingStatefulTestCase.java
   trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/ServerHandler.java
   trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/StatefulEndpointImpl.java
   trunk/src/test/java/org/jboss/test/ws/samples/wseventing/SysmonTestCase.java
   trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleEncryptTestCase.java
   trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleSignTestCase.java
   trunk/src/test/java/org/jboss/test/ws/tools/xmlschema/XercesSchemaParserTestCase.java
   trunk/src/test/resources/addressing/action/Doc-META-INF/jboss-client.xml
   trunk/src/test/resources/addressing/action/Rpc-META-INF/jboss-client.xml
   trunk/src/test/resources/eventing/META-INF/application-client.xml
   trunk/src/test/resources/eventing/WEB-INF/webservices.xml
   trunk/src/test/resources/interop/microsoft/addressing/wsa10/META-INF/application-client.xml
   trunk/src/test/resources/interop/microsoft/addressing/wsaTestService/WEB-INF/webservices.xml
   trunk/src/test/resources/samples/wseventing/META-INF/application-client.xml
   trunk/src/test/resources/samples/wseventing/WEB-INF/webservices.xml
   trunk/version.properties
Log:
JAXWS handlers on JSR181 endpoints
Split configuration in jaxrpc/jaxws
Fix offline eventing wsdl parsing
Compile against versioned jars
Test against container jars
dos2unix

Modified: trunk/.classpath
===================================================================
--- trunk/.classpath	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/.classpath	2006-08-03 21:04:42 UTC (rev 680)
@@ -3,7 +3,6 @@
 	<classpathentry kind="src" path="src/main/java"/>
 	<classpathentry excluding="org/jboss/test/ws/interop/" kind="src" path="src/test/java"/>
 	<classpathentry kind="lib" path="thirdparty/activation.jar"/>
-	<classpathentry sourcepath="D:/cvs/JBossRemoting/src/main" kind="lib" path="thirdparty/jboss-remoting.jar"/>
 	<classpathentry kind="lib" path="thirdparty/mailapi.jar"/>
 	<classpathentry kind="lib" path="thirdparty/qdox.jar"/>
 	<classpathentry kind="lib" path="thirdparty/servlet-api.jar"/>

Modified: trunk/build-thirdparty.xml
===================================================================
--- trunk/build-thirdparty.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/build-thirdparty.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -34,13 +34,13 @@
     <get src="${jboss.repository}/ibm-wsdl4j/${ibm-wsdl4j}/lib/wsdl4j.jar" dest="${thirdparty.dir}/wsdl4j.jar" usetimestamp="true" verbose="true"/>
     <get src="${jboss.repository}/javassist/${javassist}/lib/javassist.jar" dest="${thirdparty.dir}/javassist.jar" usetimestamp="true" verbose="true"/>
     <get src="${jboss.repository}/jboss/backport-concurrent/${jboss-backport-concurrent}/lib/jboss-backport-concurrent.jar" dest="${thirdparty.dir}/jboss-backport-concurrent.jar" usetimestamp="true" verbose="true"/>
+    <get src="${jboss.repository}/jboss/common/${jboss-common}/lib/jboss-common.jar" dest="${thirdparty.dir}/jboss-common.jar" usetimestamp="true" verbose="true"/>
     <get src="${jboss.repository}/jboss/remoting/${jboss-remoting}/lib/jboss-remoting.jar" dest="${thirdparty.dir}/jboss-remoting.jar" usetimestamp="true" verbose="true"/>
     <get src="${jboss.repository}/jboss/jbossretro/${jboss-jbossretro}/lib/jbossretro.jar" dest="${thirdparty.dir}/jbossretro.jar" usetimestamp="true" verbose="true"/>
     <get src="${jboss.repository}/jboss/jbossxb/${jboss-jbossxb}/lib/jboss-xml-binding.jar" dest="${thirdparty.dir}/jboss-xml-binding.jar" usetimestamp="true" verbose="true"/>
-    <get src="${jboss.repository}/jbossas/core-libs/${jbossas-core}/lib/jboss-common.jar" dest="${thirdparty.dir}/jboss-common.jar" usetimestamp="true" verbose="true"/>
-    <get src="${jboss.repository}/jbossas/core-libs/${jbossas-core}/lib/jboss-j2ee.jar" dest="${thirdparty.dir}/jboss-j2ee.jar" usetimestamp="true" verbose="true"/>
-    <get src="${jboss.repository}/jbossas/core-libs/${jbossas-core}/lib/jboss-jmx.jar" dest="${thirdparty.dir}/jboss-jmx.jar" usetimestamp="true" verbose="true"/>
-    <get src="${jboss.repository}/jbossas/core-libs/${jbossas-core}/lib/jboss-system.jar" dest="${thirdparty.dir}/jboss-system.jar" usetimestamp="true" verbose="true"/>
+    <get src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-container.jar" dest="${thirdparty.dir}/jboss-container.jar" usetimestamp="true" verbose="true"/>
+    <get src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-dependency.jar" dest="${thirdparty.dir}/jboss-dependency.jar" 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}/junit/${junit}/lib/junit.jar" dest="${thirdparty.dir}/junit.jar" usetimestamp="true" verbose="true"/>
     <get src="${jboss.repository}/oswego-concurrent/${oswego-concurrent}/lib/concurrent.jar" dest="${thirdparty.dir}/concurrent.jar" usetimestamp="true" verbose="true"/>
     <get src="${jboss.repository}/qdox/${qdox}/lib/qdox.jar" dest="${thirdparty.dir}/qdox.jar" usetimestamp="true" verbose="true"/>
@@ -67,6 +67,12 @@
       <pathelement location="${thirdparty.dir}/jaxb-api.jar"/>
       <pathelement location="${thirdparty.dir}/jaxb-impl.jar"/>
       <pathelement location="${thirdparty.dir}/jaxb-xjc.jar"/>
+      <pathelement location="${thirdparty.dir}/jboss-common.jar"/>
+      <pathelement location="${thirdparty.dir}/jboss-container.jar"/>
+      <pathelement location="${thirdparty.dir}/jboss-dependency.jar"/>
+      <pathelement location="${thirdparty.dir}/jboss-microcontainer.jar"/>
+      <pathelement location="${thirdparty.dir}/jboss-remoting.jar"/>
+      <pathelement location="${thirdparty.dir}/jboss-xml-binding.jar"/>
       <pathelement location="${thirdparty.dir}/junit.jar"/>
       <pathelement location="${thirdparty.dir}/mailapi.jar"/>
       <pathelement location="${thirdparty.dir}/policy-1.0.jar"/>
@@ -84,16 +90,10 @@
 
     <!-- The classpath for the jbossws core -->
     <path id="jboss.core.classpath">
-      <pathelement location="${thirdparty.dir}/jboss-common.jar"/>
-      <pathelement location="${thirdparty.dir}/jboss-j2ee.jar"/>
-      <pathelement location="${thirdparty.dir}/jboss-remoting.jar"/>
-      <pathelement location="${thirdparty.dir}/jboss-xml-binding.jar"/>
+      <pathelement location="${jboss.server.lib}/jboss-j2ee.jar"/>
       <pathelement location="${jboss.server.lib}/jboss-jaxrpc.jar"/>
       <pathelement location="${jboss.server.lib}/jboss-saaj.jar"/>
       <pathelement location="${jboss.server.deploy}/ejb3.deployer/jboss-annotations-ejb3.jar"/>
-      <pathelement location="${jboss.server.deploy}/jboss-bean.deployer/jboss-container.jar"/>
-      <pathelement location="${jboss.server.deploy}/jboss-bean.deployer/jboss-dependency.jar"/>
-      <pathelement location="${jboss.server.deploy}/jboss-bean.deployer/jboss-microcontainer.jar"/>
     </path>
 
     <!-- The classpath for the jboss integration -->

Modified: trunk/build.xml
===================================================================
--- trunk/build.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/build.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -231,7 +231,8 @@
         <exclude name="org/jboss/ws/transport/jms/**"/>
       </fileset>
       <fileset dir="${build.resources.dir}/jbossws.sar">
-        <include name="META-INF/standard-jbossws-client-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-client-config.xml"/>
+        <include name="META-INF/standard-jaxws-client-config.xml"/>
       </fileset>
       <fileset dir="${build.resources.dir}">
         <include name="schema/**"/>
@@ -265,8 +266,10 @@
         <include name="META-INF/jboss-beans.xml"/>
       </fileset>
       <fileset dir="${build.resources.dir}/jbossws.sar">
-        <include name="META-INF/standard-jbossws-client-config.xml"/>
-        <include name="META-INF/standard-jbossws-endpoint-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-client-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-endpoint-config.xml"/>
+        <include name="META-INF/standard-jaxws-client-config.xml"/>
+        <include name="META-INF/standard-jaxws-endpoint-config.xml"/>
       </fileset>
     </war>
 
@@ -289,8 +292,10 @@
         <include name="xmlsec.jar"/>
       </fileset>
       <fileset dir="${build.resources.dir}/jbossws.sar">
-        <include name="META-INF/standard-jbossws-client-config.xml"/>
-        <include name="META-INF/standard-jbossws-endpoint-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-client-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-endpoint-config.xml"/>
+        <include name="META-INF/standard-jaxws-client-config.xml"/>
+        <include name="META-INF/standard-jaxws-endpoint-config.xml"/>
         <include name="META-INF/jboss-service.xml"/>
       </fileset>
     </jar>
@@ -335,7 +340,7 @@
         <exclude name="org/jboss/ws/transport/jms/**"/>
       </fileset>
       <fileset dir="${build.resources.dir}/jbossws.sar">
-        <include name="META-INF/standard-jbossws-client-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-client-config.xml"/>
       </fileset>
       <fileset dir="${build.resources.dir}">
         <include name="schema/**"/>
@@ -361,8 +366,8 @@
         <include name="xmlsec.jar"/>
       </fileset>
       <fileset dir="${build.resources.dir}/jbossws.sar">
-        <include name="META-INF/standard-jbossws-client-config.xml"/>
-        <include name="META-INF/standard-jbossws-endpoint-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-client-config.xml"/>
+        <include name="META-INF/standard-jaxrpc-endpoint-config.xml"/>
       </fileset>
       <fileset dir="${build.resources.dir}/jbossws14.sar">
         <include name="META-INF/jboss-service.xml"/>

Modified: trunk/src/main/java/javax/jws/HandlerChain.java
===================================================================
--- trunk/src/main/java/javax/jws/HandlerChain.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/javax/jws/HandlerChain.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -52,8 +52,9 @@
 
    /**
     * Name of the handler chain in the configuration file
+    * @deprecated
     */
-   String name();
+   String name() default "";
 }
 
 ;

Modified: trunk/src/main/java/javax/jws/soap/SOAPMessageHandler.java
===================================================================
--- trunk/src/main/java/javax/jws/soap/SOAPMessageHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/javax/jws/soap/SOAPMessageHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -28,7 +28,8 @@
  *
  * @author thomas.diesler at jboss.org
  * @since 26-Apr-2005
- ` */
+ * @deprecated
+ */
 public @interface SOAPMessageHandler
 {
 

Modified: trunk/src/main/java/javax/jws/soap/SOAPMessageHandlers.java
===================================================================
--- trunk/src/main/java/javax/jws/soap/SOAPMessageHandlers.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/javax/jws/soap/SOAPMessageHandlers.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -29,14 +29,14 @@
 import java.lang.annotation.Target;
 
 /**
- * Specifies a list of SOAP protocol handlers that run before and after business methods on the Web Service.  These
- * handlers are called in response to SOAP messages targeting the service.
- *
- * The @SOAPMessageHandlers annotation is an array of SOAPMessageHandler types.  The handlers are run in the order in
- * which they appear in the annotation, starting with the first handler in the array.
- *
+ * This annotation was originally used to create a JAX-RPC handler chain. In this version,
+ * the annotation is ALWAYS ignored.
+ * 
+ * This annotation will be permanently removed in a future version of JSR-181.
+
  * @author thomas.diesler at jboss.org
  * @since 26-Apr-2005
+ * @deprecated
  */
 @Retention(value = RetentionPolicy.RUNTIME)
    @Target(value = {ElementType.TYPE})

Added: trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingClientHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingClientHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingClientHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,130 @@
+/*
+ * 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.addressing.jaxrpc;
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.handler.GenericHandler;
+import javax.xml.rpc.handler.HandlerInfo;
+import javax.xml.rpc.handler.MessageContext;
+import javax.xml.rpc.handler.soap.SOAPMessageContext;
+import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.addressing.AddressingBuilder;
+import javax.xml.ws.addressing.AddressingException;
+import javax.xml.ws.addressing.JAXWSAConstants;
+import javax.xml.ws.addressing.soap.SOAPAddressingBuilder;
+import javax.xml.ws.addressing.soap.SOAPAddressingProperties;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.addressing.soap.SOAPAddressingPropertiesImpl;
+
+/**
+ * A client side handler that reads/writes the addressing properties
+ * and puts then into the message context.
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 24-Nov-2005
+ */
+public class WSAddressingClientHandler extends GenericHandler
+{
+   // Provide logging
+   private static Logger log = Logger.getLogger(WSAddressingClientHandler.class);
+
+   // addressing builder & constants
+   private AddressingBuilder addrBuilder;
+
+   // should the request be normalized according to the specifications
+   private boolean normalize;
+
+   public WSAddressingClientHandler()
+   {
+      addrBuilder = AddressingBuilder.getAddressingBuilder();
+   }
+
+   public QName[] getHeaders()
+   {
+      return new QName[] {};
+   }
+
+   public void init(HandlerInfo handlerInfo)
+   {
+      super.init(handlerInfo);
+      normalize = "true".equals(handlerInfo.getHandlerConfig().get("normalize"));
+
+   }
+
+   public boolean handleRequest(MessageContext msgContext)
+   {
+      log.debug("handleRequest");
+
+      SOAPAddressingProperties addrProps = (SOAPAddressingProperties)msgContext.getProperty(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_OUTBOUND);
+
+      if (addrProps != null)
+      {
+         if (normalize)
+            normalizeRequest(msgContext, addrProps);
+
+         SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+         addrProps.writeHeaders(soapMessage);
+      }
+      else
+      {
+         // supply default addressing properties
+         addrProps = (SOAPAddressingPropertiesImpl)addrBuilder.newAddressingProperties();
+         msgContext.setProperty(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_OUTBOUND, addrProps);
+
+         if (normalize)
+            normalizeRequest(msgContext, addrProps);
+      }
+
+      return true;
+   }
+
+   /* supply the default addressing properties in case elements are missing */
+   private void normalizeRequest(MessageContext msgContext, SOAPAddressingProperties addrProps)
+   {
+      // TODO: supply default header
+   }
+
+   public boolean handleResponse(MessageContext msgContext)
+   {
+      log.debug("handleResponse");
+
+      try
+      {
+         SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+         if (soapMessage.getSOAPPart().getEnvelope() != null)
+         {
+            SOAPAddressingBuilder builder = (SOAPAddressingBuilder)SOAPAddressingBuilder.getAddressingBuilder();
+            SOAPAddressingProperties addrProps = (SOAPAddressingProperties)builder.newAddressingProperties();
+            addrProps.readHeaders(soapMessage);
+            msgContext.setProperty(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_INBOUND, addrProps);
+         }
+      }
+      catch (SOAPException ex)
+      {
+         throw new AddressingException("Cannot handle response", ex);
+      }
+
+      return true;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingClientHandler.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingServerHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingServerHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingServerHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,179 @@
+/*
+ * 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.addressing.jaxrpc;
+
+import java.net.URISyntaxException;
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.handler.GenericHandler;
+import javax.xml.rpc.handler.HandlerInfo;
+import javax.xml.rpc.handler.MessageContext;
+import javax.xml.rpc.handler.soap.SOAPMessageContext;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.addressing.AddressingBuilder;
+import javax.xml.ws.addressing.JAXWSAConstants;
+import javax.xml.ws.addressing.soap.SOAPAddressingBuilder;
+import javax.xml.ws.addressing.soap.SOAPAddressingProperties;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.addressing.AddressingConstantsImpl;
+import org.jboss.ws.addressing.metadata.AddressingOpMetaExt;
+import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
+import org.jboss.ws.metadata.OperationMetaData;
+
+/**
+ * A server side handler that reads/writes the addressing properties
+ * and puts then into the message context.
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 24-Nov-2005
+ */
+public class WSAddressingServerHandler extends GenericHandler
+{
+   // Provide logging
+   private static Logger log = Logger.getLogger(WSAddressingServerHandler.class);
+
+   // should the request be validated?
+   private boolean validate = true;
+
+   private static AddressingBuilder ADDR_BUILDER;
+   private static AddressingConstantsImpl ADDR_CONSTANTS;
+   static
+   {
+      ADDR_CONSTANTS = new AddressingConstantsImpl();
+      ADDR_BUILDER = AddressingBuilder.getAddressingBuilder();
+   }
+
+   public QName[] getHeaders()
+   {
+      return new QName[] {};
+   }
+
+   public void init(HandlerInfo handlerInfo)
+   {
+      super.init(handlerInfo);
+      String strValidate = (String)handlerInfo.getHandlerConfig().get("validate");
+      validate = "true".equals(strValidate);
+   }
+
+   /**
+    * Read the addressing headers from the incomming message and put a
+    * SOAPAddressingProperties object into the message context
+    */
+   public boolean handleRequest(MessageContext msgContext)
+   {
+      log.debug("handleRequest");
+
+      SOAPAddressingProperties addrProps = (SOAPAddressingProperties)ADDR_BUILDER.newAddressingProperties();
+      SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+      addrProps.readHeaders(soapMessage);
+      msgContext.setProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND, addrProps);
+
+      if (validate)
+         validateRequest(addrProps);
+
+      return true;
+   }
+
+   /**
+    * Get a SOAPAddressingProperties object from the message context
+    * and write the adressing headers
+    */
+   public boolean handleResponse(MessageContext msgContext)
+   {
+      log.debug("handleResponse");
+      handleResponseOrFault(msgContext, false);
+      return true;
+   }
+
+   /**
+    * Get a SOAPAddressingProperties object from the message context
+    * and write the adressing headers
+    */
+   public boolean handleFault(MessageContext msgContext)
+   {
+      log.debug("handleFault");
+      handleResponseOrFault(msgContext, true);
+      return true;
+   }
+
+   private void handleResponseOrFault(MessageContext msgContext, boolean isFault)
+   {
+      SOAPAddressingBuilder builder = (SOAPAddressingBuilder)SOAPAddressingBuilder.getAddressingBuilder();
+      SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+
+      SOAPAddressingProperties inProps = (SOAPAddressingProperties)msgContext.getProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND);
+      SOAPAddressingProperties outProps = (SOAPAddressingProperties)msgContext.getProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND);
+
+      if (outProps == null)
+      {
+         // create new response properties
+         outProps = (SOAPAddressingProperties)builder.newAddressingProperties();
+         msgContext.setProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND, outProps);
+      }
+
+      outProps.initializeAsReply(inProps, isFault);
+
+      try
+      {
+         // supply the response action
+
+         OperationMetaData opMetaData = ((SOAPMessageContextJAXRPC)msgContext).getOperationMetaData();
+
+         if (!isFault && !opMetaData.isOneWayOperation())
+         {
+
+            AddressingOpMetaExt addrExt = (AddressingOpMetaExt)opMetaData.getExtension(ADDR_CONSTANTS.getNamespaceURI());
+            if (addrExt != null)
+            {
+               outProps.setAction(ADDR_BUILDER.newURI(addrExt.getOutboundAction()));
+            }
+            else
+            {
+               log.warn("Unable to resolve replyAction for " + opMetaData.getQName());
+            }
+
+         }
+         else if (isFault)
+         {
+            outProps.setAction(ADDR_BUILDER.newURI(ADDR_CONSTANTS.getDefaultFaultAction()));
+         }
+
+      }
+      catch (URISyntaxException e)
+      {
+         log.error("Error setting response action", e);
+      }
+
+      outProps.writeHeaders(soapMessage);
+   }
+
+   /* check wsa formal constraints */
+   private void validateRequest(SOAPAddressingProperties addrProps)
+   {
+
+      // If wsa:ReplyTo is supplied and the message lacks a [message id] property, the processor MUST fault.
+      if (addrProps.getReplyTo() != null && addrProps.getMessageID() == null)
+         throw new IllegalArgumentException("wsa:MessageId is required when wsa:ReplyTo is supplied");
+
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/addressing/jaxrpc/WSAddressingServerHandler.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingClientHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingClientHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingClientHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,152 @@
+/*
+ * 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.addressing.jaxws;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.addressing.AddressingBuilder;
+import javax.xml.ws.addressing.AddressingException;
+import javax.xml.ws.addressing.JAXWSAConstants;
+import javax.xml.ws.addressing.soap.SOAPAddressingBuilder;
+import javax.xml.ws.addressing.soap.SOAPAddressingProperties;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.addressing.soap.SOAPAddressingPropertiesImpl;
+
+/**
+ * A client side handler that reads/writes the addressing properties
+ * and puts then into the message context.
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 24-Nov-2005
+ */
+public class WSAddressingClientHandler implements SOAPHandler
+{
+   // Provide logging
+   private static Logger log = Logger.getLogger(WSAddressingClientHandler.class);
+
+   // addressing builder & constants
+   private AddressingBuilder addrBuilder;
+
+   // should the request be normalized according to the specifications
+   private boolean normalize;
+
+   public WSAddressingClientHandler()
+   {
+      addrBuilder = AddressingBuilder.getAddressingBuilder();
+   }
+
+   /**
+    * Gets the header blocks that can be processed by this Handler instance.
+    */
+   public Set<QName> getHeaders()
+   {
+      return new HashSet<QName>();
+   }
+
+   /**
+    * Read the addressing headers from the incomming message and put a
+    * SOAPAddressingProperties object into the message context
+    */
+   public boolean handleMessage(MessageContext msgContext)
+   {
+      String outbound = (String)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+
+      return outbound.equals("false") ? handleRequest(msgContext) : handleResponse(msgContext);
+   }
+
+   public boolean handleRequest(MessageContext msgContext)
+   {
+      log.debug("handleRequest");
+
+      SOAPAddressingProperties addrProps = (SOAPAddressingProperties)msgContext.get(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_OUTBOUND);
+      if (addrProps != null)
+      {
+         if (normalize)
+            normalizeRequest(msgContext, addrProps);
+
+         SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+         addrProps.writeHeaders(soapMessage);
+      }
+      else
+      {
+         // supply default addressing properties
+         addrProps = (SOAPAddressingPropertiesImpl)addrBuilder.newAddressingProperties();
+         msgContext.put(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_OUTBOUND, addrProps);
+
+         if (normalize)
+            normalizeRequest(msgContext, addrProps);
+      }
+
+      return true;
+   }
+
+   /* supply the default addressing properties in case elements are missing */
+   private void normalizeRequest(MessageContext msgContext, SOAPAddressingProperties addrProps)
+   {
+      // TODO: supply default header
+   }
+
+   public boolean handleResponse(MessageContext msgContext)
+   {
+      log.debug("handleResponse");
+
+      try
+      {
+         SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+         if (soapMessage.getSOAPPart().getEnvelope() != null)
+         {
+            SOAPAddressingBuilder builder = (SOAPAddressingBuilder)SOAPAddressingBuilder.getAddressingBuilder();
+            SOAPAddressingProperties addrProps = (SOAPAddressingProperties)builder.newAddressingProperties();
+            addrProps.readHeaders(soapMessage);
+            msgContext.put(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_INBOUND, addrProps);
+         }
+      }
+      catch (SOAPException ex)
+      {
+         throw new AddressingException("Cannot handle response", ex);
+      }
+
+      return true;
+   }
+
+   public boolean handleFault(MessageContext messagecontext)
+   {
+      // do nothing
+      return true;
+   }
+   
+   public void close(MessageContext messagecontext)
+   {
+      // do nothing
+   }
+
+}


Property changes on: trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingClientHandler.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingServerHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingServerHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingServerHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,185 @@
+/*
+ * 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.addressing.jaxws;
+
+import java.net.URISyntaxException;
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.addressing.AddressingBuilder;
+import javax.xml.ws.addressing.JAXWSAConstants;
+import javax.xml.ws.addressing.soap.SOAPAddressingBuilder;
+import javax.xml.ws.addressing.soap.SOAPAddressingProperties;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.addressing.AddressingConstantsImpl;
+import org.jboss.ws.addressing.metadata.AddressingOpMetaExt;
+import org.jboss.ws.common.SOAPMessageContextBase;
+import org.jboss.ws.metadata.OperationMetaData;
+
+/**
+ * A server side handler that reads/writes the addressing properties
+ * and puts then into the message context.
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 24-Nov-2005
+ */
+public class WSAddressingServerHandler implements SOAPHandler
+{
+   // Provide logging
+   private static Logger log = Logger.getLogger(WSAddressingServerHandler.class);
+
+   private static AddressingBuilder ADDR_BUILDER;
+   private static AddressingConstantsImpl ADDR_CONSTANTS;
+   static
+   {
+      ADDR_CONSTANTS = new AddressingConstantsImpl();
+      ADDR_BUILDER = AddressingBuilder.getAddressingBuilder();
+   }
+
+   // should the request be validated?
+   private boolean validate = true;
+
+   /**
+    * Gets the header blocks that can be processed by this Handler instance.
+    */
+   public Set<QName> getHeaders()
+   {
+      return new HashSet<QName>();
+   }
+
+   /**
+    * Read the addressing headers from the incomming message and put a
+    * SOAPAddressingProperties object into the message context
+    */
+   public boolean handleMessage(MessageContext msgContext)
+   {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+
+   private boolean handleRequest(MessageContext msgContext)
+   {
+      log.debug("handleRequest");
+
+      SOAPAddressingProperties addrProps = (SOAPAddressingProperties)ADDR_BUILDER.newAddressingProperties();
+      SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+      addrProps.readHeaders(soapMessage);
+      msgContext.put(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND, addrProps);
+
+      if (validate)
+         validateRequest(addrProps);
+
+      return true;
+   }
+
+   private boolean handleResponse(MessageContext msgContext)
+   {
+      log.debug("handleResponse");
+      handleResponseOrFault(msgContext, false);
+      return true;
+   }
+
+   /**
+    * Get a SOAPAddressingProperties object from the message context
+    * and write the adressing headers
+    */
+   public boolean handleFault(MessageContext msgContext)
+   {
+      log.debug("handleFault");
+      handleResponseOrFault(msgContext, true);
+      return true;
+   }
+
+   public void close(MessageContext messagecontext)
+   {
+      // nothig to do
+   }
+
+   private void handleResponseOrFault(MessageContext msgContext, boolean isFault)
+   {
+      SOAPAddressingBuilder builder = (SOAPAddressingBuilder)SOAPAddressingBuilder.getAddressingBuilder();
+      SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
+
+      SOAPAddressingProperties inProps = (SOAPAddressingProperties)msgContext.get(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND);
+      SOAPAddressingProperties outProps = (SOAPAddressingProperties)msgContext.get(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND);
+
+      if (outProps == null)
+      {
+         // create new response properties
+         outProps = (SOAPAddressingProperties)builder.newAddressingProperties();
+         msgContext.put(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND, outProps);
+      }
+
+      outProps.initializeAsReply(inProps, isFault);
+
+      try
+      {
+         // supply the response action
+
+         OperationMetaData opMetaData = ((SOAPMessageContextBase)msgContext).getOperationMetaData();
+
+         if (!isFault && !opMetaData.isOneWayOperation())
+         {
+
+            AddressingOpMetaExt addrExt = (AddressingOpMetaExt)opMetaData.getExtension(ADDR_CONSTANTS.getNamespaceURI());
+            if (addrExt != null)
+            {
+               outProps.setAction(ADDR_BUILDER.newURI(addrExt.getOutboundAction()));
+            }
+            else
+            {
+               log.warn("Unable to resolve replyAction for " + opMetaData.getQName());
+            }
+
+         }
+         else if (isFault)
+         {
+            outProps.setAction(ADDR_BUILDER.newURI(ADDR_CONSTANTS.getDefaultFaultAction()));
+         }
+
+      }
+      catch (URISyntaxException e)
+      {
+         log.error("Error setting response action", e);
+      }
+
+      outProps.writeHeaders(soapMessage);
+   }
+
+   /* check wsa formal constraints */
+   private void validateRequest(SOAPAddressingProperties addrProps)
+   {
+      // If wsa:ReplyTo is supplied and the message lacks a [message id] property, the processor MUST fault.
+      if (addrProps.getReplyTo() != null && addrProps.getMessageID() == null)
+         throw new IllegalArgumentException("wsa:MessageId is required when wsa:ReplyTo is supplied");
+
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/addressing/jaxws/WSAddressingServerHandler.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Deleted: trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPClientHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPClientHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPClientHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -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.addressing.soap;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.handler.GenericHandler;
-import javax.xml.rpc.handler.HandlerInfo;
-import javax.xml.rpc.handler.MessageContext;
-import javax.xml.rpc.handler.soap.SOAPMessageContext;
-import javax.xml.soap.SOAPException;
-import javax.xml.soap.SOAPMessage;
-import javax.xml.ws.addressing.AddressingBuilder;
-import javax.xml.ws.addressing.AddressingException;
-import javax.xml.ws.addressing.JAXWSAConstants;
-import javax.xml.ws.addressing.soap.SOAPAddressingBuilder;
-import javax.xml.ws.addressing.soap.SOAPAddressingProperties;
-
-import org.jboss.logging.Logger;
-
-/**
- * A client side handler that reads/writes the addressing properties
- * and puts then into the message context.
- *
- * @author Thomas.Diesler at jboss.org
- * @since 24-Nov-2005
- */
-public class SOAPClientHandler extends GenericHandler
-{
-   // Provide logging
-   private static Logger log = Logger.getLogger(SOAPClientHandler.class);
-
-   // addressing builder & constants
-   private AddressingBuilder addrBuilder;
-
-   // should the request be normalized according to the specifications
-   private boolean normalize;
-
-   public SOAPClientHandler()
-   {
-      addrBuilder = AddressingBuilder.getAddressingBuilder();
-   }
-
-   public QName[] getHeaders()
-   {
-      return new QName[] {};
-   }
-
-   public void init(HandlerInfo handlerInfo)
-   {
-      super.init(handlerInfo);
-      normalize = "true".equals(handlerInfo.getHandlerConfig().get("normalize"));
-
-   }
-
-   public boolean handleRequest(MessageContext msgContext)
-   {
-      log.debug("handleRequest");
-
-      SOAPAddressingProperties addrProps = (SOAPAddressingProperties)msgContext.getProperty(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_OUTBOUND);
-
-      if (addrProps != null)
-      {
-         if (normalize)
-            normalizeRequest(msgContext, addrProps);
-
-         SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
-         addrProps.writeHeaders(soapMessage);
-      }
-      else
-      {
-         // supply default addressing properties
-         addrProps = (SOAPAddressingPropertiesImpl)addrBuilder.newAddressingProperties();
-         msgContext.setProperty(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_OUTBOUND, addrProps);
-
-         if (normalize)
-            normalizeRequest(msgContext, addrProps);
-      }
-
-      return true;
-   }
-
-   /* supply the default addressing properties in case elements are missing */
-   private void normalizeRequest(MessageContext msgContext, SOAPAddressingProperties addrProps)
-   {
-      // TODO: supply default header
-   }
-
-   public boolean handleResponse(MessageContext msgContext)
-   {
-      log.debug("handleResponse");
-
-      try
-      {
-         SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
-         if (soapMessage.getSOAPPart().getEnvelope() != null)
-         {
-            SOAPAddressingBuilder builder = (SOAPAddressingBuilder)SOAPAddressingBuilder.getAddressingBuilder();
-            SOAPAddressingProperties addrProps = (SOAPAddressingProperties)builder.newAddressingProperties();
-            addrProps.readHeaders(soapMessage);
-            msgContext.setProperty(JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES_INBOUND, addrProps);
-         }
-      }
-      catch (SOAPException ex)
-      {
-         throw new AddressingException("Cannot handle response", ex);
-      }
-
-      return true;
-   }
-}

Deleted: trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPServerHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPServerHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/addressing/soap/SOAPServerHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,182 +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.addressing.soap;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
-import org.jboss.ws.metadata.OperationMetaData;
-import org.jboss.ws.addressing.AddressingConstantsImpl;
-import org.jboss.ws.addressing.metadata.AddressingOpMetaExt;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.handler.GenericHandler;
-import javax.xml.rpc.handler.HandlerInfo;
-import javax.xml.rpc.handler.MessageContext;
-import javax.xml.rpc.handler.soap.SOAPMessageContext;
-import javax.xml.soap.SOAPMessage;
-import javax.xml.ws.addressing.AddressingBuilder;
-import javax.xml.ws.addressing.JAXWSAConstants;
-import javax.xml.ws.addressing.soap.SOAPAddressingBuilder;
-import javax.xml.ws.addressing.soap.SOAPAddressingProperties;
-import java.net.URISyntaxException;
-
-/**
- * A server side handler that reads/writes the addressing properties
- * and puts then into the message context.
- *
- * @author Thomas.Diesler at jboss.org
- * @since 24-Nov-2005
- */
-public class SOAPServerHandler extends GenericHandler
-{
-   // Provide logging
-   private static Logger log = Logger.getLogger(SOAPServerHandler.class);
-
-   // should the request be validated?
-   private boolean validate = true;
-
-   // handler configuration
-   private HandlerInfo handlerInfo;
-
-   private static AddressingBuilder ADDR_BUILDER;
-
-   private static AddressingConstantsImpl ADDR_CONSTANTS;
-
-   static {
-      ADDR_CONSTANTS = new AddressingConstantsImpl();
-      ADDR_BUILDER = AddressingBuilder.getAddressingBuilder();
-   }
-
-   public QName[] getHeaders()
-   {
-      return new QName[]{};
-   }
-
-   public void init(HandlerInfo handlerInfo) {
-      super.init(handlerInfo);
-      this.handlerInfo = handlerInfo;
-
-      String validateParam = handlerInfo.getHandlerConfig().get("validate") != null ?
-            (String)handlerInfo.getHandlerConfig().get("validate") : Boolean.TRUE.toString();
-      if(Boolean.FALSE.toString().equals(validateParam)) validate = false;
-
-   }
-   /**
-    * Read the addressing headers from the incomming message and put a
-    * SOAPAddressingProperties object into the message context
-    */
-   public boolean handleRequest(MessageContext msgContext)
-   {
-      log.debug("handleRequest");
-
-      SOAPAddressingProperties addrProps = (SOAPAddressingProperties)ADDR_BUILDER.newAddressingProperties();
-      SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
-      addrProps.readHeaders(soapMessage);
-      msgContext.setProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND, addrProps);
-
-      if(validate) validateRequest(addrProps);
-
-      return true;
-   }
-
-   /**
-    * Get a SOAPAddressingProperties object from the message context
-    * and write the adressing headers
-    */
-   public boolean handleResponse(MessageContext msgContext)
-   {
-      log.debug("handleRequest");
-
-      handleResponseOrFault(msgContext, false);
-
-      return true;
-   }
-
-   /**
-    * Get a SOAPAddressingProperties object from the message context
-    * and write the adressing headers
-    */
-   public boolean handleFault(MessageContext msgContext)
-   {
-      log.debug("handleFault");
-
-      handleResponseOrFault(msgContext, true);
-
-      return true;
-   }
-
-   private void handleResponseOrFault(MessageContext msgContext, boolean isFault)
-   {
-      SOAPAddressingBuilder builder = (SOAPAddressingBuilder)SOAPAddressingBuilder.getAddressingBuilder();
-      SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
-
-      SOAPAddressingProperties inProps = (SOAPAddressingProperties)msgContext.getProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND);
-      SOAPAddressingProperties outProps = (SOAPAddressingProperties)msgContext.getProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND);
-
-      if (outProps == null)
-      {
-         // create new response properties
-         outProps = (SOAPAddressingProperties)builder.newAddressingProperties();
-         msgContext.setProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND, outProps);
-      }
-
-      outProps.initializeAsReply(inProps, isFault);
-
-      try
-      {
-         // supply the response action
-
-         OperationMetaData opMetaData = ((SOAPMessageContextJAXRPC)msgContext).getOperationMetaData();
-
-         if(!isFault && !opMetaData.isOneWayOperation()) {
-
-            AddressingOpMetaExt addrExt = (AddressingOpMetaExt)opMetaData.getExtension(ADDR_CONSTANTS.getNamespaceURI());
-            if(addrExt!=null) {
-               outProps.setAction(ADDR_BUILDER.newURI(addrExt.getOutboundAction()));
-            }
-            else {
-               log.warn("Unable to resolve replyAction for "+opMetaData.getQName());
-            }
-
-         }
-         else if(isFault) {
-            outProps.setAction(ADDR_BUILDER.newURI(ADDR_CONSTANTS.getDefaultFaultAction()));
-         }
-
-      }
-      catch (URISyntaxException e)
-      {
-         log.error("Error setting response action", e);
-      }
-      
-      outProps.writeHeaders(soapMessage);
-   }
-
-   /* check wsa formal constraints */
-   private void validateRequest(SOAPAddressingProperties addrProps) {
-
-      // If wsa:ReplyTo is supplied and the message lacks a [message id] property, the processor MUST fault.
-      if(addrProps.getReplyTo() != null && addrProps.getMessageID() == null)
-         throw new IllegalArgumentException("wsa:MessageId is required when wsa:ReplyTo is supplied");
-
-   }
-}

Modified: trunk/src/main/java/org/jboss/ws/binding/soap/JAXWSBindingProviderPayload.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/binding/soap/JAXWSBindingProviderPayload.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/binding/soap/JAXWSBindingProviderPayload.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -37,7 +37,7 @@
 import org.jboss.ws.binding.BindingProvider;
 import org.jboss.ws.binding.EndpointInvocation;
 import org.jboss.ws.binding.UnboundHeader;
-import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
+import org.jboss.ws.common.SOAPMessageContextBase;
 import org.jboss.ws.jaxws.handler.SOAPMessageContextJAXWS;
 import org.jboss.ws.metadata.OperationMetaData;
 import org.jboss.ws.metadata.ParameterMetaData;
@@ -99,7 +99,7 @@
 
       try
       {
-         SOAPMessageContextJAXRPC msgContext = (SOAPMessageContextJAXRPC)MessageContextAssociation.peekMessageContext();
+         SOAPMessageContextBase msgContext = MessageContextAssociation.peekMessageContext();
          if (msgContext == null)
             throw new WSException("MessageContext not available");
 

Modified: trunk/src/main/java/org/jboss/ws/common/CommonClient.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/common/CommonClient.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/common/CommonClient.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -21,7 +21,7 @@
  */
 package org.jboss.ws.common;
 
-// $Id$
+// $Id:CommonClient.java 660 2006-08-01 16:29:43Z thomas.diesler at jboss.com $
 
 import java.net.MalformedURLException;
 import java.net.URL;
@@ -48,6 +48,7 @@
 import org.jboss.ws.binding.UnboundHeader;
 import org.jboss.ws.jaxrpc.ParameterWrapping;
 import org.jboss.ws.jaxrpc.Style;
+import org.jboss.ws.jaxws.handler.MessageContextJAXWS;
 import org.jboss.ws.metadata.ClientEndpointMetaData;
 import org.jboss.ws.metadata.EndpointMetaData;
 import org.jboss.ws.metadata.OperationMetaData;

Modified: trunk/src/main/java/org/jboss/ws/deployment/JSR181MetaDataBuilder.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/deployment/JSR181MetaDataBuilder.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/deployment/JSR181MetaDataBuilder.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -39,9 +39,7 @@
 import javax.jws.WebParam;
 import javax.jws.WebResult;
 import javax.jws.WebService;
-import javax.jws.soap.InitParam;
 import javax.jws.soap.SOAPBinding;
-import javax.jws.soap.SOAPMessageHandler;
 import javax.jws.soap.SOAPMessageHandlers;
 import javax.management.ObjectName;
 import javax.xml.namespace.QName;
@@ -73,10 +71,9 @@
 import org.jboss.ws.metadata.UnifiedMetaData;
 import org.jboss.ws.metadata.EndpointMetaData.Type;
 import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedInitParamMetaData;
 import org.jboss.ws.metadata.jsr181.HandlerChainMetaData;
+import org.jboss.ws.metadata.jsr181.HandlerChainsMetaData;
 import org.jboss.ws.metadata.jsr181.HandlerConfigFactory;
-import org.jboss.ws.metadata.jsr181.HandlerConfigMetaData;
 import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
 import org.jboss.ws.metadata.wsdl.WSDLUtils;
 import org.jboss.ws.metadata.wsdl.xmlschema.JBossXSModel;
@@ -193,10 +190,8 @@
          processHandlerChain(wsClass, sepMetaData);
 
       // Process an optional @SOAPMessageHandlers annotation
-      if (sepClass.isAnnotationPresent(SOAPMessageHandlers.class))
-         processSOAPMessageHandlers(sepClass, sepMetaData);
-      else if (wsClass.isAnnotationPresent(SOAPMessageHandlers.class))
-         processSOAPMessageHandlers(wsClass, sepMetaData);
+      if (sepClass.isAnnotationPresent(SOAPMessageHandlers.class) || wsClass.isAnnotationPresent(SOAPMessageHandlers.class))
+         log.warn("@SOAPMessageHandlers is deprecated as of JSR-181 2.0 with no replacement.");
 
       // Process or generate WSDL
       String wsdlLocation = anWebService.wsdlLocation();
@@ -480,14 +475,16 @@
       String handlerChainFile = anHandlerChain.file();
       try
       {
-         HandlerConfigMetaData handlerConfigMetaData = null;
+         HandlerChainsMetaData handlerConfigMetaData = null;
          URL fileURL = new URL(handlerChainFile);
          InputStream is = fileURL.openStream();
          try
          {
             Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
+            unmarshaller.setValidation(true);
+            unmarshaller.setSchemaValidation(true);
             ObjectModelFactory factory = new HandlerConfigFactory(fileURL);
-            handlerConfigMetaData = (HandlerConfigMetaData)unmarshaller.unmarshal(is, factory, null);
+            handlerConfigMetaData = (HandlerChainsMetaData)unmarshaller.unmarshal(is, factory, null);
          }
          finally
          {
@@ -496,13 +493,9 @@
 
          for (HandlerChainMetaData handlerChainMetaData : handlerConfigMetaData.getHandlerChains())
          {
-            String hcName = handlerChainMetaData.getHandlerChainName();
-            if (hcName.equals(anHandlerChain.name()) || anHandlerChain.name() == null)
+            for (UnifiedHandlerMetaData handlerMetaData : handlerChainMetaData.getHandlers())
             {
-               for (UnifiedHandlerMetaData handlerMetaData : handlerChainMetaData.getHandlers())
-               {
-                  epMetaData.addHandler(handlerMetaData);
-               }
+               epMetaData.addHandler(handlerMetaData);
             }
          }
       }
@@ -516,38 +509,6 @@
       }
    }
 
-   // Process an optional @SOAPMessageHandlers annotation
-   private void processSOAPMessageHandlers(Class wsClass, ServerEndpointMetaData epMetaData)
-   {
-      if (wsClass.isAnnotationPresent(HandlerChain.class))
-         throw new WSException("Cannot combine @SOAPMessageHandlers with @HandlerChain");
-
-      SOAPMessageHandlers anSOAPMessageHandlers = (SOAPMessageHandlers)wsClass.getAnnotation(SOAPMessageHandlers.class);
-
-      for (SOAPMessageHandler handler : anSOAPMessageHandlers.value())
-      {
-         UnifiedHandlerMetaData handlerMetaData = new UnifiedHandlerMetaData();
-         handlerMetaData.setHandlerName(handler.name());
-         handlerMetaData.setHandlerClass(handler.className());
-         for (InitParam initParam : handler.initParams())
-         {
-            UnifiedInitParamMetaData initParamMetaData = new UnifiedInitParamMetaData();
-            initParamMetaData.setParamName(initParam.name());
-            initParamMetaData.setParamValue(initParam.value());
-            handlerMetaData.addInitParam(initParamMetaData);
-         }
-         for (String role : handler.roles())
-         {
-            handlerMetaData.addSoapRole(role);
-         }
-         for (String header : handler.headers())
-         {
-            handlerMetaData.addSoapHeader(QName.valueOf(header));
-         }
-         epMetaData.addHandler(handlerMetaData);
-      }
-   }
-
    private QName getWebParamName(OperationMetaData opMetaData, Map<String, Integer> typeIndexes, Class javaType, WebParam webParam)
    {
       QName xmlName = null;

Modified: trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointDeployer.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointDeployer.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointDeployer.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,204 +1,204 @@
-/*
- * 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.deployment;
-
-import java.util.Map;
-import java.util.concurrent.ConcurrentHashMap;
-
-import javax.management.ObjectName;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.WSException;
-import org.jboss.ws.metadata.EndpointMetaData;
-import org.jboss.ws.metadata.ServerEndpointMetaData;
-import org.jboss.ws.metadata.ServiceMetaData;
-import org.jboss.ws.metadata.UnifiedMetaData;
-import org.jboss.ws.server.ServiceEndpointInfo;
-import org.jboss.ws.server.ServiceEndpointManager;
-import org.jboss.ws.server.WSDLFilePublisher;
-
-/**
- * The POJO deployer for web service endpoints
- *
- * @author Thomas.Diesler at jboss.org
- * @since 12-May-2006
- */
-public class ServiceEndpointDeployer
-{
-   // logging support
-   private static Logger log = Logger.getLogger(ServiceEndpointDeployer.class);
-
-   // default bean name
-   public static final String BEAN_NAME = "ServiceEndpointDeployer";
-
-   // The servlet init param in web.xml that is the service endpoint class
-   public static final String INIT_PARAM_SERVICE_ENDPOINT_IMPL = "ServiceEndpointImpl";
-
-   // The ServiceEndpointManger injected by the kernel
-   private ServiceEndpointManager epManager;
-
-   // Maps the deployment url to UMDM
-   private Map<String, UnifiedMetaData> metaDataMap = new ConcurrentHashMap<String, UnifiedMetaData>();
-
-   // Injected by the Microkernel
-   public void setServiceEndpointManager(ServiceEndpointManager epManager)
-   {
-      this.epManager = epManager;
-   }
-
-   public void create(UnifiedDeploymentInfo udi) throws Throwable
-   {
-      log.debug("create: " + udi.url);
-
-      UnifiedMetaData wsMetaData;
-      if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR109_JSE)
-      {
-         JSR109ServerMetaDataBuilder builder = new JSR109ServerMetaDataBuilder();
-         builder.setClassLoader(null); // the web context loader is not available yet
-         builder.setResourceLoader(udi.localCl);
-         wsMetaData = builder.buildMetaData((JSR109Deployment)udi);
-      }
-      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR109_EJB21)
-      {
-         JSR109ServerMetaDataBuilder builder = new JSR109ServerMetaDataBuilder();
-         builder.setClassLoader(udi.ucl);
-         builder.setResourceLoader(udi.localCl);
-         wsMetaData = builder.buildMetaData((JSR109Deployment)udi);
-      }
-      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR181_JSE)
-      {
-         JSR181MetaDataBuilderJSE builder = new JSR181MetaDataBuilderJSE();
-         builder.setClassLoader(udi.annotationsCl);
-         builder.setResourceLoader(udi.localCl);
-         wsMetaData = builder.buildMetaData(udi);
-      }
-      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR181_EJB21)
-      {
-         JSR181MetaDataBuilderEJB21 builder = new JSR181MetaDataBuilderEJB21();
-         builder.setClassLoader(udi.annotationsCl);
-         builder.setResourceLoader(udi.localCl);
-         wsMetaData = builder.buildMetaData(udi);
-      }
-      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR181_EJB3)
-      {
-         JSR181MetaDataBuilderEJB3 builder = new JSR181MetaDataBuilderEJB3();
-         builder.setClassLoader(udi.annotationsCl);
-         builder.setResourceLoader(udi.localCl);
-         wsMetaData = builder.buildMetaData(udi);
-      }
-      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JAXWS_PROVIDER_JSE)
-      {
-         JAXWSProviderMetaDataBuilderJSE builder = new JAXWSProviderMetaDataBuilderJSE();
-         builder.setClassLoader(udi.annotationsCl);
-         builder.setResourceLoader(udi.localCl);
-         wsMetaData = builder.buildMetaData(udi);
-      }
-      else
-      {
-         throw new WSException("Invalid type:  " + udi.type);
-      }
-
-      metaDataMap.put(udi.url.toExternalForm(), wsMetaData);
-
-      for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
-      {
-         for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
-         {
-            ServiceEndpointInfo seInfo = new ServiceEndpointInfo(udi, (ServerEndpointMetaData)epMetaData);
-            epManager.createServiceEndpoint(seInfo);
-         }
-      }
-   }
-
-   public void start(UnifiedDeploymentInfo udi) throws Throwable
-   {
-      log.debug("start: " + udi.url);
-
-      UnifiedMetaData wsMetaData = getUnifiedMetaData(udi);
-      if (wsMetaData != null)
-      {
-         // late initialization of the web context loader
-         if (wsMetaData.getClassLoader() != udi.ucl)
-            wsMetaData.setClassLoader(udi.ucl);
-         
-         // Publish the WSDL file
-         WSDLFilePublisher wsdlfp = new WSDLFilePublisher(udi);
-         wsdlfp.publishWsdlFiles(wsMetaData);
-         for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
-         {
-            for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
-            {
-               ObjectName sepID = ((ServerEndpointMetaData)epMetaData).getServiceEndpointID();
-               epManager.startServiceEndpoint(sepID);
-            }
-         }
-      }      
-   }
-
-   public void stop(UnifiedDeploymentInfo udi) throws Throwable
-   {
-      log.debug("stop: " + udi.url);
-
-      UnifiedMetaData wsMetaData = getUnifiedMetaData(udi);
-      if (wsMetaData != null)
-      {
-         // Stop the service endpoints
-         for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
-         {
-            for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
-            {
-               ObjectName sepID = ((ServerEndpointMetaData)epMetaData).getServiceEndpointID();
-               epManager.stopServiceEndpoint(sepID);
-            }
-         }
-         
-         // Unpublish the WSDL file
-         WSDLFilePublisher wsdlfp = new WSDLFilePublisher(udi);
-         wsdlfp.unpublishWsdlFiles();
-      }      
-   }
-
-   public void destroy(UnifiedDeploymentInfo udi) throws Throwable
-   {
-      log.debug("destroy: " + udi.url);
-
-      UnifiedMetaData wsMetaData = getUnifiedMetaData(udi);
-      if (wsMetaData != null)
-      {
-         // Destroy the service endpoints
-         for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
-         {
-            for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
-            {
-               ObjectName sepID = ((ServerEndpointMetaData)epMetaData).getServiceEndpointID();
-               epManager.destroyServiceEndpoint(sepID);
-            }
-         }
-      }      
-   }
-
-   public UnifiedMetaData getUnifiedMetaData(UnifiedDeploymentInfo udi)
-   {
-      UnifiedMetaData wsMetaData = metaDataMap.get(udi.url.toExternalForm());
-      return wsMetaData;
-   }
+/*
+ * 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.deployment;
+
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+
+import javax.management.ObjectName;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.WSException;
+import org.jboss.ws.metadata.EndpointMetaData;
+import org.jboss.ws.metadata.ServerEndpointMetaData;
+import org.jboss.ws.metadata.ServiceMetaData;
+import org.jboss.ws.metadata.UnifiedMetaData;
+import org.jboss.ws.server.ServiceEndpointInfo;
+import org.jboss.ws.server.ServiceEndpointManager;
+import org.jboss.ws.server.WSDLFilePublisher;
+
+/**
+ * The POJO deployer for web service endpoints
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-May-2006
+ */
+public class ServiceEndpointDeployer
+{
+   // logging support
+   private static Logger log = Logger.getLogger(ServiceEndpointDeployer.class);
+
+   // default bean name
+   public static final String BEAN_NAME = "ServiceEndpointDeployer";
+
+   // The servlet init param in web.xml that is the service endpoint class
+   public static final String INIT_PARAM_SERVICE_ENDPOINT_IMPL = "ServiceEndpointImpl";
+
+   // The ServiceEndpointManger injected by the kernel
+   private ServiceEndpointManager epManager;
+
+   // Maps the deployment url to UMDM
+   private Map<String, UnifiedMetaData> metaDataMap = new ConcurrentHashMap<String, UnifiedMetaData>();
+
+   // Injected by the Microkernel
+   public void setServiceEndpointManager(ServiceEndpointManager epManager)
+   {
+      this.epManager = epManager;
+   }
+
+   public void create(UnifiedDeploymentInfo udi) throws Throwable
+   {
+      log.debug("create: " + udi.url);
+
+      UnifiedMetaData wsMetaData;
+      if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR109_JSE)
+      {
+         JSR109ServerMetaDataBuilder builder = new JSR109ServerMetaDataBuilder();
+         builder.setClassLoader(null); // the web context loader is not available yet
+         builder.setResourceLoader(udi.localCl);
+         wsMetaData = builder.buildMetaData((JSR109Deployment)udi);
+      }
+      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR109_EJB21)
+      {
+         JSR109ServerMetaDataBuilder builder = new JSR109ServerMetaDataBuilder();
+         builder.setClassLoader(udi.ucl);
+         builder.setResourceLoader(udi.localCl);
+         wsMetaData = builder.buildMetaData((JSR109Deployment)udi);
+      }
+      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR181_JSE)
+      {
+         JSR181MetaDataBuilderJSE builder = new JSR181MetaDataBuilderJSE();
+         builder.setClassLoader(udi.annotationsCl);
+         builder.setResourceLoader(udi.localCl);
+         wsMetaData = builder.buildMetaData(udi);
+      }
+      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR181_EJB21)
+      {
+         JSR181MetaDataBuilderEJB21 builder = new JSR181MetaDataBuilderEJB21();
+         builder.setClassLoader(udi.annotationsCl);
+         builder.setResourceLoader(udi.localCl);
+         wsMetaData = builder.buildMetaData(udi);
+      }
+      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JSR181_EJB3)
+      {
+         JSR181MetaDataBuilderEJB3 builder = new JSR181MetaDataBuilderEJB3();
+         builder.setClassLoader(udi.annotationsCl);
+         builder.setResourceLoader(udi.localCl);
+         wsMetaData = builder.buildMetaData(udi);
+      }
+      else if (udi.type == UnifiedDeploymentInfo.DeploymentType.JAXWS_PROVIDER_JSE)
+      {
+         JAXWSProviderMetaDataBuilderJSE builder = new JAXWSProviderMetaDataBuilderJSE();
+         builder.setClassLoader(udi.annotationsCl);
+         builder.setResourceLoader(udi.localCl);
+         wsMetaData = builder.buildMetaData(udi);
+      }
+      else
+      {
+         throw new WSException("Invalid type:  " + udi.type);
+      }
+
+      metaDataMap.put(udi.url.toExternalForm(), wsMetaData);
+
+      for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
+      {
+         for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
+         {
+            ServiceEndpointInfo seInfo = new ServiceEndpointInfo(udi, (ServerEndpointMetaData)epMetaData);
+            epManager.createServiceEndpoint(seInfo);
+         }
+      }
+   }
+
+   public void start(UnifiedDeploymentInfo udi) throws Throwable
+   {
+      log.debug("start: " + udi.url);
+
+      UnifiedMetaData wsMetaData = getUnifiedMetaData(udi);
+      if (wsMetaData != null)
+      {
+         // late initialization of the web context loader
+         if (wsMetaData.getClassLoader() != udi.ucl)
+            wsMetaData.setClassLoader(udi.ucl);
+         
+         // Publish the WSDL file
+         WSDLFilePublisher wsdlfp = new WSDLFilePublisher(udi);
+         wsdlfp.publishWsdlFiles(wsMetaData);
+         for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
+         {
+            for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
+            {
+               ObjectName sepID = ((ServerEndpointMetaData)epMetaData).getServiceEndpointID();
+               epManager.startServiceEndpoint(sepID);
+            }
+         }
+      }      
+   }
+
+   public void stop(UnifiedDeploymentInfo udi) throws Throwable
+   {
+      log.debug("stop: " + udi.url);
+
+      UnifiedMetaData wsMetaData = getUnifiedMetaData(udi);
+      if (wsMetaData != null)
+      {
+         // Stop the service endpoints
+         for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
+         {
+            for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
+            {
+               ObjectName sepID = ((ServerEndpointMetaData)epMetaData).getServiceEndpointID();
+               epManager.stopServiceEndpoint(sepID);
+            }
+         }
+         
+         // Unpublish the WSDL file
+         WSDLFilePublisher wsdlfp = new WSDLFilePublisher(udi);
+         wsdlfp.unpublishWsdlFiles();
+      }      
+   }
+
+   public void destroy(UnifiedDeploymentInfo udi) throws Throwable
+   {
+      log.debug("destroy: " + udi.url);
+
+      UnifiedMetaData wsMetaData = getUnifiedMetaData(udi);
+      if (wsMetaData != null)
+      {
+         // Destroy the service endpoints
+         for (ServiceMetaData serviceMetaData : wsMetaData.getServices())
+         {
+            for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
+            {
+               ObjectName sepID = ((ServerEndpointMetaData)epMetaData).getServiceEndpointID();
+               epManager.destroyServiceEndpoint(sepID);
+            }
+         }
+      }      
+   }
+
+   public UnifiedMetaData getUnifiedMetaData(UnifiedDeploymentInfo udi)
+   {
+      UnifiedMetaData wsMetaData = metaDataMap.get(udi.url.toExternalForm());
+      return wsMetaData;
+   }
 }
\ No newline at end of file

Modified: trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointPublisher.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointPublisher.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/deployment/ServiceEndpointPublisher.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,242 +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.
- */
-package org.jboss.ws.deployment;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.jboss.logging.Logger;
-import org.jboss.util.xml.DOMUtils;
-import org.jboss.util.xml.DOMWriter;
-import org.jboss.ws.WSException;
-import org.w3c.dom.Element;
-
-/**
- * The publisher for web service endpoints
- *
- * @author Thomas.Diesler at jboss.org
- * @since 12-May-2006
- */
-public abstract class ServiceEndpointPublisher
-{
-   // default bean name
-   public static final String BEAN_NAME = "ServiceEndpointPublisher";
-
-   // The servlet init param in web.xml that is the service endpoint class
-   public static final String INIT_PARAM_SERVICE_ENDPOINT_IMPL = "ServiceEndpointImpl";
-
-   // logging support
-   private static Logger log = Logger.getLogger(ServiceEndpointPublisher.class);
-
-   // The service endpoint deployer
-   protected ServiceEndpointDeployer serviceEndpointDeployer;
-   // The configured service endpoint servlet
-   protected String servletName;
-
-   public ServiceEndpointDeployer getServiceEndpointDeployer()
-   {
-      return serviceEndpointDeployer;
-   }
-
-   public void setServiceEndpointDeployer(ServiceEndpointDeployer serviceEndpointDeployer)
-   {
-      this.serviceEndpointDeployer = serviceEndpointDeployer;
-   }
-
-   public String getServiceEndpointServlet()
-   {
-      return servletName;
-   }
-
-   public void setServiceEndpointServlet(String servletName)
-   {
-      this.servletName = servletName;
-   }
-
-   public abstract String publishServiceEndpoint(URL warURL) throws Exception;
-
-   public abstract String destroyServiceEndpoint(URL warURL) throws Exception;
-
-   public abstract String publishServiceEndpoint(UnifiedDeploymentInfo udi) throws Exception;
-
-   public abstract String destroyServiceEndpoint(UnifiedDeploymentInfo udi) throws Exception;
-
-   public Map<String, String> rewriteWebXML(URL warURL)
-   {
-      File warFile = new File(warURL.getFile());
-      if (warFile.isDirectory() == false)
-         throw new WSException("Expected a war directory: " + warURL);
-
-      File webXML = new File(warURL.getFile() + "/WEB-INF/web.xml");
-      if (webXML.isFile() == false)
-         throw new WSException("Cannot find web.xml: " + webXML);
-
-      try
-      {
-         Element root = DOMUtils.parse(new FileInputStream(webXML));
-
-         String warName = warFile.getName();
-         Map<String, String> sepTargetMap = modifyServletConfig(root, warName);
-
-         // After redeployment there might be a stale copy of the original web.xml.org, we delete it
-         File orgWebXML = new File(webXML.getCanonicalPath() + ".org");
-         orgWebXML.delete();
-
-         // Rename the web.xml
-         if (webXML.renameTo(orgWebXML) == false)
-            throw new WSException("Cannot rename web.xml: " + orgWebXML);
-
-         FileOutputStream fos = new FileOutputStream(webXML);
-         new DOMWriter(fos).setPrettyprint(true).print(root);
-         fos.close();
-
-         return sepTargetMap;
-      }
-      catch (RuntimeException rte)
-      {
-         throw rte;
-      }
-      catch (Exception e)
-      {
-         throw new WSException(e);
-      }
-   }
-
-   private Map<String, String> modifyServletConfig(Element root, String warName)
-   {
-      Map<String, String> sepTargetMap = new HashMap<String, String>();
-
-      Iterator itServlets = DOMUtils.getChildElements(root, "servlet");
-      while (itServlets.hasNext())
-      {
-         Element servletElement = (Element)itServlets.next();
-         String linkName = DOMUtils.getTextContent(DOMUtils.getFirstChildElement(servletElement, "servlet-name"));
-
-         // find the servlet-class
-         Element classElement = DOMUtils.getFirstChildElement(servletElement, "servlet-class");
-         if (classElement == null)
-            throw new WSException("Cannot find <servlet-class> for servlet-name: " + linkName);
-
-         // Get the servlet class
-         String servletClassName = DOMUtils.getTextContent(classElement);
-
-         String targetBeanName = null;
-
-         // Nothing to do if we have an <init-param> 
-         if (isAlreadyModified(servletElement) == false)
-         {
-            // Check if it is a real servlet that we can ignore
-            if (servletClassName.endsWith("Servlet"))
-            {
-               log.info("Ignore <servlet-class> that ends with 'Servlet': " + servletClassName);
-               continue;
-            }
-            
-            // build a list of detached elements that come after <servlet-class>
-            boolean startDetach = false;
-            List<Element> detachedElements = new ArrayList<Element>();
-            Iterator itDetached = DOMUtils.getChildElements(servletElement);
-            while (itDetached.hasNext())
-            {
-               Element el = (Element)itDetached.next();
-               if (startDetach == true)
-               {
-                  detachedElements.add(el);
-                  servletElement.removeChild(el);
-               }
-               if (el.equals(classElement))
-               {
-                  servletElement.removeChild(el);
-                  startDetach = true;
-               }
-            }
-
-            // replace the class name
-            classElement = (Element)DOMUtils.createElement("servlet-class");
-            classElement.appendChild(DOMUtils.createTextNode(servletName));
-            classElement = (Element)servletElement.getOwnerDocument().importNode(classElement, true);
-            servletElement.appendChild(classElement);
-
-            // add additional init params
-            if (servletClassName.equals(servletName) == false)
-            {
-               Element paramElement = DOMUtils.createElement("init-param");
-               paramElement.appendChild(DOMUtils.createElement("param-name")).appendChild(DOMUtils.createTextNode(INIT_PARAM_SERVICE_ENDPOINT_IMPL));
-               paramElement.appendChild(DOMUtils.createElement("param-value")).appendChild(DOMUtils.createTextNode(servletClassName));
-               paramElement = (Element)servletElement.getOwnerDocument().importNode(paramElement, true);
-               servletElement.appendChild(paramElement);
-               targetBeanName = servletClassName;
-            }
-
-            // reattach the elements
-            itDetached = detachedElements.iterator();
-            while (itDetached.hasNext())
-            {
-               Element el = (Element)itDetached.next();
-               servletElement.appendChild(el);
-            }
-         }
-         else
-         {
-            Iterator itParams = DOMUtils.getChildElements(servletElement, "init-param");
-            while (itParams.hasNext())
-            {
-               Element elParam = (Element)itParams.next();
-               Element elParamName = DOMUtils.getFirstChildElement(elParam, "param-name");
-               Element elParamValue = DOMUtils.getFirstChildElement(elParam, "param-value");
-               if (INIT_PARAM_SERVICE_ENDPOINT_IMPL.equals(DOMUtils.getTextContent(elParamName)))
-               {
-                  targetBeanName = DOMUtils.getTextContent(elParamValue);
-               }
-            }
-         }
-
-         if (targetBeanName == null)
-            throw new IllegalStateException("Cannot obtain service endpoint bean for: " + linkName);
-         
-         sepTargetMap.put(linkName, targetBeanName);
-      }
-
-      return sepTargetMap;
-   }
-
-   // Return true if the web.xml is already modified
-   private boolean isAlreadyModified(Element servletElement)
-   {
-      Iterator itParams = DOMUtils.getChildElements(servletElement, "init-param");
-      while (itParams.hasNext())
-      {
-         Element elParam = (Element)itParams.next();
-         Element elParamName = DOMUtils.getFirstChildElement(elParam, "param-name");
-         if (INIT_PARAM_SERVICE_ENDPOINT_IMPL.equals(DOMUtils.getTextContent(elParamName)))
-            return true;
-      }
-      return false;
-   }
+/*
+ * 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.deployment;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+
+import org.jboss.logging.Logger;
+import org.jboss.util.xml.DOMUtils;
+import org.jboss.util.xml.DOMWriter;
+import org.jboss.ws.WSException;
+import org.w3c.dom.Element;
+
+/**
+ * The publisher for web service endpoints
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-May-2006
+ */
+public abstract class ServiceEndpointPublisher
+{
+   // default bean name
+   public static final String BEAN_NAME = "ServiceEndpointPublisher";
+
+   // The servlet init param in web.xml that is the service endpoint class
+   public static final String INIT_PARAM_SERVICE_ENDPOINT_IMPL = "ServiceEndpointImpl";
+
+   // logging support
+   private static Logger log = Logger.getLogger(ServiceEndpointPublisher.class);
+
+   // The service endpoint deployer
+   protected ServiceEndpointDeployer serviceEndpointDeployer;
+   // The configured service endpoint servlet
+   protected String servletName;
+
+   public ServiceEndpointDeployer getServiceEndpointDeployer()
+   {
+      return serviceEndpointDeployer;
+   }
+
+   public void setServiceEndpointDeployer(ServiceEndpointDeployer serviceEndpointDeployer)
+   {
+      this.serviceEndpointDeployer = serviceEndpointDeployer;
+   }
+
+   public String getServiceEndpointServlet()
+   {
+      return servletName;
+   }
+
+   public void setServiceEndpointServlet(String servletName)
+   {
+      this.servletName = servletName;
+   }
+
+   public abstract String publishServiceEndpoint(URL warURL) throws Exception;
+
+   public abstract String destroyServiceEndpoint(URL warURL) throws Exception;
+
+   public abstract String publishServiceEndpoint(UnifiedDeploymentInfo udi) throws Exception;
+
+   public abstract String destroyServiceEndpoint(UnifiedDeploymentInfo udi) throws Exception;
+
+   public Map<String, String> rewriteWebXML(URL warURL)
+   {
+      File warFile = new File(warURL.getFile());
+      if (warFile.isDirectory() == false)
+         throw new WSException("Expected a war directory: " + warURL);
+
+      File webXML = new File(warURL.getFile() + "/WEB-INF/web.xml");
+      if (webXML.isFile() == false)
+         throw new WSException("Cannot find web.xml: " + webXML);
+
+      try
+      {
+         Element root = DOMUtils.parse(new FileInputStream(webXML));
+
+         String warName = warFile.getName();
+         Map<String, String> sepTargetMap = modifyServletConfig(root, warName);
+
+         // After redeployment there might be a stale copy of the original web.xml.org, we delete it
+         File orgWebXML = new File(webXML.getCanonicalPath() + ".org");
+         orgWebXML.delete();
+
+         // Rename the web.xml
+         if (webXML.renameTo(orgWebXML) == false)
+            throw new WSException("Cannot rename web.xml: " + orgWebXML);
+
+         FileOutputStream fos = new FileOutputStream(webXML);
+         new DOMWriter(fos).setPrettyprint(true).print(root);
+         fos.close();
+
+         return sepTargetMap;
+      }
+      catch (RuntimeException rte)
+      {
+         throw rte;
+      }
+      catch (Exception e)
+      {
+         throw new WSException(e);
+      }
+   }
+
+   private Map<String, String> modifyServletConfig(Element root, String warName)
+   {
+      Map<String, String> sepTargetMap = new HashMap<String, String>();
+
+      Iterator itServlets = DOMUtils.getChildElements(root, "servlet");
+      while (itServlets.hasNext())
+      {
+         Element servletElement = (Element)itServlets.next();
+         String linkName = DOMUtils.getTextContent(DOMUtils.getFirstChildElement(servletElement, "servlet-name"));
+
+         // find the servlet-class
+         Element classElement = DOMUtils.getFirstChildElement(servletElement, "servlet-class");
+         if (classElement == null)
+            throw new WSException("Cannot find <servlet-class> for servlet-name: " + linkName);
+
+         // Get the servlet class
+         String servletClassName = DOMUtils.getTextContent(classElement);
+
+         String targetBeanName = null;
+
+         // Nothing to do if we have an <init-param> 
+         if (isAlreadyModified(servletElement) == false)
+         {
+            // Check if it is a real servlet that we can ignore
+            if (servletClassName.endsWith("Servlet"))
+            {
+               log.info("Ignore <servlet-class> that ends with 'Servlet': " + servletClassName);
+               continue;
+            }
+            
+            // build a list of detached elements that come after <servlet-class>
+            boolean startDetach = false;
+            List<Element> detachedElements = new ArrayList<Element>();
+            Iterator itDetached = DOMUtils.getChildElements(servletElement);
+            while (itDetached.hasNext())
+            {
+               Element el = (Element)itDetached.next();
+               if (startDetach == true)
+               {
+                  detachedElements.add(el);
+                  servletElement.removeChild(el);
+               }
+               if (el.equals(classElement))
+               {
+                  servletElement.removeChild(el);
+                  startDetach = true;
+               }
+            }
+
+            // replace the class name
+            classElement = (Element)DOMUtils.createElement("servlet-class");
+            classElement.appendChild(DOMUtils.createTextNode(servletName));
+            classElement = (Element)servletElement.getOwnerDocument().importNode(classElement, true);
+            servletElement.appendChild(classElement);
+
+            // add additional init params
+            if (servletClassName.equals(servletName) == false)
+            {
+               Element paramElement = DOMUtils.createElement("init-param");
+               paramElement.appendChild(DOMUtils.createElement("param-name")).appendChild(DOMUtils.createTextNode(INIT_PARAM_SERVICE_ENDPOINT_IMPL));
+               paramElement.appendChild(DOMUtils.createElement("param-value")).appendChild(DOMUtils.createTextNode(servletClassName));
+               paramElement = (Element)servletElement.getOwnerDocument().importNode(paramElement, true);
+               servletElement.appendChild(paramElement);
+               targetBeanName = servletClassName;
+            }
+
+            // reattach the elements
+            itDetached = detachedElements.iterator();
+            while (itDetached.hasNext())
+            {
+               Element el = (Element)itDetached.next();
+               servletElement.appendChild(el);
+            }
+         }
+         else
+         {
+            Iterator itParams = DOMUtils.getChildElements(servletElement, "init-param");
+            while (itParams.hasNext())
+            {
+               Element elParam = (Element)itParams.next();
+               Element elParamName = DOMUtils.getFirstChildElement(elParam, "param-name");
+               Element elParamValue = DOMUtils.getFirstChildElement(elParam, "param-value");
+               if (INIT_PARAM_SERVICE_ENDPOINT_IMPL.equals(DOMUtils.getTextContent(elParamName)))
+               {
+                  targetBeanName = DOMUtils.getTextContent(elParamValue);
+               }
+            }
+         }
+
+         if (targetBeanName == null)
+            throw new IllegalStateException("Cannot obtain service endpoint bean for: " + linkName);
+         
+         sepTargetMap.put(linkName, targetBeanName);
+      }
+
+      return sepTargetMap;
+   }
+
+   // Return true if the web.xml is already modified
+   private boolean isAlreadyModified(Element servletElement)
+   {
+      Iterator itParams = DOMUtils.getChildElements(servletElement, "init-param");
+      while (itParams.hasNext())
+      {
+         Element elParam = (Element)itParams.next();
+         Element elParamName = DOMUtils.getFirstChildElement(elParam, "param-name");
+         if (INIT_PARAM_SERVICE_ENDPOINT_IMPL.equals(DOMUtils.getTextContent(elParamName)))
+            return true;
+      }
+      return false;
+   }
 }
\ No newline at end of file

Modified: trunk/src/main/java/org/jboss/ws/jaxrpc/InvokerDelegateJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxrpc/InvokerDelegateJAXRPC.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/jaxrpc/InvokerDelegateJAXRPC.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -90,7 +90,7 @@
    }
 
    /** Invoke the the service endpoint */
-   public SOAPMessage invoke(ServiceEndpointInfo seInfo, Object endpointContext) throws Exception
+   public SOAPMessage invoke(ServiceEndpointInfo seInfo, Object context) throws Exception
    {
       SOAPMessageContextBase msgContext = MessageContextAssociation.peekMessageContext();
       EndpointMetaData epMetaData = msgContext.getEndpointMetaData();
@@ -100,7 +100,7 @@
       Class seImpl = sepInvoker.loadServiceEndpoint(seInfo);
 
       // Create an instance of the endpoint implementation bean
-      Object seInstance = sepInvoker.createServiceEndpoint(seInfo, endpointContext, seImpl);
+      Object seInstance = sepInvoker.createServiceEndpoint(seInfo, context, seImpl);
 
       try
       {

Copied: trunk/src/main/java/org/jboss/ws/jaxrpc/ServletEndpointContextImpl.java (from rev 673, trunk/src/main/java/org/jboss/ws/server/ServletEndpointContextImpl.java)
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/ServletEndpointContextImpl.java	2006-08-03 08:57:12 UTC (rev 673)
+++ trunk/src/main/java/org/jboss/ws/jaxrpc/ServletEndpointContextImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,94 @@
+/*
+ * 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.jaxrpc;
+
+// $Id$
+
+import java.security.Principal;
+
+import javax.servlet.ServletContext;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.servlet.http.HttpSession;
+import javax.xml.rpc.handler.MessageContext;
+import javax.xml.rpc.server.ServletEndpointContext;
+
+import org.jboss.ws.server.EndpointContext;
+import org.jboss.ws.soap.MessageContextAssociation;
+
+/**
+ * Implementation of <code>ServletEndpointContext</code>
+ *
+ * @author <a href="mailto:jason at stacksmash.com">Jason T. Greene</a>
+ */
+public class ServletEndpointContextImpl implements ServletEndpointContext
+{
+   private ServletContext context;
+   private HttpServletRequest request;
+   private HttpServletResponse response;
+
+   public ServletEndpointContextImpl(EndpointContext context)
+   {
+      this.context = context.getServletContext();
+      this.request = context.getHttpServletRequest();
+      this.response = context.getHttpServletResponse();
+   }
+
+   public HttpSession getHttpSession()
+   {
+      return request.getSession();
+   }
+
+   public MessageContext getMessageContext()
+   {
+      return (MessageContext)MessageContextAssociation.peekMessageContext();
+   }
+
+   public ServletContext getServletContext()
+   {
+      return context;
+   }
+
+   public Principal getUserPrincipal()
+   {
+      return request.getUserPrincipal();
+   }
+
+   public boolean isUserInRole(String role)
+   {
+      return request.isUserInRole(role);
+   }
+
+   // BEGIN non-standard access methods
+
+   public HttpServletRequest getHttpServletRequest()
+   {
+      return request;
+   }
+
+   public HttpServletResponse getHttpServletResponse()
+   {
+      return response;
+   }
+
+   // END non-standard access methods
+}
\ No newline at end of file


Property changes on: trunk/src/main/java/org/jboss/ws/jaxrpc/ServletEndpointContextImpl.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/main/java/org/jboss/ws/jaxws/InvokerDelegateJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxws/InvokerDelegateJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/jaxws/InvokerDelegateJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -24,6 +24,12 @@
 // $Id$
 
 import java.lang.reflect.InvocationTargetException;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
 
 import javax.management.MBeanException;
 import javax.xml.namespace.QName;
@@ -37,15 +43,22 @@
 import javax.xml.ws.Service.Mode;
 
 import org.jboss.logging.Logger;
-import org.jboss.util.NotImplementedException;
 import org.jboss.ws.Constants;
+import org.jboss.ws.WSException;
 import org.jboss.ws.binding.BindingProvider;
 import org.jboss.ws.binding.BindingProviderRegistry;
 import org.jboss.ws.binding.EndpointInvocation;
-import org.jboss.ws.common.SOAPMessageContextBase;
 import org.jboss.ws.jaxrpc.SOAPFaultExceptionHelper;
+import org.jboss.ws.jaxws.handler.HandlerChainBaseImpl;
+import org.jboss.ws.jaxws.handler.HandlerInfo;
+import org.jboss.ws.jaxws.handler.MessageContextJAXWS;
+import org.jboss.ws.jaxws.handler.SOAPMessageContextJAXWS;
+import org.jboss.ws.jaxws.handler.ServerHandlerChain;
 import org.jboss.ws.metadata.EndpointMetaData;
 import org.jboss.ws.metadata.OperationMetaData;
+import org.jboss.ws.metadata.ServerEndpointMetaData;
+import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
+import org.jboss.ws.metadata.j2ee.UnifiedInitParamMetaData;
 import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData.HandlerType;
 import org.jboss.ws.server.InvokerDelegate;
 import org.jboss.ws.server.ServiceEndpointInfo;
@@ -64,6 +77,12 @@
    private static Logger log = Logger.getLogger(InvokerDelegateJAXWS.class);
 
    private ServiceEndpointInvoker sepInvoker;
+   // This endpoints handler chain
+   private ServerHandlerChain preHandlerChain;
+   // This endpoints handler chain
+   private ServerHandlerChain jaxwsHandlerChain;
+   // This endpoints handler chain
+   private ServerHandlerChain postHandlerChain;
 
    public InvokerDelegateJAXWS(ServiceEndpointInvoker sepInvoker)
    {
@@ -73,7 +92,7 @@
    /** Invoke the the service endpoint */
    public SOAPMessage invoke(ServiceEndpointInfo seInfo, Object endpointContext) throws Exception
    {
-      SOAPMessageContextBase msgContext = MessageContextAssociation.peekMessageContext();
+      SOAPMessageContextJAXWS msgContext = (SOAPMessageContextJAXWS)MessageContextAssociation.peekMessageContext();
       EndpointMetaData epMetaData = msgContext.getEndpointMetaData();
       SOAPMessageImpl reqMessage = (SOAPMessageImpl)msgContext.getMessage();
 
@@ -123,6 +142,9 @@
             // Bind the response message
             SOAPMessage resMessage = bindingProvider.bindResponseMessage(opMetaData, epInv);
             msgContext.setMessage(resMessage);
+            
+            // Mark the message context as outbound
+            msgContext.setProperty(MessageContextJAXWS.MESSAGE_OUTBOUND_PROPERTY, new Boolean(true));
          }
 
          // call the handler chain
@@ -235,18 +257,124 @@
       throw soapFaultEx;
    }
 
+   public boolean callRequestHandlerChain(ServiceEndpointInfo seInfo, HandlerType type)
+   {
+      SOAPMessageContextJAXWS msgContext = (SOAPMessageContextJAXWS)MessageContextAssociation.peekMessageContext();
+
+      // Initialize the handler chain
+      if (jaxwsHandlerChain == null)
+      {
+         initHandlerChain(seInfo, HandlerType.PRE);
+         initHandlerChain(seInfo, HandlerType.JAXWS);
+         initHandlerChain(seInfo, HandlerType.POST);
+      }
+
+      boolean status = true;
+      String[] roles = null;
+
+      HandlerChainBaseImpl handlerChain = null;
+      if (type == HandlerType.PRE)
+         handlerChain = preHandlerChain;
+      else if (type == HandlerType.JAXWS)
+         handlerChain = jaxwsHandlerChain;
+      else if (type == HandlerType.POST)
+         handlerChain = postHandlerChain;
+      
+      if (handlerChain != null)
+      {
+         roles = handlerChain.getRoles();
+         status = handlerChain.handleMessage(msgContext);
+      }
+
+      // BP-1.0 R1027
+      if (type == HandlerType.POST)
+         HandlerChainBaseImpl.checkMustUnderstand(msgContext, roles);
+      
+      return status;
+   }
+
+   public boolean callResponseHandlerChain(ServiceEndpointInfo seInfo, HandlerType type)
+   {
+      SOAPMessageContextJAXWS msgContext = (SOAPMessageContextJAXWS)MessageContextAssociation.peekMessageContext();
+      
+      HandlerChainBaseImpl handlerChain = null;
+      if (type == HandlerType.PRE)
+         handlerChain = preHandlerChain;
+      else if (type == HandlerType.JAXWS)
+         handlerChain = jaxwsHandlerChain;
+      else if (type == HandlerType.POST)
+         handlerChain = postHandlerChain;
+      
+      return (handlerChain != null ? handlerChain.handleMessage(msgContext) : true);
+   }
+
    public boolean callFaultHandlerChain(ServiceEndpointInfo seInfo, HandlerType type, Exception ex)
    {
-      return true;
+      SOAPMessageContextJAXWS msgContext = (SOAPMessageContextJAXWS)MessageContextAssociation.peekMessageContext();
+
+      HandlerChainBaseImpl handlerChain = null;
+      if (type == HandlerType.PRE)
+         handlerChain = preHandlerChain;
+      else if (type == HandlerType.JAXWS)
+         handlerChain = jaxwsHandlerChain;
+      else if (type == HandlerType.POST)
+         handlerChain = postHandlerChain;
+      
+      return (handlerChain != null ? handlerChain.handleFault(msgContext) : true);
    }
 
-   public boolean callRequestHandlerChain(ServiceEndpointInfo seInfo, HandlerType type)
+   /**
+    * Init the handler chain
+    */
+   private void initHandlerChain(ServiceEndpointInfo seInfo, HandlerType type)
    {
-      return true;
+      Set<String> handlerRoles = new HashSet<String>();
+      List<HandlerInfo> hInfos = new ArrayList<HandlerInfo>();
+
+      ServerEndpointMetaData sepMetaData = seInfo.getServerEndpointMetaData();
+      for (UnifiedHandlerMetaData handlerMetaData : sepMetaData.getHandlers(type))
+      {
+         handlerRoles.addAll(Arrays.asList(handlerMetaData.getSoapRoles()));
+
+         Class hClass;
+         String handlerClass = handlerMetaData.getHandlerClass();
+         try
+         {
+            // Load the handler class using the deployments top level CL
+            ClassLoader classLoader = sepMetaData.getClassLoader();
+            hClass = classLoader.loadClass(handlerClass);
+         }
+         catch (ClassNotFoundException e)
+         {
+            throw new WSException("Cannot load handler class: " + handlerClass);
+         }
+
+         HashMap<String, Object> hConfig = new HashMap<String, Object>();
+         UnifiedInitParamMetaData[] params = handlerMetaData.getInitParams();
+         for (int j = 0; j < params.length; j++)
+         {
+            UnifiedInitParamMetaData param = params[j];
+            hConfig.put(param.getParamName(), param.getParamValue());
+         }
+         HandlerInfo info = new HandlerInfo(hClass);
+
+         log.debug("Adding server side handler to service '" + sepMetaData.getQName() + "': " + info);
+         hInfos.add(info);
+      }
+
+      initHandlerChain(seInfo, hInfos, handlerRoles, type);
    }
 
-   public boolean callResponseHandlerChain(ServiceEndpointInfo seInfo, HandlerType type)
+   private void initHandlerChain(ServiceEndpointInfo seInfo, List<HandlerInfo> hInfos, Set<String> handlerRoles, HandlerType type)
    {
-      return true;
+      log.debug("Init handler chain with [" + hInfos.size() + "] handlers");
+
+      ServerHandlerChain handlerChain = new ServerHandlerChain(hInfos, handlerRoles, type);
+      if (type == HandlerType.PRE)
+         preHandlerChain = handlerChain;
+      else if (type == HandlerType.JAXWS)
+         jaxwsHandlerChain = handlerChain;
+      else if (type == HandlerType.POST)
+         postHandlerChain = handlerChain;
    }
 }

Modified: trunk/src/main/java/org/jboss/ws/jaxws/client/JAXWSClient.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxws/client/JAXWSClient.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/jaxws/client/JAXWSClient.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -31,6 +31,7 @@
 import javax.xml.ws.BindingProvider;
 
 import org.jboss.ws.common.CommonClient;
+import org.jboss.ws.jaxws.handler.MessageContextJAXWS;
 import org.jboss.ws.jaxws.handler.SOAPMessageContextJAXWS;
 import org.jboss.ws.metadata.EndpointMetaData;
 import org.jboss.ws.soap.MessageContextAssociation;
@@ -69,7 +70,11 @@
       SOAPMessageContextJAXWS msgContext = new SOAPMessageContextJAXWS();
       MessageContextAssociation.pushMessageContext(msgContext);
       
+      // Mark the message context as outbound
+      msgContext.setProperty(MessageContextJAXWS.MESSAGE_OUTBOUND_PROPERTY, new Boolean(true));
+      
       Object retObj = invoke(opName, args, null, false);
+      
       return retObj;
    }
 

Modified: trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerChainBaseImpl.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerChainBaseImpl.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerChainBaseImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -28,7 +28,6 @@
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
-import java.util.Map;
 import java.util.Set;
 
 import javax.xml.namespace.QName;
@@ -132,19 +131,6 @@
    }
 
    /**
-    * Initializes the configuration for a HandlerChain.
-    *
-    * @param config Configuration for the initialization of this handler chain
-    * @throws javax.xml.rpc.JAXRPCException If any error during initialization
-    */
-   public void init(Map config)
-   {
-      log.debug("init: [config=" + config + "]");
-      // set state to ready
-      state = STATE_READY;
-   }
-
-   /**
     * Indicates the end of lifecycle for a HandlerChain.
     *
     * @throws javax.xml.rpc.JAXRPCException If any error during destroy
@@ -197,11 +183,20 @@
 
    public boolean handleMessage(MessageContext msgContext)
    {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+   
+   private boolean handleRequest(MessageContext msgContext)
+   {
       boolean doNext = true;
 
       if (handlers.size() > 0)
       {
-         log.debug("Enter: handleMessage");
+         log.debug("Enter: handleRequest");
 
          int handlerIndex = 0;
          Handler currHandler = null;
@@ -218,7 +213,7 @@
                }
 
                currHandler = ((HandlerEntry)handlers.get(handlerIndex)).getHandler();
-               log.debug("Handle message: " + currHandler);
+               log.debug("Handle request: " + currHandler);
                doNext = currHandler.handleMessage(msgContext);
 
                if (log.isTraceEnabled())
@@ -241,13 +236,69 @@
             if (doNext == false)
                falseIndex = (handlerIndex - 1);
 
-            log.debug("Exit: handleMessage with status: " + doNext);
+            log.debug("Exit: handleRequest with status: " + doNext);
          }
       }
 
       return doNext;
    }
 
+   private boolean handleResponse(MessageContext msgContext)
+   {
+      boolean doNext = true;
+
+      if (handlers.size() > 0)
+      {
+         log.debug("Enter: handleResponse");
+
+         int handlerIndex = handlers.size() - 1;
+         if (falseIndex != -1)
+            handlerIndex = falseIndex;
+
+         Handler currHandler = null;
+         try
+         {
+            for (; doNext && handlerIndex >= 0; handlerIndex--)
+            {
+               String lastMessageTrace = null;
+               if (log.isTraceEnabled())
+               {
+                  SOAPMessageContextJAXWS msgCtx = (SOAPMessageContextJAXWS)msgContext;
+                  SOAPPart soapPart = msgCtx.getMessage().getSOAPPart();
+                  lastMessageTrace = traceSOAPPart(soapPart, lastMessageTrace);
+               }
+
+               currHandler = ((HandlerEntry)handlers.get(handlerIndex)).getHandler();
+               log.debug("Handle response: " + currHandler);
+               doNext = currHandler.handleMessage(msgContext);
+
+               if (log.isTraceEnabled())
+               {
+                  SOAPMessageContextJAXWS msgCtx = (SOAPMessageContextJAXWS)msgContext;
+                  SOAPPart soapPart = msgCtx.getMessage().getSOAPPart();
+                  lastMessageTrace = traceSOAPPart(soapPart, lastMessageTrace);
+               }
+            }
+         }
+         catch (RuntimeException rte)
+         {
+            log.error("RuntimeException in response handler", rte);
+            doNext = false;
+            throw rte;
+         }
+         finally
+         {
+            // we start at this index in the fault chain
+            if (doNext == false)
+               falseIndex = (handlerIndex - 1);
+
+            log.debug("Exit: handleResponse with status: " + doNext);
+         }
+      }
+
+      return doNext;
+   }
+
    /**
     * Initiates the SOAP fault processing for this handler chain.
     * <p/>

Modified: trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerWrapper.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerWrapper.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerWrapper.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,24 +1,24 @@
 /*
-* 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.
-*/
+ * 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.jaxws.handler;
 
 // $Id$
@@ -30,7 +30,7 @@
 import org.jboss.logging.Logger;
 
 /**
- * A wrapper arround a {@link javax.xml.rpc.handler.Handler} that takes care of its lifecycle.
+ * A wrapper arround a {@link javax.xml.ws.handler.Handler} that takes care of its lifecycle.
  *
  * @author thomas.diesler at jboss.org
  */
@@ -42,7 +42,7 @@
    public final static int METHOD_READY = 1;
 
    // The states as string
-   private static String[] stateNames = new String[]{"DOES_NOT_EXIST", "METHOD_READY"};
+   private static String[] stateNames = new String[] { "DOES_NOT_EXIST", "METHOD_READY" };
 
    // The handler to delegate to
    private Handler delegate;
@@ -55,7 +55,7 @@
    public HandlerWrapper(Handler handler)
    {
       delegate = handler;
-      state = DOES_NOT_EXIST; // this is somewhat a lie ;-)
+      state = METHOD_READY;
    }
 
    /**

Modified: trunk/src/main/java/org/jboss/ws/jbossxb/JBossXBSupport.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jbossxb/JBossXBSupport.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/jbossxb/JBossXBSupport.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,6 +1,9 @@
 package org.jboss.ws.jbossxb;
 
-import org.jboss.util.xml.JBossEntityResolver;
+import java.util.Map;
+
+import javax.xml.namespace.QName;
+
 import org.jboss.ws.common.SOAPMessageContextBase;
 import org.jboss.ws.metadata.EndpointMetaData;
 import org.jboss.ws.metadata.OperationMetaData;
@@ -16,9 +19,6 @@
 import org.xml.sax.ContentHandler;
 import org.xml.sax.SAXException;
 
-import javax.xml.namespace.QName;
-import java.util.Map;
-
 /**
  * @author Heiko Braun <heiko.braun at jboss.com>
  * @since May 31, 2006
@@ -103,13 +103,4 @@
          }
       };
    }
-
-   /**
-    * Create an entity resolver that has local entites registered.
-    */
-   public static JBossEntityResolver createEntityResolver() {
-      JBossEntityResolver resolver = new JBossEntityResolver();
-      resolver.registerLocalEntity("http://www.w3.org/2005/08/addressing", "schema/ws-addr.xsd");      
-      return resolver;
-   }
 }

Modified: trunk/src/main/java/org/jboss/ws/jbossxb/SchemaBindingBuilder.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jbossxb/SchemaBindingBuilder.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/jbossxb/SchemaBindingBuilder.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -39,6 +39,7 @@
 import org.jboss.ws.metadata.jaxrpcmapping.JavaXmlTypeMapping;
 import org.jboss.ws.metadata.jaxrpcmapping.PackageMapping;
 import org.jboss.ws.metadata.jaxrpcmapping.VariableMapping;
+import org.jboss.ws.utils.JBossWSEntityResolver;
 import org.jboss.ws.Constants;
 import org.jboss.ws.WSException;
 import org.jboss.xb.binding.metadata.ClassMetaData;
@@ -71,7 +72,7 @@
     */
    public SchemaBinding buildSchemaBinding(XSModel model, JavaWsdlMapping wsdlMapping)
    {
-      JBossEntityResolver resolver = JBossXBSupport.createEntityResolver();
+      JBossEntityResolver resolver = new JBossWSEntityResolver();
       SchemaBinding schemaBinding = XsdBinder.bind(model, new DefaultSchemaResolver(resolver));
 
       schemaBinding.setIgnoreLowLine(false);

Modified: trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -32,11 +32,14 @@
 
 import org.jboss.logging.Logger;
 import org.jboss.ws.WSException;
-import org.jboss.ws.metadata.EndpointMetaData.Type;
-import org.jboss.ws.metadata.config.WSClientConfig;
-import org.jboss.ws.metadata.config.WSConfig;
 import org.jboss.ws.metadata.config.WSConfigFactory;
-import org.jboss.ws.metadata.config.WSHandlerChainConfig;
+import org.jboss.ws.metadata.config.jaxrpc.WSClientConfigJAXRPC;
+import org.jboss.ws.metadata.config.jaxrpc.WSConfigRootJAXRPC;
+import org.jboss.ws.metadata.config.jaxrpc.WSHandlerChainConfigJAXRPC;
+import org.jboss.ws.metadata.config.jaxws.WSClientConfigJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSConfigRootJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSHandlerChainConfigJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSHandlerChainsConfigJAXWS;
 import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
 import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData.HandlerType;
 
@@ -51,8 +54,8 @@
    // provide logging
    private static Logger log = Logger.getLogger(ClientEndpointMetaData.class);
 
-   // The REQUIRED config
-   private WSClientConfig clientConfig;
+   // The REWQUIRED client config
+   private Object clientConfig;
 
    public ClientEndpointMetaData(ServiceMetaData service, QName qname, Type type)
    {
@@ -64,15 +67,92 @@
       super.setConfigName(configName);
       clientConfig = null;
    }
-   
+
    public void setConfigFile(String configFile)
    {
       super.setConfigFile(configFile);
       clientConfig = null;
    }
 
-   public WSClientConfig getClientConfig()
+   public List<UnifiedHandlerMetaData> getHandlers(HandlerType type)
    {
+      ArrayList<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
+
+      Object clientConfig = getClientConfig();
+      if (clientConfig instanceof WSClientConfigJAXRPC)
+      {
+         WSClientConfigJAXRPC jaxrpcConfig = (WSClientConfigJAXRPC)clientConfig;
+
+         // Add pre handlers
+         if (type == HandlerType.PRE || type == HandlerType.ALL)
+         {
+            WSHandlerChainConfigJAXRPC preHandlerConfig = jaxrpcConfig.getPreHandlerChain();
+            if (preHandlerConfig != null)
+            {
+               handlers.addAll(preHandlerConfig.getHandlers());
+            }
+         }
+
+         // Add endpoint handlers
+         if (type == HandlerType.JAXRPC || type == HandlerType.ALL)
+         {
+            handlers.addAll(super.getHandlers(type));
+         }
+
+         // Add post handlers
+         if (type == HandlerType.POST || type == HandlerType.ALL)
+         {
+            WSHandlerChainConfigJAXRPC postHandlerConfig = jaxrpcConfig.getPostHandlerChain();
+            if (postHandlerConfig != null)
+            {
+               handlers.addAll(postHandlerConfig.getHandlers());
+            }
+         }
+      }
+
+      // JAXWS Handlers
+      else
+      {
+         WSClientConfigJAXWS jaxwsConfig = (WSClientConfigJAXWS)clientConfig;
+
+         // Add pre handlers
+         if (type == HandlerType.PRE || type == HandlerType.ALL)
+         {
+            WSHandlerChainsConfigJAXWS preHandlerChains = jaxwsConfig.getPreHandlerChains();
+            if (preHandlerChains != null)
+            {
+               for (WSHandlerChainConfigJAXWS preHandlerChain : preHandlerChains.getHandlerChains())
+               {
+                  handlers.addAll(preHandlerChain.getHandlers());
+               }
+            }
+         }
+
+         // Add endpoint handlers
+         if (type == HandlerType.JAXWS || type == HandlerType.ALL)
+         {
+            handlers.addAll(super.getHandlers(type));
+         }
+
+         // Add post handlers
+         if (type == HandlerType.POST || type == HandlerType.ALL)
+         {
+            WSHandlerChainsConfigJAXWS postHandlerChains = jaxwsConfig.getPostHandlerChains();
+            if (postHandlerChains != null)
+            {
+               for (WSHandlerChainConfigJAXWS preHandlerChain : postHandlerChains.getHandlerChains())
+               {
+                  handlers.addAll(preHandlerChain.getHandlers());
+               }
+            }
+         }
+      }
+
+      return handlers;
+   }
+
+   private Object getClientConfig()
+   {
       if (clientConfig == null)
       {
          String configName = getConfigName();
@@ -85,7 +165,14 @@
          String configFile = getConfigFile();
          if (configFile == null)
          {
-            configFile = "META-INF/standard-jbossws-client-config.xml";
+            if (getType() == Type.JAXRPC)
+            {
+               configFile = "META-INF/standard-jaxrpc-client-config.xml";
+            }
+            else
+            {
+               configFile = "META-INF/standard-jaxws-client-config.xml";
+            }
             setConfigFile(configFile);
          }
 
@@ -110,7 +197,8 @@
                throw new WSException("Cannot get resource: " + configFile);
          }
 
-         WSConfig wsConfig;
+         // Get the config root
+         Object wsConfig;
          try
          {
             WSConfigFactory factory = WSConfigFactory.newInstance();
@@ -125,44 +213,22 @@
             throw new WSException("Cannot parse client config", ex);
          }
 
-         clientConfig = wsConfig.getClientConfigByName(configName);
-         if (clientConfig == null)
-            throw new WSException("Cannot obtain client config: " + configName);
-      }
-      return clientConfig;
-   }
-
-   public List<UnifiedHandlerMetaData> getHandlers(HandlerType type)
-   {
-      List<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
-
-      // Add pre handlers
-      if (type == HandlerType.PRE || type == HandlerType.ALL)
-      {
-         WSHandlerChainConfig preHandlerConfig = getClientConfig().getPreHandlerChain();
-         if (preHandlerConfig != null)
+         // Get the client config
+         if (wsConfig instanceof WSConfigRootJAXRPC)
          {
-            handlers.addAll(preHandlerConfig.getHandlers());
+            clientConfig = ((WSConfigRootJAXRPC)wsConfig).getClientConfigByName(configName);
+            if (clientConfig == null)
+               throw new WSException("Cannot obtain client config: " + configName);
          }
-      }
-      
-      // Add endpoint handlers
-      if (type == HandlerType.JAXRPC || type == HandlerType.ALL)
-      {
-         handlers.addAll(super.getHandlers(type));
-      }
-      
-      // Add post handlers
-      if (type == HandlerType.POST || type == HandlerType.ALL)
-      {
-         WSHandlerChainConfig postHandlerConfig = getClientConfig().getPostHandlerChain();
-         if (postHandlerConfig != null)
+         else
          {
-            handlers.addAll(postHandlerConfig.getHandlers());
+            clientConfig = ((WSConfigRootJAXWS)wsConfig).getClientConfigByName(configName);
+            if (clientConfig == null)
+               throw new WSException("Cannot obtain client config: " + configName);
          }
       }
-      
-      return handlers;
+
+      return clientConfig;
    }
 
    public String toString()

Modified: trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -30,15 +30,17 @@
 
 import javax.management.ObjectName;
 import javax.xml.namespace.QName;
-import javax.xml.ws.Service.Mode;
 
 import org.jboss.logging.Logger;
 import org.jboss.ws.WSException;
-import org.jboss.ws.metadata.EndpointMetaData.Type;
-import org.jboss.ws.metadata.config.WSConfig;
 import org.jboss.ws.metadata.config.WSConfigFactory;
-import org.jboss.ws.metadata.config.WSEndpointConfig;
-import org.jboss.ws.metadata.config.WSHandlerChainConfig;
+import org.jboss.ws.metadata.config.jaxrpc.WSConfigRootJAXRPC;
+import org.jboss.ws.metadata.config.jaxrpc.WSEndpointConfigJAXRPC;
+import org.jboss.ws.metadata.config.jaxrpc.WSHandlerChainConfigJAXRPC;
+import org.jboss.ws.metadata.config.jaxws.WSConfigRootJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSEndpointConfigJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSHandlerChainConfigJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSHandlerChainsConfigJAXWS;
 import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
 import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData.HandlerType;
 import org.jboss.ws.server.ServiceEndpoint;
@@ -59,8 +61,8 @@
    public static final String SEPID_PROPERTY_CONTEXT = "context";
    public static final String SEPID_PROPERTY_ENDPOINT = "endpoint";
 
-   // The REQUIRED config
-   private WSEndpointConfig endpointConfig;
+   // The REQUIRED endpoint config
+   private Object endpointConfig;
 
    // The REQUIRED link name
    private String linkName;
@@ -94,67 +96,6 @@
       endpointConfig = null;
    }
 
-   public WSEndpointConfig getEndpointConfig()
-   {
-      if (endpointConfig == null)
-      {
-         String configName = getConfigName();
-         if (configName == null)
-         {
-            configName = "Standard Endpoint";
-            setConfigName(configName);
-         }
-
-         String configFile = getConfigFile();
-         if (configFile == null)
-         {
-            configFile = "META-INF/standard-jbossws-endpoint-config.xml";
-            setConfigFile(configFile);
-         }
-
-         log.debug("getEndpointConfig: [name=" + configName + ",url=" + configFile + "]");
-
-         URL configURL = null;
-         try
-         {
-            configURL = new URL(configFile);
-         }
-         catch (MalformedURLException ex)
-         {
-            // ignore
-         }
-
-         // Try to get the URL as resource
-         if (configURL == null)
-         {
-            ClassLoader cl = Thread.currentThread().getContextClassLoader();
-            configURL = cl.getResource(configFile);
-            if (configURL == null)
-               throw new WSException("Cannot get resource: " + configFile);
-         }
-
-         WSConfig wsConfig;
-         try
-         {
-            WSConfigFactory factory = WSConfigFactory.newInstance();
-            wsConfig = factory.parseWithObjectModelFactory(configURL);
-         }
-         catch (RuntimeException rte)
-         {
-            throw rte;
-         }
-         catch (Exception ex)
-         {
-            throw new WSException("Cannot parse client config", ex);
-         }
-
-         endpointConfig = wsConfig.getEndpointConfigByName(configName);
-         if (endpointConfig == null)
-            throw new WSException("Cannot obtain endpoint config: " + configName);
-      }
-      return endpointConfig;
-   }
-
    public String getLinkName()
    {
       return linkName;
@@ -227,34 +168,160 @@
 
    public List<UnifiedHandlerMetaData> getHandlers(HandlerType type)
    {
-      List<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
+      ArrayList<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
 
-      // Add pre handlers
-      if (type == HandlerType.PRE || type == HandlerType.ALL)
+      Object endpointConfig = getEndpointConfig();
+      
+      // JAXRPC Handlers
+      if (endpointConfig instanceof WSEndpointConfigJAXRPC)
       {
-         WSHandlerChainConfig preHandlerConfig = getEndpointConfig().getPreHandlerChain();
-         if (preHandlerConfig != null)
+         WSEndpointConfigJAXRPC jaxrpcConfig = (WSEndpointConfigJAXRPC)endpointConfig;
+
+         // Add pre handlers
+         if (type == HandlerType.PRE || type == HandlerType.ALL)
          {
-            handlers.addAll(preHandlerConfig.getHandlers());
+            WSHandlerChainConfigJAXRPC preHandlerConfig = jaxrpcConfig.getPreHandlerChain();
+            if (preHandlerConfig != null)
+            {
+               handlers.addAll(preHandlerConfig.getHandlers());
+            }
          }
+
+         // Add endpoint handlers
+         if (type == HandlerType.JAXRPC || type == HandlerType.ALL)
+         {
+            handlers.addAll(super.getHandlers(type));
+         }
+
+         // Add post handlers
+         if (type == HandlerType.POST || type == HandlerType.ALL)
+         {
+            WSHandlerChainConfigJAXRPC postHandlerConfig = jaxrpcConfig.getPostHandlerChain();
+            if (postHandlerConfig != null)
+            {
+               handlers.addAll(postHandlerConfig.getHandlers());
+            }
+         }
       }
+      
+      // JAXWS Handlers
+      else
+      {
+         WSEndpointConfigJAXWS jaxwsConfig = (WSEndpointConfigJAXWS)endpointConfig;
 
-      // Add endpoint handlers
-      if (type == HandlerType.JAXRPC || type == HandlerType.ALL)
-      {
-         handlers.addAll(super.getHandlers(type));
+         // Add pre handlers
+         if (type == HandlerType.PRE || type == HandlerType.ALL)
+         {
+            WSHandlerChainsConfigJAXWS preHandlerChains = jaxwsConfig.getPreHandlerChains();
+            if (preHandlerChains != null)
+            {
+               for (WSHandlerChainConfigJAXWS preHandlerChain : preHandlerChains.getHandlerChains())
+               {
+                  handlers.addAll(preHandlerChain.getHandlers());
+               }
+            }
+         }
+
+         // Add endpoint handlers
+         if (type == HandlerType.JAXWS || type == HandlerType.ALL)
+         {
+            handlers.addAll(super.getHandlers(type));
+         }
+
+         // Add post handlers
+         if (type == HandlerType.POST || type == HandlerType.ALL)
+         {
+            WSHandlerChainsConfigJAXWS postHandlerChains = jaxwsConfig.getPostHandlerChains();
+            if (postHandlerChains != null)
+            {
+               for (WSHandlerChainConfigJAXWS preHandlerChain : postHandlerChains.getHandlerChains())
+               {
+                  handlers.addAll(preHandlerChain.getHandlers());
+               }
+            }
+         }
       }
 
-      // Add post handlers
-      if (type == HandlerType.POST || type == HandlerType.ALL)
+      return handlers;
+   }
+
+   private Object getEndpointConfig()
+   {
+      if (endpointConfig == null)
       {
-         WSHandlerChainConfig postHandlerConfig = getEndpointConfig().getPostHandlerChain();
-         if (postHandlerConfig != null)
+         String configName = getConfigName();
+         if (configName == null)
          {
-            handlers.addAll(postHandlerConfig.getHandlers());
+            configName = "Standard Endpoint";
+            setConfigName(configName);
          }
+
+         String configFile = getConfigFile();
+         if (configFile == null)
+         {
+            if (getType() == Type.JAXRPC)
+            {
+               configFile = "META-INF/standard-jaxrpc-endpoint-config.xml";
+            }
+            else
+            {
+               configFile = "META-INF/standard-jaxws-endpoint-config.xml";
+            }
+            setConfigFile(configFile);
+         }
+
+         log.debug("getEndpointConfig: [name=" + configName + ",url=" + configFile + "]");
+
+         URL configURL = null;
+         try
+         {
+            configURL = new URL(configFile);
+         }
+         catch (MalformedURLException ex)
+         {
+            // ignore
+         }
+
+         // Try to get the URL as resource
+         if (configURL == null)
+         {
+            ClassLoader cl = Thread.currentThread().getContextClassLoader();
+            configURL = cl.getResource(configFile);
+            if (configURL == null)
+               throw new WSException("Cannot get resource: " + configFile);
+         }
+
+         // Get the config root
+         Object wsConfig;
+         try
+         {
+            WSConfigFactory factory = WSConfigFactory.newInstance();
+            wsConfig = factory.parseWithObjectModelFactory(configURL);
+         }
+         catch (RuntimeException rte)
+         {
+            throw rte;
+         }
+         catch (Exception ex)
+         {
+            throw new WSException("Cannot parse client config", ex);
+         }
+
+         // Get the endpoint config
+         if (wsConfig instanceof WSConfigRootJAXRPC)
+         {
+            endpointConfig = ((WSConfigRootJAXRPC)wsConfig).getEndpointConfigByName(configName);
+            if (endpointConfig == null)
+               throw new WSException("Cannot obtain endpoint config: " + configName);
+         }
+         else
+         {
+            endpointConfig = ((WSConfigRootJAXWS)wsConfig).getEndpointConfigByName(configName);
+            if (endpointConfig == null)
+               throw new WSException("Cannot obtain endpoint config: " + configName);
+         }
       }
-      return handlers;
+      return endpointConfig;
    }
 
    public String toString()

Deleted: trunk/src/main/java/org/jboss/ws/metadata/config/WSClientConfig.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/WSClientConfig.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/WSClientConfig.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -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.metadata.config;
-
-// $Id$
-
-/** 
- * A JBossWS client configuration 
- *
- * @author Thomas.Diesler at jboss.org
- * @since 18-Dec-2005
- */
-public class WSClientConfig extends WSCommonConfig
-{
-}

Deleted: trunk/src/main/java/org/jboss/ws/metadata/config/WSCommonConfig.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/WSCommonConfig.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/WSCommonConfig.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,67 +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.config;
-
-// $Id$
-
-/** 
- * A JBossWS client configuration 
- *
- * @author Thomas.Diesler at jboss.org
- * @since 18-Dec-2005
- */
-public abstract class WSCommonConfig
-{
-   private String configName;
-   private WSHandlerChainConfig preHandlerChain;
-   private WSHandlerChainConfig postHandlerChain;
-
-   public String getConfigName()
-   {
-      return configName;
-   }
-
-   public void setConfigName(String configName)
-   {
-      this.configName = configName;
-   }
-
-   public WSHandlerChainConfig getPostHandlerChain()
-   {
-      return postHandlerChain;
-   }
-
-   public void setPostHandlerChain(WSHandlerChainConfig postHandlerChain)
-   {
-      this.postHandlerChain = postHandlerChain;
-   }
-
-   public WSHandlerChainConfig getPreHandlerChain()
-   {
-      return preHandlerChain;
-   }
-
-   public void setPreHandlerChain(WSHandlerChainConfig preHandlerChain)
-   {
-      this.preHandlerChain = preHandlerChain;
-   }
-}

Deleted: trunk/src/main/java/org/jboss/ws/metadata/config/WSConfig.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/WSConfig.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/WSConfig.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,93 +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.config;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/** 
- * A JBossWS configuration 
- *
- * @author Thomas.Diesler at jboss.org
- * @since 18-Dec-2005
- */
-public class WSConfig
-{
-   private List<WSClientConfig> clientConfigList = new ArrayList<WSClientConfig>();
-   private List<WSEndpointConfig> endpointConfigList = new ArrayList<WSEndpointConfig>();
-
-   public List<WSClientConfig> getClientConfig()
-   {
-      return clientConfigList;
-   }
-
-   public void setClientConfig(List<WSClientConfig> clientConfig)
-   {
-      this.clientConfigList = clientConfig;
-   }
-
-   public List<WSEndpointConfig> getEndpointConfig()
-   {
-      return endpointConfigList;
-   }
-
-   public void setEndpointConfig(List<WSEndpointConfig> endpointConfig)
-   {
-      this.endpointConfigList = endpointConfig;
-   }
-   
-   public WSClientConfig getClientConfigByName(String configName)
-   {
-      WSClientConfig config = null;
-      for(WSClientConfig aux : clientConfigList)
-      {
-         if (aux.getConfigName().equals(configName))
-         {
-            config = aux;
-            break;
-         }
-      }
-      
-      if (config == null && clientConfigList.size() == 1)
-         config = clientConfigList.get(0);
-      
-      return config;
-   }
-   
-   public WSEndpointConfig getEndpointConfigByName(String configName)
-   {
-      WSEndpointConfig config = null;
-      for(WSEndpointConfig aux : endpointConfigList)
-      {
-         if (aux.getConfigName().equals(configName))
-         {
-            config = aux;
-            break;
-         }
-      }
-      
-      if (config == null && endpointConfigList.size() == 1)
-         config = endpointConfigList.get(0);
-      
-      return config;
-   }
-}

Modified: trunk/src/main/java/org/jboss/ws/metadata/config/WSConfigFactory.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/WSConfigFactory.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/WSConfigFactory.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -26,20 +26,25 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.net.URL;
-import java.util.List;
 
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+
 import org.jboss.logging.Logger;
+import org.jboss.util.xml.DOMUtils;
+import org.jboss.util.xml.JBossEntityResolver;
+import org.jboss.util.xml.JBossErrorHandler;
 import org.jboss.ws.WSException;
-import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedInitParamMetaData;
+import org.jboss.ws.metadata.config.jaxrpc.WSConfigFactoryJAXRPC;
+import org.jboss.ws.metadata.config.jaxws.WSConfigFactoryJAXWS;
+import org.jboss.ws.utils.JBossWSEntityResolver;
 import org.jboss.xb.binding.JBossXBException;
-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.jboss.xb.binding.sunday.unmarshalling.SchemaBinding;
 import org.jboss.xb.binding.sunday.unmarshalling.XsdBinder;
-import org.xml.sax.Attributes;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
 
 /** 
  * A factory for the JBossWS endpoint/client configuration 
@@ -47,10 +52,13 @@
  * @author Thomas.Diesler at jboss.org
  * @since 18-Dec-2005
  */
-public class WSConfigFactory implements ObjectModelFactory
+public class WSConfigFactory 
 {
    // provide logging
    private final Logger log = Logger.getLogger(WSConfigFactory.class);
+   
+   private static String URN_JAXRPC_CONFIG = "urn:jboss:jaxrpc-config:2.0";
+   private static String URN_JAXWS_CONFIG = "urn:jboss:jaxws-config:2.0";
 
    // Hide constructor
    private WSConfigFactory()
@@ -64,11 +72,11 @@
       return new WSConfigFactory();
    }
 
-   public WSConfig parseWithSchemaBinding(URL configURL) throws IOException, JBossXBException
+   public Object parseWithSchemaBinding(URL configURL) throws IOException, JBossXBException
    {
       log.debug("parse: " + configURL);
 
-      String configSchema = "schema/jbossws_config_1_0.xsd";
+      String configSchema = "schema/jaxrpc-config_2_0.xsd";
       URL xsdURL = Thread.currentThread().getContextClassLoader().getResource(configSchema);
       if (xsdURL == null)
          throw new WSException("Cannot find: " + configSchema);
@@ -77,143 +85,51 @@
       SchemaBinding schemaBinding = XsdBinder.bind(xsd, "UTF-8");
 
       Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
-      WSConfig wsConfig = (WSConfig)unmarshaller.unmarshal(configURL.openStream(), schemaBinding);
+      unmarshaller.setValidation(true);
+      unmarshaller.setSchemaValidation(true);
+      unmarshaller.setEntityResolver(new JBossWSEntityResolver());
+      Object wsConfig = unmarshaller.unmarshal(configURL.openStream(), schemaBinding);
       return wsConfig;
    }
 
    // Below is ObjectModelFactory stuff, which should be removed when parseWithSchemaBinding works. 
-   
-   public WSConfig parseWithObjectModelFactory(URL configURL) throws IOException, JBossXBException
+
+   public Object parseWithObjectModelFactory(URL configURL) throws IOException, JBossXBException
    {
       log.debug("parse: " + configURL);
 
       Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
-      WSConfig wsConfig = (WSConfig)unmarshaller.unmarshal(configURL.openStream(), this, null);
-      return wsConfig;
-   }
-
-   public Object newRoot(Object root, UnmarshallingContext ctx, String namespaceURI, String localName, Attributes attrs)
-   {
-      return new WSConfig();
-   }
-
-   public Object completeRoot(Object root, UnmarshallingContext ctx, String namespaceURI, String localName)
-   {
-      return root;
-   }
-
-   /**
-    * Called when parsing of a new element started.
-    */
-   public Object newChild(WSConfig wsConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
-   {
-      log.trace("WSConfig newChild: " + localName);
-      if ("endpoint-config".equals(localName))
+      unmarshaller.setValidation(true);
+      unmarshaller.setSchemaValidation(true);
+      
+      Object wsConfig;
+      String nsURI = getNamespaceURI(configURL);
+      if (URN_JAXRPC_CONFIG.equals(nsURI))
       {
-         WSEndpointConfig wsEndpointConfig = new WSEndpointConfig();
-         wsConfig.getEndpointConfig().add(wsEndpointConfig);
-         return wsEndpointConfig;
+         wsConfig = unmarshaller.unmarshal(configURL.openStream(), new WSConfigFactoryJAXRPC(), null);
       }
-      if ("client-config".equals(localName))
+      else if (URN_JAXWS_CONFIG.equals(nsURI))
       {
-         WSClientConfig wsClientConfig = new WSClientConfig();
-         wsConfig.getClientConfig().add(wsClientConfig);
-         return wsClientConfig;
+         wsConfig = unmarshaller.unmarshal(configURL.openStream(), new WSConfigFactoryJAXWS(), null);
       }
-      return null;
-   }
+      else
+      {
+         throw new WSException("Invalid config namespace: " + nsURI);
+      }
 
-   /**
-    * Called when a new simple child element with text value was read from the XML content.
-    */
-   public void setValue(WSCommonConfig wsCommonConfig, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
-   {
-      if (log.isTraceEnabled())
-         log.trace("WSCommonConfig setValue: nuri=" + namespaceURI + " localName=" + localName + " value=" + value);
-
-      if (localName.equals("config-name"))
-         wsCommonConfig.setConfigName(value);
+      return wsConfig;
    }
 
-   /**
-    * Called when parsing of a new element started.
-    */
-   public Object newChild(WSCommonConfig wsCommonConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   private String getNamespaceURI(URL configURL)
    {
-      log.trace("WSCommonConfig newChild: " + localName);
-      
-      if ("pre-handler-chain".equals(localName))
+      try
       {
-         WSHandlerChainConfig preHandlerChain = new WSHandlerChainConfig();
-         wsCommonConfig.setPreHandlerChain(preHandlerChain);
-         return preHandlerChain;
+         Element root = DOMUtils.parse(configURL.openStream());
+         return root.getNamespaceURI();
       }
-      if ("post-handler-chain".equals(localName))
+      catch (IOException ex)
       {
-         WSHandlerChainConfig postHandlerChain = new WSHandlerChainConfig();
-         wsCommonConfig.setPostHandlerChain(postHandlerChain);
-         return postHandlerChain;
+         throw new WSException(ex);
       }
-      return null;
    }
-
-   /**
-    * Called when a new simple child element with text value was read from the XML content.
-    */
-   public void setValue(WSHandlerChainConfig wsHandlerChainConfig, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
-   {
-      if (log.isTraceEnabled())
-         log.trace("WSHandlerChainConfig setValue: nuri=" + namespaceURI + " localName=" + localName + " value=" + value);
-
-      if (localName.equals("handler-chain-name"))
-         wsHandlerChainConfig.setHandlerChainName(value);
-   }
-
-   /**
-    * Called when parsing of a new element started.
-    */
-   public Object newChild(WSHandlerChainConfig wsHandlerChainConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
-   {
-      log.trace("WSHandlerChainConfig newChild: " + localName);
-      if ("handler".equals(localName))
-      {
-         UnifiedHandlerMetaData handler = new UnifiedHandlerMetaData();
-         List<UnifiedHandlerMetaData> handlers = wsHandlerChainConfig.getHandlers();
-         handlers.add(handler);
-         return handler;
-      }
-      return null;
-   }
-
-   /**
-    * 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);
-   }
-
-   /**
-    * 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: trunk/src/main/java/org/jboss/ws/metadata/config/WSEndpointConfig.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/WSEndpointConfig.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/WSEndpointConfig.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -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.metadata.config;
-
-// $Id$
-
-/** 
- * A JBossWS endpoint configuration 
- *
- * @author Thomas.Diesler at jboss.org
- * @since 18-Dec-2005
- */
-public class WSEndpointConfig extends WSCommonConfig
-{
-}

Deleted: trunk/src/main/java/org/jboss/ws/metadata/config/WSHandlerChainConfig.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/WSHandlerChainConfig.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/WSHandlerChainConfig.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,60 +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.config;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
-
-
-/** 
- * A JBossWS handler chain configuration 
- *
- * @author Thomas.Diesler at jboss.org
- * @since 18-Dec-2005
- */
-public class WSHandlerChainConfig
-{
-   private String handlerChainName;
-   private List<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
-
-   public String getHandlerChainName()
-   {
-      return handlerChainName;
-   }
-
-   public void setHandlerChainName(String handlerChainName)
-   {
-      this.handlerChainName = handlerChainName;
-   }
-
-   public List<UnifiedHandlerMetaData> getHandlers()
-   {
-      return handlers;
-   }
-
-   public void setHandlers(List<UnifiedHandlerMetaData> handlers)
-   {
-      this.handlers = handlers;
-   }
-}

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSClientConfigJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSClientConfigJAXRPC.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSClientConfigJAXRPC.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,35 @@
+/*
+ * 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.config.jaxrpc;
+
+
+// $Id$
+
+/** 
+ * A JBossWS client configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSClientConfigJAXRPC extends WSCommonConfigJAXRPC
+{
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSClientConfigJAXRPC.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSCommonConfigJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSCommonConfigJAXRPC.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSCommonConfigJAXRPC.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,68 @@
+/*
+ * 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.config.jaxrpc;
+
+
+// $Id$
+
+/** 
+ * A JBossWS client configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public abstract class WSCommonConfigJAXRPC
+{
+   private String configName;
+   private WSHandlerChainConfigJAXRPC preHandlerChain;
+   private WSHandlerChainConfigJAXRPC postHandlerChain;
+
+   public String getConfigName()
+   {
+      return configName;
+   }
+
+   public void setConfigName(String configName)
+   {
+      this.configName = configName;
+   }
+
+   public WSHandlerChainConfigJAXRPC getPostHandlerChain()
+   {
+      return postHandlerChain;
+   }
+
+   public void setPostHandlerChain(WSHandlerChainConfigJAXRPC postHandlerChain)
+   {
+      this.postHandlerChain = postHandlerChain;
+   }
+
+   public WSHandlerChainConfigJAXRPC getPreHandlerChain()
+   {
+      return preHandlerChain;
+   }
+
+   public void setPreHandlerChain(WSHandlerChainConfigJAXRPC preHandlerChain)
+   {
+      this.preHandlerChain = preHandlerChain;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSCommonConfigJAXRPC.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigFactoryJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigFactoryJAXRPC.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigFactoryJAXRPC.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,170 @@
+/*
+ * 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.config.jaxrpc;
+
+//$Id$
+
+import java.util.List;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
+import org.jboss.ws.metadata.j2ee.UnifiedInitParamMetaData;
+import org.jboss.xb.binding.ObjectModelFactory;
+import org.jboss.xb.binding.UnmarshallingContext;
+import org.xml.sax.Attributes;
+
+/** 
+ * A factory for the JBossWS endpoint/client configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSConfigFactoryJAXRPC implements ObjectModelFactory
+{
+   // provide logging
+   private final Logger log = Logger.getLogger(WSConfigFactoryJAXRPC.class);
+
+   public Object newRoot(Object root, UnmarshallingContext ctx, String namespaceURI, String localName, Attributes attrs)
+   {
+      return new WSConfigRootJAXRPC();
+   }
+
+   public Object completeRoot(Object root, UnmarshallingContext ctx, String namespaceURI, String localName)
+   {
+      return root;
+   }
+
+   /**
+    * Called when parsing of a new element started.
+    */
+   public Object newChild(WSConfigRootJAXRPC wsConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   {
+      log.trace("WSConfig newChild: " + localName);
+      if ("endpoint-config".equals(localName))
+      {
+         WSEndpointConfigJAXRPC wsEndpointConfig = new WSEndpointConfigJAXRPC();
+         wsConfig.getEndpointConfig().add(wsEndpointConfig);
+         return wsEndpointConfig;
+      }
+      if ("client-config".equals(localName))
+      {
+         WSClientConfigJAXRPC wsClientConfig = new WSClientConfigJAXRPC();
+         wsConfig.getClientConfig().add(wsClientConfig);
+         return wsClientConfig;
+      }
+      return null;
+   }
+
+   /**
+    * Called when a new simple child element with text value was read from the XML content.
+    */
+   public void setValue(WSCommonConfigJAXRPC wsCommonConfig, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+   {
+      if (log.isTraceEnabled())
+         log.trace("WSCommonConfig setValue: nuri=" + namespaceURI + " localName=" + localName + " value=" + value);
+
+      if (localName.equals("config-name"))
+         wsCommonConfig.setConfigName(value);
+   }
+
+   /**
+    * Called when parsing of a new element started.
+    */
+   public Object newChild(WSCommonConfigJAXRPC wsCommonConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   {
+      log.trace("WSCommonConfig newChild: " + localName);
+
+      if ("pre-handler-chain".equals(localName))
+      {
+         WSHandlerChainConfigJAXRPC preHandlerChain = new WSHandlerChainConfigJAXRPC();
+         wsCommonConfig.setPreHandlerChain(preHandlerChain);
+         return preHandlerChain;
+      }
+      if ("post-handler-chain".equals(localName))
+      {
+         WSHandlerChainConfigJAXRPC postHandlerChain = new WSHandlerChainConfigJAXRPC();
+         wsCommonConfig.setPostHandlerChain(postHandlerChain);
+         return postHandlerChain;
+      }
+      return null;
+   }
+
+   /**
+    * Called when a new simple child element with text value was read from the XML content.
+    */
+   public void setValue(WSHandlerChainConfigJAXRPC wsHandlerChainConfig, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+   {
+      if (log.isTraceEnabled())
+         log.trace("WSHandlerChainConfig setValue: nuri=" + namespaceURI + " localName=" + localName + " value=" + value);
+
+      if (localName.equals("handler-chain-name"))
+         wsHandlerChainConfig.setHandlerChainName(value);
+   }
+
+   /**
+    * Called when parsing of a new element started.
+    */
+   public Object newChild(WSHandlerChainConfigJAXRPC wsHandlerChainConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   {
+      log.trace("WSHandlerChainConfig newChild: " + localName);
+      if ("handler".equals(localName))
+      {
+         UnifiedHandlerMetaData handler = new UnifiedHandlerMetaData();
+         List<UnifiedHandlerMetaData> handlers = wsHandlerChainConfig.getHandlers();
+         handlers.add(handler);
+         return handler;
+      }
+      return null;
+   }
+
+   /**
+    * 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);
+   }
+
+   /**
+    * 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);
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigFactoryJAXRPC.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigRootJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigRootJAXRPC.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigRootJAXRPC.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,94 @@
+/*
+ * 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.config.jaxrpc;
+
+import java.util.ArrayList;
+import java.util.List;
+
+
+/** 
+ * A JBossWS configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSConfigRootJAXRPC
+{
+   private List<WSClientConfigJAXRPC> clientConfigList = new ArrayList<WSClientConfigJAXRPC>();
+   private List<WSEndpointConfigJAXRPC> endpointConfigList = new ArrayList<WSEndpointConfigJAXRPC>();
+
+   public List<WSClientConfigJAXRPC> getClientConfig()
+   {
+      return clientConfigList;
+   }
+
+   public void setClientConfig(List<WSClientConfigJAXRPC> clientConfig)
+   {
+      this.clientConfigList = clientConfig;
+   }
+
+   public List<WSEndpointConfigJAXRPC> getEndpointConfig()
+   {
+      return endpointConfigList;
+   }
+
+   public void setEndpointConfig(List<WSEndpointConfigJAXRPC> endpointConfig)
+   {
+      this.endpointConfigList = endpointConfig;
+   }
+   
+   public WSClientConfigJAXRPC getClientConfigByName(String configName)
+   {
+      WSClientConfigJAXRPC config = null;
+      for(WSClientConfigJAXRPC aux : clientConfigList)
+      {
+         if (aux.getConfigName().equals(configName))
+         {
+            config = aux;
+            break;
+         }
+      }
+      
+      if (config == null && clientConfigList.size() == 1)
+         config = clientConfigList.get(0);
+      
+      return config;
+   }
+   
+   public WSEndpointConfigJAXRPC getEndpointConfigByName(String configName)
+   {
+      WSEndpointConfigJAXRPC config = null;
+      for(WSEndpointConfigJAXRPC aux : endpointConfigList)
+      {
+         if (aux.getConfigName().equals(configName))
+         {
+            config = aux;
+            break;
+         }
+      }
+      
+      if (config == null && endpointConfigList.size() == 1)
+         config = endpointConfigList.get(0);
+      
+      return config;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSConfigRootJAXRPC.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSEndpointConfigJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSEndpointConfigJAXRPC.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSEndpointConfigJAXRPC.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,35 @@
+/*
+ * 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.config.jaxrpc;
+
+
+// $Id$
+
+/** 
+ * A JBossWS endpoint configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSEndpointConfigJAXRPC extends WSCommonConfigJAXRPC
+{
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSEndpointConfigJAXRPC.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSHandlerChainConfigJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSHandlerChainConfigJAXRPC.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSHandlerChainConfigJAXRPC.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,60 @@
+/*
+ * 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.config.jaxrpc;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
+
+
+/** 
+ * A JBossWS handler chain configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSHandlerChainConfigJAXRPC
+{
+   private String handlerChainName;
+   private List<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
+
+   public String getHandlerChainName()
+   {
+      return handlerChainName;
+   }
+
+   public void setHandlerChainName(String handlerChainName)
+   {
+      this.handlerChainName = handlerChainName;
+   }
+
+   public List<UnifiedHandlerMetaData> getHandlers()
+   {
+      return handlers;
+   }
+
+   public void setHandlers(List<UnifiedHandlerMetaData> handlers)
+   {
+      this.handlers = handlers;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxrpc/WSHandlerChainConfigJAXRPC.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSClientConfigJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSClientConfigJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSClientConfigJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,35 @@
+/*
+ * 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.config.jaxws;
+
+
+// $Id$
+
+/** 
+ * A JBossWS client configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSClientConfigJAXWS extends WSCommonConfigJAXWS
+{
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSClientConfigJAXWS.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSCommonConfigJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSCommonConfigJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSCommonConfigJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,67 @@
+/*
+ * 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.config.jaxws;
+
+// $Id$
+
+/** 
+ * A JBossWS client configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public abstract class WSCommonConfigJAXWS
+{
+   private String configName;
+   private WSHandlerChainsConfigJAXWS preHandlerChains;
+   private WSHandlerChainsConfigJAXWS postHandlerChain;
+
+   public String getConfigName()
+   {
+      return configName;
+   }
+
+   public void setConfigName(String configName)
+   {
+      this.configName = configName;
+   }
+
+   public WSHandlerChainsConfigJAXWS getPostHandlerChains()
+   {
+      return postHandlerChain;
+   }
+
+   public void setPostHandlerChains(WSHandlerChainsConfigJAXWS postHandlerChain)
+   {
+      this.postHandlerChain = postHandlerChain;
+   }
+
+   public WSHandlerChainsConfigJAXWS getPreHandlerChains()
+   {
+      return preHandlerChains;
+   }
+
+   public void setPreHandlerChains(WSHandlerChainsConfigJAXWS preHandlerChains)
+   {
+      this.preHandlerChains = preHandlerChains;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSCommonConfigJAXWS.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigFactoryJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigFactoryJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigFactoryJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,188 @@
+/*
+ * 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.config.jaxws;
+
+//$Id$
+
+import java.util.List;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
+import org.jboss.ws.metadata.j2ee.UnifiedInitParamMetaData;
+import org.jboss.xb.binding.ObjectModelFactory;
+import org.jboss.xb.binding.UnmarshallingContext;
+import org.xml.sax.Attributes;
+
+/** 
+ * A factory for the JBossWS endpoint/client configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSConfigFactoryJAXWS implements ObjectModelFactory
+{
+   // provide logging
+   private final Logger log = Logger.getLogger(WSConfigFactoryJAXWS.class);
+
+   public Object newRoot(Object root, UnmarshallingContext ctx, String namespaceURI, String localName, Attributes attrs)
+   {
+      return new WSConfigRootJAXWS();
+   }
+
+   public Object completeRoot(Object root, UnmarshallingContext ctx, String namespaceURI, String localName)
+   {
+      return root;
+   }
+
+   /**
+    * Called when parsing of a new element started.
+    */
+   public Object newChild(WSConfigRootJAXWS wsConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   {
+      log.trace("WSConfig newChild: " + localName);
+      if ("endpoint-config".equals(localName))
+      {
+         WSEndpointConfigJAXWS wsEndpointConfig = new WSEndpointConfigJAXWS();
+         wsConfig.getEndpointConfig().add(wsEndpointConfig);
+         return wsEndpointConfig;
+      }
+      if ("client-config".equals(localName))
+      {
+         WSClientConfigJAXWS wsClientConfig = new WSClientConfigJAXWS();
+         wsConfig.getClientConfig().add(wsClientConfig);
+         return wsClientConfig;
+      }
+      return null;
+   }
+
+   /**
+    * Called when a new simple child element with text value was read from the XML content.
+    */
+   public void setValue(WSCommonConfigJAXWS wsCommonConfig, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+   {
+      if (log.isTraceEnabled())
+         log.trace("WSCommonConfig setValue: nuri=" + namespaceURI + " localName=" + localName + " value=" + value);
+
+      if (localName.equals("config-name"))
+         wsCommonConfig.setConfigName(value);
+   }
+
+   /**
+    * Called when parsing of a new element started.
+    */
+   public Object newChild(WSCommonConfigJAXWS wsCommonConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   {
+      log.trace("WSCommonConfig newChild: " + localName);
+
+      if ("pre-handler-chains".equals(localName))
+      {
+         WSHandlerChainsConfigJAXWS preHandlerChains = new WSHandlerChainsConfigJAXWS();
+         wsCommonConfig.setPreHandlerChains(preHandlerChains);
+         return preHandlerChains;
+      }
+      if ("post-handler-chains".equals(localName))
+      {
+         WSHandlerChainsConfigJAXWS postHandlerChains = new WSHandlerChainsConfigJAXWS();
+         wsCommonConfig.setPostHandlerChains(postHandlerChains);
+         return postHandlerChains;
+      }
+      return null;
+   }
+
+   /**
+    * Called when parsing of a new element started.
+    */
+   public Object newChild(WSHandlerChainsConfigJAXWS wsHandlerChains, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   {
+      log.trace("WSHandlerChainsConfig newChild: " + localName);
+
+      if ("handler-chain".equals(localName))
+      {
+         WSHandlerChainConfigJAXWS handlerChain = new WSHandlerChainConfigJAXWS();
+         wsHandlerChains.getHandlerChains().add(handlerChain);
+         return handlerChain;
+      }
+      return null;
+   }
+
+   /**
+    * Called when a new simple child element with text value was read from the XML content.
+    */
+   public void setValue(WSHandlerChainConfigJAXWS handlerChain, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+   {
+      if (log.isTraceEnabled())
+         log.trace("WSHandlerChainConfigJAXWS setValue: nuri=" + namespaceURI + " localName=" + localName + " value=" + value);
+
+      if (localName.equals("protocol-bindings"))
+         handlerChain.setProtocolBindings(value);
+      else if (localName.equals("service-name-pattern"))
+         handlerChain.setServiceNamePattern(value);
+      else if (localName.equals("port-name-pattern"))
+         handlerChain.setPortNamePattern(value);
+   }
+
+   /**
+    * Called when parsing of a new element started.
+    */
+   public Object newChild(WSHandlerChainConfigJAXWS wsHandlerChainConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   {
+      log.trace("WSHandlerChainConfig newChild: " + localName);
+      if ("handler".equals(localName))
+      {
+         UnifiedHandlerMetaData handler = new UnifiedHandlerMetaData();
+         List<UnifiedHandlerMetaData> handlers = wsHandlerChainConfig.getHandlers();
+         handlers.add(handler);
+         return handler;
+      }
+      return null;
+   }
+
+   /**
+    * 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-role"))
+         handler.addSoapRole(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);
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigFactoryJAXWS.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigRootJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigRootJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigRootJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,94 @@
+/*
+ * 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.config.jaxws;
+
+import java.util.ArrayList;
+import java.util.List;
+
+
+/** 
+ * A JBossWS configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSConfigRootJAXWS
+{
+   private List<WSClientConfigJAXWS> clientConfigList = new ArrayList<WSClientConfigJAXWS>();
+   private List<WSEndpointConfigJAXWS> endpointConfigList = new ArrayList<WSEndpointConfigJAXWS>();
+
+   public List<WSClientConfigJAXWS> getClientConfig()
+   {
+      return clientConfigList;
+   }
+
+   public void setClientConfig(List<WSClientConfigJAXWS> clientConfig)
+   {
+      this.clientConfigList = clientConfig;
+   }
+
+   public List<WSEndpointConfigJAXWS> getEndpointConfig()
+   {
+      return endpointConfigList;
+   }
+
+   public void setEndpointConfig(List<WSEndpointConfigJAXWS> endpointConfig)
+   {
+      this.endpointConfigList = endpointConfig;
+   }
+   
+   public WSClientConfigJAXWS getClientConfigByName(String configName)
+   {
+      WSClientConfigJAXWS config = null;
+      for(WSClientConfigJAXWS aux : clientConfigList)
+      {
+         if (aux.getConfigName().equals(configName))
+         {
+            config = aux;
+            break;
+         }
+      }
+      
+      if (config == null && clientConfigList.size() == 1)
+         config = clientConfigList.get(0);
+      
+      return config;
+   }
+   
+   public WSEndpointConfigJAXWS getEndpointConfigByName(String configName)
+   {
+      WSEndpointConfigJAXWS config = null;
+      for(WSEndpointConfigJAXWS aux : endpointConfigList)
+      {
+         if (aux.getConfigName().equals(configName))
+         {
+            config = aux;
+            break;
+         }
+      }
+      
+      if (config == null && endpointConfigList.size() == 1)
+         config = endpointConfigList.get(0);
+      
+      return config;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSConfigRootJAXWS.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSEndpointConfigJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSEndpointConfigJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSEndpointConfigJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,35 @@
+/*
+ * 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.config.jaxws;
+
+
+// $Id$
+
+/** 
+ * A JBossWS endpoint configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSEndpointConfigJAXWS extends WSCommonConfigJAXWS
+{
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSEndpointConfigJAXWS.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainConfigJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainConfigJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainConfigJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,82 @@
+/*
+ * 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.config.jaxws;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
+
+
+/** 
+ * A JBossWS handler chain configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSHandlerChainConfigJAXWS
+{
+   private String protocolBindings;
+   private String serviceNamePattern;
+   private String portNamePattern;
+   private List<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
+
+   public String getProtocolBindings()
+   {
+      return protocolBindings;
+   }
+
+   public void setProtocolBindings(String handlerChainName)
+   {
+      this.protocolBindings = handlerChainName;
+   }
+   
+   public String getPortNamePattern()
+   {
+      return portNamePattern;
+   }
+
+   public void setPortNamePattern(String portNamePattern)
+   {
+      this.portNamePattern = portNamePattern;
+   }
+
+   public String getServiceNamePattern()
+   {
+      return serviceNamePattern;
+   }
+
+   public void setServiceNamePattern(String serviceNamePattern)
+   {
+      this.serviceNamePattern = serviceNamePattern;
+   }
+
+   public List<UnifiedHandlerMetaData> getHandlers()
+   {
+      return handlers;
+   }
+
+   public void setHandlers(List<UnifiedHandlerMetaData> handlers)
+   {
+      this.handlers = handlers;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainConfigJAXWS.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainsConfigJAXWS.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainsConfigJAXWS.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainsConfigJAXWS.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,42 @@
+/*
+ * 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.config.jaxws;
+
+import java.util.ArrayList;
+import java.util.List;
+
+
+/** 
+ * A JBossWS handler chains configuration 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 18-Dec-2005
+ */
+public class WSHandlerChainsConfigJAXWS
+{
+   private List<WSHandlerChainConfigJAXWS> chains = new ArrayList<WSHandlerChainConfigJAXWS>();
+
+   public List<WSHandlerChainConfigJAXWS> getHandlerChains()
+   {
+      return chains;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/config/jaxws/WSHandlerChainsConfigJAXWS.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerChainMetaData.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerChainMetaData.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerChainMetaData.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -40,33 +40,23 @@
    private static final Logger log = Logger.getLogger(HandlerChainMetaData.class);
 
    // The parent <handler-config> element
-   private HandlerConfigMetaData handlerConfig;
+   private HandlerChainsMetaData handlerConfig;
 
-   // The required <handler-chain-name> element
-   private String handlerChainName;
-   // The required <handler> elements
+   private String protocolBindings;
+   private String serviceNamePattern;
+   private String portNamePattern;
    private ArrayList<UnifiedHandlerMetaData> handlers = new ArrayList<UnifiedHandlerMetaData>();
 
-   public HandlerChainMetaData(HandlerConfigMetaData handlerConfig)
+   public HandlerChainMetaData(HandlerChainsMetaData handlerConfig)
    {
       this.handlerConfig = handlerConfig;
    }
 
-   public HandlerConfigMetaData getHandlerConfig()
+   public HandlerChainsMetaData getHandlerConfig()
    {
       return handlerConfig;
    }
 
-   public String getHandlerChainName()
-   {
-      return handlerChainName;
-   }
-
-   public void setHandlerChainName(String handlerChainName)
-   {
-      this.handlerChainName = handlerChainName;
-   }
-
    public void addHandler(UnifiedHandlerMetaData handlerMetaData)
    {
       handlers.add(handlerMetaData);
@@ -78,4 +68,35 @@
       handlers.toArray(array);
       return array;
    }
+
+   public String getPortNamePattern()
+   {
+      return portNamePattern;
+   }
+
+   public void setPortNamePattern(String portNamePattern)
+   {
+      this.portNamePattern = portNamePattern;
+   }
+
+   public String getProtocolBindings()
+   {
+      return protocolBindings;
+   }
+
+   public void setProtocolBindings(String protocolBindings)
+   {
+      this.protocolBindings = protocolBindings;
+   }
+
+   public String getServiceNamePattern()
+   {
+      return serviceNamePattern;
+   }
+
+   public void setServiceNamePattern(String serviceNamePattern)
+   {
+      this.serviceNamePattern = serviceNamePattern;
+   }
+
 }

Copied: trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerChainsMetaData.java (from rev 661, trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigMetaData.java)
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigMetaData.java	2006-08-01 16:32:34 UTC (rev 661)
+++ trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerChainsMetaData.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,65 @@
+/*
+* 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.jsr181;
+
+//$Id$
+
+import java.net.URL;
+import java.util.ArrayList;
+
+/**
+ * XML Binding root element for JSR-181 HandlerChain
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 15-Oct-2005
+ */
+public class HandlerChainsMetaData
+{
+   // The required <handler-chain> elements
+   private ArrayList<HandlerChainMetaData> handlerChains = new ArrayList<HandlerChainMetaData>();
+
+   // The URL to the webservices.xml descriptor
+   private URL fileURL;
+
+   public HandlerChainsMetaData(URL fileURL)
+   {
+      this.fileURL = fileURL;
+   }
+
+   public URL getDescriptorURL()
+   {
+      return fileURL;
+   }
+
+   public void addHandlerChain(HandlerChainMetaData handlerChain)
+   {
+      handlerChains.add(handlerChain);
+   }
+
+   public HandlerChainMetaData[] getHandlerChains()
+   {
+      HandlerChainMetaData[] array = new HandlerChainMetaData[handlerChains.size()];
+      handlerChains.toArray(array);
+      return array;
+   }
+}

Modified: trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigFactory.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigFactory.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigFactory.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -33,7 +33,7 @@
 import org.xml.sax.Attributes;
 
 /**
- * A JBossXB factory for {@link HandlerConfigMetaData}
+ * A JBossXB factory for {@link HandlerChainsMetaData}
  *
  * @author Thomas.Diesler at jboss.org
  * @since 15-Oct-2005
@@ -58,7 +58,7 @@
     */
    public Object newRoot(Object root, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
    {
-      HandlerConfigMetaData handlerConfigMetaData = new HandlerConfigMetaData(fileURL);
+      HandlerChainsMetaData handlerConfigMetaData = new HandlerChainsMetaData(fileURL);
       return handlerConfigMetaData;
    }
 
@@ -70,7 +70,7 @@
    /**
     * Called when parsing of a new element started.
     */
-   public Object newChild(HandlerConfigMetaData handlerConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+   public Object newChild(HandlerChainsMetaData handlerConfig, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
    {
       if ("handler-chain".equals(localName))
          return new HandlerChainMetaData(handlerConfig);
@@ -81,7 +81,7 @@
    /**
     * Called when parsing character is complete.
     */
-   public void addChild(HandlerConfigMetaData handlerConfig, HandlerChainMetaData handlerChain, UnmarshallingContext navigator, String namespaceURI, String localName)
+   public void addChild(HandlerChainsMetaData handlerConfig, HandlerChainMetaData handlerChain, UnmarshallingContext navigator, String namespaceURI, String localName)
    {
       handlerConfig.addHandlerChain(handlerChain);
    }
@@ -131,8 +131,12 @@
       if (log.isTraceEnabled())
          log.trace("HandlerChainMetaData setValue: nuri=" + namespaceURI + " localName=" + localName + " value=" + value);
 
-      if (localName.equals("handler-chain-name"))
-         handlerChain.setHandlerChainName(value);
+      if (localName.equals("protocol-bindings"))
+         handlerChain.setProtocolBindings(value);
+      else if (localName.equals("service-name-pattern"))
+         handlerChain.setServiceNamePattern(value);
+      else if (localName.equals("port-name-pattern"))
+         handlerChain.setPortNamePattern(value);
    }
 
    /**
@@ -147,8 +151,6 @@
          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);
    }

Deleted: trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigMetaData.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigMetaData.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/jsr181/HandlerConfigMetaData.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,65 +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.jsr181;
-
-//$Id$
-
-import java.net.URL;
-import java.util.ArrayList;
-
-/**
- * XML Binding root element for JSR-181 HandlerChain
- *
- * @author Thomas.Diesler at jboss.org
- * @since 15-Oct-2005
- */
-public class HandlerConfigMetaData
-{
-   // The required <handler-chain> elements
-   private ArrayList<HandlerChainMetaData> handlerChains = new ArrayList<HandlerChainMetaData>();
-
-   // The URL to the webservices.xml descriptor
-   private URL fileURL;
-
-   public HandlerConfigMetaData(URL fileURL)
-   {
-      this.fileURL = fileURL;
-   }
-
-   public URL getDescriptorURL()
-   {
-      return fileURL;
-   }
-
-   public void addHandlerChain(HandlerChainMetaData handlerChain)
-   {
-      handlerChains.add(handlerChain);
-   }
-
-   public HandlerChainMetaData[] getHandlerChains()
-   {
-      HandlerChainMetaData[] array = new HandlerChainMetaData[handlerChains.size()];
-      handlerChains.toArray(array);
-      return array;
-   }
-}

Modified: trunk/src/main/java/org/jboss/ws/metadata/wsdl/DOMTypes.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/DOMTypes.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/DOMTypes.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -32,7 +32,7 @@
  * thread safety.
  *
  * @author <a href="mailto:jason.greene at jboss.com">Jason T. Greene</a>
- * @version $Revision:$
+ * @version $Revision$
  */
 public class DOMTypes extends WSDLTypes
 {

Modified: trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11DefinitionFactory.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11DefinitionFactory.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11DefinitionFactory.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -24,8 +24,12 @@
 // $Id$
 
 import org.jboss.logging.Logger;
+import org.jboss.ws.utils.JBossWSEntityResolver;
+import org.xml.sax.EntityResolver;
 import org.xml.sax.InputSource;
 
+import com.ibm.wsdl.xml.WSDLReaderImpl;
+
 import javax.wsdl.Definition;
 import javax.wsdl.WSDLException;
 import javax.wsdl.factory.WSDLFactory;
@@ -83,116 +87,14 @@
       if (wsdlLocation == null)
          throw new IllegalArgumentException("URL cannot be null");
 
-      Definition wsdlDefinition = wsdlReader.readWSDL(new WSDLLocatorImpl(wsdlLocation));
+      log.debug("parse: " + wsdlLocation.toExternalForm());
+      
+      EntityResolver entityResolver = new JBossWSEntityResolver();
+      
+      // Set EntityResolver in patched version of wsdl4j-1.5.2jboss
+      ((WSDLReaderImpl)wsdlReader).setEntityResolver(entityResolver);
+      
+      Definition wsdlDefinition = wsdlReader.readWSDL(new WSDLLocatorImpl(entityResolver, wsdlLocation));
       return wsdlDefinition;
    }
-
-   /* A WSDLLocator that can handle wsdl imports
-   */
-   public static class WSDLLocatorImpl implements WSDLLocator
-   {
-      private URL wsdlURL;
-      private String latestImportURI;
-
-      public WSDLLocatorImpl(URL wsdlFile)
-      {
-         if (wsdlFile == null)
-            throw new IllegalArgumentException("WSDL file argument cannot be null");
-
-         this.wsdlURL = wsdlFile;
-      }
-
-      public InputSource getBaseInputSource()
-      {
-         log.debug("getBaseInputSource [wsdlUrl=" + wsdlURL + "]");
-         try
-         {
-            InputStream is = wsdlURL.openStream();
-            if (is == null)
-               throw new IllegalArgumentException("Cannot obtain wsdl from [" + wsdlURL + "]");
-
-            return new InputSource(is);
-         }
-         catch (IOException e)
-         {
-            throw new RuntimeException("Cannot access wsdl from [" + wsdlURL + "], " + e.getMessage());
-         }
-      }
-
-      public String getBaseURI()
-      {
-         return wsdlURL.toExternalForm();
-      }
-
-      public InputSource getImportInputSource(String parent, String resource)
-      {
-         log.debug("getImportInputSource [parent=" + parent + ",resource=" + resource + "]");
-
-         URL parentURL = null;
-         try
-         {
-            parentURL = new URL(parent);
-         }
-         catch (MalformedURLException e)
-         {
-            log.error("Not a valid URL: " + parent);
-            return null;
-         }
-
-         String wsdlImport = null;
-         String external = parentURL.toExternalForm();
-
-         // An external URL
-         if (resource.startsWith("http://") || resource.startsWith("https://"))
-         {
-            wsdlImport = resource;
-         }
-
-         // Absolute path
-         else if (resource.startsWith("/"))
-         {
-            String beforePath = external.substring(0, external.indexOf(parentURL.getPath()));
-            wsdlImport = beforePath + resource;
-         }
-
-         // A relative path
-         else
-         {
-            String parentDir = external.substring(0, external.lastIndexOf("/"));
-
-            // remove references to current dir
-            while (resource.startsWith("./"))
-               resource = resource.substring(2);
-
-            // remove references to parentdir
-            while (resource.startsWith("../"))
-            {
-               parentDir = parentDir.substring(0, parentDir.lastIndexOf("/"));
-               resource = resource.substring(3);
-            }
-
-            wsdlImport = parentDir + "/" + resource;
-         }
-
-         try
-         {
-            log.debug("Resolved to: " + wsdlImport);
-            InputStream is = new URL(wsdlImport).openStream();
-            if (is == null)
-               throw new IllegalArgumentException("Cannot import wsdl from [" + wsdlImport + "]");
-
-            latestImportURI = wsdlImport;
-            return new InputSource(is);
-         }
-         catch (IOException e)
-         {
-            throw new RuntimeException("Cannot access imported wsdl [" + wsdlImport + "], " + e.getMessage());
-         }
-      }
-
-      public String getLatestImportURI()
-      {
-         return latestImportURI;
-      }
-   }
 }

Modified: trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11Reader.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11Reader.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDL11Reader.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -369,7 +369,7 @@
          // Skip, let the entity resolver resolve these
          if (namespace.length() > 0 && schemaLocation.length() > 0)
          {
-            URL currLoc = this.getLocationURL(wsdlLoc, schemaLocation);
+            URL currLoc = getLocationURL(wsdlLoc, schemaLocation);
             schemaLocationsMap.put(namespace, currLoc);
          }
          else

Modified: trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLDefinitionsFactory.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLDefinitionsFactory.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLDefinitionsFactory.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -23,10 +23,8 @@
 
 // $Id$
 
-import java.io.IOException;
 import java.io.InputStream;
 import java.io.StringWriter;
-import java.net.MalformedURLException;
 import java.net.URL;
 import java.util.HashMap;
 import java.util.Iterator;
@@ -34,20 +32,17 @@
 
 import javax.wsdl.Definition;
 import javax.wsdl.factory.WSDLFactory;
-import javax.wsdl.xml.WSDLLocator;
 import javax.wsdl.xml.WSDLReader;
 import javax.xml.parsers.DocumentBuilder;
 
 import org.jboss.logging.Logger;
 import org.jboss.util.xml.DOMUtils;
-import org.jboss.util.xml.JBossEntityResolver;
 import org.jboss.ws.Constants;
-import org.jboss.ws.WSException;
-import org.jboss.ws.jbossxb.JBossXBSupport;
+import org.jboss.ws.utils.JBossWSEntityResolver;
 import org.w3c.dom.Document;
 import org.w3c.dom.Element;
 import org.xml.sax.EntityResolver;
-import org.xml.sax.InputSource;
+
 import com.ibm.wsdl.xml.WSDLReaderImpl;
 
 /**
@@ -102,8 +97,9 @@
       if (wsdlLocation == null)
          throw new IllegalArgumentException("URL cannot be null");
 
-      EntityResolver entityResolver = JBossXBSupport.createEntityResolver();
       log.debug("parse: " + wsdlLocation.toExternalForm());
+      
+      EntityResolver entityResolver = new JBossWSEntityResolver();
       WSDLDefinitions wsdlDefinitions = null;
       try
       {
@@ -211,124 +207,4 @@
       String defaultNamespace = root.getNamespaceURI();
       return defaultNamespace;
    }
-
-   /* A WSDLLocator that can handle wsdl imports
-   */
-   public static class WSDLLocatorImpl implements WSDLLocator
-   {
-      private EntityResolver entityResolver;
-      private URL wsdlURL;
-      private String latestImportURI;
-
-      public WSDLLocatorImpl(EntityResolver entityResolver, URL wsdlFile)
-      {
-         if (wsdlFile == null)
-            throw new IllegalArgumentException("WSDL file argument cannot be null");
-
-         this.entityResolver = entityResolver;
-         this.wsdlURL = wsdlFile;
-      }
-
-      public InputSource getBaseInputSource()
-      {
-         log.trace("getBaseInputSource [wsdlUrl=" + wsdlURL + "]");
-         try
-         {
-            InputStream is = wsdlURL.openStream();
-            if (is == null)
-               throw new IllegalArgumentException("Cannot obtain wsdl from [" + wsdlURL + "]");
-
-            return new InputSource(is);
-         }
-         catch (IOException e)
-         {
-            throw new RuntimeException("Cannot access wsdl from [" + wsdlURL + "], " + e.getMessage());
-         }
-      }
-
-      public String getBaseURI()
-      {
-         return wsdlURL.toExternalForm();
-      }
-
-      public InputSource getImportInputSource(String parent, String resource)
-      {
-         log.trace("getImportInputSource [parent=" + parent + ",resource=" + resource + "]");
-
-         URL parentURL = null;
-         try
-         {
-            parentURL = new URL(parent);
-         }
-         catch (MalformedURLException e)
-         {
-            log.error("Not a valid URL: " + parent);
-            return null;
-         }
-
-         String wsdlImport = null;
-         String external = parentURL.toExternalForm();
-
-         // An external URL
-         if (resource.startsWith("http://") || resource.startsWith("https://"))
-         {
-            wsdlImport = resource;
-         }
-
-         // Absolute path
-         else if (resource.startsWith("/"))
-         {
-            String beforePath = external.substring(0, external.indexOf(parentURL.getPath()));
-            wsdlImport = beforePath + resource;
-         }
-
-         // A relative path
-         else
-         {
-            String parentDir = external.substring(0, external.lastIndexOf("/"));
-
-            // remove references to current dir
-            while (resource.startsWith("./"))
-               resource = resource.substring(2);
-
-            // remove references to parentdir
-            while (resource.startsWith("../"))
-            {
-               parentDir = parentDir.substring(0, parentDir.lastIndexOf("/"));
-               resource = resource.substring(3);
-            }
-
-            wsdlImport = parentDir + "/" + resource;
-         }
-
-         try
-         {
-            log.trace("Trying to resolve: " + wsdlImport);
-            InputSource inputSource = entityResolver.resolveEntity(wsdlImport, wsdlImport);
-            if (inputSource != null)
-            {
-               latestImportURI = wsdlImport;
-            }
-            else
-            {
-               throw new IllegalArgumentException("Cannot resolve imported resource: " + wsdlImport);
-            }
-            
-            return inputSource;
-         }
-         catch (RuntimeException rte)
-         {
-            throw rte;
-         }
-         catch (Exception e)
-         {
-            throw new WSException("Cannot access imported wsdl [" + wsdlImport + "], " + e.getMessage());
-         }
-      }
-
-      public String getLatestImportURI()
-      {
-         return latestImportURI;
-      }
-   }
 }

Added: trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLLocatorImpl.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLLocatorImpl.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLLocatorImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,159 @@
+/*
+ * 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.wsdl;
+
+// $Id$
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.MalformedURLException;
+import java.net.URL;
+
+import javax.wsdl.xml.WSDLLocator;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.WSException;
+import org.xml.sax.EntityResolver;
+import org.xml.sax.InputSource;
+
+/* A WSDLLocator that can handle wsdl imports
+ */
+class WSDLLocatorImpl implements WSDLLocator
+{
+   // provide logging
+   private static final Logger log = Logger.getLogger(WSDLDefinitionsFactory.class);
+
+   private EntityResolver entityResolver;
+   private URL wsdlURL;
+   private String latestImportURI;
+
+   public WSDLLocatorImpl(EntityResolver entityResolver, URL wsdlFile)
+   {
+      if (wsdlFile == null)
+         throw new IllegalArgumentException("WSDL file argument cannot be null");
+
+      this.entityResolver = entityResolver;
+      this.wsdlURL = wsdlFile;
+   }
+
+   public InputSource getBaseInputSource()
+   {
+      log.trace("getBaseInputSource [wsdlUrl=" + wsdlURL + "]");
+      try
+      {
+         InputStream is = wsdlURL.openStream();
+         if (is == null)
+            throw new IllegalArgumentException("Cannot obtain wsdl from [" + wsdlURL + "]");
+
+         return new InputSource(is);
+      }
+      catch (IOException e)
+      {
+         throw new RuntimeException("Cannot access wsdl from [" + wsdlURL + "], " + e.getMessage());
+      }
+   }
+
+   public String getBaseURI()
+   {
+      return wsdlURL.toExternalForm();
+   }
+
+   public InputSource getImportInputSource(String parent, String resource)
+   {
+      log.trace("getImportInputSource [parent=" + parent + ",resource=" + resource + "]");
+
+      URL parentURL = null;
+      try
+      {
+         parentURL = new URL(parent);
+      }
+      catch (MalformedURLException e)
+      {
+         log.error("Not a valid URL: " + parent);
+         return null;
+      }
+
+      String wsdlImport = null;
+      String external = parentURL.toExternalForm();
+
+      // An external URL
+      if (resource.startsWith("http://") || resource.startsWith("https://"))
+      {
+         wsdlImport = resource;
+      }
+
+      // Absolute path
+      else if (resource.startsWith("/"))
+      {
+         String beforePath = external.substring(0, external.indexOf(parentURL.getPath()));
+         wsdlImport = beforePath + resource;
+      }
+
+      // A relative path
+      else
+      {
+         String parentDir = external.substring(0, external.lastIndexOf("/"));
+
+         // remove references to current dir
+         while (resource.startsWith("./"))
+            resource = resource.substring(2);
+
+         // remove references to parentdir
+         while (resource.startsWith("../"))
+         {
+            parentDir = parentDir.substring(0, parentDir.lastIndexOf("/"));
+            resource = resource.substring(3);
+         }
+
+         wsdlImport = parentDir + "/" + resource;
+      }
+
+      try
+      {
+         log.trace("Trying to resolve: " + wsdlImport);
+         InputSource inputSource = entityResolver.resolveEntity(wsdlImport, wsdlImport);
+         if (inputSource != null)
+         {
+            latestImportURI = wsdlImport;
+         }
+         else
+         {
+            throw new IllegalArgumentException("Cannot resolve imported resource: " + wsdlImport);
+         }
+
+         return inputSource;
+      }
+      catch (RuntimeException rte)
+      {
+         throw rte;
+      }
+      catch (Exception e)
+      {
+         throw new WSException("Cannot access imported wsdl [" + wsdlImport + "], " + e.getMessage());
+      }
+   }
+
+   public String getLatestImportURI()
+   {
+      return latestImportURI;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/metadata/wsdl/WSDLLocatorImpl.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/main/java/org/jboss/ws/metadata/wsdl/XSModelTypes.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/XSModelTypes.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/XSModelTypes.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -33,7 +33,7 @@
  * A JBossXSModel based type definition.
  *
  * @author <a href="mailto:jason.greene at jboss.com">Jason T. Greene</a>
- * @version $Revision:$
+ * @version $Revision$
  */
 public class XSModelTypes extends WSDLTypes
 {

Modified: trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSEntityResolver.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSEntityResolver.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSEntityResolver.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -34,8 +34,8 @@
 import org.apache.xerces.xni.parser.XMLEntityResolver;
 import org.apache.xerces.xni.parser.XMLInputSource;
 import org.jboss.logging.Logger;
-import org.jboss.util.xml.JBossEntityResolver;
 import org.jboss.ws.Constants;
+import org.xml.sax.EntityResolver;
 import org.xml.sax.InputSource;
 import org.xml.sax.SAXException;
 
@@ -52,11 +52,12 @@
 
    private Map<String, URL> schemaLocationByNamespace = new HashMap<String, URL>();
 
-   private JBossEntityResolver resolver = new JBossEntityResolver();
+   private EntityResolver delegate;
 
-   public JBossXSEntityResolver(Map<String, URL> schemaLocationByNamespace)
+   public JBossXSEntityResolver(EntityResolver resolver, Map<String, URL> schemaLocationByNamespace)
    {
       this.schemaLocationByNamespace = schemaLocationByNamespace;
+      this.delegate = resolver;
    }
 
    /**
@@ -79,7 +80,7 @@
       try
       {
          String publicURI = (publicId != null ? publicId : namespace);
-         InputSource inputSource = resolver.resolveEntity(publicURI, systemId);
+         InputSource inputSource = delegate.resolveEntity(publicURI, systemId);
          if (inputSource != null)
          {
             XMLInputSource source = getXMLInputSource(inputSource, resId);
@@ -136,7 +137,7 @@
 
          // Delegate to JBoss Entity Resolver
          XMLInputSource source = getXMLInputSource(
-               resolver.resolveEntity(null, namespaceURI), resId);
+               delegate.resolveEntity(null, namespaceURI), resId);
          if (source != null)
             return source;
       }

Modified: trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSStringList.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSStringList.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/JBossXSStringList.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -91,7 +91,7 @@
       return strList;
    }
 
-   void addItem(String str)
+   public void addItem(String str)
    {
       strList.add(str);
    }

Added: trunk/src/main/java/org/jboss/ws/server/EndpointContext.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/EndpointContext.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/server/EndpointContext.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,76 @@
+/*
+ * 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.server;
+
+// $Id$
+
+import javax.servlet.ServletContext;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.servlet.http.HttpSession;
+import javax.xml.rpc.handler.MessageContext;
+
+import org.jboss.ws.soap.MessageContextAssociation;
+
+/**
+ * Implementation of ServletEndpointContext
+ *
+ * @author Thomas.Diesler at jboss.org
+ */
+public class EndpointContext 
+{
+   private ServletContext context;
+   private HttpServletRequest request;
+   private HttpServletResponse response;
+
+   public EndpointContext(ServletContext context, HttpServletRequest request, HttpServletResponse response)
+   {
+      this.context = context;
+      this.request = request;
+      this.response = response;
+   }
+
+   public HttpSession getHttpSession()
+   {
+      return request.getSession();
+   }
+
+   public MessageContext getMessageContext()
+   {
+      return (MessageContext)MessageContextAssociation.peekMessageContext();
+   }
+
+   public ServletContext getServletContext()
+   {
+      return context;
+   }
+
+   public HttpServletRequest getHttpServletRequest()
+   {
+      return request;
+   }
+
+   public HttpServletResponse getHttpServletResponse()
+   {
+      return response;
+   }
+}
\ No newline at end of file


Property changes on: trunk/src/main/java/org/jboss/ws/server/EndpointContext.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/main/java/org/jboss/ws/server/ServiceEndpoint.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/ServiceEndpoint.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/server/ServiceEndpoint.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -42,8 +42,6 @@
 import org.jboss.ws.binding.BindingException;
 import org.jboss.ws.common.SOAPMessageContextBase;
 import org.jboss.ws.jaxrpc.SOAPFaultExceptionHelper;
-import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
-import org.jboss.ws.jaxws.handler.SOAPMessageContextJAXWS;
 import org.jboss.ws.metadata.EndpointMetaData;
 import org.jboss.ws.metadata.ServerEndpointMetaData;
 import org.jboss.ws.metadata.UnifiedMetaData;
@@ -143,27 +141,10 @@
    /**
     * Handle a request to this web service endpoint
     */
-   public SOAPMessage handleRequest(HeaderSource headerSource, Object context, InputStream inputStream) throws BindingException
+   public SOAPMessage handleRequest(HeaderSource headerSource, EndpointContext context, InputStream inputStream) throws BindingException
    {
-      boolean popMessageContext = false;
-
-      // Associate a message context with the current thread if the caller has not done so already
       SOAPMessageContextBase msgContext = MessageContextAssociation.peekMessageContext();
       ServerEndpointMetaData epMetaData = seInfo.getServerEndpointMetaData();
-      if (msgContext == null)
-      {
-         if (epMetaData.getType() == EndpointMetaData.Type.JAXRPC)
-         {
-            msgContext = new SOAPMessageContextJAXRPC();
-         }
-         else
-         {
-            msgContext = new SOAPMessageContextJAXWS();
-         }
-         MessageContextAssociation.pushMessageContext(msgContext);
-         popMessageContext = true;
-      }
-      msgContext.setEndpointMetaData(epMetaData);
 
       long beginProcessing = 0;
       ClassLoader ctxClassLoader = Thread.currentThread().getContextClassLoader();
@@ -247,10 +228,6 @@
             log.error("Cannot process metrics", ex);
          }
 
-         // Reset the message context association
-         if (popMessageContext)
-            MessageContextAssociation.popMessageContext();
-
          // Reset the thread context class loader
          Thread.currentThread().setContextClassLoader(ctxClassLoader);
          log.debug("END handleRequest: " + seInfo.getServiceEndpointID());

Modified: trunk/src/main/java/org/jboss/ws/server/ServiceEndpointInvokerJSE.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/ServiceEndpointInvokerJSE.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/server/ServiceEndpointInvokerJSE.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -33,6 +33,7 @@
 import org.jboss.logging.Logger;
 import org.jboss.ws.WSException;
 import org.jboss.ws.binding.EndpointInvocation;
+import org.jboss.ws.jaxrpc.ServletEndpointContextImpl;
 import org.jboss.ws.metadata.ServerEndpointMetaData;
 
 /**
@@ -57,18 +58,15 @@
    }
 
    /** Create an instance of the SEI implementation bean if necessary */
-   public Object createServiceEndpoint(ServiceEndpointInfo seInfo, Object sepContext, Class seiImplClass) throws IllegalAccessException, InstantiationException
+   public Object createServiceEndpoint(ServiceEndpointInfo seInfo, Object context, Class seiImplClass) throws IllegalAccessException, InstantiationException
    {
       Object seiImpl = seiImplClass.newInstance();
-      if (seiImpl instanceof ServiceLifecycle)
+      if (seiImpl instanceof ServiceLifecycle && context != null)
       {
          try
          {
-            if ((sepContext instanceof ServletEndpointContext) == false)
-               throw new WSException("Invalid endpoint context: " + sepContext);
-
             ServiceLifecycle serviceLifecycle = ((ServiceLifecycle)seiImpl);
-            ServletEndpointContext servletEndpointContext = (ServletEndpointContext)sepContext;
+            ServletEndpointContext servletEndpointContext = new ServletEndpointContextImpl((EndpointContext)context);
             serviceLifecycle.init(servletEndpointContext);
          }
          catch (ServiceException ex)

Modified: trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -35,15 +35,20 @@
 import java.net.URL;
 import java.net.UnknownHostException;
 import java.util.ArrayList;
+import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 import java.util.concurrent.ConcurrentHashMap;
 
+import javax.activation.DataHandler;
 import javax.management.MBeanServer;
 import javax.management.MBeanServerFactory;
 import javax.management.ObjectName;
+import javax.servlet.ServletContext;
+import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
+import javax.servlet.http.HttpSession;
 import javax.xml.soap.SOAPEnvelope;
 import javax.xml.soap.SOAPException;
 import javax.xml.soap.SOAPMessage;
@@ -57,6 +62,7 @@
 import org.jboss.ws.common.SOAPMessageContextBase;
 import org.jboss.ws.jaxrpc.handler.MessageContextJAXRPC;
 import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
+import org.jboss.ws.jaxws.handler.MessageContextJAXWS;
 import org.jboss.ws.jaxws.handler.SOAPMessageContextJAXWS;
 import org.jboss.ws.metadata.EndpointMetaData;
 import org.jboss.ws.metadata.ServerEndpointMetaData;
@@ -325,49 +331,65 @@
       ServiceEndpoint wsEndpoint = getServiceEndpointByID(sepID);
       if (wsEndpoint == null)
          throw new WSException("Cannot obtain endpoint for: " + sepID);
-      
+
       wsEndpoint.handleWSDLRequest(outStream, requestURL, resourcePath);
    }
 
-   public void processSOAPRequest(ObjectName sepID, InputStream inStream, OutputStream outStream, Object context) throws Exception
+   public void processSOAPRequest(ObjectName sepID, InputStream inStream, OutputStream outStream, EndpointContext context) throws Exception
    {
       ServiceEndpoint wsEndpoint = getServiceEndpointByID(sepID);
       if (wsEndpoint == null)
          throw new WSException("Cannot obtain endpoint for: " + sepID);
 
       // Get the type of the endpoint
-      Type type = wsEndpoint.getServiceEndpointInfo().getServerEndpointMetaData().getType();
+      ServerEndpointMetaData sepMetaData = wsEndpoint.getServiceEndpointInfo().getServerEndpointMetaData();
+      Type type = sepMetaData.getType();
 
-      ServletHeaderSource headerSource = null;
-      HttpServletResponse httpResponse = null;
-      
+      HttpSession httpSession = context.getHttpSession();
+      ServletContext servletContext = context.getServletContext();
+      HttpServletRequest httpRequest = context.getHttpServletRequest();
+      HttpServletResponse httpResponse = context.getHttpServletResponse();
+      ServletHeaderSource headerSource = new ServletHeaderSource(httpRequest, httpResponse);
+
       // Associate a message context with the current thread
       SOAPMessageContextBase msgContext;
       if (type == EndpointMetaData.Type.JAXRPC)
       {
          msgContext = new SOAPMessageContextJAXRPC();
-         if (context instanceof ServletEndpointContextImpl)
-         {
-            ServletEndpointContextImpl sepContext = (ServletEndpointContextImpl)context;
-            httpResponse = sepContext.getHttpServletResponse();
-            
-            msgContext.setProperty(MessageContextJAXRPC.SERVLET_CONTEXT, sepContext);
-            msgContext.setProperty(MessageContextJAXRPC.SERVLET_REQUEST, sepContext.getHttpServletRequest());
-            msgContext.setProperty(MessageContextJAXRPC.SERVLET_RESPONSE, httpResponse);
-            msgContext.setProperty(MessageContextJAXRPC.SERVLET_SESSION, sepContext.getHttpSession());
-            
-            headerSource = new ServletHeaderSource(sepContext.getHttpServletRequest(), httpResponse);
-         }
+         msgContext.setProperty(MessageContextJAXRPC.SERVLET_CONTEXT, servletContext);
+         msgContext.setProperty(MessageContextJAXRPC.SERVLET_REQUEST, httpRequest);
+         msgContext.setProperty(MessageContextJAXRPC.SERVLET_RESPONSE, httpResponse);
+         msgContext.setProperty(MessageContextJAXRPC.SERVLET_SESSION, httpSession);
       }
       else
       {
          msgContext = new SOAPMessageContextJAXWS();
+         msgContext.setProperty(MessageContextJAXWS.MESSAGE_OUTBOUND_PROPERTY, new Boolean(false));
+         msgContext.setProperty(MessageContextJAXWS.INBOUND_MESSAGE_ATTACHMENTS, new HashMap<String, DataHandler>());
+         msgContext.setProperty(MessageContextJAXWS.HTTP_REQUEST_HEADERS, headerSource.getHeaderMap());
+         msgContext.setProperty(MessageContextJAXWS.HTTP_REQUEST_METHOD, httpRequest.getMethod());
+         msgContext.setProperty(MessageContextJAXWS.QUERY_STRING, httpRequest.getQueryString());
+         msgContext.setProperty(MessageContextJAXWS.PATH_INFO, httpRequest.getPathInfo());
+         msgContext.setProperty(MessageContextJAXWS.SERVLET_CONTEXT, servletContext);
+         msgContext.setProperty(MessageContextJAXWS.SERVLET_REQUEST, httpRequest);
+         msgContext.setProperty(MessageContextJAXWS.SERVLET_RESPONSE, httpResponse);
+         
       }
+      msgContext.setEndpointMetaData(sepMetaData);
       MessageContextAssociation.pushMessageContext(msgContext);
 
       try
       {
          SOAPMessage resMessage = wsEndpoint.handleRequest(headerSource, context, inStream);
+         
+         Map<String, List<String>> headers = (Map<String, List<String>>)msgContext.getProperty(MessageContextJAXWS.HTTP_RESPONSE_HEADERS);
+         if (headers != null)
+            headerSource.setHeaderMap(headers);
+         
+         Integer code = (Integer)msgContext.getProperty(MessageContextJAXWS.HTTP_RESPONSE_CODE);
+         if (code != null)
+            httpResponse.setStatus(code.intValue());
+            
          SOAPPart part = resMessage.getSOAPPart();
          if (part == null)
             throw new SOAPException("Cannot obtain SOAPPart from response message");
@@ -505,7 +527,7 @@
          throw new WSException("Endpoint expected to be in STOPED state");
 
       ServerEndpointMetaData sepMetaData = wsEndpoint.getServiceEndpointInfo().getServerEndpointMetaData();
-      
+
       sepMetaData.clearHandlers();
       for (UnifiedHandlerMetaData handlerMetaData : handlers)
       {

Deleted: trunk/src/main/java/org/jboss/ws/server/ServletEndpointContextImpl.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/ServletEndpointContextImpl.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/server/ServletEndpointContextImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,93 +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.server;
-
-// $Id$
-
-import java.security.Principal;
-
-import javax.servlet.ServletContext;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-import javax.servlet.http.HttpSession;
-import javax.xml.rpc.handler.MessageContext;
-import javax.xml.rpc.server.ServletEndpointContext;
-
-import org.jboss.ws.soap.MessageContextAssociation;
-
-/**
- * Implementation of <code>ServletEndpointContext</code>
- *
- * @author <a href="mailto:jason at stacksmash.com">Jason T. Greene</a>
- */
-public class ServletEndpointContextImpl implements ServletEndpointContext
-{
-   private ServletContext context;
-   private HttpServletRequest request;
-   private HttpServletResponse response;
-
-   public ServletEndpointContextImpl(ServletContext context, HttpServletRequest request, HttpServletResponse response)
-   {
-      this.context = context;
-      this.request = request;
-      this.response = response;
-   }
-
-   public HttpSession getHttpSession()
-   {
-      return request.getSession();
-   }
-
-   public MessageContext getMessageContext()
-   {
-      return (MessageContext)MessageContextAssociation.peekMessageContext();
-   }
-
-   public ServletContext getServletContext()
-   {
-      return context;
-   }
-
-   public Principal getUserPrincipal()
-   {
-      return request.getUserPrincipal();
-   }
-
-   public boolean isUserInRole(String role)
-   {
-      return request.isUserInRole(role);
-   }
-
-   // BEGIN non-standard access methods
-
-   public HttpServletRequest getHttpServletRequest()
-   {
-      return request;
-   }
-
-   public HttpServletResponse getHttpServletResponse()
-   {
-      return response;
-   }
-
-   // END non-standard access methods
-}
\ No newline at end of file

Modified: trunk/src/main/java/org/jboss/ws/server/ServletHeaderSource.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/ServletHeaderSource.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/server/ServletHeaderSource.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,28 +1,34 @@
 /*
-* 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.
-*/
+ * 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.server;
 
+// $Id: $
+
+import java.util.ArrayList;
 import java.util.Enumeration;
+import java.util.HashMap;
 import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
 
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
@@ -34,6 +40,7 @@
  * information from an HttpServlet.
  *
  * @author <a href="mailto:jason at stacksmash.com">Jason T. Greene</a>
+ * @author Thomas.Diesler at jboss.org
  */
 public class ServletHeaderSource implements HeaderSource
 {
@@ -63,6 +70,25 @@
       return headers;
    }
 
+   public Map<String, List<String>> getHeaderMap()
+   {
+      Map<String, List<String>> headerMap = new HashMap<String, List<String>>();
+
+      Enumeration e = req.getHeaderNames();
+      if (e != null)
+      {
+         while (e.hasMoreElements())
+         {
+            String name = (String)e.nextElement();
+            List<String> values = new ArrayList<String>();
+            values.add(req.getHeader(name));
+            headerMap.put(name, values);
+         }
+      }
+
+      return headerMap;
+   }
+
    public void setMimeHeaders(MimeHeaders headers)
    {
       Iterator i = headers.getAllHeaders();
@@ -73,4 +99,17 @@
       }
    }
 
+   public void setHeaderMap(Map<String, List<String>> headers)
+   {
+      Iterator<String> it = headers.keySet().iterator();
+      while (it.hasNext())
+      {
+         String name = it.next();
+         List<String> values = headers.get(name);
+         for (String value : values)
+         {
+            res.addHeader(name, value);
+         }
+      }
+   }
 }

Modified: trunk/src/main/java/org/jboss/ws/server/StandardEndpointServlet.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/StandardEndpointServlet.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/server/StandardEndpointServlet.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -38,6 +38,7 @@
 import org.jboss.logging.Logger;
 import org.jboss.util.NotImplementedException;
 import org.jboss.ws.WSException;
+import org.jboss.ws.jaxrpc.ServletEndpointContextImpl;
 import org.jboss.ws.metadata.ServerEndpointMetaData;
 import org.jboss.ws.utils.ObjectNameFactory;
 
@@ -111,7 +112,7 @@
 
       try
       {
-         ServletEndpointContextImpl context = new ServletEndpointContextImpl(getServletContext(), req, res);
+         EndpointContext context = new EndpointContext(getServletContext(), req, res);
          epManager.processSOAPRequest(sepId, req.getInputStream(), res.getOutputStream(), context);
       }
       catch (Exception ex)

Modified: trunk/src/main/java/org/jboss/ws/tools/JavaToXSD.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/tools/JavaToXSD.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/tools/JavaToXSD.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -25,9 +25,8 @@
 
 import java.io.IOException;
 import java.net.URL;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
+import java.util.HashMap;
+import java.util.Iterator;
 import java.util.Map;
 
 import javax.xml.namespace.QName;
@@ -46,6 +45,7 @@
 import org.jboss.ws.tools.helpers.JavaToXSDHelper;
 import org.jboss.ws.tools.interfaces.JavaToXSDIntf;
 import org.jboss.ws.tools.interfaces.SchemaCreatorIntf;
+import org.jboss.ws.utils.JBossWSEntityResolver;
 import org.jboss.xb.binding.sunday.unmarshalling.LSInputAdaptor;
 import org.jboss.xb.binding.sunday.unmarshalling.SchemaBinding;
 import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
@@ -126,12 +126,14 @@
    public JBossXSModel parseSchema(URL xsdURL)
    {
       JBossXSErrorHandler xserr = new JBossXSErrorHandler();
-      XMLSchemaLoader loader = (XMLSchemaLoader)schemautils.getXSLoader(xserr, null);
+      JBossWSEntityResolver resolver = new JBossWSEntityResolver();
+      JBossXSEntityResolver xsresolve = new JBossXSEntityResolver(resolver, new HashMap<String, URL>());
+      XMLSchemaLoader loader = (XMLSchemaLoader)schemautils.getXSLoader(xserr, xsresolve);
+      
       XSModel xsmodel = loader.loadURI(xsdURL.toExternalForm());
-      //XSModel xsmodel =  schemautils.parseSchema(xsdURL);
-      String typeNamespace = SchemaUtils.getTargetNamespace(xsmodel);
       if (xsmodel == null)
-         throw new WSException("Parsed XSModel is null");
+         throw new WSException("Cannot load schema: " + xsdURL);
+      
       WSSchemaUtils sutils = WSSchemaUtils.getInstance(null, null);
       JBossXSModel jbxs = new JBossXSModel();
       sutils.copyXSModel(xsmodel, jbxs);
@@ -139,66 +141,44 @@
    }
 
    /**
-    * Given a set of schema files, parse them to yield an unified
-    * JBossXSModel
-    * @param locations a List of locations of schema files as String
-    * @return unified JBossXSModel
-    */
-   public JBossXSModel parseSchema(List<String> locations)
-   {
-
-      XSModel xsmodel = schemautils.parseSchema(locations);
-      String typeNamespace = SchemaUtils.getTargetNamespace(xsmodel);
-      if (xsmodel == null)
-         throw new WSException("Parsed XSModel is null");
-      WSSchemaUtils sutils = WSSchemaUtils.getInstance(null, null);
-      JBossXSModel jbxs = new JBossXSModel();
-      sutils.copyXSModel(xsmodel, jbxs);
-      return jbxs;
-   }
-
-   /**
-    * Given a set of schema files, parse them to yield an unified
-    * JBossXSModel
+    * Given a set of schema files, parse them to yield an unified JBossXSModel
     * @param locs a map of schema namespace to schema location
     * @return unified JBossXSModel
     */
    public JBossXSModel parseSchema(Map<String, URL> locs)
    {
-      if (locs == null)
-         throw new IllegalArgumentException("Illegal Null Argument:locs");
-      if (locs.size() == 0)
-         throw new IllegalArgumentException("Illegal size Argument:locs is zero");
-      Collection<URL> col = locs.values();
-      List<String> strlist = new ArrayList<String>();
-      for (URL uri : col)
-      {
-         strlist.add(uri.toExternalForm());
-      }
+      if (locs == null || locs.size() == 0)
+         throw new IllegalArgumentException("Illegal schema location map");
+
       JBossXSErrorHandler xserr = new JBossXSErrorHandler();
-      JBossXSEntityResolver xsresolve = new JBossXSEntityResolver(locs);
+      JBossWSEntityResolver resolver = new JBossWSEntityResolver();
+      JBossXSEntityResolver xsresolve = new JBossXSEntityResolver(resolver, locs);
       XMLSchemaLoader loader = (XMLSchemaLoader)schemautils.getXSLoader(xserr, xsresolve);
-      //XMLSchemaLoader loader = (XMLSchemaLoader)schemautils.getXSLoader();
-      List<String> locations = new ArrayList<String>();
-      Collection<URL> urls = locs.values();
-      for (URL url : urls)
+      
+      JBossXSStringList slist = new JBossXSStringList();
+      Iterator<String> keys = locs.keySet().iterator();
+      while (keys.hasNext())
       {
-         locations.add(url.toExternalForm());
+         String nsURI = keys.next();
+         URL orgURL = locs.get(nsURI); 
+         URL resURL = resolver.resolveNamespaceURI(nsURI);
+         URL url = resURL != null ? resURL : orgURL;
+         log.debug("load schema: " + nsURI + "=" + url);
+         slist.addItem(url.toExternalForm());
       }
-      JBossXSStringList slist = new JBossXSStringList(locations);
+      
       XSModel xsmodel = loader.loadURIList(slist);
       if (xsmodel == null)
          throw new WSException("Cannot load schema: " + slist);
 
       //TODO: Once JBXB-33 is fixed, migrate Schema Parsing to XB
       //XSModel xsmodel = Util.loadSchema(slist,this.getSchemaBindingResolver(locs));
-      String typeNamespace = SchemaUtils.getTargetNamespace(xsmodel);
-      if (xsmodel == null)
-         throw new WSException("Parsed XSModel is null");
       
+      // Convert Xerces XSModel into r/w JBossXSModel 
       WSSchemaUtils sutils = WSSchemaUtils.getInstance(null, null);
       JBossXSModel jbxs = new JBossXSModel();
       sutils.copyXSModel(xsmodel, jbxs);
+      
       return jbxs;
    }
 
@@ -212,8 +192,6 @@
 
    /**
     * Set the WSDL Style
-    *
-    * @param style
     */
    public void setWSDLStyle(String style)
    {
@@ -224,16 +202,8 @@
    //             PRIVATE METHODS
    //******************************************************************
 
-   private Class loadClass(String classname) throws ClassNotFoundException
-   {
-      return Thread.currentThread().getContextClassLoader().loadClass(classname);
-   }
-
    /**
     * FIXME: JBXB-33
-    *
-    * @param map
-    * @return
     */
    private SchemaBindingResolver getSchemaBindingResolver(final Map<String, URL> map)
    {

Modified: trunk/src/main/java/org/jboss/ws/transport/jms/JMSMessageDispatcher.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/transport/jms/JMSMessageDispatcher.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/transport/jms/JMSMessageDispatcher.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -25,7 +25,9 @@
 
 import java.io.InputStream;
 import java.rmi.RemoteException;
+import java.util.HashMap;
 
+import javax.activation.DataHandler;
 import javax.management.ObjectName;
 import javax.xml.soap.SOAPMessage;
 
@@ -34,11 +36,19 @@
 import org.jboss.webservice.transport.jms.MessageDispatcher;
 import org.jboss.ws.WSException;
 import org.jboss.ws.binding.BindingException;
+import org.jboss.ws.common.SOAPMessageContextBase;
 import org.jboss.ws.integration.jboss.ServiceEndpointInvokerMDB;
+import org.jboss.ws.jaxrpc.handler.MessageContextJAXRPC;
+import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
+import org.jboss.ws.jaxws.handler.MessageContextJAXWS;
+import org.jboss.ws.jaxws.handler.SOAPMessageContextJAXWS;
+import org.jboss.ws.metadata.EndpointMetaData;
+import org.jboss.ws.metadata.ServerEndpointMetaData;
 import org.jboss.ws.server.ServiceEndpoint;
 import org.jboss.ws.server.ServiceEndpointInvoker;
 import org.jboss.ws.server.ServiceEndpointManager;
 import org.jboss.ws.server.ServiceEndpointManagerFactory;
+import org.jboss.ws.soap.MessageContextAssociation;
 
 /**
  * A dispatcher for SOAPMessages
@@ -74,6 +84,22 @@
             mdbInvoker.setTargetBeanObject(targetBean);
          }
 
+         // Associate a message context with the current thread
+         SOAPMessageContextBase msgContext;
+         ServerEndpointMetaData sepMetaData = sep.getServiceEndpointInfo().getServerEndpointMetaData();
+         if (sepMetaData.getType() == EndpointMetaData.Type.JAXRPC)
+         {
+            msgContext = new SOAPMessageContextJAXRPC();
+         }
+         else
+         {
+            msgContext = new SOAPMessageContextJAXWS();
+            msgContext.setProperty(MessageContextJAXWS.MESSAGE_OUTBOUND_PROPERTY, new Boolean(false));
+            msgContext.setProperty(MessageContextJAXWS.INBOUND_MESSAGE_ATTACHMENTS, new HashMap<String, DataHandler>());
+         }
+         msgContext.setEndpointMetaData(sepMetaData);
+         MessageContextAssociation.pushMessageContext(msgContext);
+         
          return sep.handleRequest(null, null, reqMessage);
       }
       catch (BindingException ex)

Added: trunk/src/main/java/org/jboss/ws/utils/JBossWSEntityResolver.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/utils/JBossWSEntityResolver.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/utils/JBossWSEntityResolver.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,82 @@
+/*
+ * 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.IOException;
+import java.net.URL;
+
+import org.jboss.logging.Logger;
+import org.jboss.util.xml.JBossEntityResolver;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/** 
+ * Dynamically register the JBossWS entities.
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 02-Aug-2006
+ */
+public class JBossWSEntityResolver extends JBossEntityResolver
+{
+   // provide logging
+   private static final Logger log = Logger.getLogger(JBossWSEntityResolver.class);
+
+   public JBossWSEntityResolver()
+   {
+      registerEntity("urn:jboss:jaxrpc-config:2.0", "schema/jaxrpc-config_2_0.xsd");
+      registerEntity("urn:jboss:jaxws-config:2.0", "schema/jaxws-config_2_0.xsd");
+      registerEntity("http://java.sun.com/xml/ns/javaee", "schema/handler-chain.xsd");
+      registerEntity("http://www.w3.org/2005/08/addressing", "schema/ws-addr.xsd");      
+      registerEntity("http://schemas.xmlsoap.org/ws/2004/08/eventing", "eventing.xsd");
+   }
+
+   public InputSource resolveEntity(String publicId, String systemId) throws SAXException, IOException
+   {
+      log.debug("resolveEntity: [pub=" + publicId + ",sysid=" + systemId + "]");
+      InputSource inputSource = super.resolveEntity(publicId, systemId);
+      return inputSource;
+   }
+   
+   public URL resolveNamespaceURI(String nsURI)
+   {
+      URL url = null;
+      
+      String resource = (String)getEntityMap().get(nsURI);
+      if (resource != null)
+      {
+         ClassLoader loader = Thread.currentThread().getContextClassLoader();
+         url = loader.getResource(resource);
+         if( url == null )
+         {
+            if( resource.endsWith(".dtd") )
+               resource = "dtd/" + resource;
+            else if( resource.endsWith(".xsd") )
+               resource = "schema/" + resource;
+            url = loader.getResource(resource);
+         }
+      }
+      
+      return url;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/utils/JBossWSEntityResolver.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/main/java/org/jboss/ws/wsse/WSSecurityDispatcher.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/WSSecurityDispatcher.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/wsse/WSSecurityDispatcher.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -35,8 +35,8 @@
 import org.jboss.logging.Logger;
 import org.jboss.util.xml.DOMWriter;
 import org.jboss.ws.WSException;
+import org.jboss.ws.common.SOAPMessageContextBase;
 import org.jboss.ws.jaxrpc.StubExt;
-import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
 import org.jboss.ws.metadata.EndpointMetaData;
 import org.jboss.ws.metadata.OperationMetaData;
 import org.jboss.ws.metadata.wsse.Config;
@@ -103,7 +103,7 @@
       return new SOAPFaultException(e.getFaultCode(), e.getFaultString(), null, null);
    }
 
-   public static void handleInbound(SOAPMessageContextJAXRPC ctx) throws SOAPException, SOAPFaultException
+   public static void handleInbound(SOAPMessageContextBase ctx) throws SOAPException, SOAPFaultException
    {
       WSSecurityConfiguration config = getSecurityConfig(ctx);
       SOAPMessageImpl soapMessage = (SOAPMessageImpl)ctx.getMessage();
@@ -174,7 +174,7 @@
       }
    }
 
-   private static WSSecurityConfiguration getSecurityConfig(SOAPMessageContextJAXRPC ctx)
+   private static WSSecurityConfiguration getSecurityConfig(SOAPMessageContextBase ctx)
    {
       WSSecurityConfiguration config = ctx.getEndpointMetaData().getServiceMetaData().getSecurityConfiguration();
       if (config == null)
@@ -221,7 +221,7 @@
       return operations;
    }
 
-   public static void handleOutbound(SOAPMessageContextJAXRPC ctx) throws SOAPException, SOAPFaultException
+   public static void handleOutbound(SOAPMessageContextBase ctx) throws SOAPException, SOAPFaultException
    {
       WSSecurityConfiguration config = getSecurityConfig(ctx);
       SOAPMessageImpl soapMessage = (SOAPMessageImpl)ctx.getMessage();

Deleted: trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -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.wsse;
-
-// $Id$
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.handler.GenericHandler;
-import javax.xml.rpc.handler.MessageContext;
-import javax.xml.soap.SOAPException;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
-import org.jboss.ws.metadata.EndpointMetaData;
-import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
-
-/**
- * An abstract JAXRPC handler that delegates to the WSSecurityDispatcher
- *
- * @author Thomas.Diesler at jboss.org
- * @since 12-Nov-2005
- */
-public abstract class WSSecurityHandler extends GenericHandler
-{
-   // provide logging
-   private static Logger log = Logger.getLogger(WSSecurityHandler.class);
-   
-   public QName[] getHeaders()
-   {
-      return null;
-   }
-
-   protected boolean handleInboundSecurity(MessageContext msgContext)
-   {
-      try
-      {
-         if (getSecurityConfiguration(msgContext) != null)
-         {
-            WSSecurityDispatcher.handleInbound((SOAPMessageContextJAXRPC)msgContext);
-         }
-      }
-      catch (SOAPException ex)
-      {
-         log.error("Cannot handle inbound ws-security", ex);
-         return false;
-      }
-      return true;
-   }
-
-   protected boolean handleOutboundSecurity(MessageContext msgContext)
-   {
-      try
-      {
-         if (getSecurityConfiguration(msgContext) != null)
-         {
-            WSSecurityDispatcher.handleOutbound((SOAPMessageContextJAXRPC)msgContext);
-         }
-      }
-      catch (SOAPException ex)
-      {
-         log.error("Cannot handle outbound ws-security", ex);
-         return false;
-      }
-      return true;
-   }
-
-   private WSSecurityConfiguration getSecurityConfiguration(MessageContext msgContext)
-   {
-      EndpointMetaData epMetaData = ((SOAPMessageContextJAXRPC)msgContext).getEndpointMetaData();
-      WSSecurityConfiguration securityConfiguration = epMetaData.getServiceMetaData().getSecurityConfiguration();
-      if (securityConfiguration == null)
-         log.warn("Cannot obtain security configuration");
-      
-      return securityConfiguration;
-   }
-}

Deleted: trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerInbound.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerInbound.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerInbound.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -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.wsse;
-
-// $Id$
-
-import javax.xml.rpc.handler.MessageContext;
-
-/**
- * A JAXRPC handler that delegates to the WSSecurityDispatcher
- * where the request is an inbound message.
- *
- * @author Thomas.Diesler at jboss.org
- * @since 12-Nov-2005
- */
-public class WSSecurityHandlerInbound extends WSSecurityHandler
-{
-   public boolean handleRequest(MessageContext msgContext)
-   {
-      return handleInboundSecurity(msgContext);
-   }
-
-   public boolean handleResponse(MessageContext msgContext)
-   {
-      return handleOutboundSecurity(msgContext);
-   }
-}

Deleted: trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerOutbound.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerOutbound.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerOutbound.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,45 +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.wsse;
-
-// $Id$
-
-import javax.xml.rpc.handler.MessageContext;
-
-/**
- * A JAXRPC handler that delegates to the WSSecurityDispatcher
- *
- * @author Thomas.Diesler at jboss.org
- * @since 12-Nov-2005
- */
-public class WSSecurityHandlerOutbound extends WSSecurityHandler
-{
-   public boolean handleRequest(MessageContext msgContext)
-   {
-      return handleOutboundSecurity(msgContext);
-   }
-
-   public boolean handleResponse(MessageContext msgContext)
-   {
-      return handleInboundSecurity(msgContext);
-   }
-}

Copied: trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandler.java (from rev 673, trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandler.java)
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandler.java	2006-08-03 08:57:12 UTC (rev 673)
+++ trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,96 @@
+/*
+* 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.wsse.jaxrpc;
+
+// $Id$
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.handler.GenericHandler;
+import javax.xml.rpc.handler.MessageContext;
+import javax.xml.soap.SOAPException;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.jaxrpc.handler.SOAPMessageContextJAXRPC;
+import org.jboss.ws.metadata.EndpointMetaData;
+import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
+import org.jboss.ws.wsse.WSSecurityDispatcher;
+
+/**
+ * An abstract JAXRPC handler that delegates to the WSSecurityDispatcher
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-Nov-2005
+ */
+public abstract class WSSecurityHandler extends GenericHandler
+{
+   // provide logging
+   private static Logger log = Logger.getLogger(WSSecurityHandler.class);
+   
+   public QName[] getHeaders()
+   {
+      return null;
+   }
+
+   protected boolean handleInboundSecurity(MessageContext msgContext)
+   {
+      try
+      {
+         if (getSecurityConfiguration(msgContext) != null)
+         {
+            WSSecurityDispatcher.handleInbound((SOAPMessageContextJAXRPC)msgContext);
+         }
+      }
+      catch (SOAPException ex)
+      {
+         log.error("Cannot handle inbound ws-security", ex);
+         return false;
+      }
+      return true;
+   }
+
+   protected boolean handleOutboundSecurity(MessageContext msgContext)
+   {
+      try
+      {
+         if (getSecurityConfiguration(msgContext) != null)
+         {
+            WSSecurityDispatcher.handleOutbound((SOAPMessageContextJAXRPC)msgContext);
+         }
+      }
+      catch (SOAPException ex)
+      {
+         log.error("Cannot handle outbound ws-security", ex);
+         return false;
+      }
+      return true;
+   }
+
+   private WSSecurityConfiguration getSecurityConfiguration(MessageContext msgContext)
+   {
+      EndpointMetaData epMetaData = ((SOAPMessageContextJAXRPC)msgContext).getEndpointMetaData();
+      WSSecurityConfiguration securityConfiguration = epMetaData.getServiceMetaData().getSecurityConfiguration();
+      if (securityConfiguration == null)
+         log.warn("Cannot obtain security configuration");
+      
+      return securityConfiguration;
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandler.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Copied: trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerInbound.java (from rev 673, trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerInbound.java)
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerInbound.java	2006-08-03 08:57:12 UTC (rev 673)
+++ trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerInbound.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -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.wsse.jaxrpc;
+
+// $Id$
+
+import javax.xml.rpc.handler.MessageContext;
+
+
+/**
+ * A JAXRPC handler that delegates to the WSSecurityDispatcher
+ * where the request is an inbound message.
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-Nov-2005
+ */
+public class WSSecurityHandlerInbound extends WSSecurityHandler
+{
+   public boolean handleRequest(MessageContext msgContext)
+   {
+      return handleInboundSecurity(msgContext);
+   }
+
+   public boolean handleResponse(MessageContext msgContext)
+   {
+      return handleOutboundSecurity(msgContext);
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerInbound.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Copied: trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerOutbound.java (from rev 673, trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerOutbound.java)
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/WSSecurityHandlerOutbound.java	2006-08-03 08:57:12 UTC (rev 673)
+++ trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerOutbound.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,46 @@
+/*
+ * 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.wsse.jaxrpc;
+
+// $Id$
+
+import javax.xml.rpc.handler.MessageContext;
+
+
+/**
+ * A JAXRPC handler that delegates to the WSSecurityDispatcher
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-Nov-2005
+ */
+public class WSSecurityHandlerOutbound extends WSSecurityHandler
+{
+   public boolean handleRequest(MessageContext msgContext)
+   {
+      return handleOutboundSecurity(msgContext);
+   }
+
+   public boolean handleResponse(MessageContext msgContext)
+   {
+      return handleInboundSecurity(msgContext);
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/wsse/jaxrpc/WSSecurityHandlerOutbound.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandler.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,111 @@
+/*
+* 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.wsse.jaxws;
+
+// $Id$
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+import javax.xml.soap.SOAPException;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.common.SOAPMessageContextBase;
+import org.jboss.ws.metadata.EndpointMetaData;
+import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
+import org.jboss.ws.wsse.WSSecurityDispatcher;
+
+/**
+ * An abstract JAXWS handler that delegates to the WSSecurityDispatcher
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-Nov-2005
+ */
+public abstract class WSSecurityHandler implements SOAPHandler
+{
+   // provide logging
+   private static Logger log = Logger.getLogger(WSSecurityHandler.class);
+   
+   /**
+    * Gets the header blocks that can be processed by this Handler instance.
+    */
+   public Set<QName> getHeaders()
+   {
+      return new HashSet<QName>();
+   }
+
+   protected boolean handleInboundSecurity(MessageContext msgContext)
+   {
+      try
+      {
+         if (getSecurityConfiguration(msgContext) != null)
+         {
+            WSSecurityDispatcher.handleInbound((SOAPMessageContextBase)msgContext);
+         }
+      }
+      catch (SOAPException ex)
+      {
+         log.error("Cannot handle inbound ws-security", ex);
+         return false;
+      }
+      return true;
+   }
+
+   protected boolean handleOutboundSecurity(MessageContext msgContext)
+   {
+      try
+      {
+         if (getSecurityConfiguration(msgContext) != null)
+         {
+            WSSecurityDispatcher.handleOutbound((SOAPMessageContextBase)msgContext);
+         }
+      }
+      catch (SOAPException ex)
+      {
+         log.error("Cannot handle outbound ws-security", ex);
+         return false;
+      }
+      return true;
+   }
+
+   private WSSecurityConfiguration getSecurityConfiguration(MessageContext msgContext)
+   {
+      EndpointMetaData epMetaData = ((SOAPMessageContextBase)msgContext).getEndpointMetaData();
+      WSSecurityConfiguration securityConfiguration = epMetaData.getServiceMetaData().getSecurityConfiguration();
+      if (securityConfiguration == null)
+         log.warn("Cannot obtain security configuration");
+      
+      return securityConfiguration;
+   }
+
+   public boolean handleFault(MessageContext messagecontext)
+   {
+      return true;
+   }
+   
+   public void close(MessageContext messagecontext)
+   {
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandler.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerInbound.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerInbound.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerInbound.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,56 @@
+/*
+ * 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.wsse.jaxws;
+
+import javax.xml.ws.handler.MessageContext;
+
+// $Id$
+
+/**
+ * A JAXWS handler that delegates to the WSSecurityDispatcher
+ * where the request is an inbound message.
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-Nov-2005
+ */
+public class WSSecurityHandlerInbound extends WSSecurityHandler
+{
+
+   public boolean handleMessage(MessageContext msgContext)
+   {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+
+   private boolean handleRequest(MessageContext msgContext)
+   {
+      return handleInboundSecurity(msgContext);
+   }
+
+   private boolean handleResponse(MessageContext msgContext)
+   {
+      return handleOutboundSecurity(msgContext);
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerInbound.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerOutbound.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerOutbound.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerOutbound.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,55 @@
+/*
+ * 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.wsse.jaxws;
+
+import javax.xml.ws.handler.MessageContext;
+
+// $Id$
+
+/**
+ * A JAXWS handler that delegates to the WSSecurityDispatcher
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 12-Nov-2005
+ */
+public class WSSecurityHandlerOutbound extends WSSecurityHandler
+{
+
+   public boolean handleMessage(MessageContext msgContext)
+   {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+
+   public boolean handleRequest(MessageContext msgContext)
+   {
+      return handleOutboundSecurity(msgContext);
+   }
+
+   public boolean handleResponse(MessageContext msgContext)
+   {
+      return handleInboundSecurity(msgContext);
+   }
+}


Property changes on: trunk/src/main/java/org/jboss/ws/wsse/jaxws/WSSecurityHandlerOutbound.java
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Copied: trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxrpc-client-config.xml (from rev 661, trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-client-config.xml)
===================================================================
--- trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-client-config.xml	2006-08-01 16:32:34 UTC (rev 661)
+++ trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxrpc-client-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxrpc-config xmlns="urn:jboss:jaxrpc-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
+  xsi:schemaLocation="urn:jboss:jaxrpc-config:2.0 jaxrpc-config_2_0.xsd">
+  
+  <client-config>
+    <config-name>Standard Client</config-name>
+  </client-config>
+  
+  <client-config>
+    <config-name>Standard Secure Client</config-name>
+    <post-handler-chain>
+      <handler-chain-name>PostHandlerChain</handler-chain-name>
+      <handler>
+        <j2ee:handler-name>WSSecurityHandlerOutbound</j2ee:handler-name>
+        <j2ee:handler-class>org.jboss.ws.wsse.jaxrpc.WSSecurityHandlerOutbound</j2ee:handler-class>
+      </handler>
+    </post-handler-chain>
+  </client-config>
+  
+  <client-config>
+    <config-name>Standard Addressing Client</config-name>
+    <post-handler-chain>
+      <handler-chain-name>PostHandlerChain</handler-chain-name>
+      <handler>
+        <j2ee:handler-name>WSAddressingClientHandler</j2ee:handler-name>
+        <j2ee:handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler</j2ee:handler-class>
+      </handler>
+    </post-handler-chain>
+  </client-config>
+  
+</jaxrpc-config>
\ No newline at end of file

Copied: trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxrpc-endpoint-config.xml (from rev 661, trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-endpoint-config.xml)
===================================================================
--- trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-endpoint-config.xml	2006-08-01 16:32:34 UTC (rev 661)
+++ trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxrpc-endpoint-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxrpc-config xmlns="urn:jboss:jaxrpc-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
+  xsi:schemaLocation="urn:jboss:jaxrpc-config:2.0 jaxrpc-config_2_0.xsd">
+  
+  <endpoint-config>
+    <config-name>Standard Endpoint</config-name>
+  </endpoint-config>
+  
+  <endpoint-config>
+    <config-name>Standard Secure Endpoint</config-name>
+    <pre-handler-chain>
+      <handler-chain-name>PreHandlerChain</handler-chain-name>
+      <handler>
+        <j2ee:handler-name>WSSecurityHandlerInbound</j2ee:handler-name>
+        <j2ee:handler-class>org.jboss.ws.wsse.jaxrpc.WSSecurityHandlerInbound</j2ee:handler-class>
+      </handler>
+    </pre-handler-chain>
+   </endpoint-config>
+  
+</jaxrpc-config>
\ No newline at end of file

Added: trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-client-config.xml
===================================================================
--- trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-client-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-client-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxws-config xmlns="urn:jboss:jaxws-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:javaee="http://java.sun.com/xml/ns/javaee"
+  xsi:schemaLocation="urn:jboss:jaxws-config:2.0 jaxws-config_2_0.xsd">
+  
+  <client-config>
+    <config-name>Standard Client</config-name>
+  </client-config>
+  
+  <client-config>
+    <config-name>Standard Secure Client</config-name>
+    <post-handler-chains>
+      <javaee:handler-chain>
+        <javaee:protocol-bindings>##SOAP11_HTTP</javaee:protocol-bindings>
+        <javaee:handler>
+          <javaee:handler-name>WSSecurityHandlerOutbound</javaee:handler-name>
+          <javaee:handler-class>org.jboss.ws.wsse.jaxws.WSSecurityHandlerOutbound</javaee:handler-class>
+        </javaee:handler>
+      </javaee:handler-chain>
+    </post-handler-chains>
+  </client-config>
+  
+  <client-config>
+    <config-name>Standard Addressing Client</config-name>
+    <post-handler-chains>
+      <javaee:handler-chain>
+        <javaee:protocol-bindings>##SOAP11_HTTP</javaee:protocol-bindings>
+        <javaee:handler>
+          <javaee:handler-name>SOAPClientHandler</javaee:handler-name>
+          <javaee:handler-class>org.jboss.ws.addressing.jaxws.WSAddressingClientHandler</javaee:handler-class>
+        </javaee:handler>
+      </javaee:handler-chain>
+    </post-handler-chains>
+  </client-config>
+  
+</jaxws-config>
\ No newline at end of file


Property changes on: trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-client-config.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-endpoint-config.xml
===================================================================
--- trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-endpoint-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-endpoint-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxws-config xmlns="urn:jboss:jaxws-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:javaee="http://java.sun.com/xml/ns/javaee"
+  xsi:schemaLocation="urn:jboss:jaxws-config:2.0 jaxws-config_2_0.xsd">
+  
+  <endpoint-config>
+    <config-name>Standard Endpoint</config-name>
+  </endpoint-config>
+  
+  <endpoint-config>
+    <config-name>Standard Secure Endpoint</config-name>
+    <pre-handler-chains>
+      <javaee:handler-chain>
+        <javaee:protocol-bindings>##SOAP11_HTTP</javaee:protocol-bindings>
+        <javaee:handler>
+          <javaee:handler-name>WSSecurityHandlerInbound</javaee:handler-name>
+          <javaee:handler-class>org.jboss.ws.wsse.jaxws.WSSecurityHandlerInbound</javaee:handler-class>
+        </javaee:handler>
+      </javaee:handler-chain>
+    </pre-handler-chains>
+   </endpoint-config>
+  
+</jaxws-config>
\ No newline at end of file


Property changes on: trunk/src/main/resources/jbossws.sar/META-INF/standard-jaxws-endpoint-config.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Deleted: trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-client-config.xml
===================================================================
--- trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-client-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-client-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- $Id$ -->
-
-<jbossws-config xmlns="urn:jboss:jbossws-config:5.0"
-  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
-  xsi:schemaLocation="urn:jboss:jbossws-config:5.0 http://www.jboss.com/xml/jbossws-config_1_0.xsd">
-  
-  <client-config>
-    <config-name>Standard Client</config-name>
-  </client-config>
-  
-  <client-config>
-    <config-name>Standard Secure Client</config-name>
-    <post-handler-chain>
-      <handler-chain-name>PostHandlerChain</handler-chain-name>
-      <handler>
-        <j2ee:handler-name>WSSecurityHandlerOutbound</j2ee:handler-name>
-        <j2ee:handler-class>org.jboss.ws.wsse.WSSecurityHandlerOutbound</j2ee:handler-class>
-      </handler>
-    </post-handler-chain>
-  </client-config>
-  
-  <client-config>
-    <config-name>Standard Addressing Client</config-name>
-    <post-handler-chain>
-      <handler-chain-name>PostHandlerChain</handler-chain-name>
-      <handler>
-        <j2ee:handler-name>SOAPClientHandler</j2ee:handler-name>
-        <j2ee:handler-class>org.jboss.ws.addressing.soap.SOAPClientHandler</j2ee:handler-class>
-      </handler>
-    </post-handler-chain>
-  </client-config>
-  
-</jbossws-config>
\ No newline at end of file

Deleted: trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-endpoint-config.xml
===================================================================
--- trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-endpoint-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/jbossws.sar/META-INF/standard-jbossws-endpoint-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- $Id$ -->
-
-<jbossws-config xmlns="urn:jboss:jbossws-config:5.0"
-  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
-  xsi:schemaLocation="urn:jboss:jbossws-config:5.0 http://www.jboss.com/xml/jbossws-config_1_0.xsd">
-  
-  <endpoint-config>
-    <config-name>Standard Endpoint</config-name>
-  </endpoint-config>
-  
-  <endpoint-config>
-    <config-name>Standard Secure Endpoint</config-name>
-    <pre-handler-chain>
-      <handler-chain-name>PreHandlerChain</handler-chain-name>
-      <handler>
-        <j2ee:handler-name>WSSecurityHandlerInbound</j2ee:handler-name>
-        <j2ee:handler-class>org.jboss.ws.wsse.WSSecurityHandlerInbound</j2ee:handler-class>
-      </handler>
-    </pre-handler-chain>
-   </endpoint-config>
-  
-</jbossws-config>
\ No newline at end of file

Added: trunk/src/main/resources/schema/handler-chain.xsd
===================================================================
--- trunk/src/main/resources/schema/handler-chain.xsd	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/schema/handler-chain.xsd	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,252 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema"
+	    targetNamespace="http://java.sun.com/xml/ns/javaee"
+	    xmlns:javaee="http://java.sun.com/xml/ns/javaee"
+	    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+	    elementFormDefault="qualified"
+	    attributeFormDefault="unqualified"
+	    version="1.0">
+
+  <xsd:include schemaLocation="javaee_5.xsd"/>
+
+<!-- **************************************************** -->
+
+  <xsd:element name="handler-chains" type="javaee:handler-chainsType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The handler-chains element is the root element for defining handlerchains.
+
+      </xsd:documentation>
+    </xsd:annotation>
+  </xsd:element>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="handler-chainsType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+      The handler-chains element defines the handlerchains associated with this
+      service or service endpoint.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="handler-chain" 
+                   type="javaee:handler-chainType"
+		   minOccurs="1" maxOccurs="unbounded"/>
+    </xsd:sequence>
+
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+  
+<!-- **************************************************** -->
+
+  <xsd:complexType name="handler-chainType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+      The handler-chain element defines the handlerchain.
+      Handlerchain can be defined such that the handlers in the
+      handlerchain operate,all ports of a service, on a specific
+      port or on a list of protocol-bindings. The choice of elements
+      service-name-pattern, port-name-pattern and protocol-bindings
+      are used to specify whether the handlers in handler-chain are
+      for a service, port or protocol binding. If none of these
+      choices are specified with the handler-chain element then the
+      handlers specified in the handler-chain will be applied on
+      everything.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+
+      <xsd:choice minOccurs="0" maxOccurs="1">
+         <xsd:element name="service-name-pattern"
+		      type="javaee:qname-pattern" />
+         <xsd:element name="port-name-pattern"
+		      type="javaee:qname-pattern" />
+         <xsd:element name="protocol-bindings"
+		      type="javaee:protocol-bindingListType"/>
+      </xsd:choice>
+
+      <xsd:element name="handler"
+                   type="javaee:handlerType"
+		   minOccurs="1" maxOccurs="unbounded"/>
+    </xsd:sequence>
+
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:simpleType name="protocol-URIAliasType">
+     <xsd:annotation>
+        <xsd:documentation>
+	   Defines the type that is used for specifying tokens that
+	   start with ## which are used to alias existing standard
+	   protocol bindings and support aliases for new standard
+	   binding URIs that are introduced in future specifications.
+
+	   The following tokens alias the standard protocol binding
+	   URIs:
+
+	   ##SOAP11_HTTP = "http://schemas.xmlsoap.org/wsdl/soap/http"
+           ##SOAP12_HTTP = "http://www.w3.org/2003/05/soap/bindings/HTTP/"
+           ##XML_HTTP = "http://www.w3.org/2004/08/wsdl/http"
+
+        </xsd:documentation>
+     </xsd:annotation>
+     <xsd:restriction base="xsd:token">
+        <xsd:pattern value="##.+"/>
+     </xsd:restriction>
+  </xsd:simpleType>
+
+<!-- **************************************************** -->
+
+  <xsd:simpleType name="protocol-bindingListType">
+     <xsd:annotation>
+        <xsd:documentation>
+	   Defines the type used for specifying a list of
+	   protocol-bindingType(s). For e.g.
+
+	    ##SOAP11_HTTP ##SOAP12_HTTP ##XML_HTTP
+
+        </xsd:documentation>
+     </xsd:annotation>
+     <xsd:list itemType="javaee:protocol-bindingType"/>
+  </xsd:simpleType>
+
+<!-- **************************************************** -->
+
+  <xsd:simpleType name="protocol-bindingType">
+     <xsd:annotation>
+        <xsd:documentation>
+	   Defines the type used for specifying the URI for the
+	   protocol binding used by the port-component.  For
+	   portability one could use one of the following tokens that
+	   alias the standard binding types:
+
+	    ##SOAP11_HTTP
+	    ##SOAP12_HTTP
+	    ##XML_HTTP
+
+	   Other specifications could define tokens that start with ##
+	   to alias new standard binding URIs that are introduced.
+
+        </xsd:documentation>
+     </xsd:annotation>
+     <xsd:union memberTypes="xsd:anyURI javaee:protocol-URIAliasType"/>
+  </xsd:simpleType>
+
+<!-- **************************************************** -->
+
+  <xsd:simpleType name="qname-pattern">
+     <xsd:annotation>
+        <xsd:documentation>
+	     This is used to specify the QName pattern in the
+	     attribute service-name-pattern and port-name-pattern in
+	     the handler-chain element
+
+	     For example, the various forms acceptable here for
+	     service-name-pattern attribute in handler-chain element
+	     are :
+
+	     Exact Name: service-name-pattern="ns1:EchoService"
+
+		 In this case, handlers specified in this
+		 handler-chain element will apply to all ports with
+		 this exact service name. The namespace prefix must
+		 have been declared in a namespace declaration
+		 attribute in either the start-tag of the element
+		 where the prefix is used or in an an ancestor
+		 element (i.e. an element in whose content the
+		 prefixed markup occurs)
+
+	     Pattern : service-name-pattern="ns1:EchoService*"
+
+		 In this case, handlers specified in this
+		 handler-chain element will apply to all ports whose
+		 Service names are like EchoService1, EchoServiceFoo
+		 etc. The namespace prefix must have been declared in
+		 a namespace declaration attribute in either the
+		 start-tag of the element where the prefix is used or
+		 in an an ancestor element (i.e. an element in whose
+		 content the prefixed markup occurs)
+
+	     Wild Card : service-name-pattern="*"
+
+		In this case, handlers specified in this handler-chain
+		element will apply to ports of all service names.
+
+	    The same can be applied to port-name attribute in
+	    handler-chain element.
+
+        </xsd:documentation>
+     </xsd:annotation>
+
+     <xsd:restriction base="xsd:token">
+        <xsd:pattern value="\*|([\i-[:]][\c-[:]]*:)?[\i-[:]][\c-[:]]*\*?"/>
+     </xsd:restriction>
+
+  </xsd:simpleType>
+
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="handlerType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	Declares the handler. Handlers can access the
+	init-param name/value pairs using the HandlerInfo interface.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:group ref="javaee:descriptionGroup"/>
+      <xsd:element name="handler-name"
+		   type="javaee:string">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    Defines the name of the handler.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+      <xsd:element name="handler-class"
+		   type="javaee:fully-qualified-classType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    Defines a fully qualified class name for the handler implementation.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+      <xsd:element name="init-param"
+		   type="javaee:param-valueType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+
+      <xsd:element name="soap-role"
+		   type="javaee:string"
+		   minOccurs="0" maxOccurs="unbounded">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The soap-role element contains a SOAP actor definition that the
+	    Handler will play as a role.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+</xsd:schema>
+


Property changes on: trunk/src/main/resources/schema/handler-chain.xsd
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Deleted: trunk/src/main/resources/schema/handler-config_1_0.xsd
===================================================================
--- trunk/src/main/resources/schema/handler-config_1_0.xsd	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/schema/handler-config_1_0.xsd	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.bea.com/xml/ns/jws" xmlns:jws="http://www.bea.com/xml/ns/jws"
-  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee" xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified" version="1.1">
-  
-  <xsd:annotation>
-    <xsd:documentation>
-      <![CDATA[
-      This is the schema definition for the handler chain configuration
-      file used by JSR-181. It relies on the handler definitions that
-      are part of the standard J2EE deployment descriptors.
-      ]]>
-    </xsd:documentation>
-  </xsd:annotation>
-  
-  <xsd:include schemaLocation="j2ee_1_4.xsd"/>
-  <xsd:include schemaLocation="j2ee_web_services_1_1.xsd"/>
-  
-  <xsd:complexType name="handler-chainType">
-    <xsd:sequence>
-      <xsd:element name="handler-chain-name" type="j2ee:string"/>
-      <xsd:element name="handler" type="j2ee:port-component_handlerType" minOccurs="0" maxOccurs="unbounded"/>
-    </xsd:sequence>
-  </xsd:complexType>
-  
-  <xsd:complexType name="handler-configType">
-    <xsd:sequence>
-      <xsd:element name="handler-chain" type="jws:handler-chainType" minOccurs="1" maxOccurs="unbounded"/>
-    </xsd:sequence>
-  </xsd:complexType>
-  
-  <xsd:element name="handler-config" type="jws:handler-configType"/>
-  
-</xsd:schema>
\ No newline at end of file

Added: trunk/src/main/resources/schema/javaee_5.xsd
===================================================================
--- trunk/src/main/resources/schema/javaee_5.xsd	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/schema/javaee_5.xsd	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,2095 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<xsd:schema
+     targetNamespace="http://java.sun.com/xml/ns/javaee"
+     xmlns:javaee="http://java.sun.com/xml/ns/javaee"
+     xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+     elementFormDefault="qualified"
+     attributeFormDefault="unqualified"
+     version="5">
+  <xsd:annotation>
+    <xsd:documentation>
+      @(#)javaee_5.xsds	1.65 06/02/17
+    </xsd:documentation>
+  </xsd:annotation>
+
+  <xsd:annotation>
+    <xsd:documentation>
+
+      Copyright 2003-2006 Sun Microsystems, Inc.
+      4150 Network Circle
+      Santa Clara, California 95054
+      U.S.A
+      All rights reserved.
+
+      Sun Microsystems, Inc. has intellectual property rights
+      relating to technology described in this document. In
+      particular, and without limitation, these intellectual
+      property rights may include one or more of the U.S. patents
+      listed at http://www.sun.com/patents and one or more
+      additional patents or pending patent applications in the
+      U.S. and other countries.
+
+      This document and the technology which it describes are
+      distributed under licenses restricting their use, copying,
+      distribution, and decompilation. No part of this document
+      may be reproduced in any form by any means without prior
+      written authorization of Sun and its licensors, if any.
+
+      Third-party software, including font technology, is
+      copyrighted and licensed from Sun suppliers.
+
+      Sun, Sun Microsystems, the Sun logo, Solaris, Java, J2EE,
+      JavaServer Pages, Enterprise JavaBeans and the Java Coffee
+      Cup logo are trademarks or registered trademarks of Sun
+      Microsystems, Inc. in the U.S. and other countries.
+
+      Federal Acquisitions: Commercial Software - Government Users
+      Subject to Standard License Terms and Conditions.
+
+    </xsd:documentation>
+  </xsd:annotation>
+
+<xsd:annotation>
+<xsd:documentation>
+
+The following definitions that appear in the common
+shareable schema(s) of J2EE deployment descriptors should be
+interpreted with respect to the context they are included:
+
+Deployment Component may indicate one of the following:
+    j2ee application;
+    application client;
+    web application;
+    enterprise bean;
+    resource adapter;
+
+Deployment File may indicate one of the following:
+    ear file;
+    war file;
+    jar file;
+    rar file;
+
+</xsd:documentation>
+</xsd:annotation>
+
+  <xsd:import namespace="http://www.w3.org/XML/1998/namespace"
+	      schemaLocation="http://www.w3.org/2001/xml.xsd"/>
+
+  <xsd:include schemaLocation="javaee_web_services_client_1_2.xsd"/>
+
+
+<!-- **************************************************** -->
+
+  <xsd:group name="descriptionGroup">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This group keeps the usage of the contained description related
+	elements consistent across Java EE deployment descriptors.
+
+	All elements may occur multiple times with different languages,
+	to support localization of the content.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="display-name"
+		   type="javaee:display-nameType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="icon"
+		   type="javaee:iconType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+    </xsd:sequence>
+  </xsd:group>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="descriptionType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The description type is used by a description element to
+	provide text describing the parent element.  The elements
+	that use this type should include any information that the
+	Deployment Component's Deployment File file producer wants
+	to provide to the consumer of the Deployment Component's
+	Deployment File (i.e., to the Deployer). Typically, the
+	tools used by such a Deployment File consumer will display
+	the description when processing the parent element that
+	contains the description.
+
+	The lang attribute defines the language that the
+	description is provided in. The default value is "en" (English).
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="javaee:xsdStringType">
+	<xsd:attribute ref="xml:lang"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:simpleType name="dewey-versionType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type defines a dewey decimal that is used
+	to describe versions of documents.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:restriction base="xsd:token">
+      <xsd:pattern value="\.?[0-9]+(\.[0-9]+)*"/>
+    </xsd:restriction>
+  </xsd:simpleType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="display-nameType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The display-name type contains a short name that is intended
+	  to be displayed by tools. It is used by display-name
+	  elements.  The display name need not be unique.
+
+	  Example:
+
+	  ...
+	     <display-name xml:lang="en">
+	       Employee Self Service
+	     </display-name>
+
+	  The value of the xml:lang attribute is "en" (English) by default.
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="javaee:string">
+	<xsd:attribute ref="xml:lang"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="ejb-linkType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The ejb-linkType is used by ejb-link
+	  elements in the ejb-ref or ejb-local-ref elements to specify
+	  that an EJB reference is linked to enterprise bean.
+
+	  The value of the ejb-link element must be the ejb-name of an
+	  enterprise bean in the same ejb-jar file or in another ejb-jar
+	  file in the same Java EE application unit.
+
+	  Alternatively, the name in the ejb-link element may be
+	  composed of a path name specifying the ejb-jar containing the
+	  referenced enterprise bean with the ejb-name of the target
+	  bean appended and separated from the path name by "#".  The
+	  path name is relative to the Deployment File containing
+	  Deployment Component that is referencing the enterprise
+	  bean.  This allows multiple enterprise beans with the same
+	  ejb-name to be uniquely identified.
+
+	  Examples:
+
+	      <ejb-link>EmployeeRecord</ejb-link>
+
+	      <ejb-link>../products/product.jar#ProductEJB</ejb-link>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="ejb-local-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The ejb-local-refType is used by ejb-local-ref elements for
+	the declaration of a reference to an enterprise bean's local
+	home or to the local business interface of a 3.0 bean.
+        The declaration consists of:
+
+	    - an optional description
+	    - the EJB reference name used in the code of the Deployment
+	      Component that's referencing the enterprise bean.
+	    - the optional expected type of the referenced enterprise bean
+	    - the optional expected local interface of the referenced
+              enterprise bean or the local business interface of the
+              referenced enterprise bean.
+	    - the optional expected local home interface of the referenced
+              enterprise bean. Not applicable if this ejb-local-ref refers
+              to the local business interface of a 3.0 bean.
+	    - optional ejb-link information, used to specify the
+	      referenced enterprise bean
+            - optional elements to define injection of the named enterprise
+              bean into a component field or property.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="ejb-ref-name"
+		   type="javaee:ejb-ref-nameType"/>
+      <xsd:element name="ejb-ref-type"
+		   type="javaee:ejb-ref-typeType"
+                   minOccurs="0"/>
+      <xsd:element name="local-home"
+		   type="javaee:local-homeType"
+                   minOccurs="0"/>
+      <xsd:element name="local"
+		   type="javaee:localType"
+                   minOccurs="0"/>
+      <xsd:element name="ejb-link"
+		   type="javaee:ejb-linkType"
+		   minOccurs="0"/>
+      <xsd:group ref="javaee:resourceGroup"/>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="ejb-ref-nameType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The ejb-ref-name element contains the name of an EJB
+	  reference. The EJB reference is an entry in the
+	  Deployment Component's environment and is relative to the
+	  java:comp/env context.  The name must be unique within the
+	  Deployment Component.
+
+	  It is recommended that name is prefixed with "ejb/".
+
+	  Example:
+
+	  <ejb-ref-name>ejb/Payroll</ejb-ref-name>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:jndi-nameType"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="ejb-ref-typeType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The ejb-ref-typeType contains the expected type of the
+	referenced enterprise bean.
+
+	The ejb-ref-type designates a value
+	that must be one of the following:
+
+	    Entity
+	    Session
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:enumeration value="Entity"/>
+	<xsd:enumeration value="Session"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="ejb-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The ejb-refType is used by ejb-ref elements for the
+	declaration of a reference to an enterprise bean's home or
+        to the remote business interface of a 3.0 bean.
+	The declaration consists of:
+
+	    - an optional description
+	    - the EJB reference name used in the code of
+	      the Deployment Component that's referencing the enterprise
+	      bean.
+	    - the optional expected type of the referenced enterprise bean
+            - the optional remote interface of the referenced enterprise bean
+              or the remote business interface of the referenced enterprise
+              bean
+	    - the optional expected home interface of the referenced
+              enterprise bean.  Not applicable if this ejb-ref
+              refers to the remote business interface of a 3.0 bean.
+	    - optional ejb-link information, used to specify the
+	      referenced enterprise bean
+            - optional elements to define injection of the named enterprise
+              bean into a component field or property
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="ejb-ref-name"
+		   type="javaee:ejb-ref-nameType"/>
+      <xsd:element name="ejb-ref-type"
+		   type="javaee:ejb-ref-typeType"
+		   minOccurs="0"/>
+      <xsd:element name="home"
+		   type="javaee:homeType"
+		   minOccurs="0"/>
+      <xsd:element name="remote"
+		   type="javaee:remoteType"
+                   minOccurs="0"/>
+      <xsd:element name="ejb-link"
+		   type="javaee:ejb-linkType"
+		   minOccurs="0"/>
+      <xsd:group ref="javaee:resourceGroup"/>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="emptyType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type is used to designate an empty
+	element when used.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="env-entry-type-valuesType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  This type contains the fully-qualified Java type of the
+	  environment entry value that is expected by the
+	  application's code.
+
+	  The following are the legal values of env-entry-type-valuesType:
+
+	      java.lang.Boolean
+	      java.lang.Byte
+	      java.lang.Character
+	      java.lang.String
+	      java.lang.Short
+	      java.lang.Integer
+	      java.lang.Long
+	      java.lang.Float
+	      java.lang.Double
+
+	  Example:
+
+	  <env-entry-type>java.lang.Boolean</env-entry-type>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:enumeration value="java.lang.Boolean"/>
+	<xsd:enumeration value="java.lang.Byte"/>
+	<xsd:enumeration value="java.lang.Character"/>
+	<xsd:enumeration value="java.lang.String"/>
+	<xsd:enumeration value="java.lang.Short"/>
+	<xsd:enumeration value="java.lang.Integer"/>
+	<xsd:enumeration value="java.lang.Long"/>
+	<xsd:enumeration value="java.lang.Float"/>
+	<xsd:enumeration value="java.lang.Double"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="env-entryType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The env-entryType is used to declare an application's
+	environment entry. The declaration consists of an optional
+	description, the name of the environment entry, a type
+	(optional if the value is injected, otherwise required), and
+	an optional value.
+
+	It also includes optional elements to define injection of
+	the named resource into fields or JavaBeans properties.
+
+	If a value is not specified and injection is requested,
+	no injection will occur and no entry of the specified name
+	will be created.  This allows an initial value to be
+	specified in the source code without being incorrectly
+	changed when no override has been specified.
+
+	If a value is not specified and no injection is requested,
+	a value must be supplied during deployment.
+
+	This type is used by env-entry elements.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="env-entry-name"
+		   type="javaee:jndi-nameType">
+	<xsd:annotation>
+	  <xsd:documentation>
+	    <![CDATA[
+
+	      The env-entry-name element contains the name of a
+	      Deployment Component's environment entry.  The name
+	      is a JNDI name relative to the java:comp/env
+	      context.  The name must be unique within a
+	      Deployment Component. The uniqueness
+	      constraints must be defined within the declared
+	      context.
+
+	      Example:
+
+	      <env-entry-name>minAmount</env-entry-name>
+
+	      ]]>
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="env-entry-type"
+		   type="javaee:env-entry-type-valuesType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+	    <![CDATA[
+
+	      The env-entry-type element contains the Java language
+	      type of the environment entry.  If an injection target
+	      is specified for the environment entry, the type may
+	      be omitted, or must match the type of the injection
+	      target.  If no injection target is specified, the type
+	      is required.
+
+	      Example:
+
+	      <env-entry-type>java.lang.Integer</env-entry-type>
+
+	      ]]>
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="env-entry-value"
+		   type="javaee:xsdStringType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+	    <![CDATA[
+
+	      The env-entry-value designates the value of a
+	      Deployment Component's environment entry. The value
+	      must be a String that is valid for the
+	      constructor of the specified type that takes a
+	      single String parameter, or for java.lang.Character,
+	      a single character.
+
+	      Example:
+
+	      <env-entry-value>100.00</env-entry-value>
+
+	      ]]>
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:group ref="javaee:resourceGroup"/>
+
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="fully-qualified-classType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The elements that use this type designate the name of a
+	Java class or interface.  The name is in the form of a
+	"binary name", as defined in the JLS.  This is the form
+	of name used in Class.forName().  Tools that need the
+	canonical name (the name used in source code) will need
+	to convert this binary name to the canonical name.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="generic-booleanType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type defines four different values which can designate
+	boolean values. This includes values yes and no which are
+	not designated by xsd:boolean
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:enumeration value="true"/>
+	<xsd:enumeration value="false"/>
+	<xsd:enumeration value="yes"/>
+	<xsd:enumeration value="no"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="homeType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The homeType defines the fully-qualified name of
+	  an enterprise bean's home interface.
+
+	  Example:
+
+	      <home>com.aardvark.payroll.PayrollHome</home>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:fully-qualified-classType"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="iconType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The icon type contains small-icon and large-icon elements
+	that specify the file names for small and large GIF, JPEG,
+	or PNG icon images used to represent the parent element in a
+	GUI tool.
+
+	The xml:lang attribute defines the language that the
+	icon file names are provided in. Its value is "en" (English)
+	by default.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="small-icon" type="javaee:pathType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+	    <![CDATA[
+
+	      The small-icon element contains the name of a file
+	      containing a small (16 x 16) icon image. The file
+	      name is a relative path within the Deployment
+	      Component's Deployment File.
+
+	      The image may be in the GIF, JPEG, or PNG format.
+	      The icon can be used by tools.
+
+	      Example:
+
+	      <small-icon>employee-service-icon16x16.jpg</small-icon>
+
+	      ]]>
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+      <xsd:element name="large-icon" type="javaee:pathType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+	    <![CDATA[
+
+	      The large-icon element contains the name of a file
+	      containing a large
+	      (32 x 32) icon image. The file name is a relative
+	      path within the Deployment Component's Deployment
+	      File.
+
+	      The image may be in the GIF, JPEG, or PNG format.
+	      The icon can be used by tools.
+
+	      Example:
+
+	      <large-icon>employee-service-icon32x32.jpg</large-icon>
+
+	      ]]>
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+    </xsd:sequence>
+
+    <xsd:attribute ref="xml:lang"/>
+    <xsd:attribute name="id" type="xsd:ID"/>
+
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="injection-targetType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	An injection target specifies a class and a name within
+	that class into which a resource should be injected.
+
+	The injection target class specifies the fully qualified
+	class name that is the target of the injection.  The
+	Java EE specifications describe which classes can be an
+	injection target.
+
+	The injection target name specifies the target within
+	the specified class.  The target is first looked for as a
+	JavaBeans property name.  If not found, the target is
+	looked for as a field name.
+
+	The specified resource will be injected into the target
+	during initialization of the class by either calling the
+	set method for the target property or by setting a value
+	into the named field.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="injection-target-class"
+		   type="javaee:fully-qualified-classType"/>
+      <xsd:element name="injection-target-name"
+		   type="javaee:java-identifierType"/>
+    </xsd:sequence>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="java-identifierType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The java-identifierType defines a Java identifier.
+	The users of this type should further verify that
+	the content does not contain Java reserved keywords.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:pattern value="($|_|\p{L})(\p{L}|\p{Nd}|_|$)*"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="java-typeType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This is a generic type that designates a Java primitive
+	type or a fully qualified name of a Java interface/type,
+	or an array of such types.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:pattern value="[^\p{Z}]*"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="jndi-nameType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The jndi-nameType type designates a JNDI name in the
+	Deployment Component's environment and is relative to the
+	java:comp/env context.  A JNDI name must be unique within the
+	Deployment Component.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:group name="jndiEnvironmentRefsGroup">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This group keeps the usage of the contained JNDI environment
+	reference elements consistent across Java EE deployment descriptors.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="env-entry"
+		   type="javaee:env-entryType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="ejb-ref"
+		   type="javaee:ejb-refType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="ejb-local-ref"
+		   type="javaee:ejb-local-refType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:group ref="javaee:service-refGroup"/>
+      <xsd:element name="resource-ref"
+		   type="javaee:resource-refType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="resource-env-ref"
+		   type="javaee:resource-env-refType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="message-destination-ref"
+		   type="javaee:message-destination-refType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="persistence-context-ref"
+		   type="javaee:persistence-context-refType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="persistence-unit-ref"
+		   type="javaee:persistence-unit-refType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="post-construct"
+		   type="javaee:lifecycle-callbackType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:element name="pre-destroy"
+		   type="javaee:lifecycle-callbackType"
+		   minOccurs="0" maxOccurs="unbounded"/>
+    </xsd:sequence>
+  </xsd:group>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="lifecycle-callbackType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The lifecycle-callback type specifies a method on a
+	class to be called when a lifecycle event occurs.
+	Note that each class may have only one lifecycle callback
+        method for any given event and that the method may not
+	be overloaded.
+
+        If the lifefycle-callback-class element is missing then
+        the class defining the callback is assumed to be the
+        component class in scope at the place in the descriptor
+        in which the callback definition appears.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="lifecycle-callback-class"
+		   type="javaee:fully-qualified-classType"
+                   minOccurs="0"/>
+      <xsd:element name="lifecycle-callback-method"
+		   type="javaee:java-identifierType"/>
+    </xsd:sequence>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="listenerType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The listenerType indicates the deployment properties for a web
+	application listener bean.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:group ref="javaee:descriptionGroup"/>
+      <xsd:element name="listener-class"
+		   type="javaee:fully-qualified-classType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The listener-class element declares a class in the
+	    application must be registered as a web
+	    application listener bean. The value is the fully
+	    qualified classname of the listener class.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="local-homeType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The local-homeType defines the fully-qualified
+	name of an enterprise bean's local home interface.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:fully-qualified-classType"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="localType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The localType defines the fully-qualified name of an
+	enterprise bean's local interface.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:fully-qualified-classType"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="message-destination-linkType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The message-destination-linkType is used to link a message
+	destination reference or message-driven bean to a message
+	destination.
+
+	The Assembler sets the value to reflect the flow of messages
+	between producers and consumers in the application.
+
+	The value must be the message-destination-name of a message
+	destination in the same Deployment File or in another
+	Deployment File in the same Java EE application unit.
+
+	Alternatively, the value may be composed of a path name
+	specifying a Deployment File containing the referenced
+	message destination with the message-destination-name of the
+	destination appended and separated from the path name by
+	"#". The path name is relative to the Deployment File
+	containing Deployment Component that is referencing the
+	message destination.  This allows multiple message
+	destinations with the same name to be uniquely identified.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="message-destination-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The message-destination-ref element contains a declaration
+	  of Deployment Component's reference to a message destination
+	  associated with a resource in Deployment Component's
+	  environment. It consists of:
+
+		  - an optional description
+		  - the message destination reference name
+		  - an optional message destination type
+		  - an optional specification as to whether
+		    the destination is used for
+		    consuming or producing messages, or both.
+		    if not specified, "both" is assumed.
+		  - an optional link to the message destination
+		  - optional injection targets
+
+	  The message destination type must be supplied unless an
+	  injection target is specified, in which case the type
+	  of the target is used.  If both are specified, the type
+	  must be assignment compatible with the type of the injection
+	  target.
+
+	  Examples:
+
+	  <message-destination-ref>
+		  <message-destination-ref-name>jms/StockQueue
+		  </message-destination-ref-name>
+		  <message-destination-type>javax.jms.Queue
+		  </message-destination-type>
+		  <message-destination-usage>Consumes
+		  </message-destination-usage>
+		  <message-destination-link>CorporateStocks
+		  </message-destination-link>
+	  </message-destination-ref>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="message-destination-ref-name"
+		   type="javaee:jndi-nameType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The message-destination-ref-name element specifies
+	    the name of a message destination reference; its
+	    value is the environment entry name used in
+	    Deployment Component code.  The name is a JNDI name
+	    relative to the java:comp/env context and must be
+	    unique within an ejb-jar (for enterprise beans) or a
+	    Deployment File (for others).
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+      <xsd:element name="message-destination-type"
+		   type="javaee:message-destination-typeType"
+		   minOccurs="0"/>
+      <xsd:element name="message-destination-usage"
+		   type="javaee:message-destination-usageType"
+		   minOccurs="0"/>
+      <xsd:element name="message-destination-link"
+		   type="javaee:message-destination-linkType"
+		   minOccurs="0"/>
+
+      <xsd:group ref="javaee:resourceGroup"/>
+
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="message-destination-typeType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The message-destination-typeType specifies the type of
+	  the destination. The type is specified by the Java interface
+	  expected to be implemented by the destination.
+
+	  Example:
+
+	    <message-destination-type>javax.jms.Queue
+	    </message-destination-type>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:fully-qualified-classType"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="message-destination-usageType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The message-destination-usageType specifies the use of the
+	message destination indicated by the reference.  The value
+	indicates whether messages are consumed from the message
+	destination, produced for the destination, or both.  The
+	Assembler makes use of this information in linking producers
+	of a destination with its consumers.
+
+	The value of the message-destination-usage element must be
+	one of the following:
+	    Consumes
+	    Produces
+	    ConsumesProduces
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:enumeration value="Consumes"/>
+	<xsd:enumeration value="Produces"/>
+	<xsd:enumeration value="ConsumesProduces"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="message-destinationType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The message-destinationType specifies a message
+	  destination. The logical destination described by this
+	  element is mapped to a physical destination by the Deployer.
+
+	  The message destination element contains:
+
+		  - an optional description
+		  - an optional display-name
+		  - an optional icon
+		  - a message destination name which must be unique
+		    among message destination names within the same
+		    Deployment File.
+		  - an optional mapped name
+
+	  Example:
+
+	  <message-destination>
+		  <message-destination-name>CorporateStocks
+		  </message-destination-name>
+	  </message-destination>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:group ref="javaee:descriptionGroup"/>
+      <xsd:element name="message-destination-name"
+		   type="javaee:string">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The message-destination-name element specifies a
+	    name for a message destination.  This name must be
+	    unique among the names of message destinations
+	    within the Deployment File.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+      <xsd:element name="mapped-name"
+		   type="javaee:xsdStringType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+	    <![CDATA[
+
+	      A product specific name that this message destination
+	      should be mapped to.  Each message-destination-ref
+	      element that references this message destination will
+	      define a name in the namespace of the referencing
+	      component.  (It's a name in the JNDI java:comp/env
+	      namespace.)  Many application servers provide a way to
+	      map these local names to names of resources known to the
+	      application server.  This mapped name is often a global
+	      JNDI name, but may be a name of any form.  Each of the
+	      local names should be mapped to this same global name.
+
+	      Application servers are not required to support any
+	      particular form or type of mapped name, nor the ability
+	      to use mapped names.  The mapped name is
+	      product-dependent and often installation-dependent.  No
+	      use of a mapped name is portable.
+
+	      ]]>
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="param-valueType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type is a general type that can be used to declare
+	parameter/value lists.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="param-name"
+		   type="javaee:string">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The param-name element contains the name of a
+	    parameter.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="param-value"
+		   type="javaee:xsdStringType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The param-value element contains the value of a
+	    parameter.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="pathType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The elements that use this type designate either a relative
+	path or an absolute path starting with a "/".
+
+	In elements that specify a pathname to a file within the
+	same Deployment File, relative filenames (i.e., those not
+	starting with "/") are considered relative to the root of
+	the Deployment File's namespace.  Absolute filenames (i.e.,
+	those starting with "/") also specify names in the root of
+	the Deployment File's namespace.  In general, relative names
+	are preferred.  The exception is .war files where absolute
+	names are preferred for consistency with the Servlet API.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="persistence-context-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The persistence-context-ref element contains a declaration
+	  of Deployment Component's reference to a persistence context
+	  associated within a Deployment Component's
+	  environment. It consists of:
+
+		  - an optional description
+		  - the persistence context reference name
+		  - an optional persistence unit name.  If not specified,
+                    the default persistence unit is assumed.
+		  - an optional specification as to whether
+		    the persistence context type is Transaction or
+		    Extended.  If not specified, Transaction is assumed.
+                  - an optional list of persistence properties
+		  - optional injection targets
+
+	  Examples:
+
+            <persistence-context-ref>
+              <persistence-context-ref-name>myPersistenceContext
+              </persistence-context-ref-name>
+            </persistence-context-ref>
+
+            <persistence-context-ref>
+              <persistence-context-ref-name>myPersistenceContext
+                </persistence-context-ref-name>
+              <persistence-unit-name>PersistenceUnit1
+                </persistence-unit-name>
+              <persistence-context-type>Extended</persistence-context-type>
+            </persistence-context-ref>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="persistence-context-ref-name"
+		   type="javaee:jndi-nameType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The persistence-context-ref-name element specifies
+	    the name of a persistence context reference; its
+	    value is the environment entry name used in
+	    Deployment Component code.  The name is a JNDI name
+	    relative to the java:comp/env context.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+      <xsd:element name="persistence-unit-name"
+		   type="javaee:string"
+		   minOccurs="0">
+        <xsd:annotation>
+	  <xsd:documentation>
+
+            The Application Assembler(or BeanProvider) may use the
+            following syntax to avoid the need to rename persistence
+            units to have unique names within a Java EE application.
+
+            The Application Assembler specifies the pathname of the
+            root of the persistence.xml file for the referenced
+            persistence unit and appends the name of the persistence
+            unit separated from the pathname by #. The pathname is
+            relative to the referencing application component jar file.
+            In this manner, multiple persistence units with the same
+            persistence unit name may be uniquely identified when the
+            Application Assembler cannot change persistence unit names.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="persistence-context-type"
+		   type="javaee:persistence-context-typeType"
+		   minOccurs="0"/>
+
+      <xsd:element name="persistence-property"
+		   type="javaee:propertyType"
+		   minOccurs="0"
+		   maxOccurs="unbounded">
+        <xsd:annotation>
+	  <xsd:documentation>
+
+            Used to specify properties for the container or persistence
+            provider.  Vendor-specific properties may be included in
+            the set of properties.  Properties that are not recognized
+            by a vendor must be ignored.  Entries that make use of the
+            namespace javax.persistence and its subnamespaces must not
+            be used for vendor-specific properties.  The namespace
+            javax.persistence is reserved for use by the specification.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:group ref="javaee:resourceGroup"/>
+
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="persistence-context-typeType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The persistence-context-typeType specifies the transactional
+	nature of a persistence context reference.
+
+	The value of the persistence-context-type element must be
+	one of the following:
+	    Transaction
+            Extended
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:enumeration value="Transaction"/>
+	<xsd:enumeration value="Extended"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="persistence-unit-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The persistence-unit-ref element contains a declaration
+	  of Deployment Component's reference to a persistence unit
+	  associated within a Deployment Component's
+	  environment. It consists of:
+
+		  - an optional description
+		  - the persistence unit reference name
+		  - an optional persistence unit name.  If not specified,
+                    the default persistence unit is assumed.
+		  - optional injection targets
+
+	  Examples:
+
+            <persistence-unit-ref>
+              <persistence-unit-ref-name>myPersistenceUnit
+              </persistence-unit-ref-name>
+            </persistence-unit-ref>
+
+            <persistence-unit-ref>
+              <persistence-unit-ref-name>myPersistenceUnit
+                </persistence-unit-ref-name>
+              <persistence-unit-name>PersistenceUnit1
+                </persistence-unit-name>
+            </persistence-unit-ref>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="persistence-unit-ref-name"
+		   type="javaee:jndi-nameType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The persistence-unit-ref-name element specifies
+	    the name of a persistence unit reference; its
+	    value is the environment entry name used in
+	    Deployment Component code.  The name is a JNDI name
+	    relative to the java:comp/env context.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+      <xsd:element name="persistence-unit-name"
+		   type="javaee:string"
+		   minOccurs="0">
+        <xsd:annotation>
+	  <xsd:documentation>
+
+            The Application Assembler(or BeanProvider) may use the
+            following syntax to avoid the need to rename persistence
+            units to have unique names within a Java EE application.
+
+            The Application Assembler specifies the pathname of the
+            root of the persistence.xml file for the referenced
+            persistence unit and appends the name of the persistence
+            unit separated from the pathname by #. The pathname is
+            relative to the referencing application component jar file.
+            In this manner, multiple persistence units with the same
+            persistence unit name may be uniquely identified when the
+            Application Assembler cannot change persistence unit names.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:group ref="javaee:resourceGroup"/>
+
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="propertyType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	Specifies a name/value pair.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="name"
+		   type="javaee:xsdStringType">
+      </xsd:element>
+      <xsd:element name="value"
+		   type="javaee:xsdStringType">
+      </xsd:element>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="remoteType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The remote element contains the fully-qualified name
+	  of the enterprise bean's remote interface.
+
+	  Example:
+
+	      <remote>com.wombat.empl.EmployeeService</remote>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:fully-qualified-classType"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="res-authType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The res-authType specifies whether the Deployment Component
+	code signs on programmatically to the resource manager, or
+	whether the Container will sign on to the resource manager
+	on behalf of the Deployment Component. In the latter case,
+	the Container uses information that is supplied by the
+	Deployer.
+
+	The value must be one of the two following:
+
+	    Application
+	    Container
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:enumeration value="Application"/>
+	<xsd:enumeration value="Container"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="res-sharing-scopeType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The res-sharing-scope type specifies whether connections
+	obtained through the given resource manager connection
+	factory reference can be shared. The value, if specified,
+	must be one of the two following:
+
+	    Shareable
+	    Unshareable
+
+	The default value is Shareable.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string">
+	<xsd:enumeration value="Shareable"/>
+	<xsd:enumeration value="Unshareable"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="resource-env-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The resource-env-refType is used to define
+	  resource-env-type elements.  It contains a declaration of a
+	  Deployment Component's reference to an administered object
+	  associated with a resource in the Deployment Component's
+	  environment.  It consists of an optional description, the
+	  resource environment reference name, and an optional
+	  indication of the resource environment reference type
+	  expected by the Deployment Component code.
+
+	  It also includes optional elements to define injection of
+	  the named resource into fields or JavaBeans properties.
+
+	  The resource environment type must be supplied unless an
+	  injection target is specified, in which case the type
+	  of the target is used.  If both are specified, the type
+	  must be assignment compatible with the type of the injection
+	  target.
+
+	  Example:
+
+	  <resource-env-ref>
+	      <resource-env-ref-name>jms/StockQueue
+	      </resource-env-ref-name>
+	      <resource-env-ref-type>javax.jms.Queue
+	      </resource-env-ref-type>
+	  </resource-env-ref>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="resource-env-ref-name"
+		   type="javaee:jndi-nameType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The resource-env-ref-name element specifies the name
+	    of a resource environment reference; its value is
+	    the environment entry name used in
+	    the Deployment Component code.  The name is a JNDI
+	    name relative to the java:comp/env context and must
+	    be unique within a Deployment Component.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="resource-env-ref-type"
+		   type="javaee:fully-qualified-classType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The resource-env-ref-type element specifies the type
+	    of a resource environment reference.  It is the
+	    fully qualified name of a Java language class or
+	    interface.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:group ref="javaee:resourceGroup"/>
+
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="resource-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The resource-refType contains a declaration of a
+	  Deployment Component's reference to an external resource. It
+	  consists of an optional description, the resource manager
+	  connection factory reference name, an optional indication of
+	  the resource manager connection factory type expected by the
+	  Deployment Component code, an optional type of authentication
+	  (Application or Container), and an optional specification of
+	  the shareability of connections obtained from the resource
+	  (Shareable or Unshareable).
+
+	  It also includes optional elements to define injection of
+	  the named resource into fields or JavaBeans properties.
+
+	  The connection factory type must be supplied unless an
+	  injection target is specified, in which case the type
+	  of the target is used.  If both are specified, the type
+	  must be assignment compatible with the type of the injection
+	  target.
+
+	  Example:
+
+	  <resource-ref>
+	      <res-ref-name>jdbc/EmployeeAppDB</res-ref-name>
+	      <res-type>javax.sql.DataSource</res-type>
+	      <res-auth>Container</res-auth>
+	      <res-sharing-scope>Shareable</res-sharing-scope>
+	  </resource-ref>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="res-ref-name"
+		   type="javaee:jndi-nameType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The res-ref-name element specifies the name of a
+	    resource manager connection factory reference.
+	    The name is a JNDI name relative to the
+	    java:comp/env context.
+	    The name must be unique within a Deployment File.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="res-type"
+		   type="javaee:fully-qualified-classType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The res-type element specifies the type of the data
+	    source. The type is specified by the fully qualified
+	    Java language class or interface
+	    expected to be implemented by the data source.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="res-auth"
+		   type="javaee:res-authType"
+		   minOccurs="0"/>
+
+      <xsd:element name="res-sharing-scope"
+		   type="javaee:res-sharing-scopeType"
+		   minOccurs="0"/>
+
+      <xsd:group ref="javaee:resourceGroup"/>
+
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:group name="resourceGroup">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This group collects elements that are common to all the
+	JNDI resource elements.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:sequence>
+      <xsd:element name="mapped-name"
+		   type="javaee:xsdStringType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+	    <![CDATA[
+
+	      A product specific name that this resource should be
+	      mapped to.  The name of this resource, as defined by the
+	      resource's name element or defaulted, is a name that is
+	      local to the application component using the resource.
+	      (It's a name in the JNDI java:comp/env namespace.)  Many
+	      application servers provide a way to map these local
+	      names to names of resources known to the application
+	      server.  This mapped name is often a global JNDI name,
+	      but may be a name of any form.
+
+	      Application servers are not required to support any
+	      particular form or type of mapped name, nor the ability
+	      to use mapped names.  The mapped name is
+	      product-dependent and often installation-dependent.  No
+	      use of a mapped name is portable.
+
+	      ]]>
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="injection-target"
+		   type="javaee:injection-targetType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+    </xsd:sequence>
+  </xsd:group>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="role-nameType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The role-nameType designates the name of a security role.
+
+	The name must conform to the lexical rules for a token.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:string"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="run-asType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The run-asType specifies the run-as identity to be
+	used for the execution of a component. It contains an
+	optional description, and the name of a security role.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="role-name"
+		   type="javaee:role-nameType"/>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="security-role-refType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The security-role-refType contains the declaration of a
+	security role reference in a component's or a
+	Deployment Component's code. The declaration consists of an
+	optional description, the security role name used in the
+	code, and an optional link to a security role. If the
+	security role is not specified, the Deployer must choose an
+	appropriate security role.
+
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="role-name"
+		   type="javaee:role-nameType">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The value of the role-name element must be the String used
+	    as the parameter to the
+	    EJBContext.isCallerInRole(String roleName) method or the
+	    HttpServletRequest.isUserInRole(String role) method.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+
+      <xsd:element name="role-link"
+		   type="javaee:role-nameType"
+		   minOccurs="0">
+	<xsd:annotation>
+	  <xsd:documentation>
+
+	    The role-link element is a reference to a defined
+	    security role. The role-link element must contain
+	    the name of one of the security roles defined in the
+	    security-role elements.
+
+	  </xsd:documentation>
+	</xsd:annotation>
+      </xsd:element>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="security-roleType">
+    <xsd:annotation>
+      <xsd:documentation>
+	<![CDATA[
+
+	  The security-roleType contains the definition of a security
+	  role. The definition consists of an optional description of
+	  the security role, and the security role name.
+
+	  Example:
+
+	      <security-role>
+	      <description>
+		  This role includes all employees who are authorized
+		  to access the employee service application.
+	      </description>
+	      <role-name>employee</role-name>
+	      </security-role>
+
+	  ]]>
+      </xsd:documentation>
+    </xsd:annotation>
+
+    <xsd:sequence>
+      <xsd:element name="description"
+		   type="javaee:descriptionType"
+		   minOccurs="0"
+		   maxOccurs="unbounded"/>
+      <xsd:element name="role-name"
+		   type="javaee:role-nameType"/>
+    </xsd:sequence>
+    <xsd:attribute name="id" type="xsd:ID"/>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="string">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This is a special string datatype that is defined by Java EE as
+	a base type for defining collapsed strings. When schemas
+	require trailing/leading space elimination as well as
+	collapsing the existing whitespace, this base type may be
+	used.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:token">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="true-falseType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This simple type designates a boolean with only two
+	permissible values
+
+	- true
+	- false
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:restriction base="javaee:xsdBooleanType">
+	<xsd:pattern value="(true|false)"/>
+      </xsd:restriction>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="url-patternType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	The url-patternType contains the url pattern of the mapping.
+	It must follow the rules specified in Section 11.2 of the
+	Servlet API Specification. This pattern is assumed to be in
+	URL-decoded form and must not contain CR(#xD) or LF(#xA).
+	If it contains those characters, the container must inform
+	the developer with a descriptive error message.
+	The container must preserve all characters including whitespaces.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:string"/>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdAnyURIType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:anyURI.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:anyURI">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdBooleanType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:boolean.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:boolean">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdIntegerType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:integer.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:integer">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdNMTOKENType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:NMTOKEN.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:NMTOKEN">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdNonNegativeIntegerType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:nonNegativeInteger.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:nonNegativeInteger">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdPositiveIntegerType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:positiveInteger.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:positiveInteger">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdQNameType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:QName.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:QName">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+<!-- **************************************************** -->
+
+  <xsd:complexType name="xsdStringType">
+    <xsd:annotation>
+      <xsd:documentation>
+
+	This type adds an "id" attribute to xsd:string.
+
+      </xsd:documentation>
+    </xsd:annotation>
+    <xsd:simpleContent>
+      <xsd:extension base="xsd:string">
+	<xsd:attribute name="id" type="xsd:ID"/>
+      </xsd:extension>
+    </xsd:simpleContent>
+  </xsd:complexType>
+
+</xsd:schema>
+


Property changes on: trunk/src/main/resources/schema/javaee_5.xsd
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Copied: trunk/src/main/resources/schema/jaxrpc-config_2_0.xsd (from rev 661, trunk/src/main/resources/schema/jbossws-config_1_0.xsd)
===================================================================
--- trunk/src/main/resources/schema/jbossws-config_1_0.xsd	2006-08-01 16:32:34 UTC (rev 661)
+++ trunk/src/main/resources/schema/jaxrpc-config_2_0.xsd	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema" 
+	targetNamespace="urn:jboss:jaxrpc-config:2.0"
+	xmlns:tns="urn:jboss:jaxrpc-config:2.0" 
+	xmlns:jbxb="http://www.jboss.org/xml/ns/jbxb" 
+	xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
+	xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
+	elementFormDefault="qualified" attributeFormDefault="unqualified" version="1.1">
+	
+	<xsd:annotation>
+		<xsd:documentation>
+			<![CDATA[
+      This is the schema definition for JBossWS configurations JAXRPC.
+      It relies on the handler definitions that are part of the standard J2EE-1.4 deployment descriptors.
+      ]]>
+		</xsd:documentation>
+	</xsd:annotation>
+	
+	<xsd:import namespace="http://java.sun.com/xml/ns/j2ee" schemaLocation="j2ee_web_services_1_1.xsd"/>
+	
+	<xsd:complexType name="jaxrpcConfigType">
+		<xsd:annotation>
+			<xsd:appinfo>
+				<jbxb:class impl="org.jboss.ws.metadata.config.WSConfig"/>
+			</xsd:appinfo>
+		</xsd:annotation>
+		<xsd:choice>
+			<xsd:element name="endpoint-config" type="tns:endpointConfigType" minOccurs="0" maxOccurs="unbounded"/>
+			<xsd:element name="client-config" type="tns:clientConfigType" minOccurs="0" maxOccurs="unbounded"/>
+		</xsd:choice>
+	</xsd:complexType>
+	
+	<xsd:element name="jaxrpc-config" type="tns:jaxrpcConfigType"/>
+	
+	<xsd:complexType name="endpointConfigType">
+		<xsd:annotation>
+			<xsd:appinfo>
+				<jbxb:class impl="org.jboss.ws.metadata.config.WSEndpointConfig"/>
+			</xsd:appinfo>
+		</xsd:annotation>
+    <xsd:complexContent>
+      <xsd:extension base="tns:commonConfigType"/>
+    </xsd:complexContent>
+	</xsd:complexType>
+	
+	<xsd:complexType name="clientConfigType">
+		<xsd:annotation>
+			<xsd:appinfo>
+				<jbxb:class impl="org.jboss.ws.metadata.config.WSClientConfig"/>
+			</xsd:appinfo>
+		</xsd:annotation>
+    <xsd:complexContent>
+      <xsd:extension base="tns:commonConfigType"/>
+    </xsd:complexContent>
+	</xsd:complexType>
+	
+	<xsd:complexType name="commonConfigType">
+		<xsd:sequence>
+			<xsd:element name="config-name" type="xsd:string"/>
+			<xsd:element name="pre-handler-chain" type="tns:handlerChainType" minOccurs="0"/>
+			<xsd:element name="post-handler-chain" type="tns:handlerChainType" minOccurs="0"/>
+		</xsd:sequence>
+	</xsd:complexType>
+	
+	<xsd:complexType name="handlerChainType">
+		<xsd:annotation>
+			<xsd:appinfo>
+				<jbxb:class impl="org.jboss.ws.metadata.config.WSHandlerChainConfig"/>
+			</xsd:appinfo>
+		</xsd:annotation>
+		<xsd:sequence>
+			<xsd:element name="handler-chain-name" type="xsd:string"/>
+			<xsd:element name="handler" type="j2ee:port-component_handlerType" minOccurs="0" maxOccurs="unbounded"/>
+		</xsd:sequence>
+	</xsd:complexType>
+	
+</xsd:schema>
\ No newline at end of file

Added: trunk/src/main/resources/schema/jaxws-config_2_0.xsd
===================================================================
--- trunk/src/main/resources/schema/jaxws-config_2_0.xsd	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/schema/jaxws-config_2_0.xsd	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema" 
+	targetNamespace="urn:jboss:jaxws-config:2.0"
+	xmlns:tns="urn:jboss:jaxws-config:2.0" 
+	xmlns:jbxb="http://www.jboss.org/xml/ns/jbxb" 
+	xmlns:javaee="http://java.sun.com/xml/ns/javaee"
+	xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
+	elementFormDefault="qualified" attributeFormDefault="unqualified" version="1.1">
+	
+	<xsd:annotation>
+		<xsd:documentation>
+			<![CDATA[
+      This is the schema definition for JBossWS configurations JAXWS.
+      It relies on the handler definitions that are part of the standard J2EE-1.5 deployment descriptors.
+      ]]>
+		</xsd:documentation>
+	</xsd:annotation>
+	
+	<xsd:import namespace="http://java.sun.com/xml/ns/javaee" schemaLocation="handler-chain.xsd"/>
+	
+	<xsd:complexType name="jaxwsConfigType">
+		<xsd:annotation>
+			<xsd:appinfo>
+				<jbxb:class impl="org.jboss.ws.metadata.config.WSConfig"/>
+			</xsd:appinfo>
+		</xsd:annotation>
+		<xsd:choice>
+			<xsd:element name="endpoint-config" type="tns:endpointConfigType" minOccurs="0" maxOccurs="unbounded"/>
+			<xsd:element name="client-config" type="tns:clientConfigType" minOccurs="0" maxOccurs="unbounded"/>
+		</xsd:choice>
+	</xsd:complexType>
+	
+	<xsd:element name="jaxws-config" type="tns:jaxwsConfigType"/>
+	
+	<xsd:complexType name="endpointConfigType">
+		<xsd:annotation>
+			<xsd:appinfo>
+				<jbxb:class impl="org.jboss.ws.metadata.config.WSEndpointConfig"/>
+			</xsd:appinfo>
+		</xsd:annotation>
+    <xsd:complexContent>
+      <xsd:extension base="tns:commonConfigType"/>
+    </xsd:complexContent>
+	</xsd:complexType>
+	
+	<xsd:complexType name="clientConfigType">
+		<xsd:annotation>
+			<xsd:appinfo>
+				<jbxb:class impl="org.jboss.ws.metadata.config.WSClientConfig"/>
+			</xsd:appinfo>
+		</xsd:annotation>
+    <xsd:complexContent>
+      <xsd:extension base="tns:commonConfigType"/>
+    </xsd:complexContent>
+	</xsd:complexType>
+	
+	<xsd:complexType name="commonConfigType">
+		<xsd:sequence>
+			<xsd:element name="config-name" type="xsd:string"/>
+			<xsd:element name="pre-handler-chains" type="javaee:handler-chainsType" minOccurs="0"/>
+			<xsd:element name="post-handler-chains" type="javaee:handler-chainsType" minOccurs="0"/>
+		</xsd:sequence>
+	</xsd:complexType>
+	
+</xsd:schema>
\ No newline at end of file


Property changes on: trunk/src/main/resources/schema/jaxws-config_2_0.xsd
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Deleted: trunk/src/main/resources/schema/jbossws-config_1_0.xsd
===================================================================
--- trunk/src/main/resources/schema/jbossws-config_1_0.xsd	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/main/resources/schema/jbossws-config_1_0.xsd	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,78 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<xsd:schema xmlns="http://www.w3.org/2001/XMLSchema" 
-	targetNamespace="urn:jboss:jbossws-config:5.0"
-	xmlns:tns="urn:jboss:jbossws-config:5.0" 
-	xmlns:jbxb="http://www.jboss.org/xml/ns/jbxb" 
-	xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
-	xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
-	elementFormDefault="qualified" attributeFormDefault="unqualified" version="1.1">
-	
-	<xsd:annotation>
-		<xsd:documentation>
-			<![CDATA[
-      This is the schema definition for the jboss webservice configurations.
-      It relies on the handler definitions that are part of the standard J2EE deployment descriptors.
-      ]]>
-		</xsd:documentation>
-	</xsd:annotation>
-	
-	<xsd:import namespace="http://java.sun.com/xml/ns/j2ee" schemaLocation="j2ee_web_services_1_1.xsd"/>
-	
-	<xsd:complexType name="jbosswsConfigType">
-		<xsd:annotation>
-			<xsd:appinfo>
-				<jbxb:class impl="org.jboss.ws.metadata.config.WSConfig"/>
-			</xsd:appinfo>
-		</xsd:annotation>
-		<xsd:choice>
-			<xsd:element name="endpoint-config" type="tns:endpointConfigType" minOccurs="0" maxOccurs="unbounded"/>
-			<xsd:element name="client-config" type="tns:clientConfigType" minOccurs="0" maxOccurs="unbounded"/>
-		</xsd:choice>
-	</xsd:complexType>
-	
-	<xsd:element name="jbossws-config" type="tns:jbosswsConfigType"/>
-	
-	<xsd:complexType name="endpointConfigType">
-		<xsd:annotation>
-			<xsd:appinfo>
-				<jbxb:class impl="org.jboss.ws.metadata.config.WSEndpointConfig"/>
-			</xsd:appinfo>
-		</xsd:annotation>
-    <xsd:complexContent>
-      <xsd:extension base="tns:commonConfigType"/>
-    </xsd:complexContent>
-	</xsd:complexType>
-	
-	<xsd:complexType name="clientConfigType">
-		<xsd:annotation>
-			<xsd:appinfo>
-				<jbxb:class impl="org.jboss.ws.metadata.config.WSClientConfig"/>
-			</xsd:appinfo>
-		</xsd:annotation>
-    <xsd:complexContent>
-      <xsd:extension base="tns:commonConfigType"/>
-    </xsd:complexContent>
-	</xsd:complexType>
-	
-	<xsd:complexType name="commonConfigType">
-		<xsd:sequence>
-			<xsd:element name="config-name" type="xsd:string"/>
-			<xsd:element name="pre-handler-chain" type="tns:handlerChainType" minOccurs="0"/>
-			<xsd:element name="post-handler-chain" type="tns:handlerChainType" minOccurs="0"/>
-		</xsd:sequence>
-	</xsd:complexType>
-	
-	<xsd:complexType name="handlerChainType">
-		<xsd:annotation>
-			<xsd:appinfo>
-				<jbxb:class impl="org.jboss.ws.metadata.config.WSHandlerChainConfig"/>
-			</xsd:appinfo>
-		</xsd:annotation>
-		<xsd:sequence>
-			<xsd:element name="handler-chain-name" type="xsd:string"/>
-			<xsd:element name="handler" type="j2ee:port-component_handlerType" minOccurs="0" maxOccurs="unbounded"/>
-		</xsd:sequence>
-	</xsd:complexType>
-	
-</xsd:schema>
\ No newline at end of file

Modified: trunk/src/test/ant/build-jars.xml
===================================================================
--- trunk/src/test/ant/build-jars.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/ant/build-jars.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -28,6 +28,7 @@
       </classes>
       <webinf dir="${build.test.dir}/resources/addressing/action/Doc-META-INF">
         <include name="wsdl/**"/>
+        <include name="jaxws-handlers.xml"/>
       </webinf>
     </war>
     <jar destfile="${build.test.dir}/libs/jbossws-addressing-action-doc-client.jar">
@@ -39,7 +40,7 @@
       <metainf dir="${build.test.dir}/resources/addressing/action/Doc-META-INF">
         <include name="application-client.xml"/>
         <include name="jboss-client.xml"/>
-        <include name="jbossws-client-config.xml"/>
+        <include name="jaxrpc-client-config.xml"/>
         <include name="jaxrpc-mapping.xml"/>
         <include name="wsdl/**"/>
       </metainf>
@@ -51,6 +52,7 @@
       </classes>
       <webinf dir="${build.test.dir}/resources/addressing/action/Rpc-META-INF">
         <include name="wsdl/**"/>
+        <include name="jaxws-handlers.xml"/>
       </webinf>
     </war>
     <jar destfile="${build.test.dir}/libs/jbossws-addressing-action-rpc-client.jar">
@@ -60,7 +62,7 @@
       <metainf dir="${build.test.dir}/resources/addressing/action/Rpc-META-INF">
         <include name="application-client.xml"/>
         <include name="jboss-client.xml"/>
-        <include name="jbossws-client-config.xml"/>
+        <include name="jaxrpc-client-config.xml"/>
         <include name="jaxrpc-mapping.xml"/>
         <include name="wsdl/**"/>
       </metainf>
@@ -74,6 +76,9 @@
         <include name="org/jboss/test/ws/addressing/replyto/InitialEndpoint_*_RequestStruct.class"/>
         <include name="org/jboss/test/ws/addressing/replyto/InitialEndpoint_*_ResponseStruct.class"/>
       </classes>
+      <webinf dir="${build.test.dir}/resources/addressing/replyto/Initial-WEB-INF">
+        <include name="jaxws-handlers.xml"/>
+      </webinf>
     </war>
     <war warfile="${build.test.dir}/libs/jbossws-addressing-replyto.war" webxml="${build.test.dir}/resources/addressing/replyto/ReplyTo-WEB-INF/web.xml">
       <classes dir="${build.test.dir}/classes">
@@ -726,15 +731,23 @@
       </webinf>
     </war>
     
+    <!-- jbossws-jsr181-complex -->
+    <war warfile="${build.test.dir}/libs/jbossws-jsr181-complex.war" webxml="${build.test.dir}/resources/jsr181/complex/WEB-INF/web.xml">
+      <classes dir="${build.test.dir}/classes">
+        <include name="org/jboss/test/ws/jsr181/complex/*.class"/>
+        <include name="org/jboss/test/ws/jsr181/complex/extra/*.class"/>
+      </classes>
+    </war>
+    
     <!-- jbossws-jsr181-handlerchain -->
     <war warfile="${build.test.dir}/libs/jbossws-jsr181-handlerchain.war" webxml="${build.test.dir}/resources/jsr181/handlerchain/WEB-INF/web.xml">
       <classes dir="${build.test.dir}/classes">
         <include name="org/jboss/test/ws/jsr181/handlerchain/MyWebService.class"/>
         <include name="org/jboss/test/ws/jsr181/handlerchain/*Handler.class"/>
       </classes>
-      <fileset dir="${build.test.dir}/resources/jsr181/handlerchain">
-        <include name="config/ProjectHandlers.xml"/>
-      </fileset>
+      <webinf dir="${build.test.dir}/resources/jsr181/handlerchain/WEB-INF">
+        <include name="jaxws-handlers.xml"/>
+      </webinf>
     </war>
     
     <!-- jbossws-jsr181-oneway -->
@@ -757,22 +770,6 @@
       </classes>
     </war>
     
-    <!-- jbossws-jsr181-complex -->
-    <war warfile="${build.test.dir}/libs/jbossws-jsr181-complex.war" webxml="${build.test.dir}/resources/jsr181/complex/WEB-INF/web.xml">
-      <classes dir="${build.test.dir}/classes">
-        <include name="org/jboss/test/ws/jsr181/complex/*.class"/>
-        <include name="org/jboss/test/ws/jsr181/complex/extra/*.class"/>
-      </classes>
-    </war>
-    
-    <!-- jbossws-jsr181-soapmessagehandlers -->
-    <war warfile="${build.test.dir}/libs/jbossws-jsr181-soapmessagehandlers.war" webxml="${build.test.dir}/resources/jsr181/soapmessagehandlers/WEB-INF/web.xml">
-      <classes dir="${build.test.dir}/classes">
-        <include name="org/jboss/test/ws/jsr181/soapmessagehandlers/MyWebService.class"/>
-        <include name="org/jboss/test/ws/jsr181/handlerchain/*Handler.class"/>
-      </classes>
-    </war>
-    
     <!-- jbossws-jsr181-webmethod -->
     <war warfile="${build.test.dir}/libs/jbossws-jsr181-webmethod.war" webxml="${build.test.dir}/resources/jsr181/webmethod/WEB-INF/web.xml">
       <classes dir="${build.test.dir}/classes">
@@ -1330,11 +1327,9 @@
         <include name="org/jboss/test/ws/samples/jsr181ejb/EJB3Bean01.class"/>
         <include name="org/jboss/test/ws/samples/jsr181ejb/EJB3RemoteInterface.class"/>
       </fileset>
-       <fileset dir="${build.test.dir}/resources/samples/jsr181ejb">
-          <include name="config/ServerHandlers.xml"/>
-       </fileset>
-       <metainf dir="${build.test.dir}/resources/samples/jsr181ejb/META-INF">
+      <metainf dir="${build.test.dir}/resources/samples/jsr181ejb/META-INF">
         <include name="jboss-wsse-server.xml"/>
+        <include name="jaxws-handlers.xml"/>
         <include name="wsse.*"/>
       </metainf>
     </jar>
@@ -1554,6 +1549,9 @@
         <include name="org/jboss/test/ws/samples/wsaddressing/StatefulEndpoint.class"/>
         <include name="org/jboss/test/ws/samples/wsaddressing/ServerHandler.class"/>
       </classes>
+      <webinf dir="${build.test.dir}/resources/samples/wsaddressing/WEB-INF">
+        <include name="jaxws-handlers.xml"/>
+      </webinf>
     </war>
     <jar destfile="${build.test.dir}/libs/jbossws-samples-wsaddressing-client.jar">
       <fileset dir="${build.test.dir}/classes">

Modified: trunk/src/test/java/org/jboss/test/ws/JBossWSTestDeployer.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/JBossWSTestDeployer.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/JBossWSTestDeployer.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,41 +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.test.ws;
-
-import java.net.URL;
-
-/**
- * WS test deployer 
- *
- * @author Thomas.Diesler at jboss.org
- * @since 16-May-2006
- */
-public interface JBossWSTestDeployer
-{
-   /** Deploy the given archive
-    */
-   void deploy(URL archive) throws Exception;
-
-   /** Undeploy the given archive
-    */
-   void undeploy(URL archive) throws Exception;
+/*
+ * 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.test.ws;
+
+import java.net.URL;
+
+/**
+ * WS test deployer 
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @since 16-May-2006
+ */
+public interface JBossWSTestDeployer
+{
+   /** Deploy the given archive
+    */
+   void deploy(URL archive) throws Exception;
+
+   /** Undeploy the given archive
+    */
+   void undeploy(URL archive) throws Exception;
 }
\ No newline at end of file

Modified: trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionDocEndpointImpl.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionDocEndpointImpl.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionDocEndpointImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -23,11 +23,10 @@
 
 //$Id$
 
+import javax.jws.HandlerChain;
 import javax.jws.WebMethod;
 import javax.jws.WebService;
 import javax.jws.soap.SOAPBinding;
-import javax.jws.soap.SOAPMessageHandler;
-import javax.jws.soap.SOAPMessageHandlers;
 import javax.xml.ws.RequestWrapper;
 import javax.xml.ws.ResponseWrapper;
 
@@ -42,7 +41,7 @@
  */
 @SOAPBinding(style = SOAPBinding.Style.DOCUMENT)
 @WebService(name = "ActionEndpoint", targetNamespace = "http://org.jboss.ws/addressing/action", wsdlLocation = "WEB-INF/wsdl/ActionDocService.wsdl")
- at SOAPMessageHandlers( { @SOAPMessageHandler(className = "org.jboss.ws.addressing.soap.SOAPServerHandler") })
+ at HandlerChain(file = "resource://WEB-INF/jaxws-handlers.xml")
 public class ActionDocEndpointImpl implements ActionEndpoint
 {
    // provide logging

Modified: trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionRpcEndpointImpl.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionRpcEndpointImpl.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/addressing/action/ActionRpcEndpointImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -23,11 +23,10 @@
 
 //$Id$
 
+import javax.jws.HandlerChain;
 import javax.jws.WebMethod;
 import javax.jws.WebService;
 import javax.jws.soap.SOAPBinding;
-import javax.jws.soap.SOAPMessageHandler;
-import javax.jws.soap.SOAPMessageHandlers;
 
 import org.jboss.logging.Logger;
 
@@ -40,7 +39,7 @@
  */
 @SOAPBinding(style = SOAPBinding.Style.RPC)
 @WebService(name = "ActionEndpoint", targetNamespace = "http://org.jboss.ws/addressing/action", wsdlLocation = "WEB-INF/wsdl/ActionRpcService.wsdl")
- at SOAPMessageHandlers( { @SOAPMessageHandler(className = "org.jboss.ws.addressing.soap.SOAPServerHandler") })
+ at HandlerChain(file = "resource://WEB-INF/jaxws-handlers.xml")
 public class ActionRpcEndpointImpl implements ActionEndpoint
 {
    // provide logging

Modified: trunk/src/test/java/org/jboss/test/ws/addressing/replyto/AddressingReplyToTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/addressing/replyto/AddressingReplyToTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/addressing/replyto/AddressingReplyToTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -28,7 +28,6 @@
 import java.util.List;
 
 import javax.xml.namespace.QName;
-import javax.xml.rpc.Service;
 import javax.xml.rpc.ServiceFactory;
 import javax.xml.rpc.handler.HandlerInfo;
 import javax.xml.rpc.handler.HandlerRegistry;
@@ -41,9 +40,8 @@
 
 import org.jboss.test.ws.JBossWSTest;
 import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.addressing.soap.SOAPClientHandler;
+import org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler;
 import org.jboss.ws.jaxrpc.ServiceImpl;
-import org.jboss.ws.wsse.WSSecurityHandlerOutbound;
 
 /**
  * Test endpoint using ws-addressing
@@ -81,7 +79,7 @@
          QName portName = new QName(nsURI, "InitialEndpointPort");
          List infos = registry.getHandlerChain(portName);
          infos.add(new HandlerInfo(ClientHandler.class, new HashMap(), new QName[]{}));
-         infos.add(new HandlerInfo(SOAPClientHandler.class, new HashMap(), new QName[]{}));
+         infos.add(new HandlerInfo(WSAddressingClientHandler.class, new HashMap(), new QName[]{}));
          registry.setHandlerChain(portName, infos);
 
          URL replyToURL = new File("resources/addressing/replyto/ReplyTo-META-INF/wsdl/ReplyToService.wsdl").toURL();
@@ -92,7 +90,7 @@
          portName = new QName(nsURI, "ReplyToEndpointPort");
          infos = registry.getHandlerChain(portName);
          infos.add(new HandlerInfo(ClientHandler.class, new HashMap(), new QName[]{}));
-         infos.add(new HandlerInfo(SOAPClientHandler.class, new HashMap(), new QName[]{}));
+         infos.add(new HandlerInfo(WSAddressingClientHandler.class, new HashMap(), new QName[]{}));
          registry.setHandlerChain(portName, infos);
 
          URL faultToURL = new File("resources/addressing/replyto/FaultTo-META-INF/wsdl/FaultToService.wsdl").toURL();
@@ -103,7 +101,7 @@
          portName = new QName(nsURI, "FaultToEndpointPort");
          infos = registry.getHandlerChain(portName);
          infos.add(new HandlerInfo(ClientHandler.class, new HashMap(), new QName[]{}));
-         infos.add(new HandlerInfo(SOAPClientHandler.class, new HashMap(), new QName[]{}));
+         infos.add(new HandlerInfo(WSAddressingClientHandler.class, new HashMap(), new QName[]{}));
          registry.setHandlerChain(portName, infos);
       }
    }

Modified: trunk/src/test/java/org/jboss/test/ws/addressing/replyto/InitialEndpointImpl.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/addressing/replyto/InitialEndpointImpl.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/addressing/replyto/InitialEndpointImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -23,11 +23,10 @@
 
 //$Id$
 
+import javax.jws.HandlerChain;
 import javax.jws.WebMethod;
 import javax.jws.WebService;
 import javax.jws.soap.SOAPBinding;
-import javax.jws.soap.SOAPMessageHandler;
-import javax.jws.soap.SOAPMessageHandlers;
 import javax.jws.soap.SOAPBinding.Style;
 
 import org.jboss.logging.Logger;
@@ -40,7 +39,7 @@
  */
 @SOAPBinding(style = Style.RPC)
 @WebService(name = "InitialEndpoint", targetNamespace = "http://org.jboss.ws/addressing/replyto")
- at SOAPMessageHandlers( { @SOAPMessageHandler(className = "org.jboss.ws.addressing.soap.SOAPServerHandler") })
+ at HandlerChain(file = "resource://WEB-INF/jaxws-handlers.xml")
 public class InitialEndpointImpl implements InitialEndpoint
 {
    // provide logging

Modified: trunk/src/test/java/org/jboss/test/ws/config/WSConfigTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/config/WSConfigTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/config/WSConfigTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -22,14 +22,15 @@
 package org.jboss.test.ws.config;
 
 import java.io.File;
-import java.io.InputStream;
-import java.net.URL;
 
 import org.jboss.test.ws.JBossWSTest;
-import org.jboss.ws.metadata.config.WSConfig;
 import org.jboss.ws.metadata.config.WSConfigFactory;
-import org.jboss.ws.metadata.config.WSEndpointConfig;
-import org.jboss.ws.metadata.config.WSHandlerChainConfig;
+import org.jboss.ws.metadata.config.jaxrpc.WSConfigRootJAXRPC;
+import org.jboss.ws.metadata.config.jaxrpc.WSEndpointConfigJAXRPC;
+import org.jboss.ws.metadata.config.jaxrpc.WSHandlerChainConfigJAXRPC;
+import org.jboss.ws.metadata.config.jaxws.WSConfigRootJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSEndpointConfigJAXWS;
+import org.jboss.ws.metadata.config.jaxws.WSHandlerChainConfigJAXWS;
 import org.jboss.ws.metadata.j2ee.UnifiedHandlerMetaData;
 
 /**
@@ -40,54 +41,67 @@
  */
 public class WSConfigTestCase extends JBossWSTest
 {
-   public void testJ2EEWebServicesSchemaBinding() throws Exception
-   {
-      ClassLoader ctxLoader = Thread.currentThread().getContextClassLoader();
-      URL xsdURL = ctxLoader.getResource("schema/j2ee_web_services_1_1.xsd");
-
-      InputStream xsd = xsdURL.openStream();
-      //XsdBinder.bind(xsd, "UTF-8");
-   }
-
    public void testParseWithSchemaBinding() throws Exception
    {
-      File confFile = new File("resources/config/jbossws-endpoint-config.xml");
+      File confFile = new File("resources/config/jaxrpc-endpoint-config.xml");
       assertTrue(confFile.exists());
 
       WSConfigFactory factory = WSConfigFactory.newInstance();
       //WSConfig wsConfig = factory.parseWithSchemaBinding(confFile.toURL());
-      //assertConfig(wsConfig);
+      //assertJAXRPCConfig(wsConfig);
    }
 
-   public void testParseWithObjectModelFactory() throws Exception
+   public void testJAXRPCObjectModelFactory() throws Exception
    {
-      File confFile = new File("resources/config/jbossws-endpoint-config.xml");
+      File confFile = new File("resources/config/jaxrpc-endpoint-config.xml");
       assertTrue(confFile.exists());
 
       WSConfigFactory factory = WSConfigFactory.newInstance();
-      WSConfig wsConfig = factory.parseWithObjectModelFactory(confFile.toURL());
-      assertConfig(wsConfig);
-   }
+      WSConfigRootJAXRPC wsConfig = (WSConfigRootJAXRPC)factory.parseWithObjectModelFactory(confFile.toURL());
 
-   private void assertConfig(WSConfig wsConfig)
-   {
       assertNotNull("Null wsConfig", wsConfig);
 
       assertEquals(2, wsConfig.getEndpointConfig().size());
-      WSEndpointConfig epc1 = (WSEndpointConfig)wsConfig.getEndpointConfig().get(0);
-      WSEndpointConfig epc2 = (WSEndpointConfig)wsConfig.getEndpointConfig().get(1);
+      WSEndpointConfigJAXRPC epc1 = (WSEndpointConfigJAXRPC)wsConfig.getEndpointConfig().get(0);
+      WSEndpointConfigJAXRPC epc2 = (WSEndpointConfigJAXRPC)wsConfig.getEndpointConfig().get(1);
 
       assertEquals("Standard Endpoint", epc1.getConfigName());
       assertNull(epc1.getPreHandlerChain());
       assertNull(epc1.getPostHandlerChain());
 
-      assertEquals("WS-Security Endpoint", epc2.getConfigName());
-      WSHandlerChainConfig preChain = epc2.getPreHandlerChain();
+      assertEquals("Standard Secure Endpoint", epc2.getConfigName());
+      WSHandlerChainConfigJAXRPC preChain = epc2.getPreHandlerChain();
       assertEquals("PreHandlerChain", preChain.getHandlerChainName());
       assertEquals(1, preChain.getHandlers().size());
       UnifiedHandlerMetaData h1 = (UnifiedHandlerMetaData)preChain.getHandlers().get(0);
       assertEquals("WSSecurityHandlerInbound", h1.getHandlerName());
-      assertEquals("org.jboss.ws.wsse.WSSecurityHandlerInbound", h1.getHandlerClass());
-      assertNull(epc2.getPostHandlerChain());
+      assertEquals("org.jboss.ws.wsse.jaxrpc.WSSecurityHandlerInbound", h1.getHandlerClass());
    }
+
+   public void testJAXWSObjectModelFactory() throws Exception
+   {
+      File confFile = new File("resources/config/jaxws-endpoint-config.xml");
+      assertTrue(confFile.exists());
+
+      WSConfigFactory factory = WSConfigFactory.newInstance();
+      WSConfigRootJAXWS wsConfig = (WSConfigRootJAXWS)factory.parseWithObjectModelFactory(confFile.toURL());
+
+      assertNotNull("Null wsConfig", wsConfig);
+
+      assertEquals(2, wsConfig.getEndpointConfig().size());
+      WSEndpointConfigJAXWS epc1 = (WSEndpointConfigJAXWS)wsConfig.getEndpointConfig().get(0);
+      WSEndpointConfigJAXWS epc2 = (WSEndpointConfigJAXWS)wsConfig.getEndpointConfig().get(1);
+
+      assertEquals("Standard Endpoint", epc1.getConfigName());
+      assertNull(epc1.getPreHandlerChains());
+      assertNull(epc1.getPostHandlerChains());
+
+      assertEquals("Standard Secure Endpoint", epc2.getConfigName());
+      WSHandlerChainConfigJAXWS preChain = epc2.getPreHandlerChains().getHandlerChains().get(0);
+      assertEquals("##SOAP11_HTTP", preChain.getProtocolBindings());
+      assertEquals(1, preChain.getHandlers().size());
+      UnifiedHandlerMetaData h1 = (UnifiedHandlerMetaData)preChain.getHandlers().get(0);
+      assertEquals("WSSecurityHandlerInbound", h1.getHandlerName());
+      assertEquals("org.jboss.ws.wsse.jaxws.WSSecurityHandlerInbound", h1.getHandlerClass());
+   }
 }

Modified: trunk/src/test/java/org/jboss/test/ws/eventing/DIIClientTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/eventing/DIIClientTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/eventing/DIIClientTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,35 +1,42 @@
 package org.jboss.test.ws.eventing;
 
+import java.io.File;
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URISyntaxException;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.Service;
+import javax.xml.rpc.ServiceFactory;
+import javax.xml.rpc.handler.HandlerInfo;
+import javax.xml.rpc.handler.HandlerRegistry;
+import javax.xml.ws.addressing.AddressingBuilder;
+import javax.xml.ws.addressing.AddressingProperties;
+
 import junit.framework.Test;
+
 import org.jboss.test.ws.JBossWSTest;
 import org.jboss.test.ws.JBossWSTestSetup;
 import org.jboss.ws.addressing.AddressingClientUtil;
-import org.jboss.ws.addressing.soap.SOAPClientHandler;
+import org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler;
 import org.jboss.ws.eventing.EventSourceEndpoint;
 import org.jboss.ws.eventing.EventingConstants;
 import org.jboss.ws.eventing.SubscriptionManagerEndpoint;
-import org.jboss.ws.eventing.element.*;
+import org.jboss.ws.eventing.element.DeliveryType;
+import org.jboss.ws.eventing.element.EndpointReference;
+import org.jboss.ws.eventing.element.FilterType;
+import org.jboss.ws.eventing.element.SubscribeRequest;
+import org.jboss.ws.eventing.element.SubscribeResponse;
+import org.jboss.ws.eventing.element.UnsubscribeRequest;
 import org.jboss.ws.jaxrpc.ServiceExt;
 import org.jboss.ws.jaxrpc.ServiceFactoryImpl;
 import org.jboss.ws.jaxrpc.StubExt;
 import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
 import org.jboss.ws.metadata.wsdl.WSDLDefinitionsFactory;
 
-import javax.xml.namespace.QName;
-import javax.xml.rpc.Service;
-import javax.xml.rpc.ServiceFactory;
-import javax.xml.rpc.handler.HandlerInfo;
-import javax.xml.rpc.handler.HandlerRegistry;
-import javax.xml.ws.addressing.AddressingBuilder;
-import javax.xml.ws.addressing.AddressingProperties;
-import java.io.File;
-import java.net.MalformedURLException;
-import java.net.URI;
-import java.net.URISyntaxException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-
 /**
  * @author Heiko Braun, <heiko at openj.net>
  * @since 19-Jan-2006
@@ -43,11 +50,11 @@
    private URI eventSourceURI;
    
    private AddressingBuilder addrBuilder = AddressingBuilder.getAddressingBuilder();
-   private static Class[] clientHandlerClasses = new Class[] { SOAPClientHandler.class };
+   private static Class[] clientHandlerClasses = new Class[] { WSAddressingClientHandler.class };
 
    public static Test suite()
    {
-      return JBossWSTestSetup.newTestSetup(DIIClientTestCase.class, "jbossws-test-eventing.war, jbossws-test-eventing-client.jar");
+      return JBossWSTestSetup.newTestSetup(DIIClientTestCase.class, "jbossws-test-eventing.war");
    }
 
    public void setUp() throws Exception

Modified: trunk/src/test/java/org/jboss/test/ws/jbws860/TestServlet.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jbws860/TestServlet.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/jbws860/TestServlet.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -42,6 +42,6 @@
    public void doGet(HttpServletRequest req, HttpServletResponse res) throws IOException
    {
       log.info("doGet");
-      res.getOutputStream().println("Hello");
+      res.getWriter().println("Hello");
    }
 }

Modified: trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/AuthorizationHandler.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/AuthorizationHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/AuthorizationHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -21,13 +21,12 @@
   */
 package org.jboss.test.ws.jsr181.handlerchain;
 
+import java.util.HashSet;
+import java.util.Set;
+
 import org.jboss.logging.Logger;
 
 import javax.xml.namespace.QName;
-import javax.xml.rpc.JAXRPCException;
-import javax.xml.rpc.handler.GenericHandler;
-import javax.xml.rpc.handler.MessageContext;
-import javax.xml.rpc.handler.soap.SOAPMessageContext;
 import javax.xml.soap.Name;
 import javax.xml.soap.SOAPBody;
 import javax.xml.soap.SOAPBodyElement;
@@ -37,6 +36,10 @@
 import javax.xml.soap.SOAPHeader;
 import javax.xml.soap.SOAPHeaderElement;
 import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
 
 /**
  * A server side handler for the @HandlerChain
@@ -44,19 +47,27 @@
  * @author Thomas.Diesler at jboss.org
  * @since 08-Oct-2005
  */
-public class AuthorizationHandler extends GenericHandler
+public class AuthorizationHandler implements SOAPHandler
 {
    // Provide logging
    private static Logger log = Logger.getLogger(AuthorizationHandler.class);
 
-   private QName[] headers = new QName[]{};
-
-   public QName[] getHeaders()
+   public Set<QName> getHeaders()
    {
-      return headers;
+      return new HashSet<QName>();
    }
+   
+   public boolean handleMessage(MessageContext msgContext)
+   {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
 
-   public boolean handleRequest(MessageContext msgContext)
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+   
+
+   private boolean handleRequest(MessageContext msgContext)
    {
       log.info("handleRequest");
 
@@ -78,13 +89,13 @@
       }
       catch (SOAPException e)
       {
-         throw  new JAXRPCException(e);
+         throw  new WebServiceException(e);
       }
 
       return true;
    }
 
-   public boolean handleResponse(MessageContext msgContext)
+   private boolean handleResponse(MessageContext msgContext)
    {
       log.info("handleResponse");
 
@@ -106,9 +117,18 @@
       }
       catch (SOAPException e)
       {
-         throw  new JAXRPCException(e);
+         throw  new WebServiceException(e);
       }
 
       return true;
    }
+
+   public boolean handleFault(MessageContext context)
+   {
+      return true;
+   }
+
+   public void close(MessageContext context)
+   {
+   }
 }

Modified: trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/LogHandler.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/LogHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/LogHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -21,13 +21,10 @@
   */
 package org.jboss.test.ws.jsr181.handlerchain;
 
-import org.jboss.logging.Logger;
+import java.util.HashSet;
+import java.util.Set;
 
 import javax.xml.namespace.QName;
-import javax.xml.rpc.JAXRPCException;
-import javax.xml.rpc.handler.GenericHandler;
-import javax.xml.rpc.handler.MessageContext;
-import javax.xml.rpc.handler.soap.SOAPMessageContext;
 import javax.xml.soap.Name;
 import javax.xml.soap.SOAPBody;
 import javax.xml.soap.SOAPBodyElement;
@@ -37,26 +34,39 @@
 import javax.xml.soap.SOAPHeader;
 import javax.xml.soap.SOAPHeaderElement;
 import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
 
+import org.jboss.logging.Logger;
+
 /**
  * A server side handler for the @HandlerChain
  *
  * @author Thomas.Diesler at jboss.org
  * @since 08-Oct-2005
  */
-public class LogHandler extends GenericHandler
+public class LogHandler implements SOAPHandler
 {
    // Provide logging
    private static Logger log = Logger.getLogger(LogHandler.class);
 
-   private QName[] headers = new QName[]{};
-
-   public QName[] getHeaders()
+   public Set<QName> getHeaders()
    {
-      return headers;
+      return new HashSet<QName>();
    }
+   
+   public boolean handleMessage(MessageContext msgContext)
+   {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
 
-   public boolean handleRequest(MessageContext msgContext)
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+   
+   private boolean handleRequest(MessageContext msgContext)
    {
       log.info("handleRequest");
 
@@ -78,13 +88,13 @@
       }
       catch (SOAPException e)
       {
-         throw  new JAXRPCException(e);
+         throw  new WebServiceException(e);
       }
 
       return true;
    }
 
-   public boolean handleResponse(MessageContext msgContext)
+   private boolean handleResponse(MessageContext msgContext)
    {
       log.info("handleResponse");
 
@@ -106,9 +116,18 @@
       }
       catch (SOAPException e)
       {
-         throw  new JAXRPCException(e);
+         throw  new WebServiceException(e);
       }
 
       return true;
    }
+
+   public boolean handleFault(MessageContext context)
+   {
+      return true;
+   }
+
+   public void close(MessageContext context)
+   {
+   }
 }

Modified: trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/MyWebService.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/MyWebService.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/MyWebService.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -35,8 +35,8 @@
  * @since 08-Oct-2005
  */
 @WebService
- at HandlerChain(file = "resource://config/ProjectHandlers.xml", name = "StandardHandlerChain")
 @SOAPBinding(style = SOAPBinding.Style.RPC)
+ at HandlerChain(file = "resource://WEB-INF/jaxws-handlers.xml")
 public class MyWebService
 {
    // Provide logging

Modified: trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/RoutingHandler.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/RoutingHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/jsr181/handlerchain/RoutingHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -21,13 +21,12 @@
   */
 package org.jboss.test.ws.jsr181.handlerchain;
 
+import java.util.HashSet;
+import java.util.Set;
+
 import org.jboss.logging.Logger;
 
 import javax.xml.namespace.QName;
-import javax.xml.rpc.JAXRPCException;
-import javax.xml.rpc.handler.GenericHandler;
-import javax.xml.rpc.handler.MessageContext;
-import javax.xml.rpc.handler.soap.SOAPMessageContext;
 import javax.xml.soap.Name;
 import javax.xml.soap.SOAPBody;
 import javax.xml.soap.SOAPBodyElement;
@@ -37,6 +36,10 @@
 import javax.xml.soap.SOAPHeader;
 import javax.xml.soap.SOAPHeaderElement;
 import javax.xml.soap.SOAPMessage;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
+import javax.xml.ws.handler.soap.SOAPMessageContext;
 
 /**
  * A server side handler for the @HandlerChain
@@ -44,19 +47,27 @@
  * @author Thomas.Diesler at jboss.org
  * @since 08-Oct-2005
  */
-public class RoutingHandler extends GenericHandler
+public class RoutingHandler implements SOAPHandler
 {
    // Provide logging
    private static Logger log = Logger.getLogger(RoutingHandler.class);
 
-   private QName[] headers = new QName[]{};
-
-   public QName[] getHeaders()
+   public Set<QName> getHeaders()
    {
-      return headers;
+      return new HashSet<QName>();
    }
+   
+   public boolean handleMessage(MessageContext msgContext)
+   {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
 
-   public boolean handleRequest(MessageContext msgContext)
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+   
+
+   private boolean handleRequest(MessageContext msgContext)
    {
       log.info("handleRequest");
 
@@ -78,13 +89,13 @@
       }
       catch (SOAPException e)
       {
-         throw  new JAXRPCException(e);
+         throw  new WebServiceException(e);
       }
 
       return true;
    }
 
-   public boolean handleResponse(MessageContext msgContext)
+   private boolean handleResponse(MessageContext msgContext)
    {
       log.info("handleResponse");
 
@@ -106,9 +117,18 @@
       }
       catch (SOAPException e)
       {
-         throw  new JAXRPCException(e);
+         throw  new WebServiceException(e);
       }
 
       return true;
    }
+
+   public boolean handleFault(MessageContext context)
+   {
+      return true;
+   }
+
+   public void close(MessageContext context)
+   {
+   }
 }

Deleted: trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/JSR181SOAPMessageHandlersTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/JSR181SOAPMessageHandlersTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/JSR181SOAPMessageHandlersTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,65 +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.test.ws.jsr181.soapmessagehandlers;
-
-import java.net.URL;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.Service;
-
-import junit.framework.Test;
-
-import org.jboss.test.ws.JBossWSTest;
-import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.jaxrpc.CallImpl;
-import org.jboss.ws.jaxrpc.ServiceFactoryImpl;
-
-/**
- * Test the JSR-181 annotation: javax.jws.SOAPMessageHandlers
- *
- * @author Thomas.Diesler at jboss.org
- * @since 15-Oct-2005
- */
-public class JSR181SOAPMessageHandlersTestCase extends JBossWSTest
-{
-   private static final String targetNS = "http://soapmessagehandlers.jsr181.ws.test.jboss.org/jaws";
-
-   public static Test suite()
-   {
-      return JBossWSTestSetup.newTestSetup(JSR181SOAPMessageHandlersTestCase.class, "jbossws-jsr181-soapmessagehandlers.war");
-   }
-
-   public void testHandlerChain() throws Exception
-   {
-      QName serviceName = new QName(targetNS, "MyWebServiceService");
-      QName portName = new QName(targetNS, "MyWebServicePort");
-      
-      URL wsdlURL = new URL("http://" + getServerHost() + ":8080/jbossws-jsr181-soapmessagehandlers/TestService?wsdl");
-
-      ServiceFactoryImpl factory = new ServiceFactoryImpl();
-      Service service = factory.createService(wsdlURL, serviceName);
-      CallImpl call = (CallImpl)service.createCall(portName, "echo");
-      
-      Object retObj = call.invoke(new Object[]{"Kermit"});
-      assertEquals("Kermit|LogHandlerRequest|AuthorizationHandlerRequest|RoutingHandlerRequest|endpoint|RoutingHandlerResponse|AuthorizationHandlerResponse|LogHandlerResponse", retObj);
-   }
-}

Deleted: trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/MyWebService.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/MyWebService.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/jsr181/soapmessagehandlers/MyWebService.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,55 +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.test.ws.jsr181.soapmessagehandlers;
-
-import javax.jws.WebMethod;
-import javax.jws.WebService;
-import javax.jws.soap.SOAPBinding;
-import javax.jws.soap.SOAPMessageHandler;
-import javax.jws.soap.SOAPMessageHandlers;
-
-import org.jboss.logging.Logger;
-
-/**
- * Test the JSR-181 annotation: javax.jws.SOAPMessageHandlers
- *
- * @author Thomas.Diesler at jboss.org
- * @since 19-Oct-2005
- */
- at WebService
- at SOAPMessageHandlers( { 
-   @SOAPMessageHandler(className = "org.jboss.test.ws.jsr181.handlerchain.LogHandler"),
-   @SOAPMessageHandler(className = "org.jboss.test.ws.jsr181.handlerchain.AuthorizationHandler"), 
-   @SOAPMessageHandler(className = "org.jboss.test.ws.jsr181.handlerchain.RoutingHandler") })
- at SOAPBinding(style = SOAPBinding.Style.RPC)
-public class MyWebService
-{
-   // Provide logging
-   private static Logger log = Logger.getLogger(MyWebService.class);
-
-   @WebMethod
-   public String echo(String input)
-   {
-      log.info("echo: " + input);
-      return input + "|endpoint";
-   }
-};
\ No newline at end of file

Modified: trunk/src/test/java/org/jboss/test/ws/samples/jsr181ejb/EJB3Bean01.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/samples/jsr181ejb/EJB3Bean01.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/samples/jsr181ejb/EJB3Bean01.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -42,6 +42,7 @@
 
 // standard JSR181 annotations
 @WebService(name = "EndpointInterface", targetNamespace = "http://org.jboss.ws/samples/jsr181ejb", serviceName = "TestService")
+ at HandlerChain(file = "resource://META-INF/jaxws-handlers.xml")
 @SOAPBinding(style = SOAPBinding.Style.RPC)
 
 // standard EJB3 annotations
@@ -53,7 +54,6 @@
 @RemoteBinding(jndiBinding = "/ejb3/EJB3EndpointInterface")
 @PortComponent(authMethod="BASIC", transportGuarantee="NONE")
 @SecurityDomain("JBossWS")
- at HandlerChain(file = "resource://config/ServerHandlers.xml", name = "SecureHandlerChain")
 public class EJB3Bean01 implements EJB3RemoteInterface
 {
    @WebMethod

Modified: trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/AddressingStatefulTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/AddressingStatefulTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/AddressingStatefulTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -24,13 +24,11 @@
 import java.io.File;
 import java.net.URL;
 import java.util.HashMap;
-import java.util.Iterator;
 import java.util.List;
 
 import javax.naming.InitialContext;
 import javax.xml.namespace.QName;
 import javax.xml.rpc.Service;
-import javax.xml.rpc.Stub;
 import javax.xml.rpc.handler.HandlerInfo;
 import javax.xml.rpc.handler.HandlerRegistry;
 
@@ -38,8 +36,7 @@
 
 import org.jboss.test.ws.JBossWSTest;
 import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.test.ws.samples.dynamichandler.ClientSideHandler;
-import org.jboss.ws.addressing.soap.SOAPClientHandler;
+import org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler;
 import org.jboss.ws.jaxrpc.ServiceFactoryImpl;
 import org.jboss.ws.jaxrpc.ServiceImpl;
 
@@ -86,7 +83,7 @@
             HandlerRegistry registry1 = service1.getDynamicHandlerRegistry();
             List infos1 = registry1.getHandlerChain(portName);
             infos1.add(new HandlerInfo(ClientHandler.class, new HashMap(), new QName[]{}));
-            infos1.add(new HandlerInfo(SOAPClientHandler.class, new HashMap(), new QName[]{}));
+            infos1.add(new HandlerInfo(WSAddressingClientHandler.class, new HashMap(), new QName[]{}));
             registry1.setHandlerChain(portName, infos1);
 
             
@@ -94,7 +91,7 @@
             HandlerRegistry registry2 = service2.getDynamicHandlerRegistry();
             List infos2 = registry2.getHandlerChain(portName);
             infos2.add(new HandlerInfo(ClientHandler.class, new HashMap(), new QName[]{}));
-            infos2.add(new HandlerInfo(SOAPClientHandler.class, new HashMap(), new QName[]{}));
+            infos2.add(new HandlerInfo(WSAddressingClientHandler.class, new HashMap(), new QName[]{}));
             registry2.setHandlerChain(portName, infos2);
             
             port2 = (StatefulEndpoint)service2.getPort(StatefulEndpoint.class);

Modified: trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/ServerHandler.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/ServerHandler.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/ServerHandler.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -22,16 +22,18 @@
 package org.jboss.test.ws.samples.wsaddressing;
 
 import java.net.URISyntaxException;
+import java.util.HashSet;
+import java.util.Set;
 
 import javax.xml.namespace.QName;
-import javax.xml.rpc.handler.GenericHandler;
-import javax.xml.rpc.handler.MessageContext;
 import javax.xml.soap.SOAPElement;
 import javax.xml.ws.addressing.AddressingBuilder;
 import javax.xml.ws.addressing.AddressingProperties;
 import javax.xml.ws.addressing.EndpointReference;
 import javax.xml.ws.addressing.JAXWSAConstants;
 import javax.xml.ws.addressing.ReferenceParameters;
+import javax.xml.ws.handler.MessageContext;
+import javax.xml.ws.handler.soap.SOAPHandler;
 
 import org.jboss.logging.Logger;
 import org.jboss.util.xml.DOMUtils;
@@ -42,23 +44,39 @@
  * @author Thomas.Diesler at jboss.org
  * @since 24-Nov-2005
  */
-public class ServerHandler extends GenericHandler
+public class ServerHandler implements SOAPHandler
 {
    // Provide logging
    private static Logger log = Logger.getLogger(ServerHandler.class);
 
    private static final QName IDQN = StatefulEndpointImpl.IDQN;
 
-   public QName[] getHeaders()
+   /**
+    * Gets the header blocks that can be processed by this Handler instance.
+    */
+   public Set<QName> getHeaders()
    {
-      return new QName[] {};
+      return new HashSet<QName>();
    }
 
-   public boolean handleRequest(MessageContext msgContext)
+   /**
+    * Read the addressing headers from the incomming message and put a
+    * SOAPAddressingProperties object into the message context
+    */
+   public boolean handleMessage(MessageContext msgContext)
    {
+      Boolean outbound = (Boolean)msgContext.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+      if (outbound == null)
+         throw new IllegalStateException("Cannot obtain required property: " + MessageContext.MESSAGE_OUTBOUND_PROPERTY);
+
+      return outbound ? handleResponse(msgContext) : handleRequest(msgContext);
+   }
+
+   private boolean handleRequest(MessageContext msgContext)
+   {
       log.info("handleRequest");
 
-      AddressingProperties addrProps = (AddressingProperties)msgContext.getProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND);
+      AddressingProperties addrProps = (AddressingProperties)msgContext.get(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND);
       if (addrProps == null)
          throw new IllegalStateException("Cannot obtain AddressingProperties");
 
@@ -82,17 +100,17 @@
          throw new IllegalStateException("Cannot obtain client id");
 
       // put the clientid in the message context
-      msgContext.setProperty("clientid", clientid);
+      msgContext.put("clientid", clientid);
       return true;
    }
 
-   public boolean handleResponse(MessageContext msgContext)
+   private boolean handleResponse(MessageContext msgContext)
    {
       log.info("handleResponse");
 
       try
       {
-         AddressingProperties inProps = (AddressingProperties)msgContext.getProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND);
+         AddressingProperties inProps = (AddressingProperties)msgContext.get(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_INBOUND);
          AddressingBuilder builder = AddressingBuilder.getAddressingBuilder();
 
          builder.newAddressingConstants();
@@ -100,7 +118,7 @@
          outProps.initializeAsReply(inProps, false);
          outProps.setAction(builder.newURI("http://org.jboss.ws/addressing/stateful/actionReply"));
 
-         msgContext.setProperty(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND, outProps);
+         msgContext.put(JAXWSAConstants.SERVER_ADDRESSING_PROPERTIES_OUTBOUND, outProps);
       }
       catch (URISyntaxException ex)
       {
@@ -109,4 +127,13 @@
 
       return true;
    }
+
+   public boolean handleFault(MessageContext messagecontext)
+   {
+      return true;
+   }
+
+   public void close(MessageContext messagecontext)
+   {
+   }
 }

Modified: trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/StatefulEndpointImpl.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/StatefulEndpointImpl.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/samples/wsaddressing/StatefulEndpointImpl.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -29,11 +29,10 @@
 import java.util.Map;
 
 import javax.annotation.Resource;
+import javax.jws.HandlerChain;
 import javax.jws.WebMethod;
 import javax.jws.WebService;
 import javax.jws.soap.SOAPBinding;
-import javax.jws.soap.SOAPMessageHandler;
-import javax.jws.soap.SOAPMessageHandlers;
 import javax.xml.namespace.QName;
 import javax.xml.ws.WebServiceContext;
 import javax.xml.ws.handler.MessageContext;
@@ -48,10 +47,7 @@
  */
 @WebService(name = "StatefulEndpoint", targetNamespace = "http://org.jboss.ws/samples/wsaddressing", serviceName = "TestService")
 @SOAPBinding(style = SOAPBinding.Style.RPC)
- at SOAPMessageHandlers( { 
-   @SOAPMessageHandler(className = "org.jboss.ws.addressing.soap.SOAPServerHandler"),
-   @SOAPMessageHandler(className = "org.jboss.test.ws.samples.wsaddressing.ServerHandler")
-   })
+ at HandlerChain(file = "resource://WEB-INF/jaxws-handlers.xml")
 public class StatefulEndpointImpl implements StatefulEndpoint
 {
    // provide logging

Modified: trunk/src/test/java/org/jboss/test/ws/samples/wseventing/SysmonTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/samples/wseventing/SysmonTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/samples/wseventing/SysmonTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -43,7 +43,7 @@
 import org.jboss.test.ws.JBossWSTest;
 import org.jboss.test.ws.JBossWSTestSetup;
 import org.jboss.ws.addressing.AddressingClientUtil;
-import org.jboss.ws.addressing.soap.SOAPClientHandler;
+import org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler;
 import org.jboss.ws.eventing.EventSourceEndpoint;
 import org.jboss.ws.eventing.EventingConstants;
 import org.jboss.ws.eventing.SubscriptionManagerEndpoint;
@@ -107,11 +107,11 @@
             ServiceImpl service = (ServiceImpl)factory.createService(wsdlURL, serviceName, mappingURL);
             HandlerRegistry registry = service.getDynamicHandlerRegistry();
             List infos1 = registry.getHandlerChain(portName1);
-            infos1.add(new HandlerInfo(SOAPClientHandler.class, new HashMap(), new QName[]{}));
+            infos1.add(new HandlerInfo(WSAddressingClientHandler.class, new HashMap(), new QName[]{}));
             registry.setHandlerChain(portName1, infos1);
             
             List infos2 = registry.getHandlerChain(portName2);
-            infos2.add(new HandlerInfo(SOAPClientHandler.class, new HashMap(), new QName[]{}));
+            infos2.add(new HandlerInfo(WSAddressingClientHandler.class, new HashMap(), new QName[]{}));
             registry.setHandlerChain(portName2, infos2);
             
             subscriptionPort = (EventSourceEndpoint)service.getPort(EventSourceEndpoint.class);

Modified: trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleEncryptTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleEncryptTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleEncryptTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -39,7 +39,7 @@
 import org.jboss.test.ws.JBossWSTestSetup;
 import org.jboss.ws.jaxrpc.ServiceFactoryImpl;
 import org.jboss.ws.jaxrpc.ServiceImpl;
-import org.jboss.ws.wsse.WSSecurityHandlerOutbound;
+import org.jboss.ws.wsse.jaxrpc.WSSecurityHandlerOutbound;
 
 /**
  * Test WS-Security with RPC/Literal

Modified: trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleSignTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleSignTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/samples/wssecurity/SimpleSignTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -39,7 +39,7 @@
 import org.jboss.test.ws.JBossWSTestSetup;
 import org.jboss.ws.jaxrpc.ServiceFactoryImpl;
 import org.jboss.ws.jaxrpc.ServiceImpl;
-import org.jboss.ws.wsse.WSSecurityHandlerOutbound;
+import org.jboss.ws.wsse.jaxrpc.WSSecurityHandlerOutbound;
 
 /**
  * Test WS-Security with RPC/Literal

Modified: trunk/src/test/java/org/jboss/test/ws/tools/xmlschema/XercesSchemaParserTestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/tools/xmlschema/XercesSchemaParserTestCase.java	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/java/org/jboss/test/ws/tools/xmlschema/XercesSchemaParserTestCase.java	2006-08-03 21:04:42 UTC (rev 680)
@@ -23,7 +23,6 @@
 
 import java.io.File;
 import java.io.FileOutputStream;
-import java.io.FileWriter;
 import java.io.IOException;
 import java.net.URL;
 import java.util.HashMap;
@@ -55,6 +54,7 @@
 import org.jboss.ws.metadata.wsdl.xmlschema.JBossXSParticle;
 import org.jboss.ws.metadata.wsdl.xsd.SchemaUtils;
 import org.jboss.ws.tools.JavaToXSD;
+import org.jboss.ws.utils.JBossWSEntityResolver;
 import org.jboss.xb.binding.sunday.unmarshalling.LSInputAdaptor;
 import org.jboss.xb.binding.sunday.unmarshalling.SchemaBinding;
 import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
@@ -180,7 +180,7 @@
       map.put(typeNS,new File("resources/wsdlfixture/customtype/CustomTypeObj.xsd").toURL());
       map.put(arrTypeNS,new File("resources/wsdlfixture/customtype/CustomTypeArrays.xsd").toURL());
 
-      ((XMLSchemaLoader)xsloader).setEntityResolver(new JBossXSEntityResolver(map));
+      ((XMLSchemaLoader)xsloader).setEntityResolver(new JBossXSEntityResolver(new JBossWSEntityResolver(), map));
       //Construct a StringList
       StringList slist = new StringListImpl(arr, 2);
       System.out.println("FIXME: JBXB-33");

Deleted: trunk/src/test/resources/addressing/action/Doc-META-INF/config.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Doc-META-INF/config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Doc-META-INF/config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-   wscompile -cp ../../../../output/classes -gen:server -f:documentliteral -mapping jaxrpc-mapping.xml -keep config.xml
--->
-
-<configuration
-  xmlns="http://java.sun.com/xml/ns/jax-rpc/ri/config">
-
-  <service name="ActionDocService"
-    targetNamespace="http://org.jboss.ws/addressing/action"
-    typeNamespace="http://org.jboss.ws/addressing/action"
-    packageName="org.jboss.test.ws.addressing.action">
-    <interface name="org.jboss.test.ws.addressing.action.ActionEndpoint"/>
-  </service>
-
-</configuration>
-

Added: trunk/src/test/resources/addressing/action/Doc-META-INF/jaxrpc-client-config.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Doc-META-INF/jaxrpc-client-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Doc-META-INF/jaxrpc-client-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxrpc-config xmlns="urn:jboss:jaxrpc-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
+  xsi:schemaLocation="urn:jboss:jaxrpc-config:2.0 jaxrpc-config_2_0.xsd">
+  
+  <client-config>
+    <config-name>Addressing Client</config-name>
+    <post-handler-chain>
+      <handler-chain-name>PostHandlerChain</handler-chain-name>
+      <handler>
+        <j2ee:handler-name>SOAPClientHandler</j2ee:handler-name>
+        <j2ee:handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler</j2ee:handler-class>
+      </handler>
+    </post-handler-chain>
+  </client-config>
+  
+</jaxrpc-config>
\ No newline at end of file


Property changes on: trunk/src/test/resources/addressing/action/Doc-META-INF/jaxrpc-client-config.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/test/resources/addressing/action/Doc-META-INF/jaxws-handlers.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Doc-META-INF/jaxws-handlers.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Doc-META-INF/jaxws-handlers.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee handler-chain.xsd">
+
+	<handler-chain>
+    <protocol-bindings>##SOAP11_HTTP</protocol-bindings>
+		<handler>
+			<handler-name>WS-Addressing Handler</handler-name>
+			<handler-class>org.jboss.ws.addressing.jaxws.WSAddressingServerHandler</handler-class>
+		</handler>
+	</handler-chain>
+</handler-chains>
\ No newline at end of file


Property changes on: trunk/src/test/resources/addressing/action/Doc-META-INF/jaxws-handlers.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/test/resources/addressing/action/Doc-META-INF/jboss-client.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Doc-META-INF/jboss-client.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Doc-META-INF/jboss-client.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -10,7 +10,7 @@
   <service-ref>
     <service-ref-name>service/ActionDocService</service-ref-name>
     <config-name>Addressing Client</config-name>
-    <config-file>META-INF/jbossws-client-config.xml</config-file>
+    <config-file>META-INF/jaxrpc-client-config.xml</config-file>
   </service-ref>
   
 </jboss-client>

Deleted: trunk/src/test/resources/addressing/action/Doc-META-INF/jbossws-client-config.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Doc-META-INF/jbossws-client-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Doc-META-INF/jbossws-client-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- $Id$ -->
-
-<jbossws-config xmlns="urn:jboss:jbossws-config:5.0"
-  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
-  xsi:schemaLocation="urn:jboss:jbossws-config:5.0 http://www.jboss.com/xml/jbossws-config_1_0.xsd">
-  
-  <client-config>
-    <config-name>Addressing Client</config-name>
-    <post-handler-chain>
-      <handler-chain-name>PostHandlerChain</handler-chain-name>
-      <handler>
-        <j2ee:handler-name>SOAPClientHandler</j2ee:handler-name>
-        <j2ee:handler-class>org.jboss.ws.addressing.soap.SOAPClientHandler</j2ee:handler-class>
-      </handler>
-    </post-handler-chain>
-  </client-config>
-  
-</jbossws-config>
\ No newline at end of file

Copied: trunk/src/test/resources/addressing/action/Doc-META-INF/wstools-config.xml (from rev 661, trunk/src/test/resources/addressing/action/Doc-META-INF/config.xml)

Deleted: trunk/src/test/resources/addressing/action/Rpc-META-INF/config.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Rpc-META-INF/config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Rpc-META-INF/config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
-   wscompile -cp ../../../../output/classes -gen:server -f:rpcliteral -mapping jaxrpc-mapping.xml config.xml
--->
-
-<configuration
-  xmlns="http://java.sun.com/xml/ns/jax-rpc/ri/config">
-
-  <service name="ActionRpcService"
-    targetNamespace="http://org.jboss.ws/addressing/action"
-    typeNamespace="http://org.jboss.ws/addressing/action"
-    packageName="org.jboss.test.ws.addressing.action">
-    <interface name="org.jboss.test.ws.addressing.action.ActionEndpoint"/>
-  </service>
-
-</configuration>
-

Added: trunk/src/test/resources/addressing/action/Rpc-META-INF/jaxrpc-client-config.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Rpc-META-INF/jaxrpc-client-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Rpc-META-INF/jaxrpc-client-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxrpc-config xmlns="urn:jboss:jaxrpc-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
+  xsi:schemaLocation="urn:jboss:jaxrpc-config:2.0 jaxrpc-config_2_0.xsd">
+  
+  <client-config>
+    <config-name>Addressing Client</config-name>
+    <post-handler-chain>
+      <handler-chain-name>PostHandlerChain</handler-chain-name>
+      <handler>
+        <j2ee:handler-name>SOAPClientHandler</j2ee:handler-name>
+        <j2ee:handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler</j2ee:handler-class>
+      </handler>
+    </post-handler-chain>
+  </client-config>
+  
+</jaxrpc-config>
\ No newline at end of file


Property changes on: trunk/src/test/resources/addressing/action/Rpc-META-INF/jaxrpc-client-config.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/test/resources/addressing/action/Rpc-META-INF/jboss-client.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Rpc-META-INF/jboss-client.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Rpc-META-INF/jboss-client.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -9,6 +9,6 @@
   <service-ref>
     <service-ref-name>service/ActionRpcService</service-ref-name>
     <!-- test unnamed config-name -->
-    <config-file>META-INF/jbossws-client-config.xml</config-file>
+    <config-file>META-INF/jaxrpc-client-config.xml</config-file>
   </service-ref>
 </jboss-client>

Deleted: trunk/src/test/resources/addressing/action/Rpc-META-INF/jbossws-client-config.xml
===================================================================
--- trunk/src/test/resources/addressing/action/Rpc-META-INF/jbossws-client-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/action/Rpc-META-INF/jbossws-client-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- $Id$ -->
-
-<jbossws-config xmlns="urn:jboss:jbossws-config:5.0"
-  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
-  xsi:schemaLocation="urn:jboss:jbossws-config:5.0 http://www.jboss.com/xml/jbossws-config_1_0.xsd">
-  
-  <client-config>
-    <config-name>Addressing Client</config-name>
-    <post-handler-chain>
-      <handler-chain-name>PostHandlerChain</handler-chain-name>
-      <handler>
-        <j2ee:handler-name>SOAPClientHandler</j2ee:handler-name>
-        <j2ee:handler-class>org.jboss.ws.addressing.soap.SOAPClientHandler</j2ee:handler-class>
-      </handler>
-    </post-handler-chain>
-  </client-config>
-  
-</jbossws-config>
\ No newline at end of file

Copied: trunk/src/test/resources/addressing/action/Rpc-META-INF/wstools-config.xml (from rev 661, trunk/src/test/resources/addressing/action/Rpc-META-INF/config.xml)

Added: trunk/src/test/resources/addressing/replyto/Initial-WEB-INF/jaxws-handlers.xml
===================================================================
--- trunk/src/test/resources/addressing/replyto/Initial-WEB-INF/jaxws-handlers.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/addressing/replyto/Initial-WEB-INF/jaxws-handlers.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee handler-chain.xsd">
+
+	<handler-chain>
+    <protocol-bindings>##SOAP11_HTTP</protocol-bindings>
+		<handler>
+			<handler-name>WS-Addressing Handler</handler-name>
+			<handler-class>org.jboss.ws.addressing.jaxws.WSAddressingServerHandler</handler-class>
+		</handler>
+	</handler-chain>
+</handler-chains>
\ No newline at end of file


Property changes on: trunk/src/test/resources/addressing/replyto/Initial-WEB-INF/jaxws-handlers.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/test/resources/config/jaxrpc-endpoint-config.xml
===================================================================
--- trunk/src/test/resources/config/jaxrpc-endpoint-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/config/jaxrpc-endpoint-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxrpc-config xmlns="urn:jboss:jaxrpc-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
+  xsi:schemaLocation="urn:jboss:jaxrpc-config:2.0 jaxrpc-config_2_0.xsd">
+  
+  <endpoint-config>
+    <config-name>Standard Endpoint</config-name>
+  </endpoint-config>
+  
+  <endpoint-config>
+    <config-name>Standard Secure Endpoint</config-name>
+    <pre-handler-chain>
+      <handler-chain-name>PreHandlerChain</handler-chain-name>
+      <handler>
+        <j2ee:handler-name>WSSecurityHandlerInbound</j2ee:handler-name>
+        <j2ee:handler-class>org.jboss.ws.wsse.jaxrpc.WSSecurityHandlerInbound</j2ee:handler-class>
+      </handler>
+    </pre-handler-chain>
+   </endpoint-config>
+  
+</jaxrpc-config>
\ No newline at end of file


Property changes on: trunk/src/test/resources/config/jaxrpc-endpoint-config.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Added: trunk/src/test/resources/config/jaxws-endpoint-config.xml
===================================================================
--- trunk/src/test/resources/config/jaxws-endpoint-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/config/jaxws-endpoint-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxws-config xmlns="urn:jboss:jaxws-config:2.0"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:javaee="http://java.sun.com/xml/ns/javaee"
+  xsi:schemaLocation="urn:jboss:jaxws-config:2.0 jaxws-config_2_0.xsd">
+  
+  <endpoint-config>
+    <config-name>Standard Endpoint</config-name>
+  </endpoint-config>
+  
+  <endpoint-config>
+    <config-name>Standard Secure Endpoint</config-name>
+    <pre-handler-chains>
+      <javaee:handler-chain>
+        <javaee:protocol-bindings>##SOAP11_HTTP</javaee:protocol-bindings>
+        <javaee:handler>
+          <javaee:handler-name>WSSecurityHandlerInbound</javaee:handler-name>
+          <javaee:handler-class>org.jboss.ws.wsse.jaxws.WSSecurityHandlerInbound</javaee:handler-class>
+        </javaee:handler>
+      </javaee:handler-chain>
+    </pre-handler-chains>
+   </endpoint-config>
+  
+</jaxws-config>
\ No newline at end of file


Property changes on: trunk/src/test/resources/config/jaxws-endpoint-config.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Deleted: trunk/src/test/resources/config/jbossws-endpoint-config.xml
===================================================================
--- trunk/src/test/resources/config/jbossws-endpoint-config.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/config/jbossws-endpoint-config.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- $Id$ -->
-
-<jbossws-config xmlns="urn:jboss:jbossws-config:5.0"
-  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-  xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
-  xsi:schemaLocation="urn:jboss:jbossws-config:5.0 http://www.jboss.com/xml/jbossws-config_1_0.xsd">
-  
-  <endpoint-config>
-    <config-name>Standard Endpoint</config-name>
-  </endpoint-config>
-  
-  <endpoint-config>
-    <config-name>WS-Security Endpoint</config-name>
-    <pre-handler-chain>
-      <handler-chain-name>PreHandlerChain</handler-chain-name>
-      <handler>
-        <j2ee:handler-name>WSSecurityHandlerInbound</j2ee:handler-name>
-        <j2ee:handler-class>org.jboss.ws.wsse.WSSecurityHandlerInbound</j2ee:handler-class>
-      </handler>
-    </pre-handler-chain>
-   </endpoint-config>
-  
-</jbossws-config>
\ No newline at end of file

Modified: trunk/src/test/resources/eventing/META-INF/application-client.xml
===================================================================
--- trunk/src/test/resources/eventing/META-INF/application-client.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/eventing/META-INF/application-client.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -22,7 +22,7 @@
 
         <handler>
             <handler-name>SOAPOutboundHandler</handler-name>
-            <handler-class>org.jboss.ws.addressing.soap.SOAPClientHandler</handler-class>
+            <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler</handler-class>
         </handler>
 
     </service-ref>

Modified: trunk/src/test/resources/eventing/WEB-INF/webservices.xml
===================================================================
--- trunk/src/test/resources/eventing/WEB-INF/webservices.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/eventing/WEB-INF/webservices.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -21,8 +21,8 @@
             </service-impl-bean>
 
             <handler>
-                <handler-name>org.jboss.ws.addressing.soap.SOAPServerHandler</handler-name>
-                <handler-class>org.jboss.ws.addressing.soap.SOAPServerHandler</handler-class>
+                <handler-name>WSAddressingServerHandler</handler-name>
+                <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingServerHandler</handler-class>
             </handler>
 
         </port-component>
@@ -35,8 +35,8 @@
                 <servlet-link>EventSourceServlet</servlet-link>
             </service-impl-bean>
             <handler>
-                <handler-name>org.jboss.ws.addressing.soap.SOAPServerHandler</handler-name>
-                <handler-class>org.jboss.ws.addressing.soap.SOAPServerHandler</handler-class>
+                <handler-name>WSAddressingServerHandler</handler-name>
+                <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingServerHandler</handler-class>
             </handler>         
 
         </port-component>

Modified: trunk/src/test/resources/interop/microsoft/addressing/wsa10/META-INF/application-client.xml
===================================================================
--- trunk/src/test/resources/interop/microsoft/addressing/wsa10/META-INF/application-client.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/interop/microsoft/addressing/wsa10/META-INF/application-client.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -25,8 +25,8 @@
       </port-component-ref>
 
       <handler>
-         <handler-name>client.notify.handler</handler-name>
-         <handler-class>org.jboss.ws.addressing.soap.SOAPClientHandler</handler-class>
+         <handler-name>WSAddressingClientHandler</handler-name>
+         <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler</handler-class>
          <!--init-param>
             <param-name>javax.xml.ws.addressing.to.inbound</param-name>
             <param-value>http://example.org/node/A</param-value>
@@ -37,7 +37,7 @@
 
       <handler>
          <handler-name>client.echo.handler</handler-name>
-         <handler-class>org.jboss.ws.addressing.soap.SOAPClientHandler</handler-class>
+         <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler</handler-class>
          <!--init-param>
             <param-name>javax.xml.ws.addressing.to.inbound</param-name>
             <param-value>http://example.org/node/A</param-value>

Modified: trunk/src/test/resources/interop/microsoft/addressing/wsaTestService/WEB-INF/webservices.xml
===================================================================
--- trunk/src/test/resources/interop/microsoft/addressing/wsaTestService/WEB-INF/webservices.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/interop/microsoft/addressing/wsaTestService/WEB-INF/webservices.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -29,7 +29,7 @@
 
          <handler>
             <handler-name>addressing handler</handler-name>
-            <handler-class>org.jboss.ws.addressing.soap.SOAPServerHandler</handler-class>
+            <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingServerHandler</handler-class>
             <init-param>
                <param-name>validate</param-name>
                <param-value>false</param-value>

Added: trunk/src/test/resources/jsr181/handlerchain/WEB-INF/jaxws-handlers.xml
===================================================================
--- trunk/src/test/resources/jsr181/handlerchain/WEB-INF/jaxws-handlers.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/jsr181/handlerchain/WEB-INF/jaxws-handlers.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee handler-chain.xsd">
+
+	<handler-chain>
+    <protocol-bindings>##SOAP11_HTTP</protocol-bindings>
+		<handler>
+			<handler-name> LogHandler </handler-name>
+			<handler-class> org.jboss.test.ws.jsr181.handlerchain.LogHandler </handler-class>
+			<init-param>
+				<param-name>logCategory</param-name>
+				<param-value>MyService</param-value>
+			</init-param>
+		</handler>
+    <handler>
+      <handler-name> AuthorizationHandler </handler-name>
+      <handler-class> org.jboss.test.ws.jsr181.handlerchain.AuthorizationHandler </handler-class>
+      <soap-role>SecurityProvider</soap-role>
+    </handler>
+		<handler>
+			<handler-name> RoutingHandler </handler-name>
+			<handler-class> org.jboss.test.ws.jsr181.handlerchain.RoutingHandler </handler-class>
+		</handler>
+	</handler-chain>
+</handler-chains>
\ No newline at end of file


Property changes on: trunk/src/test/resources/jsr181/handlerchain/WEB-INF/jaxws-handlers.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Deleted: trunk/src/test/resources/jsr181/handlerchain/config/ProjectHandlers.xml
===================================================================
--- trunk/src/test/resources/jsr181/handlerchain/config/ProjectHandlers.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/jsr181/handlerchain/config/ProjectHandlers.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<handler-config>
-	<handler-chain>
-		<handler-chain-name>StandardHandlerChain</handler-chain-name>
-		<handler>
-			<handler-name> LogHandler </handler-name>
-			<handler-class> org.jboss.test.ws.jsr181.handlerchain.LogHandler </handler-class>
-			<init-param>
-				<param-name>logCategory</param-name>
-				<param-value>MyService</param-value>
-			</init-param>
-		</handler>
-    <handler>
-      <handler-name> AuthorizationHandler </handler-name>
-      <handler-class> org.jboss.test.ws.jsr181.handlerchain.AuthorizationHandler </handler-class>
-      <soap-role>SecurityProvider</soap-role>
-      <soap-header xmlns:ns2='http://openuri.org/examples/security'>ns2:SecurityHeader</soap-header> 
-    </handler>
-		<handler>
-			<handler-name> RoutingHandler </handler-name>
-			<handler-class> org.jboss.test.ws.jsr181.handlerchain.RoutingHandler </handler-class>
-		</handler>
-	</handler-chain>
-</handler-config>
\ No newline at end of file

Deleted: trunk/src/test/resources/jsr181/soapmessagehandlers/WEB-INF/web.xml
===================================================================
--- trunk/src/test/resources/jsr181/soapmessagehandlers/WEB-INF/web.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/jsr181/soapmessagehandlers/WEB-INF/web.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
-  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-  xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
-  version="2.4">
-
-  <servlet>
-    <servlet-name>TestService</servlet-name>
-    <servlet-class>org.jboss.test.ws.jsr181.soapmessagehandlers.MyWebService</servlet-class>
-  </servlet>
-
-  <servlet-mapping>
-    <servlet-name>TestService</servlet-name>
-    <url-pattern>/*</url-pattern>
-  </servlet-mapping>
-
-</web-app>
-

Added: trunk/src/test/resources/samples/jsr181ejb/META-INF/jaxws-handlers.xml
===================================================================
--- trunk/src/test/resources/samples/jsr181ejb/META-INF/jaxws-handlers.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/samples/jsr181ejb/META-INF/jaxws-handlers.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee handler-chain.xsd">
+
+	<handler-chain>
+    <protocol-bindings>##SOAP11_HTTP</protocol-bindings>
+      <handler>
+         <handler-name>WSSecurityHandlerInbound</handler-name>
+         <handler-class>org.jboss.ws.wsse.jaxws.WSSecurityHandlerInbound</handler-class>         
+      </handler>
+	</handler-chain>
+</handler-chains>
\ No newline at end of file


Property changes on: trunk/src/test/resources/samples/jsr181ejb/META-INF/jaxws-handlers.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Copied: trunk/src/test/resources/samples/jsr181ejb/WEB-INF (from rev 673, trunk/src/test/resources/samples/jsr181ejb/config)

Deleted: trunk/src/test/resources/samples/jsr181ejb/WEB-INF/ServerHandlers.xml
===================================================================
--- trunk/src/test/resources/samples/jsr181ejb/config/ServerHandlers.xml	2006-08-03 08:57:12 UTC (rev 673)
+++ trunk/src/test/resources/samples/jsr181ejb/WEB-INF/ServerHandlers.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<handler-config>
-   <handler-chain>
-      <handler-chain-name>SecureHandlerChain</handler-chain-name>
-      <handler>
-         <handler-name>WSSecurityHandlerInbound</handler-name>
-         <handler-class>org.jboss.ws.wsse.WSSecurityHandlerInbound</handler-class>         
-      </handler>
-   </handler-chain>
-</handler-config>

Added: trunk/src/test/resources/samples/wsaddressing/WEB-INF/jaxws-handlers.xml
===================================================================
--- trunk/src/test/resources/samples/wsaddressing/WEB-INF/jaxws-handlers.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/samples/wsaddressing/WEB-INF/jaxws-handlers.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://java.sun.com/xml/ns/javaee handler-chain.xsd">
+
+	<handler-chain>
+    <protocol-bindings>##SOAP11_HTTP</protocol-bindings>
+		<handler>
+			<handler-name>WS-Addressing Handler</handler-name>
+			<handler-class>org.jboss.ws.addressing.jaxws.WSAddressingServerHandler</handler-class>
+		</handler>
+		<handler>
+			<handler-name>Application Server Handler</handler-name>
+			<handler-class>org.jboss.test.ws.samples.wsaddressing.ServerHandler</handler-class>
+		</handler>
+	</handler-chain>
+</handler-chains>
\ No newline at end of file


Property changes on: trunk/src/test/resources/samples/wsaddressing/WEB-INF/jaxws-handlers.xml
___________________________________________________________________
Name: svn:keywords
   + Id Revision
Name: svn:eol-style
   + LF

Modified: trunk/src/test/resources/samples/wseventing/META-INF/application-client.xml
===================================================================
--- trunk/src/test/resources/samples/wseventing/META-INF/application-client.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/samples/wseventing/META-INF/application-client.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -22,7 +22,7 @@
 
       <handler>
          <handler-name>WSAddressingHandler</handler-name>
-         <handler-class>org.jboss.ws.addressing.soap.SOAPClientHandler</handler-class>
+         <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingClientHandler</handler-class>
       </handler>
 
    </service-ref>

Modified: trunk/src/test/resources/samples/wseventing/WEB-INF/webservices.xml
===================================================================
--- trunk/src/test/resources/samples/wseventing/WEB-INF/webservices.xml	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/src/test/resources/samples/wseventing/WEB-INF/webservices.xml	2006-08-03 21:04:42 UTC (rev 680)
@@ -22,7 +22,7 @@
 
          <handler>
             <handler-name>WSAddressingHandler</handler-name>
-            <handler-class>org.jboss.ws.addressing.soap.SOAPServerHandler</handler-class>
+            <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingServerHandler</handler-class>
          </handler>
 
       </port-component>
@@ -37,7 +37,7 @@
 
          <handler>
             <handler-name>WSAddressingHandler</handler-name>
-            <handler-class>org.jboss.ws.addressing.soap.SOAPServerHandler</handler-class>
+            <handler-class>org.jboss.ws.addressing.jaxrpc.WSAddressingServerHandler</handler-class>
          </handler>
 
       </port-component>

Modified: trunk/version.properties
===================================================================
--- trunk/version.properties	2006-08-03 20:24:31 UTC (rev 679)
+++ trunk/version.properties	2006-08-03 21:04:42 UTC (rev 680)
@@ -1,7 +1,9 @@
 
+# $Id: $
+
 specification.title=JBossWS
 specification.vendor=JBoss (http://www.jboss.org)
-specification.version=jbossws-1.0
+specification.version=jbossws-2.0
 
 version.id=2.0.0.DEV
 
@@ -14,7 +16,9 @@
 apache-xmlsec=1.3.0
 ibm-wsdl4j=1.5.2jboss
 javassist=3.2.0.CR2
+jboss-common=1.0.1
 jboss-jbossxb=1.0.0.CR6
+jboss-microcontainer=snapshot
 jboss-remoting=1.4.3.GA
 
 # thirdparty library versions
@@ -24,7 +28,6 @@
 apache-xerces=2.7.1
 jboss-backport-concurrent=2.1.0.GA
 jboss-jbossretro=1.0.0.GA
-jbossas-core=4.0.4.GA
 junit=3.8.1
 oswego-concurrent=1.3.4
 qdox=1.4




More information about the jboss-svn-commits mailing list