Author: thomas.diesler(a)jboss.com
Date: 2007-03-08 18:42:11 -0500 (Thu, 08 Mar 2007)
New Revision: 2558
Added:
trunk/jbossws-core/src/java/org/jboss/ws/core/client/
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java
Removed:
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandler.java
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandlerMBean.java
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandlerMBean.java
trunk/jbossws-core/src/java/org/jboss/ws/core/UnifiedVirtualFile.java
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java
trunk/jbossws-core/src/java/org/jboss/ws/core/server/KernelLocator.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/CallPropertyMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/InitParamMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/PortComponentRefMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefObjectFactory.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/StubPropertyMetaData.java
Modified:
trunk/build/ant-import/build-release.xml
trunk/build/etc/jbossws-component-info.xml
trunk/build/version.properties
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptor.java
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorEJB21.java
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorJSE.java
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptor.java
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21.java
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSE.java
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/URLLoaderAdapter.java
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/AbstractDeployer.java
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/JAXRPCDeployerJSE.java
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceEndpointLifecycleDeployer.java
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/VirtualFileAdaptor.java
trunk/integration-jboss50/src/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/KernelBootstrap.java
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/TomcatServiceEndpointServlet.java
trunk/jbossws-core/build.xml
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceExt.java
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/spi/ServiceDelegateImpl.java
trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServerConfigFactory.java
trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServiceEndpointManagerFactory.java
trunk/jbossws-core/src/java/org/jboss/ws/core/server/UnifiedDeploymentInfo.java
trunk/jbossws-core/src/java/org/jboss/ws/extensions/eventing/mgmt/SubscriptionManagerFactory.java
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxrpc/WSSecurityHandler.java
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxws/WSSecurityHandler.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCClientMetaDataBuilder.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCDeployment.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxws/JAXWSClientMetaDataBuilder.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/config/JBossWSConfigFactory.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedCallPropertyMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedInitParamMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedPortComponentRefMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedStubPropertyMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/EndpointMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ResourceLoaderAdapter.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ServiceMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/UnifiedMetaData.java
trunk/jbossws-core/src/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java
Log:
Provide general purpose ws integration
Modified: trunk/build/ant-import/build-release.xml
===================================================================
--- trunk/build/ant-import/build-release.xml 2007-03-08 22:29:02 UTC (rev 2557)
+++ trunk/build/ant-import/build-release.xml 2007-03-08 23:42:11 UTC (rev 2558)
@@ -50,6 +50,7 @@
</delete>
<copy todir="${jbossws.repository.dir}/lib"
overwrite="true">
<fileset dir="${core.output.lib.dir}">
+ <include name="jbossws-integration.jar"/>
<include name="jbossws-client.jar"/>
<include name="jbossws-core.jar"/>
<include name="jboss-jaxrpc.jar"/>
@@ -60,14 +61,12 @@
<include name="jbossws50.sar"/>
<include name="jbossws50-deployer.zip"/>
</fileset>
- <!--
<fileset dir="${jboss42.output.lib.dir}">
<include name="jbossws42.sar"/>
</fileset>
<fileset dir="${jboss40.output.lib.dir}">
<include name="jbossws40.sar"/>
</fileset>
- -->
</copy>
<copy tofile="${jbossws.repository.dir}/component-info.xml"
file="${etc.dir}/jbossws-component-info.xml" filtering="true"
overwrite="true">
<filterset>
Modified: trunk/build/etc/jbossws-component-info.xml
===================================================================
--- trunk/build/etc/jbossws-component-info.xml 2007-03-08 22:29:02 UTC (rev 2557)
+++ trunk/build/etc/jbossws-component-info.xml 2007-03-08 23:42:11 UTC (rev 2558)
@@ -2,6 +2,7 @@
<component id="jboss/jbossws" licenseType="lgpl"
version="@repository.id(a)" description="JBossWS an implementation of J2EE
Web Services">
+ <artifact id="jbossws-integration.jar"/>
<artifact id="jbossws-client.jar"/>
<artifact id="jbossws-core.jar"/>
<artifact id="jboss-jaxrpc.jar"/>
@@ -43,6 +44,7 @@
</import>
<export>
+ <include input="jbossws-integration.jar"/>
<include input="jbossws-core.jar"/>
<include input="jboss-jaxrpc.jar"/>
<include input="jboss-jaxws.jar"/>
Modified: trunk/build/version.properties
===================================================================
--- trunk/build/version.properties 2007-03-08 22:29:02 UTC (rev 2557)
+++ trunk/build/version.properties 2007-03-08 23:42:11 UTC (rev 2558)
@@ -5,8 +5,8 @@
specification.vendor=JBoss (
http://www.jboss.org)
specification.version=jbossws-1.2
-version.id=2.0.0.DEV
-repository.id=snapshot
+version.id=2.0.0.CR5
+repository.id=2.0.0.CR5
implementation.title=JBoss Web Services (JBossWS)
implementation.url=http://www.jboss.org/products/jbossws
@@ -17,7 +17,7 @@
apache-xmlsec=1.3.0
ibm-wsdl4j=1.5.2jboss
javassist=3.5.0.CR1
-jboss-jbossxb=1.0.0.CR9
+jboss-jbossxb=2.0.0.CR1
jboss-microcontainer=2.0.0.Beta3
jboss-remoting=2.2.0.Alpha7
sun-jaxb=2.0.3
Modified:
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptor.java
===================================================================
---
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptor.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptor.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -33,9 +33,9 @@
import org.jboss.mx.server.Invocation;
import org.jboss.mx.util.MBeanProxy;
import org.jboss.ws.core.server.AbstractServiceEndpointPublisher;
-import org.jboss.ws.core.server.KernelLocator;
import org.jboss.ws.core.server.ServiceEndpointDeployer;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.KernelLocator;
/**
* A deployer service that manages WS4EE compliant Web Services
Modified:
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorEJB21.java
===================================================================
---
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorEJB21.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorEJB21.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -31,8 +31,8 @@
import org.jboss.metadata.ApplicationMetaData;
import org.jboss.metadata.BeanMetaData;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.integration.jboss42.ServiceEndpointGeneratorEJB21;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCDeployment;
import org.jboss.ws.metadata.umdm.ResourceLoaderAdapter;
Modified:
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorJSE.java
===================================================================
---
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorJSE.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss40/src/java/org/jboss/ws/integration/jboss40/DeployerInterceptorJSE.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -33,12 +33,12 @@
import org.jboss.deployment.DeploymentInfo;
import org.jboss.metadata.WebMetaData;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.AbstractServiceEndpointPublisher;
import org.jboss.ws.core.server.JAXWSDeployment;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.AbstractServiceEndpointPublisher.RewriteResults;
import org.jboss.ws.core.server.UnifiedDeploymentInfo.DeploymentType;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCDeployment;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
import org.jboss.ws.metadata.umdm.ResourceLoaderAdapter;
Modified:
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptor.java
===================================================================
---
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptor.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptor.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -33,9 +33,9 @@
import org.jboss.mx.server.Invocation;
import org.jboss.mx.util.MBeanProxy;
import org.jboss.ws.core.server.AbstractServiceEndpointPublisher;
-import org.jboss.ws.core.server.KernelLocator;
import org.jboss.ws.core.server.ServiceEndpointDeployer;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.KernelLocator;
/**
* A deployer service that manages WS4EE compliant Web Services
Modified:
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21.java
===================================================================
---
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorEJB21.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -31,8 +31,8 @@
import org.jboss.metadata.ApplicationMetaData;
import org.jboss.metadata.BeanMetaData;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCDeployment;
import org.jboss.ws.metadata.umdm.ResourceLoaderAdapter;
import org.jboss.ws.metadata.umdm.UnifiedMetaData;
Modified:
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSE.java
===================================================================
---
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSE.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/DeployerInterceptorJSE.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -33,12 +33,12 @@
import org.jboss.deployment.DeploymentInfo;
import org.jboss.metadata.WebMetaData;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.AbstractServiceEndpointPublisher;
import org.jboss.ws.core.server.JAXWSDeployment;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.AbstractServiceEndpointPublisher.RewriteResults;
import org.jboss.ws.core.server.UnifiedDeploymentInfo.DeploymentType;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCDeployment;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
import org.jboss.ws.metadata.umdm.ResourceLoaderAdapter;
Modified:
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/URLLoaderAdapter.java
===================================================================
---
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/URLLoaderAdapter.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/URLLoaderAdapter.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -29,7 +29,7 @@
import java.net.URL;
import java.net.URLClassLoader;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.integration.UnifiedVirtualFile;
/**
* The default file adapter loads resources through an associated classloader.
Deleted:
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandler.java
===================================================================
---
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandler.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandler.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,87 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.integration.jboss42;
-
-// $Id$
-
-import java.io.ByteArrayOutputStream;
-import java.lang.reflect.AnnotatedElement;
-import java.net.URL;
-
-import javax.management.MBeanServer;
-import javax.naming.Context;
-import javax.naming.NamingException;
-import javax.xml.transform.Source;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.stream.StreamResult;
-
-import org.jboss.mx.util.MBeanServerLocator;
-import org.jboss.ws.core.jaxws.client.ServiceRefHandlerJAXWS;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.ServiceRefObjectFactory;
-
-/**
- * Binds a JAXWS @WebServiceRef object in the client's ENC
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 17-Jan-2007
- */
-public class WebServiceRefHandler implements WebServiceRefHandlerMBean
-{
- public void setupWebServiceRef(Context encCtx, String encName, AnnotatedElement
anElement, URL rootURL, Source metadata) throws NamingException
- {
- String xmlFragment = null;
- try
- {
- ByteArrayOutputStream baos = new ByteArrayOutputStream();
- StreamResult result = new StreamResult(baos);
- TransformerFactory tf = TransformerFactory.newInstance();
- tf.newTransformer().transform(metadata, result);
- xmlFragment = new String(baos.toByteArray());
- }
- catch (Exception ex)
- {
- throw new IllegalStateException("Cannot transform <service-ref>
metadata", ex);
- }
-
- ServiceRefObjectFactory factory = ServiceRefObjectFactory.newInstance();
- UnifiedServiceRefMetaData serviceRef = factory.parse(xmlFragment);
- serviceRef.setVfsRoot(new URLLoaderAdapter(rootURL));
-
- ServiceRefHandlerJAXWS handler = new ServiceRefHandlerJAXWS();
- handler.setupServiceRef(encCtx, encName, anElement, serviceRef);
- }
-
- public void create() throws Exception
- {
- MBeanServer server = MBeanServerLocator.locateJBoss();
- if (server != null)
- server.registerMBean(this, OBJECT_NAME);
- }
-
- public void destroy() throws Exception
- {
- MBeanServer server = MBeanServerLocator.locateJBoss();
- if (server != null)
- server.unregisterMBean(OBJECT_NAME);
- }
-}
Deleted:
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandlerMBean.java
===================================================================
---
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandlerMBean.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss42/src/java/org/jboss/ws/integration/jboss42/WebServiceRefHandlerMBean.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,46 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
-*/
-package org.jboss.ws.integration.jboss42;
-
-
-import java.lang.reflect.AnnotatedElement;
-import java.net.URL;
-
-import javax.management.ObjectName;
-import javax.naming.Context;
-import javax.naming.NamingException;
-import javax.xml.transform.Source;
-
-import org.jboss.ws.core.utils.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface WebServiceRefHandlerMBean
-{
- // default object name
- public static final ObjectName OBJECT_NAME =
ObjectNameFactory.create("jboss.ws:service=WebServiceRefHandler");
-
- /** Binds a JAXWS WebServiceRef into the callers ENC
- */
- void setupWebServiceRef(Context encCtx, String encName, AnnotatedElement enElement,
URL rootURL, Source metadata) throws NamingException;
-}
Modified:
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/AbstractDeployer.java
===================================================================
---
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/AbstractDeployer.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/AbstractDeployer.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -29,10 +29,10 @@
import org.jboss.kernel.spi.registry.KernelRegistry;
import org.jboss.kernel.spi.registry.KernelRegistryEntry;
import org.jboss.ws.core.server.AbstractServiceEndpointPublisher;
-import org.jboss.ws.core.server.KernelLocator;
import org.jboss.ws.core.server.ServiceEndpointDeployer;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.UnifiedDeploymentInfo.DeploymentType;
+import org.jboss.ws.integration.KernelLocator;
/**
* An abstract web service deployer.
Modified:
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/JAXRPCDeployerJSE.java
===================================================================
---
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/JAXRPCDeployerJSE.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/JAXRPCDeployerJSE.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -27,9 +27,9 @@
import org.jboss.deployers.spi.deployer.DeploymentUnit;
import org.jboss.metadata.WebMetaData;
import org.jboss.virtual.VirtualFile;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
import org.jboss.ws.core.server.UnifiedDeploymentInfo.DeploymentType;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCDeployment;
/**
Modified:
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceEndpointLifecycleDeployer.java
===================================================================
---
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceEndpointLifecycleDeployer.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceEndpointLifecycleDeployer.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -31,9 +31,9 @@
import org.jboss.kernel.spi.registry.KernelRegistry;
import org.jboss.kernel.spi.registry.KernelRegistryEntry;
import org.jboss.metadata.WebMetaData;
-import org.jboss.ws.core.server.KernelLocator;
import org.jboss.ws.core.server.ServiceEndpointDeployer;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.KernelLocator;
/**
* A deployer that starts and stops web service deployments
Deleted:
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java
===================================================================
---
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,108 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.integration.jboss50;
-
-// $Id$
-
-import java.io.IOException;
-import java.lang.reflect.AnnotatedElement;
-
-import javax.management.MBeanServer;
-import javax.naming.Context;
-import javax.naming.NamingException;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.MBeanServerLocator;
-import org.jboss.virtual.VirtualFile;
-import org.jboss.ws.core.jaxrpc.client.ServiceRefHandlerJAXRPC;
-import org.jboss.ws.core.jaxws.client.ServiceRefHandlerJAXWS;
-import org.jboss.ws.core.utils.DOMUtils;
-import org.jboss.ws.core.utils.DOMWriter;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.ServiceRefObjectFactory;
-import org.w3c.dom.Element;
-
-/**
- * Binds a JAXRPC Service object in the client's ENC for every service-ref element in
the
- * deployment descriptor.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 04-Nov-2006
- */
-public class ServiceRefHandler implements ServiceRefHandlerMBean
-{
- // logging support
- private static Logger log = Logger.getLogger(ServiceRefHandler.class);
-
- /**
- * Binds a Service into the callers ENC for every service-ref element
- */
- public void setupServiceRef(Context encCtx, String encName, AnnotatedElement
anElement, VirtualFile vfsRoot, String xmlFragment) throws NamingException
- {
- try
- {
- Element root = DOMUtils.parse(xmlFragment);
- if (log.isDebugEnabled())
- log.debug("setupServiceRef\n" + DOMWriter.printNode(root, true));
- }
- catch (IOException e)
- {
- log.error("Invalid service-ref: " + xmlFragment);
- }
-
- ServiceRefObjectFactory factory = ServiceRefObjectFactory.newInstance();
- UnifiedServiceRefMetaData serviceRef = factory.parse(xmlFragment);
- serviceRef.setVfsRoot(new VirtualFileAdaptor(vfsRoot));
-
- if (isServiceRefJaxRpc(serviceRef))
- {
- ServiceRefHandlerJAXRPC handler = new ServiceRefHandlerJAXRPC();
- handler.setupServiceRef(encCtx, encName, serviceRef);
- }
- else
- {
- ServiceRefHandlerJAXWS handler = new ServiceRefHandlerJAXWS();
- handler.setupServiceRef(encCtx, encName, anElement, serviceRef);
- }
- }
-
- private boolean isServiceRefJaxRpc(UnifiedServiceRefMetaData serviceRef)
- {
- // The <service-interface> is a required element
- // for JAXRPC and not defined for JAXWS
- return serviceRef.getServiceInterface() != null;
- }
-
- public void create() throws Exception
- {
- MBeanServer server = MBeanServerLocator.locateJBoss();
- if (server != null)
- server.registerMBean(this, OBJECT_NAME);
- }
-
- public void destroy() throws Exception
- {
- MBeanServer server = MBeanServerLocator.locateJBoss();
- if (server != null)
- server.unregisterMBean(OBJECT_NAME);
- }
-}
Deleted:
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandlerMBean.java
===================================================================
---
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandlerMBean.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/ServiceRefHandlerMBean.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -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.integration.jboss50;
-
-import java.lang.reflect.AnnotatedElement;
-
-import javax.management.ObjectName;
-import javax.naming.Context;
-import javax.naming.NamingException;
-
-import org.jboss.virtual.VirtualFile;
-import org.jboss.ws.core.utils.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface ServiceRefHandlerMBean
-{
- // default object name
- public static final ObjectName OBJECT_NAME =
ObjectNameFactory.create("jboss.ws:service=ServiceRefHandler");
-
- /**
- * Binds a Service into the callers ENC for every service-ref element
- */
- void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement,
VirtualFile vfsRoot, String xmlFragment) throws NamingException;
-}
Modified:
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/VirtualFileAdaptor.java
===================================================================
---
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/VirtualFileAdaptor.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss50/src/java/org/jboss/ws/integration/jboss50/VirtualFileAdaptor.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -25,7 +25,7 @@
import java.net.URL;
import org.jboss.virtual.VirtualFile;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.integration.UnifiedVirtualFile;
// $Id$
Modified:
trunk/integration-jboss50/src/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml
===================================================================
---
trunk/integration-jboss50/src/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-jboss50/src/resources/jbossws.deployer/META-INF/jbossws-deployer-beans.xml 2007-03-08
23:42:11 UTC (rev 2558)
@@ -2,7 +2,7 @@
<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="KernelLocator"
class="org.jboss.ws.core.server.KernelLocator">
+ <bean name="KernelLocator"
class="org.jboss.ws.integration.KernelLocator">
<property name="kernel"><inject
bean="jboss.kernel:service=Kernel"/></property>
</bean>
@@ -48,7 +48,7 @@
</bean>
<!-- Bind Service objects in client environment context -->
- <bean name="ServiceRefHandler"
class="org.jboss.ws.integration.jboss50.ServiceRefHandler"/>
+ <bean name="ServiceRefHandler"
class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/>
<!-- A subscription manager for WS-Eventing -->
<bean name="SubscriptionManager"
class="org.jboss.ws.extensions.eventing.mgmt.SubscriptionManager"/>
Modified:
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/KernelBootstrap.java
===================================================================
---
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/KernelBootstrap.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/KernelBootstrap.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -28,7 +28,7 @@
import org.jboss.kernel.plugins.bootstrap.basic.BasicBootstrap;
import org.jboss.kernel.plugins.deployment.xml.BeanXMLDeployer;
import org.jboss.logging.Logger;
-import org.jboss.ws.core.server.KernelLocator;
+import org.jboss.ws.integration.KernelLocator;
/**
* Bootstrap the microkernel in Tomcat
Modified:
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/TomcatServiceEndpointServlet.java
===================================================================
---
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/TomcatServiceEndpointServlet.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/integration-tomcat/src/java/org/jboss/ws/integration/tomcat/TomcatServiceEndpointServlet.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -37,12 +37,12 @@
import org.jboss.kernel.spi.registry.KernelRegistryEntry;
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.AbstractServiceEndpointServlet;
import org.jboss.ws.core.server.JAXWSDeployment;
-import org.jboss.ws.core.server.KernelLocator;
import org.jboss.ws.core.server.ServiceEndpointDeployer;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.KernelLocator;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCDeployment;
import org.jboss.ws.metadata.umdm.ResourceLoaderAdapter;
Modified: trunk/jbossws-core/build.xml
===================================================================
--- trunk/jbossws-core/build.xml 2007-03-08 22:29:02 UTC (rev 2557)
+++ trunk/jbossws-core/build.xml 2007-03-08 23:42:11 UTC (rev 2558)
@@ -64,7 +64,6 @@
<include name="javax/jws/**"/>
<include name="org/jboss/annotation/**"/>
<include name="org/jboss/ws/**"/>
- <exclude name="org/jboss/ws/integration/**"/>
<classpath path="${core.output.classes14.dir}"/>
<classpath refid="core.classpath"/>
</javac>
@@ -142,6 +141,14 @@
</fileset>
</jar>
+ <!-- Build jbossws-integration.jar -->
+ <mkdir dir="${core.output.lib.dir}"/>
+ <jar jarfile="${core.output.lib.dir}/jbossws-integration.jar"
manifest="${etc.dir}/default.mf">
+ <fileset dir="${core.output.classes.dir}">
+ <include name="org/jboss/ws/integration/**"/>
+ </fileset>
+ </jar>
+
<!-- Build jbossws-client.jar -->
<jar jarfile="${core.output.lib.dir}/jbossws-client.jar"
manifest="${etc.dir}/default.mf">
<fileset dir="${core.output.classes.dir}">
Deleted: trunk/jbossws-core/src/java/org/jboss/ws/core/UnifiedVirtualFile.java
===================================================================
--- trunk/jbossws-core/src/java/org/jboss/ws/core/UnifiedVirtualFile.java 2007-03-08
22:29:02 UTC (rev 2557)
+++ trunk/jbossws-core/src/java/org/jboss/ws/core/UnifiedVirtualFile.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,42 +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.core;
-
-// $Id$
-
-import java.io.IOException;
-import java.io.Serializable;
-import java.net.URL;
-
-/**
- * An adaptor to a VirtualFile from jboss-vfs.jar
- * jboss-vfs cannot be used in jboss-4.x because of its dependeny on
jboss-common-core.jar
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 05-May-2006
- */
-public interface UnifiedVirtualFile extends Serializable
-{
- UnifiedVirtualFile findChild(String child) throws IOException;
-
- URL toURL();
-}
Copied: trunk/jbossws-core/src/java/org/jboss/ws/core/client (from rev 2557,
branches/jbossws-1.2.0/jbossws-core/src/java/org/jboss/ws/core/client)
Deleted: trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,117 +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.core.client;
-
-// $Id$
-
-import java.lang.reflect.AnnotatedElement;
-import java.util.Collection;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.core.jaxrpc.client.ServiceRefHandlerJAXRPC;
-import org.jboss.ws.core.jaxws.client.ServiceRefHandlerJAXWS;
-import org.jboss.ws.integration.ServiceRefElement;
-import org.jboss.ws.integration.ServiceRefHandler;
-import org.jboss.ws.integration.ServiceRefMetaData;
-import org.jboss.ws.integration.UnifiedVirtualFile;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-/**
- * Bind service refs in the client's ENC for every service-ref element in the
- * deployment descriptor.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 04-Nov-2006
- */
-public class ServiceRefHandlerImpl implements ServiceRefHandler
-{
- // logging support
- private static Logger log = Logger.getLogger(ServiceRefHandlerImpl.class);
-
- private ServiceRefObjectFactory objectFactory = new ServiceRefObjectFactory();
-
- public ServiceRefMetaData newMetaData()
- {
- return new UnifiedServiceRefMetaData();
- }
-
- public void setupServiceRefs(Context envCtx, UnifiedVirtualFile vfsRoot,
Collection<ServiceRefMetaData> serviceRefs) throws NamingException
- {
- for (ServiceRefMetaData sref : serviceRefs)
- {
- String encName = sref.getServiceRefName();
- setupServiceRef(envCtx, encName, vfsRoot, sref);
- }
- }
-
- public void setupServiceRef(Context encCtx, String encName, UnifiedVirtualFile
vfsRoot, ServiceRefMetaData sref) throws NamingException
- {
- if (sref.isProcessed())
- {
- log.warn("Attempt to rebind service-ref: " + sref);
- return;
- }
-
- UnifiedServiceRefMetaData serviceRef = (UnifiedServiceRefMetaData)sref;
- serviceRef.setVfsRoot(vfsRoot);
- try
- {
- if (isServiceRefJaxRpc(serviceRef))
- {
- ServiceRefHandlerJAXRPC handler = new ServiceRefHandlerJAXRPC();
- handler.setupServiceRef(encCtx, encName, serviceRef);
- }
- else
- {
- AnnotatedElement anElement = sref.getAnnotatedElement();
- ServiceRefHandlerJAXWS handler = new ServiceRefHandlerJAXWS();
- handler.setupServiceRef(encCtx, encName, anElement, serviceRef);
- }
- }
- finally
- {
- sref.setProcessed(true);
- }
- }
-
- public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, Attributes attrs)
- {
- return objectFactory.newChild(ref, navigator, namespaceURI, localName, attrs);
- }
-
- public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, String value)
- {
- objectFactory.setValue(ref, navigator, namespaceURI, localName, value);
- }
-
- private boolean isServiceRefJaxRpc(UnifiedServiceRefMetaData serviceRef)
- {
- // The <service-interface> is a required element
- // for JAXRPC and not defined for JAXWS
- return serviceRef.getServiceInterface() != null;
- }
-}
Copied: trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java
(from rev 2557,
branches/jbossws-1.2.0/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java)
===================================================================
--- trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java
(rev 0)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -0,0 +1,117 @@
+/*
+ * 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.core.client;
+
+// $Id$
+
+import java.lang.reflect.AnnotatedElement;
+import java.util.Collection;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.core.jaxrpc.client.ServiceRefHandlerJAXRPC;
+import org.jboss.ws.core.jaxws.client.ServiceRefHandlerJAXWS;
+import org.jboss.ws.integration.ServiceRefElement;
+import org.jboss.ws.integration.ServiceRefHandler;
+import org.jboss.ws.integration.ServiceRefMetaData;
+import org.jboss.ws.integration.UnifiedVirtualFile;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+import org.jboss.xb.binding.UnmarshallingContext;
+import org.xml.sax.Attributes;
+
+/**
+ * Bind service refs in the client's ENC for every service-ref element in the
+ * deployment descriptor.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 04-Nov-2006
+ */
+public class ServiceRefHandlerImpl implements ServiceRefHandler
+{
+ // logging support
+ private static Logger log = Logger.getLogger(ServiceRefHandlerImpl.class);
+
+ private ServiceRefObjectFactory objectFactory = new ServiceRefObjectFactory();
+
+ public ServiceRefMetaData newMetaData()
+ {
+ return new UnifiedServiceRefMetaData();
+ }
+
+ public void setupServiceRefs(Context envCtx, UnifiedVirtualFile vfsRoot,
Collection<ServiceRefMetaData> serviceRefs) throws NamingException
+ {
+ for (ServiceRefMetaData sref : serviceRefs)
+ {
+ String encName = sref.getServiceRefName();
+ setupServiceRef(envCtx, encName, vfsRoot, sref);
+ }
+ }
+
+ public void setupServiceRef(Context encCtx, String encName, UnifiedVirtualFile
vfsRoot, ServiceRefMetaData sref) throws NamingException
+ {
+ if (sref.isProcessed())
+ {
+ log.warn("Attempt to rebind service-ref: " + sref);
+ return;
+ }
+
+ UnifiedServiceRefMetaData serviceRef = (UnifiedServiceRefMetaData)sref;
+ serviceRef.setVfsRoot(vfsRoot);
+ try
+ {
+ if (isServiceRefJaxRpc(serviceRef))
+ {
+ ServiceRefHandlerJAXRPC handler = new ServiceRefHandlerJAXRPC();
+ handler.setupServiceRef(encCtx, encName, serviceRef);
+ }
+ else
+ {
+ AnnotatedElement anElement = sref.getAnnotatedElement();
+ ServiceRefHandlerJAXWS handler = new ServiceRefHandlerJAXWS();
+ handler.setupServiceRef(encCtx, encName, anElement, serviceRef);
+ }
+ }
+ finally
+ {
+ sref.setProcessed(true);
+ }
+ }
+
+ public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, Attributes attrs)
+ {
+ return objectFactory.newChild(ref, navigator, namespaceURI, localName, attrs);
+ }
+
+ public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, String value)
+ {
+ objectFactory.setValue(ref, navigator, namespaceURI, localName, value);
+ }
+
+ private boolean isServiceRefJaxRpc(UnifiedServiceRefMetaData serviceRef)
+ {
+ // The <service-interface> is a required element
+ // for JAXRPC and not defined for JAXWS
+ return serviceRef.getServiceInterface() != null;
+ }
+}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,298 +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.core.client;
-
-// $Id$
-
-import javax.xml.namespace.QName;
-
-import org.jboss.ws.integration.ServiceRefElement;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedCallPropertyMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.ws.metadata.j2ee.serviceref.UnifiedStubPropertyMetaData;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-/**
- * A object model factory for <service-ref>
- *
- * @author Thomas.Diesler(a)jboss.com
- */
-public class ServiceRefObjectFactory
-{
- public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (ref instanceof UnifiedHandlerChainsMetaData)
- child = newChild((UnifiedHandlerChainsMetaData)ref, navigator, namespaceURI,
localName, attrs);
- else if (ref instanceof UnifiedHandlerMetaData)
- child = newChild((UnifiedHandlerMetaData)ref, navigator, namespaceURI,
localName, attrs);
- else if (ref instanceof UnifiedPortComponentRefMetaData)
- child = newChild((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI,
localName, attrs);
- else if (ref instanceof UnifiedServiceRefMetaData)
- child = newChild((UnifiedServiceRefMetaData)ref, navigator, namespaceURI,
localName, attrs);
- return child;
- }
-
- public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, String value)
- {
- if (ref instanceof UnifiedCallPropertyMetaData)
- setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName,
value);
- else if (ref instanceof UnifiedHandlerChainMetaData)
- setValue((UnifiedHandlerChainMetaData)ref, navigator, namespaceURI, localName,
value);
- else if (ref instanceof UnifiedHandlerMetaData)
- setValue((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName,
value);
- else if (ref instanceof UnifiedInitParamMetaData)
- setValue((UnifiedInitParamMetaData)ref, navigator, namespaceURI, localName,
value);
- else if (ref instanceof UnifiedPortComponentRefMetaData)
- setValue((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI,
localName, value);
- else if (ref instanceof UnifiedServiceRefMetaData)
- setValue((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName,
value);
- else if (ref instanceof UnifiedStubPropertyMetaData)
- setValue((UnifiedStubPropertyMetaData)ref, navigator, namespaceURI, localName,
value);
-
- }
-
- private void setValue(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- /* Standard properties */
- if (localName.equals("service-ref-name"))
- {
- ref.setServiceRefName(value);
- }
- else if (localName.equals("service-interface"))
- {
- ref.setServiceInterface(value);
- }
- else if (localName.equals("service-ref-type"))
- {
- ref.setServiceRefType(value);
- }
- else if (localName.equals("wsdl-file"))
- {
- ref.setWsdlFile(value);
- }
- else if (localName.equals("jaxrpc-mapping-file"))
- {
- ref.setMappingFile(value);
- }
- else if (localName.equals("service-qname"))
- {
- ref.setServiceQName(QName.valueOf(value));
- }
-
- /* JBoss properties */
- else if (localName.equals("service-impl-class"))
- {
- ref.setServiceImplClass(value);
- }
- else if (localName.equals("config-name"))
- {
- ref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- ref.setConfigFile(value);
- }
- else if (localName.equals("wsdl-override"))
- {
- ref.setWsdlOverride(value);
- }
- else if (localName.equals("handler-chain"))
- {
- ref.setHandlerChain(value);
- }
- }
-
- private Object newChild(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("port-component-ref"))
- {
- child = new UnifiedPortComponentRefMetaData(ref);
- ref.addPortComponentRef((UnifiedPortComponentRefMetaData)child);
- }
- else if (localName.equals("handler"))
- {
- child = new UnifiedHandlerMetaData();
- ref.addHandler((UnifiedHandlerMetaData)child);
- }
- else if (localName.equals("handler-chains"))
- {
- child = new UnifiedHandlerChainsMetaData();
- ref.setHandlerChains((UnifiedHandlerChainsMetaData)child);
- }
- else if (localName.equals("call-property"))
- {
- child = new UnifiedCallPropertyMetaData();
- ref.addCallProperty((UnifiedCallPropertyMetaData)child);
- }
- return child;
- }
-
- private Object newChild(UnifiedHandlerChainsMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("handler-chain"))
- {
- child = new UnifiedHandlerChainMetaData();
- ref.addHandlerChain((UnifiedHandlerChainMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedPortComponentRefMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-endpoint-interface"))
- {
- ref.setServiceEndpointInterface(value);
- }
- else if (localName.equals("enable-mtom"))
- {
- ref.setEnableMTOM(Boolean.valueOf(value));
- }
- else if (localName.equals("port-component-link"))
- {
- ref.setPortComponentLink(value);
- }
- else if (localName.equals("port-qname"))
- {
- ref.setPortQName(QName.valueOf(value));
- }
- else if (localName.equals("config-name"))
- {
- ref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- ref.setConfigFile(value);
- }
- }
-
- private Object newChild(UnifiedPortComponentRefMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("call-property"))
- {
- child = new UnifiedCallPropertyMetaData();
- ref.addCallProperty((UnifiedCallPropertyMetaData)child);
- }
- if (localName.equals("stub-property"))
- {
- child = new UnifiedStubPropertyMetaData();
- ref.addStubProperty((UnifiedStubPropertyMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedHandlerChainMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-name-pattern"))
- {
- ref.setServiceNamePattern(QName.valueOf(value));
- }
- else if (localName.equals("port-name-pattern"))
- {
- ref.setPortNamePattern(QName.valueOf(value));
- }
- else if (localName.equals("protocol-binding"))
- {
- ref.setProtocolBindings(value);
- }
- }
-
- private void setValue(UnifiedHandlerMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("handler-name"))
- {
- ref.setHandlerName(value);
- }
- else if (localName.equals("handler-class"))
- {
- ref.setHandlerClass(value);
- }
- else if (localName.equals("soap-header"))
- {
- ref.addSoapHeader(navigator.resolveQName(value));
- }
- else if (localName.equals("soap-role"))
- {
- ref.addSoapRole(value);
- }
- else if (localName.equals("port-name"))
- {
- ref.addPortName(value);
- }
- }
-
- private Object newChild(UnifiedHandlerMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("init-param"))
- {
- child = new UnifiedInitParamMetaData();
- ref.addInitParam((UnifiedInitParamMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedInitParamMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("param-name"))
- {
- ref.setParamName(value);
- }
- else if (localName.equals("param-value"))
- {
- ref.setParamValue(value);
- }
- }
-
- private void setValue(UnifiedCallPropertyMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-
- private void setValue(UnifiedStubPropertyMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-}
Copied: trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java
(from rev 2557,
branches/jbossws-1.2.0/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java)
===================================================================
--- trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java
(rev 0)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -0,0 +1,298 @@
+/*
+ * 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.core.client;
+
+// $Id$
+
+import javax.xml.namespace.QName;
+
+import org.jboss.ws.integration.ServiceRefElement;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedCallPropertyMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+import org.jboss.ws.metadata.j2ee.serviceref.UnifiedStubPropertyMetaData;
+import org.jboss.xb.binding.UnmarshallingContext;
+import org.xml.sax.Attributes;
+
+/**
+ * A object model factory for <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ */
+public class ServiceRefObjectFactory
+{
+ public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (ref instanceof UnifiedHandlerChainsMetaData)
+ child = newChild((UnifiedHandlerChainsMetaData)ref, navigator, namespaceURI,
localName, attrs);
+ else if (ref instanceof UnifiedHandlerMetaData)
+ child = newChild((UnifiedHandlerMetaData)ref, navigator, namespaceURI,
localName, attrs);
+ else if (ref instanceof UnifiedPortComponentRefMetaData)
+ child = newChild((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI,
localName, attrs);
+ else if (ref instanceof UnifiedServiceRefMetaData)
+ child = newChild((UnifiedServiceRefMetaData)ref, navigator, namespaceURI,
localName, attrs);
+ return child;
+ }
+
+ public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String
namespaceURI, String localName, String value)
+ {
+ if (ref instanceof UnifiedCallPropertyMetaData)
+ setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName,
value);
+ else if (ref instanceof UnifiedHandlerChainMetaData)
+ setValue((UnifiedHandlerChainMetaData)ref, navigator, namespaceURI, localName,
value);
+ else if (ref instanceof UnifiedHandlerMetaData)
+ setValue((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName,
value);
+ else if (ref instanceof UnifiedInitParamMetaData)
+ setValue((UnifiedInitParamMetaData)ref, navigator, namespaceURI, localName,
value);
+ else if (ref instanceof UnifiedPortComponentRefMetaData)
+ setValue((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI,
localName, value);
+ else if (ref instanceof UnifiedServiceRefMetaData)
+ setValue((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName,
value);
+ else if (ref instanceof UnifiedStubPropertyMetaData)
+ setValue((UnifiedStubPropertyMetaData)ref, navigator, namespaceURI, localName,
value);
+
+ }
+
+ private void setValue(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ /* Standard properties */
+ if (localName.equals("service-ref-name"))
+ {
+ ref.setServiceRefName(value);
+ }
+ else if (localName.equals("service-interface"))
+ {
+ ref.setServiceInterface(value);
+ }
+ else if (localName.equals("service-ref-type"))
+ {
+ ref.setServiceRefType(value);
+ }
+ else if (localName.equals("wsdl-file"))
+ {
+ ref.setWsdlFile(value);
+ }
+ else if (localName.equals("jaxrpc-mapping-file"))
+ {
+ ref.setMappingFile(value);
+ }
+ else if (localName.equals("service-qname"))
+ {
+ ref.setServiceQName(QName.valueOf(value));
+ }
+
+ /* JBoss properties */
+ else if (localName.equals("service-impl-class"))
+ {
+ ref.setServiceImplClass(value);
+ }
+ else if (localName.equals("config-name"))
+ {
+ ref.setConfigName(value);
+ }
+ else if (localName.equals("config-file"))
+ {
+ ref.setConfigFile(value);
+ }
+ else if (localName.equals("wsdl-override"))
+ {
+ ref.setWsdlOverride(value);
+ }
+ else if (localName.equals("handler-chain"))
+ {
+ ref.setHandlerChain(value);
+ }
+ }
+
+ private Object newChild(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("port-component-ref"))
+ {
+ child = new UnifiedPortComponentRefMetaData(ref);
+ ref.addPortComponentRef((UnifiedPortComponentRefMetaData)child);
+ }
+ else if (localName.equals("handler"))
+ {
+ child = new UnifiedHandlerMetaData();
+ ref.addHandler((UnifiedHandlerMetaData)child);
+ }
+ else if (localName.equals("handler-chains"))
+ {
+ child = new UnifiedHandlerChainsMetaData();
+ ref.setHandlerChains((UnifiedHandlerChainsMetaData)child);
+ }
+ else if (localName.equals("call-property"))
+ {
+ child = new UnifiedCallPropertyMetaData();
+ ref.addCallProperty((UnifiedCallPropertyMetaData)child);
+ }
+ return child;
+ }
+
+ private Object newChild(UnifiedHandlerChainsMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("handler-chain"))
+ {
+ child = new UnifiedHandlerChainMetaData();
+ ref.addHandlerChain((UnifiedHandlerChainMetaData)child);
+ }
+ return child;
+ }
+
+ private void setValue(UnifiedPortComponentRefMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("service-endpoint-interface"))
+ {
+ ref.setServiceEndpointInterface(value);
+ }
+ else if (localName.equals("enable-mtom"))
+ {
+ ref.setEnableMTOM(Boolean.valueOf(value));
+ }
+ else if (localName.equals("port-component-link"))
+ {
+ ref.setPortComponentLink(value);
+ }
+ else if (localName.equals("port-qname"))
+ {
+ ref.setPortQName(QName.valueOf(value));
+ }
+ else if (localName.equals("config-name"))
+ {
+ ref.setConfigName(value);
+ }
+ else if (localName.equals("config-file"))
+ {
+ ref.setConfigFile(value);
+ }
+ }
+
+ private Object newChild(UnifiedPortComponentRefMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("call-property"))
+ {
+ child = new UnifiedCallPropertyMetaData();
+ ref.addCallProperty((UnifiedCallPropertyMetaData)child);
+ }
+ if (localName.equals("stub-property"))
+ {
+ child = new UnifiedStubPropertyMetaData();
+ ref.addStubProperty((UnifiedStubPropertyMetaData)child);
+ }
+ return child;
+ }
+
+ private void setValue(UnifiedHandlerChainMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("service-name-pattern"))
+ {
+ ref.setServiceNamePattern(QName.valueOf(value));
+ }
+ else if (localName.equals("port-name-pattern"))
+ {
+ ref.setPortNamePattern(QName.valueOf(value));
+ }
+ else if (localName.equals("protocol-binding"))
+ {
+ ref.setProtocolBindings(value);
+ }
+ }
+
+ private void setValue(UnifiedHandlerMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("handler-name"))
+ {
+ ref.setHandlerName(value);
+ }
+ else if (localName.equals("handler-class"))
+ {
+ ref.setHandlerClass(value);
+ }
+ else if (localName.equals("soap-header"))
+ {
+ ref.addSoapHeader(navigator.resolveQName(value));
+ }
+ else if (localName.equals("soap-role"))
+ {
+ ref.addSoapRole(value);
+ }
+ else if (localName.equals("port-name"))
+ {
+ ref.addPortName(value);
+ }
+ }
+
+ private Object newChild(UnifiedHandlerMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("init-param"))
+ {
+ child = new UnifiedInitParamMetaData();
+ ref.addInitParam((UnifiedInitParamMetaData)child);
+ }
+ return child;
+ }
+
+ private void setValue(UnifiedInitParamMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("param-name"))
+ {
+ ref.setParamName(value);
+ }
+ else if (localName.equals("param-value"))
+ {
+ ref.setParamValue(value);
+ }
+ }
+
+ private void setValue(UnifiedCallPropertyMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("prop-name"))
+ {
+ ref.setPropName(value);
+ }
+ else if (localName.equals("prop-value"))
+ {
+ ref.setPropValue(value);
+ }
+ }
+
+ private void setValue(UnifiedStubPropertyMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("prop-name"))
+ {
+ ref.setPropName(value);
+ }
+ else if (localName.equals("prop-value"))
+ {
+ ref.setPropValue(value);
+ }
+ }
+}
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -47,12 +47,11 @@
*/
public void setupServiceRef(Context encCtx, String encName, UnifiedServiceRefMetaData
serviceRef) throws NamingException
{
- String serviceRefName = serviceRef.getServiceRefName();
- ServiceReferenceable ref = new ServiceReferenceable(serviceRef);
+ String externalName = encCtx.getNameInNamespace() + "/" + encName;
+ log.info("setupServiceRef [jndi=" + externalName + "]");
// Do not use rebind, the binding should be unique
+ ServiceReferenceable ref = new ServiceReferenceable(serviceRef);
Util.bind(encCtx, encName, ref);
-
- log.debug("<service-ref> bound to: java:comp/env/" +
serviceRefName);
}
}
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -36,9 +36,9 @@
import javax.naming.StringRefAddr;
import org.jboss.logging.Logger;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.ServiceEndpointManager;
import org.jboss.ws.core.server.ServiceEndpointManagerFactory;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
Modified: trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceExt.java
===================================================================
--- trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceExt.java 2007-03-08
22:29:02 UTC (rev 2557)
+++ trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceExt.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -34,7 +34,7 @@
import org.jboss.ws.WSException;
import org.jboss.ws.core.ConfigProvider;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
import org.jboss.ws.metadata.umdm.ServiceMetaData;
import org.jboss.ws.metadata.wsse.WSSecurityConfigFactory;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -99,9 +99,9 @@
else if (anElement instanceof Method)
targetClass = ((Method)anElement).getParameterTypes()[0];
- String externalName = encCtx.getNameInNamespace() + "/" + encName;
String targetClassName = (targetClass != null ? targetClass.getName() : null);
- log.debug("setupWebServiceRef [jndi=" + externalName +
",target=" + targetClassName + "]");
+ String externalName = encCtx.getNameInNamespace() + "/" + encName;
+ log.info("setupServiceRef [jndi=" + externalName + ",target=" +
targetClassName + "]");
String serviceImplClass = null;
@@ -164,7 +164,5 @@
// Do not use rebind, the binding should be unique
// [JBWS-1499] - Revisit WebServiceRefHandler JNDI rebind
Util.rebind(encCtx, encName, new ServiceReferenceable(serviceImplClass,
targetClassName, serviceRef));
-
- log.debug("<service-ref> bound to: java:comp/env/" + encName);
}
}
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/spi/ServiceDelegateImpl.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/spi/ServiceDelegateImpl.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/jaxws/spi/ServiceDelegateImpl.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -48,12 +48,12 @@
import org.jboss.logging.Logger;
import org.jboss.util.NotImplementedException;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.jaxws.client.ClientImpl;
import org.jboss.ws.core.jaxws.client.ClientProxy;
import org.jboss.ws.core.jaxws.client.DispatchImpl;
import org.jboss.ws.core.jaxws.client.ServiceObjectFactory;
import org.jboss.ws.core.jaxws.handler.HandlerResolverImpl;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.builder.jaxws.JAXWSClientMetaDataBuilder;
import org.jboss.ws.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
Deleted: trunk/jbossws-core/src/java/org/jboss/ws/core/server/KernelLocator.java
===================================================================
--- trunk/jbossws-core/src/java/org/jboss/ws/core/server/KernelLocator.java 2007-03-08
22:29:02 UTC (rev 2557)
+++ trunk/jbossws-core/src/java/org/jboss/ws/core/server/KernelLocator.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,47 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.core.server;
-
-//$Id: WebServiceDeployer.java 312 2006-05-11 10:49:22Z thomas.diesler(a)jboss.com $
-
-import org.jboss.kernel.Kernel;
-
-/**
- * Locate the single instance of the kernel
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 12-May-2006
- */
-public class KernelLocator
-{
- private static Kernel kernel;
-
- public static Kernel getKernel()
- {
- return KernelLocator.kernel;
- }
-
- public void setKernel(Kernel kernel)
- {
- KernelLocator.kernel = kernel;
- }
-}
Modified: trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServerConfigFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServerConfigFactory.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServerConfigFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,6 +23,7 @@
import org.jboss.kernel.spi.registry.KernelRegistry;
import org.jboss.logging.Logger;
+import org.jboss.ws.integration.KernelLocator;
// $Id: ServiceEndpointManagerFactory.java 293 2006-05-08 16:31:50Z
thomas.diesler(a)jboss.com $
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServiceEndpointManagerFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServiceEndpointManagerFactory.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/server/ServiceEndpointManagerFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,6 +23,7 @@
import org.jboss.kernel.spi.registry.KernelRegistry;
import org.jboss.kernel.spi.registry.KernelRegistryEntry;
+import org.jboss.ws.integration.KernelLocator;
// $Id$
Modified: trunk/jbossws-core/src/java/org/jboss/ws/core/server/UnifiedDeploymentInfo.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/core/server/UnifiedDeploymentInfo.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/core/server/UnifiedDeploymentInfo.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -31,7 +31,7 @@
import javax.management.ObjectName;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.integration.UnifiedVirtualFile;
/**
* The container independent deployment info.
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/extensions/eventing/mgmt/SubscriptionManagerFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/extensions/eventing/mgmt/SubscriptionManagerFactory.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/extensions/eventing/mgmt/SubscriptionManagerFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -2,7 +2,7 @@
import org.jboss.kernel.spi.registry.KernelRegistry;
import org.jboss.kernel.spi.registry.KernelRegistryEntry;
-import org.jboss.ws.core.server.KernelLocator;
+import org.jboss.ws.integration.KernelLocator;
/**
* @author Heiko Braun, <heiko(a)openj.net>
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxrpc/WSSecurityHandler.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxrpc/WSSecurityHandler.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxrpc/WSSecurityHandler.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -33,8 +33,8 @@
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
import org.jboss.ws.core.CommonMessageContext;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.extensions.security.WSSecurityDispatcher;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
import org.jboss.ws.metadata.umdm.ServiceMetaData;
import org.jboss.ws.metadata.wsse.WSSecurityConfigFactory;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxws/WSSecurityHandler.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxws/WSSecurityHandler.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/extensions/security/jaxws/WSSecurityHandler.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -31,9 +31,9 @@
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
import org.jboss.ws.core.CommonMessageContext;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.jaxws.handler.GenericSOAPHandler;
import org.jboss.ws.extensions.security.WSSecurityDispatcher;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
import org.jboss.ws.metadata.umdm.ServiceMetaData;
import org.jboss.ws.metadata.wsse.WSSecurityConfigFactory;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCClientMetaDataBuilder.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCClientMetaDataBuilder.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCClientMetaDataBuilder.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -32,7 +32,7 @@
import org.jboss.logging.Logger;
import org.jboss.ws.Constants;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
import org.jboss.ws.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCDeployment.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCDeployment.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCDeployment.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -25,8 +25,8 @@
import java.net.URL;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.webservices.WebservicesFactory;
import org.jboss.ws.metadata.webservices.WebservicesMetaData;
import org.jboss.xb.binding.ObjectModelFactory;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxws/JAXWSClientMetaDataBuilder.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxws/JAXWSClientMetaDataBuilder.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/builder/jaxws/JAXWSClientMetaDataBuilder.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -32,8 +32,8 @@
import org.jboss.ws.Constants;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.jaxrpc.Style;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.umdm.ClientEndpointMetaData;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
import org.jboss.ws.metadata.umdm.OperationMetaData;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/config/JBossWSConfigFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/config/JBossWSConfigFactory.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/config/JBossWSConfigFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -28,8 +28,8 @@
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.config.binding.OMFactoryJAXRPC;
import org.jboss.ws.metadata.config.binding.OMFactoryJAXWS;
import org.jboss.ws.metadata.config.jaxrpc.ConfigRootJAXRPC;
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/CallPropertyMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/CallPropertyMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/CallPropertyMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
-*/
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-
-/**
- * @author Thomas.Diesler(a)jboss.org
- * @since 06-May-2004
- */
-public class CallPropertyMetaData implements Serializable
-{
- // The required <prop-name> element
- private String propName;
- // The required <prop-value> element
- private String propValue;
-
- public String getPropName()
- {
- return propName;
- }
-
- public void setPropName(String paramName)
- {
- this.propName = paramName;
- }
-
- public String getPropValue()
- {
- return propValue;
- }
-
- public void setPropValue(String paramValue)
- {
- this.propValue = paramValue;
- }
-
- public String toString()
- {
- return "[name=" + propName + ",value=" + propValue +
"]";
- }
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,82 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.xml.namespace.QName;
-
-/** The unified metdata data for a handler chain element
- *
- * @author Thomas.Diesler(a)jboss.org
- */
-public class HandlerChainMetaData implements Serializable
-{
- private QName serviceNamePattern;
- private QName portNamePattern;
- private String protocolBindings;
- private List<HandlerMetaData> handlers = new
ArrayList<HandlerMetaData>();
-
- public QName getPortNamePattern()
- {
- return portNamePattern;
- }
-
- public void setPortNamePattern(QName portNamePattern)
- {
- this.portNamePattern = portNamePattern;
- }
-
- public QName getServiceNamePattern()
- {
- return serviceNamePattern;
- }
-
- public void setServiceNamePattern(QName serviceNamePattern)
- {
- this.serviceNamePattern = serviceNamePattern;
- }
-
- public String getProtocolBindings()
- {
- return protocolBindings;
- }
-
- public void setProtocolBindings(String protocolBindings)
- {
- this.protocolBindings = protocolBindings;
- }
-
- public List<HandlerMetaData> getHandlers()
- {
- return handlers;
- }
-
- public void addHandler(HandlerMetaData handler)
- {
- handlers.add(handler);
- }
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerChainsMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,47 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-/** The unified metdata data for a handler chains element
- *
- * @author Thomas.Diesler(a)jboss.org
- */
-public class HandlerChainsMetaData implements Serializable
-{
- private List<HandlerChainMetaData> handlerChains = new
ArrayList<HandlerChainMetaData>();
-
- public List<HandlerChainMetaData> getHandlerChains()
- {
- return handlerChains;
- }
-
- public void addHandlerChain(HandlerChainMetaData handlerChain)
- {
- handlerChains.add(handlerChain);
- }
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/HandlerMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,148 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.ws.metadata.umdm.EndpointMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
-import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXWS;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
-
-/** The unified metdata data for a handler element
- *
- * @author Thomas.Diesler(a)jboss.org
- * @version $Revision$
- */
-public class HandlerMetaData implements Serializable
-{
- private HandlerChainMetaData handlerChain;
-
- // The required <handler-name> element
- private String handlerName;
- // The required <handler-class> element
- private String handlerClass;
- // The optional <init-param> elements
- private List<UnifiedInitParamMetaData> initParams = new
ArrayList<UnifiedInitParamMetaData>();
- // The optional <soap-header> elements
- private Set<QName> soapHeaders = new HashSet<QName>();
- // The optional <soap-role> elements
- private Set<String> soapRoles = new HashSet<String>();
- // The optional <port-name> elements, these only apply to webserve clients
- private Set<String> portNames = new HashSet<String>();
-
-
- public void setHandlerName(String value)
- {
- this.handlerName = value;
- }
-
- public String getHandlerName()
- {
- return handlerName;
- }
-
- public void setHandlerClass(String handlerClass)
- {
- this.handlerClass = handlerClass;
- }
-
- public String getHandlerClass()
- {
- return handlerClass;
- }
-
- public void addInitParam(UnifiedInitParamMetaData param)
- {
- initParams.add(param);
- }
-
- public List<UnifiedInitParamMetaData> getInitParams()
- {
- return initParams;
- }
-
- public void addSoapHeader(QName qName)
- {
- soapHeaders.add(qName);
- }
-
- public Set<QName> getSoapHeaders()
- {
- return soapHeaders;
- }
-
- public void addSoapRole(String value)
- {
- soapRoles.add(value);
- }
-
- public Set<String> getSoapRoles()
- {
- return soapRoles;
- }
-
- public Set<String> getPortNames()
- {
- return portNames;
- }
-
- public void addPortName(String value)
- {
- portNames.add(value);
- }
-
- public HandlerMetaDataJAXRPC getHandlerMetaDataJAXRPC (EndpointMetaData epMetaData,
HandlerType type)
- {
- HandlerMetaDataJAXRPC hmd = new HandlerMetaDataJAXRPC(epMetaData, type);
- hmd.setHandlerName(getHandlerName());
- hmd.setHandlerClassName(getHandlerClass());
- hmd.seiInitParams(getInitParams());
- hmd.setSoapHeaders(getSoapHeaders());
- hmd.setSoapRoles(getSoapRoles());
- hmd.setPortNames(getPortNames());
- return hmd;
- }
-
- public HandlerMetaDataJAXWS getHandlerMetaDataJAXWS (EndpointMetaData epMetaData,
HandlerType type)
- {
- HandlerMetaDataJAXWS hmd = new HandlerMetaDataJAXWS(epMetaData, type);
- hmd.setHandlerName(getHandlerName());
- hmd.setHandlerClassName(getHandlerClass());
- hmd.seiInitParams(getInitParams());
- if (handlerChain != null)
- {
- hmd.setProtocolBindings(handlerChain.getProtocolBindings());
- hmd.setServiceNamePattern(handlerChain.getServiceNamePattern());
- hmd.setPortNamePattern(handlerChain.getPortNamePattern());
- }
- return hmd;
- }
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/InitParamMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/InitParamMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/InitParamMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
-*/
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-
-/**
- * @author Thomas.Diesler(a)jboss.org
- * @since 06-May-2004
- */
-public class InitParamMetaData implements Serializable
-{
- // The required <param-name> element
- private String paramName;
- // The required <param-value> element
- private String paramValue;
-
- public String getParamName()
- {
- return paramName;
- }
-
- public void setParamName(String paramName)
- {
- this.paramName = paramName;
- }
-
- public String getParamValue()
- {
- return paramValue;
- }
-
- public void setParamValue(String paramValue)
- {
- this.paramValue = paramValue;
- }
-
- public String toString()
- {
- return "[name=" + paramName + ",value=" + paramValue +
"]";
- }
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/PortComponentRefMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/PortComponentRefMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/PortComponentRefMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,168 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.xml.namespace.QName;
-
-/** The metdata data from service-ref/port-component-ref element in web.xml, ejb-jar.xml,
and application-client.xml.
- *
- * @author Thomas.Diesler(a)jboss.org
- */
-public class PortComponentRefMetaData implements Serializable
-{
- // The parent service-ref
- private ServiceRefMetaData serviceRefMetaData;
-
- // The required <service-endpoint-interface> element
- private String serviceEndpointInterface;
- // The optional <enable-mtom> element
- private Boolean enableMTOM;
- // The optional <port-component-link> element
- private String portComponentLink;
- // The optional <port-qname> element
- private QName portQName;
- // Arbitrary proxy properties given by <call-property>
- private List<CallPropertyMetaData> callProperties = new
ArrayList<CallPropertyMetaData>();
- // Arbitrary proxy properties given by <stub-property>
- private List<StubPropertyMetaData> stubProperties = new
ArrayList<StubPropertyMetaData>();
- // The optional JBossWS config-name
- private String configName;
- // The optional JBossWS config-file
- private String configFile;
-
- public PortComponentRefMetaData(ServiceRefMetaData serviceRefMetaData)
- {
- this.serviceRefMetaData = serviceRefMetaData;
- }
-
- public ServiceRefMetaData getServiceRefMetaData()
- {
- return serviceRefMetaData;
- }
-
- public Boolean getEnableMTOM()
- {
- return enableMTOM;
- }
-
- public void setEnableMTOM(Boolean enableMTOM)
- {
- this.enableMTOM = enableMTOM;
- }
-
- /**
- * The port-component-link element links a port-component-ref
- * to a specific port-component required to be made available
- * by a service reference.
- *
- * The value of a port-component-link must be the
- * port-component-name of a port-component in the same module
- * or another module in the same application unit. The syntax
- * for specification follows the syntax defined for ejb-link
- * in the EJB 2.0 specification.
- */
- public String getPortComponentLink()
- {
- return portComponentLink;
- }
-
- public void setPortComponentLink(String portComponentLink)
- {
- this.portComponentLink = portComponentLink;
- }
-
- public String getServiceEndpointInterface()
- {
- return serviceEndpointInterface;
- }
-
- public void setServiceEndpointInterface(String serviceEndpointInterface)
- {
- this.serviceEndpointInterface = serviceEndpointInterface;
- }
-
- public QName getPortQName()
- {
- return portQName;
- }
-
- public void setPortQName(QName portQName)
- {
- this.portQName = portQName;
- }
-
- public List<CallPropertyMetaData> getCallProperties()
- {
- return callProperties;
- }
-
- public void setCallProperties(List<CallPropertyMetaData> callProps)
- {
- callProperties = callProps;
- }
-
- public void addCallProperty(CallPropertyMetaData callProp)
- {
- callProperties.add(callProp);
- }
-
- public List<StubPropertyMetaData> getStubProperties()
- {
- return stubProperties;
- }
-
- public void setStubProperties(List<StubPropertyMetaData> stubProps)
- {
- stubProperties = stubProps;
- }
-
- public void addStubProperty(StubPropertyMetaData stubProp)
- {
- stubProperties.add(stubProp);
- }
-
- public String getConfigFile()
- {
- return configFile;
- }
-
- public void setConfigFile(String configFile)
- {
- this.configFile = configFile;
- }
-
- public String getConfigName()
- {
- return configName;
- }
-
- public void setConfigName(String configName)
- {
- this.configName = configName;
- }
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,314 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
-
-/**
- * The metdata data from service-ref element in web.xml, ejb-jar.xml, and
- * application-client.xml.
- *
- * @author Thomas.Diesler(a)jboss.org
- */
-public class ServiceRefMetaData implements Serializable
-{
- // provide logging
- private static Logger log = Logger.getLogger(ServiceRefMetaData.class);
-
- private UnifiedVirtualFile vfsRoot;
-
- // Standard properties
-
- // The required <service-ref-name> element
- private String serviceRefName;
- // The JAXRPC required <service-interface> element
- private String serviceInterface;
- // service-res-type
- private String serviceRefType;
- // The optional <wsdl-file> element
- private String wsdlFile;
- // The optional <jaxrpc-mapping-file> element
- private String mappingFile;
- // The optional <service-qname> element
- private QName serviceQName;
- // The LinkedHashMap<String, PortComponentRefMetaData> for
<port-component-ref> elements
- private Map<String, PortComponentRefMetaData> portComponentRefs = new
LinkedHashMap<String, PortComponentRefMetaData>();
- // The optional <handler> elements. JAX-RPC handlers declared in the standard
J2EE1.4 descriptor
- private List<HandlerMetaData> handlers = new
ArrayList<HandlerMetaData>();
- // The optional <handler-chains> elements. JAX-WS handlers declared in the
standard JavaEE5 descriptor
- private HandlerChainsMetaData handlerChains;
-
- // JBoss properties
-
- // The optional <service-impl-class> element
- private String serviceImplClass;
- // The optional JBossWS config-name
- private String configName;
- // The optional JBossWS config-file
- private String configFile;
- // The optional URL of the actual WSDL to use, <wsdl-override>
- private String wsdlOverride;
- // The optional <handler-chain> element. JAX-WS handler chain declared in the
JBoss JavaEE5 descriptor
- private String handlerChain;
- // Arbitrary proxy properties given by <call-property>
- private List<CallPropertyMetaData> callProperties = new
ArrayList<CallPropertyMetaData>();
-
- public UnifiedVirtualFile getVfsRoot()
- {
- return vfsRoot;
- }
-
- public void setVfsRoot(UnifiedVirtualFile vfsRoot)
- {
- this.vfsRoot = vfsRoot;
- }
-
- public String getServiceRefName()
- {
- return serviceRefName;
- }
-
- public void setServiceRefName(String serviceRefName)
- {
- this.serviceRefName = serviceRefName;
- }
-
- public String getMappingFile()
- {
- return mappingFile;
- }
-
- public void setMappingFile(String mappingFile)
- {
- this.mappingFile = mappingFile;
- }
-
- public URL getMappingLocation()
- {
- URL mappingURL = null;
- if (mappingFile != null)
- {
- try
- {
- mappingURL = vfsRoot.findChild(mappingFile).toURL();
- }
- catch (Exception e)
- {
- throw new WSException("Cannot find jaxrcp-mapping-file: " +
mappingFile, e);
- }
- }
- return mappingURL;
- }
-
- public Collection<PortComponentRefMetaData> getPortComponentRefs()
- {
- return portComponentRefs.values();
- }
-
- public PortComponentRefMetaData getPortComponentRef(String seiName)
- {
- PortComponentRefMetaData ref = portComponentRefs.get(seiName);
- return ref;
- }
-
- public void addPortComponentRef(PortComponentRefMetaData pcRef)
- {
- portComponentRefs.put(pcRef.getServiceEndpointInterface(), pcRef);
- }
-
- public List<HandlerMetaData> getHandlers()
- {
- return handlers;
- }
-
- public void addHandler(HandlerMetaData handler)
- {
- handlers.add(handler);
- }
-
- public String getServiceInterface()
- {
- return serviceInterface;
- }
-
- public void setServiceInterface(String serviceInterface)
- {
- this.serviceInterface = serviceInterface;
- }
-
- public String getServiceImplClass()
- {
- return serviceImplClass;
- }
-
- public void setServiceImplClass(String serviceImplClass)
- {
- this.serviceImplClass = serviceImplClass;
- }
-
- public QName getServiceQName()
- {
- return serviceQName;
- }
-
- public void setServiceQName(QName serviceQName)
- {
- this.serviceQName = serviceQName;
- }
-
- public String getServiceRefType()
- {
- return serviceRefType;
- }
-
- public void setServiceRefType(String serviceResType)
- {
- this.serviceRefType = serviceResType;
- }
-
- public String getWsdlFile()
- {
- return wsdlFile;
- }
-
- public void setWsdlFile(String wsdlFile)
- {
- this.wsdlFile = wsdlFile;
- }
-
- public URL getWsdlLocation()
- {
- URL wsdlLocation = null;
- if (wsdlOverride != null)
- {
- try
- {
- wsdlLocation = new URL(wsdlOverride);
- }
- catch (MalformedURLException e1)
- {
- try
- {
- wsdlLocation = vfsRoot.findChild(wsdlOverride).toURL();
- }
- catch (Exception e)
- {
- throw new WSException("Cannot find wsdl-override: " +
wsdlOverride, e);
- }
- }
- }
-
- if (wsdlLocation == null && wsdlFile != null)
- {
- try
- {
- wsdlLocation = vfsRoot.findChild(wsdlFile).toURL();
- }
- catch (Exception e)
- {
- throw new WSException("Cannot find wsdl-file: " + wsdlFile, e);
- }
- }
-
- return wsdlLocation;
- }
-
- public String getConfigFile()
- {
- return configFile;
- }
-
- public void setConfigFile(String configFile)
- {
- this.configFile = configFile;
- }
-
- public String getConfigName()
- {
- return configName;
- }
-
- public void setConfigName(String configName)
- {
- this.configName = configName;
- }
-
- public String getWsdlOverride()
- {
- return wsdlOverride;
- }
-
- public void setWsdlOverride(String wsdlOverride)
- {
- this.wsdlOverride = wsdlOverride;
- }
-
- public List<CallPropertyMetaData> getCallProperties()
- {
- return callProperties;
- }
-
- public void setCallProperties(List<CallPropertyMetaData> callProps)
- {
- callProperties = callProps;
- }
-
- public void addCallProperty(CallPropertyMetaData callProp)
- {
- callProperties.add(callProp);
- }
-
- public HandlerChainsMetaData getHandlerChains()
- {
- return handlerChains;
- }
-
- public void setHandlerChains(HandlerChainsMetaData handlerChains)
- {
- this.handlerChains = handlerChains;
- }
-
- public String getHandlerChain()
- {
- return handlerChain;
- }
-
- public void setHandlerChain(String handlerChain)
- {
- this.handlerChain = handlerChain;
- }
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefObjectFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefObjectFactory.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/ServiceRefObjectFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,324 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-import java.io.ByteArrayInputStream;
-import java.io.InputStream;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.ws.WSException;
-import org.jboss.xb.binding.ObjectModelFactory;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-/**
- * An ObjectModelFactory for ServiceRefMetaData
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 17-Jan-2007
- */
-public class ServiceRefObjectFactory implements ObjectModelFactory
-{
- // Hide constructor
- private ServiceRefObjectFactory()
- {
- }
-
- public static ServiceRefObjectFactory newInstance()
- {
- return new ServiceRefObjectFactory();
- }
-
- public UnifiedServiceRefMetaData parse(String xmlFragment)
- {
- try
- {
- InputStream is = new ByteArrayInputStream(xmlFragment.getBytes());
-
- Unmarshaller unmarshaller =
UnmarshallerFactory.newInstance().newUnmarshaller();
- return (UnifiedServiceRefMetaData)unmarshaller.unmarshal(is, this, null);
- }
- catch (Exception ex)
- {
- WSException.rethrow(ex);
- return null;
- }
- }
-
- public Object newRoot(Object root, UnmarshallingContext navigator, String
namespaceURI, String localName, Attributes attrs)
- {
- return new UnifiedServiceRefMetaData();
- }
-
- public Object completeRoot(Object root, UnmarshallingContext ctx, String uri, String
name)
- {
- return root;
- }
-
- // ********************************************************
- // START ServiceRefMetaData
-
- public void setValue(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- /* Standard properties */
- if (localName.equals("service-ref-name"))
- {
- ref.setServiceRefName(value);
- }
- else if (localName.equals("service-interface"))
- {
- ref.setServiceInterface(value);
- }
- else if (localName.equals("service-ref-type"))
- {
- ref.setServiceRefType(value);
- }
- else if (localName.equals("wsdl-file"))
- {
- ref.setWsdlFile(value);
- }
- else if (localName.equals("jaxrpc-mapping-file"))
- {
- ref.setMappingFile(value);
- }
- else if (localName.equals("service-qname"))
- {
- ref.setServiceQName(QName.valueOf(value));
- }
-
- /* JBoss properties */
- else if (localName.equals("service-impl-class"))
- {
- ref.setServiceImplClass(value);
- }
- else if (localName.equals("config-name"))
- {
- ref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- ref.setConfigFile(value);
- }
- else if (localName.equals("wsdl-override"))
- {
- ref.setWsdlOverride(value);
- }
- else if (localName.equals("handler-chain"))
- {
- ref.setHandlerChain(value);
- }
- }
-
- public Object newChild(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("port-component-ref"))
- child = new UnifiedPortComponentRefMetaData(ref);
- else if (localName.equals("handler"))
- child = new UnifiedHandlerMetaData();
- else if (localName.equals("handler-chains"))
- child = new UnifiedHandlerChainsMetaData();
-
- else if (localName.equals("call-property"))
- child = new UnifiedCallPropertyMetaData();
-
- return child;
- }
-
- public Object newChild(UnifiedHandlerChainsMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("handler-chain"))
- child = new UnifiedHandlerChainMetaData();
-
- return child;
- }
-
- public void addChild(UnifiedServiceRefMetaData parent, UnifiedPortComponentRefMetaData
pcRef, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- parent.addPortComponentRef(pcRef);
- }
-
- public void addChild(UnifiedServiceRefMetaData parent, UnifiedHandlerMetaData handler,
UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- parent.addHandler(handler);
- }
-
- public void addChild(UnifiedServiceRefMetaData parent, UnifiedHandlerChainsMetaData
handlerChains, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- parent.setHandlerChains(handlerChains);
- }
-
- public void addChild(UnifiedServiceRefMetaData parent, UnifiedCallPropertyMetaData
callProp, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- parent.addCallProperty(callProp);
- }
-
- public void addChild(UnifiedHandlerChainsMetaData parent, UnifiedHandlerChainMetaData
handlerChain, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- parent.addHandlerChain(handlerChain);
- }
-
- public void setValue(UnifiedPortComponentRefMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-endpoint-interface"))
- {
- ref.setServiceEndpointInterface(value);
- }
- else if (localName.equals("enable-mtom"))
- {
- ref.setEnableMTOM(Boolean.valueOf(value));
- }
- else if (localName.equals("port-component-link"))
- {
- ref.setPortComponentLink(value);
- }
- else if (localName.equals("port-qname"))
- {
- ref.setPortQName(QName.valueOf(value));
- }
- else if (localName.equals("config-name"))
- {
- ref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- ref.setConfigFile(value);
- }
- }
-
- public Object newChild(UnifiedPortComponentRefMetaData ref, UnmarshallingContext
navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("call-property"))
- child = new UnifiedCallPropertyMetaData();
- if (localName.equals("stub-property"))
- child = new UnifiedStubPropertyMetaData();
- return child;
- }
-
- public void setValue(UnifiedHandlerChainMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-name-pattern"))
- {
- ref.setServiceNamePattern(QName.valueOf(value));
- }
- else if (localName.equals("port-name-pattern"))
- {
- ref.setPortNamePattern(QName.valueOf(value));
- }
- else if (localName.equals("protocol-binding"))
- {
- ref.setProtocolBindings(value);
- }
- }
-
- public void setValue(UnifiedHandlerMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("handler-name"))
- {
- ref.setHandlerName(value);
- }
- else if (localName.equals("handler-class"))
- {
- ref.setHandlerClass(value);
- }
- else if (localName.equals("soap-header"))
- {
- ref.addSoapHeader(QName.valueOf(value));
- }
- else if (localName.equals("soap-role"))
- {
- ref.addSoapRole(value);
- }
- else if (localName.equals("port-name"))
- {
- ref.addPortName(value);
- }
- }
-
- public Object newChild(UnifiedHandlerMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("init-param"))
- child = new UnifiedInitParamMetaData();
-
- return child;
- }
-
- public void addChild(UnifiedHandlerMetaData parent, UnifiedInitParamMetaData param,
UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- parent.addInitParam(param);
- }
-
- public void setValue(UnifiedInitParamMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("param-name"))
- {
- ref.setParamName(value);
- }
- else if (localName.equals("param-value"))
- {
- ref.setParamValue(value);
- }
- }
-
- public void setValue(UnifiedCallPropertyMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-
- public void setValue(UnifiedStubPropertyMetaData ref, UnmarshallingContext navigator,
String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-
- public void addChild(UnifiedPortComponentRefMetaData ref, UnifiedCallPropertyMetaData
callProp, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- ref.addCallProperty(callProp);
- }
-
- public void addChild(UnifiedPortComponentRefMetaData ref, UnifiedStubPropertyMetaData
stubProp, UnmarshallingContext navigator, String namespaceURI, String localName)
- {
- ref.addStubProperty(stubProp);
- }
-
- // END ServiceRefMetaData
- // ********************************************************
-}
Deleted:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/StubPropertyMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/StubPropertyMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/StubPropertyMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
-*/
-package org.jboss.ws.metadata.j2ee.serviceref;
-
-// $Id$
-
-import java.io.Serializable;
-
-/**
- * @author Thomas.Diesler(a)jboss.org
- * @since 06-May-2004
- */
-public class StubPropertyMetaData implements Serializable
-{
- // The required <prop-name> element
- private String propName;
- // The required <prop-value> element
- private String propValue;
-
- public String getPropName()
- {
- return propName;
- }
-
- public void setPropName(String paramName)
- {
- this.propName = paramName;
- }
-
- public String getPropValue()
- {
- return propValue;
- }
-
- public void setPropValue(String paramValue)
- {
- this.propValue = paramValue;
- }
-
- public String toString()
- {
- return "[name=" + propName + ",value=" + propValue +
"]";
- }
-}
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedCallPropertyMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedCallPropertyMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedCallPropertyMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,13 +23,13 @@
// $Id$
-import java.io.Serializable;
+import org.jboss.ws.integration.ServiceRefElement;
/**
* @author Thomas.Diesler(a)jboss.org
* @since 06-May-2004
*/
-public class UnifiedCallPropertyMetaData implements Serializable
+public class UnifiedCallPropertyMetaData extends ServiceRefElement
{
// The required <prop-name> element
private String propName;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,17 +23,18 @@
// $Id$
-import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import javax.xml.namespace.QName;
+import org.jboss.ws.integration.ServiceRefElement;
+
/** The unified metdata data for a handler chain element
*
* @author Thomas.Diesler(a)jboss.org
*/
-public class UnifiedHandlerChainMetaData implements Serializable
+public class UnifiedHandlerChainMetaData extends ServiceRefElement
{
private UnifiedHandlerChainsMetaData handlerChains;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerChainsMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,17 +23,17 @@
// $Id$
-import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
+import org.jboss.ws.integration.ServiceRefElement;
import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
/** The unified metdata data for a handler chains element
*
* @author Thomas.Diesler(a)jboss.org
*/
-public class UnifiedHandlerChainsMetaData implements Serializable
+public class UnifiedHandlerChainsMetaData extends ServiceRefElement
{
private HandlerType handlerType;
private List<UnifiedHandlerChainMetaData> handlerChains = new
ArrayList<UnifiedHandlerChainMetaData>();
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedHandlerMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,25 +23,29 @@
// $Id$
-import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashSet;
+import java.util.Iterator;
import java.util.List;
import java.util.Set;
import javax.xml.namespace.QName;
+import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.ServiceRefElement;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXWS;
import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+import org.jboss.xb.QNameBuilder;
+import org.w3c.dom.Element;
/** The unified metdata data for a handler element
*
* @author Thomas.Diesler(a)jboss.org
* @version $Revision$
*/
-public class UnifiedHandlerMetaData implements Serializable
+public class UnifiedHandlerMetaData extends ServiceRefElement
{
private UnifiedHandlerChainMetaData handlerChain;
@@ -153,4 +157,55 @@
}
return hmd;
}
+
+ @Deprecated
+ public void importStandardXml(Element root)
+ {
+ Element child = DOMUtils.getFirstChildElement(root, "handler-name");
+ if (child != null)
+ handlerName = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "handler-class");
+ if (child != null)
+ handlerClass = DOMUtils.getTextContent(child);
+
+ // Parse the init-param elements
+ Iterator iterator = DOMUtils.getChildElements(root, "init-param");
+ while (iterator.hasNext())
+ {
+ Element paramElement = (Element)iterator.next();
+ UnifiedInitParamMetaData param = new UnifiedInitParamMetaData();
+
param.setParamName(DOMUtils.getTextContent(DOMUtils.getFirstChildElement(paramElement,
"param-name")));
+
param.setParamValue(DOMUtils.getTextContent(DOMUtils.getFirstChildElement(paramElement,
"param-value")));
+ initParams.add(param);
+ }
+
+ // Parse the soap-header elements
+ iterator = DOMUtils.getChildElements(root, "soap-header");
+ while (iterator.hasNext())
+ {
+ Element headerElement = (Element)iterator.next();
+ String content = DOMUtils.getTextContent(headerElement);
+ QName qname = QNameBuilder.buildQName(headerElement, content);
+ soapHeaders.add(qname);
+ }
+
+ // Parse the soap-role elements
+ iterator = DOMUtils.getChildElements(root, "soap-role");
+ while (iterator.hasNext())
+ {
+ Element roleElement = (Element)iterator.next();
+ String content = DOMUtils.getTextContent(roleElement);
+ soapRoles.add(content);
+ }
+
+ // Parse the port-name elements
+ iterator = DOMUtils.getChildElements(root, "port-name");
+ while (iterator.hasNext())
+ {
+ Element portElement = (Element)iterator.next();
+ String content = DOMUtils.getTextContent(portElement);
+ portNames.add(content);
+ }
+ }
}
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedInitParamMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedInitParamMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedInitParamMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,13 +23,13 @@
// $Id$
-import java.io.Serializable;
+import org.jboss.ws.integration.ServiceRefElement;
/**
* @author Thomas.Diesler(a)jboss.org
* @since 06-May-2004
*/
-public class UnifiedInitParamMetaData implements Serializable
+public class UnifiedInitParamMetaData extends ServiceRefElement
{
// The required <param-name> element
private String paramName;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedPortComponentRefMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedPortComponentRefMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedPortComponentRefMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,17 +23,21 @@
// $Id$
-import java.io.Serializable;
import java.util.ArrayList;
+import java.util.Iterator;
import java.util.List;
import javax.xml.namespace.QName;
+import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.ServiceRefElement;
+import org.w3c.dom.Element;
+
/** The metdata data from service-ref/port-component-ref element in web.xml, ejb-jar.xml,
and application-client.xml.
*
* @author Thomas.Diesler(a)jboss.org
*/
-public class UnifiedPortComponentRefMetaData implements Serializable
+public class UnifiedPortComponentRefMetaData extends ServiceRefElement
{
// The parent service-ref
private UnifiedServiceRefMetaData serviceRefMetaData;
@@ -60,6 +64,15 @@
this.serviceRefMetaData = serviceRefMetaData;
}
+ public void merge(UnifiedPortComponentRefMetaData pcref)
+ {
+ portQName = pcref.portQName;
+ configName = pcref.configName;
+ configFile = pcref.configFile;
+ callProperties = pcref.callProperties;
+ stubProperties = pcref.stubProperties;
+ }
+
public UnifiedServiceRefMetaData getServiceRefMetaData()
{
return serviceRefMetaData;
@@ -165,4 +178,30 @@
{
this.configName = configName;
}
+
+ @Deprecated
+ public void importStandardXml(Element root)
+ {
+ Element child = DOMUtils.getFirstChildElement(root,
"service-endpoint-interface");
+ if (child != null)
+ serviceEndpointInterface = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "port-component-link");
+ if (child != null)
+ portComponentLink = DOMUtils.getTextContent(child);
+ }
+
+ @Deprecated
+ public void importJBossXml(Element root)
+ {
+ // Look for call-property elements
+ Iterator iterator = DOMUtils.getChildElements(root, "call-property");
+ while (iterator.hasNext())
+ {
+ Element propElement = (Element)iterator.next();
+ String name = DOMUtils.getTextContent(DOMUtils.getFirstChildElement(propElement,
"prop-name"));
+ String value =
DOMUtils.getTextContent(DOMUtils.getFirstChildElement(propElement,
"prop-value"));
+ callProperties.add(new UnifiedCallPropertyMetaData(name, value));
+ }
+ }
}
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedServiceRefMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,11 +23,12 @@
// $Id$
-import java.io.Serializable;
+import java.lang.reflect.AnnotatedElement;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.ArrayList;
import java.util.Collection;
+import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
@@ -36,7 +37,11 @@
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.integration.ServiceRefMetaData;
+import org.jboss.ws.integration.UnifiedVirtualFile;
+import org.jboss.xb.QNameBuilder;
+import org.w3c.dom.Element;
/**
* The metdata data from service-ref element in web.xml, ejb-jar.xml, and
@@ -44,7 +49,7 @@
*
* @author Thomas.Diesler(a)jboss.org
*/
-public class UnifiedServiceRefMetaData implements Serializable
+public class UnifiedServiceRefMetaData extends ServiceRefMetaData
{
// provide logging
private static Logger log = Logger.getLogger(UnifiedServiceRefMetaData.class);
@@ -87,6 +92,9 @@
// Arbitrary proxy properties given by <call-property>
private List<UnifiedCallPropertyMetaData> callProperties = new
ArrayList<UnifiedCallPropertyMetaData>();
+ private transient AnnotatedElement anElement;
+ private transient boolean processed;
+
public UnifiedServiceRefMetaData(UnifiedVirtualFile vfRoot)
{
this.vfsRoot = vfRoot;
@@ -96,6 +104,41 @@
{
}
+ @Override
+ public void merge(ServiceRefMetaData sref)
+ {
+ UnifiedServiceRefMetaData sourceRef = (UnifiedServiceRefMetaData)sref;
+ serviceImplClass = sourceRef.serviceImplClass;
+ configName = sourceRef.configName;
+ configFile = sourceRef.configFile;
+ wsdlOverride = sourceRef.wsdlOverride;
+ handlerChain = sourceRef.handlerChain;
+ callProperties = sourceRef.callProperties;
+
+ if (serviceQName == null && sourceRef.serviceQName != null)
+ serviceQName = sourceRef.serviceQName;
+
+ for (UnifiedPortComponentRefMetaData pcref : sourceRef.getPortComponentRefs())
+ {
+ String seiName = pcref.getServiceEndpointInterface();
+ if (seiName == null)
+ {
+ log.warn("Ignore <port-component-ref> with null
<service-endpoint-interface>");
+ continue;
+ }
+
+ UnifiedPortComponentRefMetaData targetPCRef = portComponentRefs.get(seiName);
+ if (targetPCRef == null)
+ {
+ log.warn("Cannot find port component ref with SEI name: " +
seiName);
+ addPortComponentRef(pcref);
+ targetPCRef = pcref;
+ }
+
+ targetPCRef.merge(pcref);
+ }
+ }
+
public UnifiedVirtualFile getVfsRoot()
{
return vfsRoot;
@@ -320,4 +363,116 @@
{
this.handlerChain = handlerChain;
}
+
+ public AnnotatedElement getAnnotatedElement()
+ {
+ return anElement;
+
+ }
+
+ public boolean isProcessed()
+ {
+ return processed;
+ }
+
+ public void setProcessed(boolean flag)
+ {
+ this.processed = flag;
+ }
+
+ public void setAnnotatedElement(AnnotatedElement anElement)
+ {
+ this.anElement = anElement;
+ }
+
+ @Override
+ public void importStandardXml(Element root)
+ {
+ Element child = DOMUtils.getFirstChildElement(root, "service-ref-name");
+ if (child != null)
+ serviceRefName = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "service-interface");
+ if (child != null)
+ serviceInterface = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "wsdl-file");
+ if (child != null)
+ wsdlFile = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "jaxrpc-mapping-file");
+ if (child != null)
+ mappingFile = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "service-qname");
+ if (child != null)
+ serviceQName = QNameBuilder.buildQName(child, DOMUtils.getTextContent(child));
+
+ // Parse the port-component-ref elements
+ Iterator iterator = DOMUtils.getChildElements(root,
"port-component-ref");
+ while (iterator.hasNext())
+ {
+ Element pcrefElement = (Element)iterator.next();
+ UnifiedPortComponentRefMetaData pcrefMetaData = new
UnifiedPortComponentRefMetaData(this);
+ pcrefMetaData.importStandardXml(pcrefElement);
+ portComponentRefs.put(pcrefMetaData.getServiceEndpointInterface(),
pcrefMetaData);
+ }
+
+ // Parse the handler elements
+ iterator = DOMUtils.getChildElements(root, "handler");
+ while (iterator.hasNext())
+ {
+ Element handlerElement = (Element)iterator.next();
+ UnifiedHandlerMetaData handlerMetaData = new UnifiedHandlerMetaData();
+ handlerMetaData.importStandardXml(handlerElement);
+ handlers.add(handlerMetaData);
+ }
+ }
+
+ @Override
+ public void importJBossXml(Element root)
+ {
+ Element child = DOMUtils.getFirstChildElement(root, "config-name");
+ if (child != null)
+ configName = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "config-file");
+ if (child != null)
+ configFile = DOMUtils.getTextContent(child);
+
+ child = DOMUtils.getFirstChildElement(root, "wsdl-override");
+ if (child != null)
+ wsdlOverride = DOMUtils.getTextContent(child);
+
+ // Parse the port-component-ref elements
+ Iterator iterator = DOMUtils.getChildElements(root,
"port-component-ref");
+ while (iterator.hasNext())
+ {
+ Element pcrefElement = (Element)iterator.next();
+ Element seiElement = DOMUtils.getFirstChildElement(pcrefElement,
"service-endpoint-interface");
+ if (seiElement != null)
+ {
+ String seiName = DOMUtils.getTextContent(seiElement);
+ UnifiedPortComponentRefMetaData pcrefMetaData =
(UnifiedPortComponentRefMetaData)portComponentRefs.get(seiName);
+ if (pcrefMetaData == null)
+ {
+ // Its ok to only have the <port-component-ref> in jboss.xml and not
in ejb-jar.xml
+ pcrefMetaData = new UnifiedPortComponentRefMetaData(this);
+ pcrefMetaData.importStandardXml(pcrefElement);
+ portComponentRefs.put(pcrefMetaData.getServiceEndpointInterface(),
pcrefMetaData);
+ }
+ pcrefMetaData.importJBossXml(pcrefElement);
+ }
+ }
+
+ // Parse the call-property elements
+ iterator = DOMUtils.getChildElements(root, "call-property");
+ while (iterator.hasNext())
+ {
+ Element propElement = (Element)iterator.next();
+ String name = DOMUtils.getTextContent(DOMUtils.getFirstChildElement(propElement,
"prop-name"));
+ String value =
DOMUtils.getTextContent(DOMUtils.getFirstChildElement(propElement,
"prop-value"));
+ callProperties.add(new UnifiedCallPropertyMetaData(name, value));
+ }
+ }
}
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedStubPropertyMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedStubPropertyMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/j2ee/serviceref/UnifiedStubPropertyMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -23,13 +23,13 @@
// $Id$
-import java.io.Serializable;
+import org.jboss.ws.integration.ServiceRefElement;
/**
* @author Thomas.Diesler(a)jboss.org
* @since 06-May-2004
*/
-public class UnifiedStubPropertyMetaData implements Serializable
+public class UnifiedStubPropertyMetaData extends ServiceRefElement
{
// The required <prop-name> element
private String propName;
Modified: trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/EndpointMetaData.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/EndpointMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/EndpointMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -43,7 +43,6 @@
import org.jboss.ws.WSException;
import org.jboss.ws.core.CommonBindingProvider;
import org.jboss.ws.core.CommonSOAPBinding;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.jaxrpc.Style;
import org.jboss.ws.core.jaxrpc.TypeMappingImpl;
import org.jboss.ws.core.jaxrpc.Use;
@@ -54,6 +53,7 @@
import org.jboss.ws.core.jaxws.JAXBDeserializerFactory;
import org.jboss.ws.core.jaxws.JAXBSerializerFactory;
import org.jboss.ws.core.utils.JavaUtils;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.config.CommonConfig;
import org.jboss.ws.metadata.config.Configurable;
import org.jboss.ws.metadata.config.ConfigurationProvider;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ResourceLoaderAdapter.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ResourceLoaderAdapter.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ResourceLoaderAdapter.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -28,7 +28,7 @@
import java.net.MalformedURLException;
import java.net.URL;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.integration.UnifiedVirtualFile;
/**
* The default file adapter loads resources through an associated classloader.
Modified: trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ServiceMetaData.java
===================================================================
--- trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ServiceMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++ trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/ServiceMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -37,11 +37,11 @@
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.jaxrpc.TypeMappingImpl;
import org.jboss.ws.core.jaxrpc.TypeMappingRegistryImpl;
import org.jboss.ws.core.jaxrpc.Use;
import org.jboss.ws.core.jaxrpc.binding.jbossxb.SchemaBindingBuilder;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMappingFactory;
import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
Modified: trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/UnifiedMetaData.java
===================================================================
--- trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/UnifiedMetaData.java 2007-03-08
22:29:02 UTC (rev 2557)
+++ trunk/jbossws-core/src/java/org/jboss/ws/metadata/umdm/UnifiedMetaData.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -30,8 +30,8 @@
import java.util.StringTokenizer;
import org.jboss.logging.Logger;
-import org.jboss.ws.core.UnifiedVirtualFile;
import org.jboss.ws.core.server.ServiceEndpointManager;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
Modified:
trunk/jbossws-core/src/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java
===================================================================
---
trunk/jbossws-core/src/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java 2007-03-08
22:29:02 UTC (rev 2557)
+++
trunk/jbossws-core/src/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java 2007-03-08
23:42:11 UTC (rev 2558)
@@ -29,7 +29,7 @@
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.UnifiedVirtualFile;
+import org.jboss.ws.integration.UnifiedVirtualFile;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCServerMetaDataBuilder;
/**