Author: richard.opalka(a)jboss.com
Date: 2010-10-13 10:20:40 -0400 (Wed, 13 Oct 2010)
New Revision: 13114
Removed:
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParser.java
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParserFactory.java
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/ServiceRefObjectFactory.java
Modified:
framework/trunk/src/main/java/org/jboss/wsf/framework/DefaultSPIProvider.java
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandler.java
Log:
removing obsolete & deprecated code
Modified: framework/trunk/src/main/java/org/jboss/wsf/framework/DefaultSPIProvider.java
===================================================================
---
framework/trunk/src/main/java/org/jboss/wsf/framework/DefaultSPIProvider.java 2010-10-13
14:19:06 UTC (rev 13113)
+++
framework/trunk/src/main/java/org/jboss/wsf/framework/DefaultSPIProvider.java 2010-10-13
14:20:40 UTC (rev 13114)
@@ -30,7 +30,6 @@
import org.jboss.wsf.framework.management.DefaultJMSEndpointResolver;
import org.jboss.wsf.framework.security.DefaultSecurityAdapterFactory;
import org.jboss.wsf.framework.serviceref.DefaultServiceRefHandlerFactory;
-import org.jboss.wsf.framework.serviceref.DefaultServiceRefMetaDataParserFactory;
import org.jboss.wsf.spi.SPIProvider;
import org.jboss.wsf.spi.WSFException;
import org.jboss.wsf.spi.deployment.DeploymentAspectManagerFactory;
@@ -41,7 +40,6 @@
import org.jboss.wsf.spi.management.EndpointMetricsFactory;
import org.jboss.wsf.spi.management.EndpointRegistryFactory;
import org.jboss.wsf.spi.management.JMSEndpointResolver;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.ServiceRefMetaDataParserFactory;
import org.jboss.wsf.spi.serviceref.ServiceRefHandlerFactory;
import org.jboss.wsf.spi.util.ServiceLoader;
@@ -84,10 +82,6 @@
{
returnType = loadService(spiType, DefaultServiceRefHandlerFactory.class);
}
- else if (ServiceRefMetaDataParserFactory.class.equals(spiType))
- {
- returnType = loadService(spiType,
DefaultServiceRefMetaDataParserFactory.class);
- }
else if (SecurityAdaptorFactory.class.equals(spiType))
{
returnType = loadService(spiType, DefaultSecurityAdapterFactory.class);
Modified:
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandler.java
===================================================================
---
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandler.java 2010-10-13
14:19:06 UTC (rev 13113)
+++
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefHandler.java 2010-10-13
14:20:40 UTC (rev 13114)
@@ -21,28 +21,20 @@
*/
package org.jboss.wsf.framework.serviceref;
-import java.io.File;
import java.lang.reflect.AnnotatedElement;
-import java.net.MalformedURLException;
-import java.net.URL;
import javax.naming.Context;
import javax.naming.NamingException;
import org.jboss.logging.Logger;
-import org.jboss.wsf.common.URLLoaderAdapter;
import org.jboss.wsf.spi.SPIProvider;
import org.jboss.wsf.spi.SPIProviderResolver;
-import org.jboss.wsf.spi.WSFException;
import org.jboss.wsf.spi.deployment.UnifiedVirtualFile;
import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
import org.jboss.wsf.spi.serviceref.ServiceRefBinder;
import org.jboss.wsf.spi.serviceref.ServiceRefBinderFactory;
-import org.jboss.wsf.spi.serviceref.ServiceRefElement;
import org.jboss.wsf.spi.serviceref.ServiceRefHandler;
import org.jboss.wsf.spi.serviceref.ServiceRefMetaData;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
/**
* Bind service refs in the client's ENC
@@ -109,26 +101,23 @@
if (serviceRef.getMappingFile() != null)
return Type.JAXRPC;
- String siName = serviceRef.getServiceInterface();
- if (siName == null)
+ String serviceInterfaceName = serviceRef.getServiceInterface();
+ if (serviceInterfaceName == null)
throw new IllegalStateException("<service-interface> cannot be
null");
- if (siName.equals("javax.xml.rpc.Service"))
- return Type.JAXRPC;
-
try
{
- Class siClass = loader.loadClass(siName);
+ Class<?> siClass = loader.loadClass(serviceInterfaceName);
if (javax.xml.ws.Service.class.isAssignableFrom(siClass))
return Type.JAXWS;
else if (javax.xml.rpc.Service.class.isAssignableFrom(siClass))
return Type.JAXRPC;
else
- throw new IllegalStateException("Illegal service interface: " +
siName);
+ throw new IllegalStateException("Illegal service interface: " +
serviceInterfaceName);
}
catch (ClassNotFoundException e)
{
- throw new IllegalStateException("Cannot load <service-interface>:
" + siName);
+ throw new IllegalStateException("Cannot load <service-interface>:
" + serviceInterfaceName);
}
}
}
Deleted:
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParser.java
===================================================================
---
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParser.java 2010-10-13
14:19:06 UTC (rev 13113)
+++
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParser.java 2010-10-13
14:20:40 UTC (rev 13114)
@@ -1,254 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.wsf.framework.serviceref;
-
-import java.util.Iterator;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.logging.Logger;
-import org.jboss.wsf.common.DOMUtils;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.ServiceRefMetaDataParser;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedCallPropertyMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedStubPropertyMetaData;
-import org.jboss.xb.QNameBuilder;
-import org.w3c.dom.Element;
-
-/**
- * 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 DefaultServiceRefMetaDataParser implements ServiceRefMetaDataParser
-{
- private static final Logger log =
Logger.getLogger(DefaultServiceRefMetaDataParser.class);
-
- public void importStandardXml(Element root, UnifiedServiceRefMetaData sref)
- {
- sref.setServiceRefName(getElementContent(root, "service-ref-name"));
- sref.setServiceInterface(getOptionalElementContent(root,
"service-interface"));
- sref.setWsdlFile(getOptionalElementContent(root, "wsdl-file"));
- sref.setMappingFile(getOptionalElementContent(root,
"jaxrpc-mapping-file"));
-
- Element child = DOMUtils.getFirstChildElement(root, "service-qname");
- if (child != null)
- sref.setServiceQName(QNameBuilder.buildQName(child, 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(sref);
- pcrefMetaData.importStandardXml(pcrefElement);
- sref.addPortComponentRef(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);
- sref.addHandler(handlerMetaData);
- }
- }
-
- public void importJBossXml(Element root, UnifiedServiceRefMetaData sref)
- {
- sref.setConfigName(getOptionalElementContent(root, "config-name"));
- sref.setConfigFile(getOptionalElementContent(root, "config-file"));
- sref.setWsdlOverride(getOptionalElementContent(root, "wsdl-override"));
-
- // Parse the port-component-ref elements
- Iterator iterator = DOMUtils.getChildElements(root,
"port-component-ref");
- while (iterator.hasNext())
- {
- Element pcrefElement = (Element)iterator.next();
- String seiName = getOptionalElementContent(pcrefElement,
"service-endpoint-interface");
- QName portName = getOptionalElementContentAsQName(pcrefElement,
"port-qname");
-
- UnifiedPortComponentRefMetaData pcref = sref.getPortComponentRef(seiName,
portName);
- if (pcref == null && seiName != null)
- {
- // Its ok to only have the <port-component-ref> in jboss.xml and not in
ejb-jar.xml
- // if it has at least a SEI declared
- pcref = new UnifiedPortComponentRefMetaData(sref);
- pcref.importStandardXml(pcrefElement);
- sref.addPortComponentRef(pcref);
- }
-
- if (pcref != null)
- pcref.importJBossXml(pcrefElement);
- }
-
- // Parse the call-property elements
- iterator = DOMUtils.getChildElements(root, "call-property");
- while (iterator.hasNext())
- {
- Element propElement = (Element)iterator.next();
- String name = getElementContent(propElement, "prop-name");
- String value = getElementContent(propElement, "prop-value");
- sref.addCallProperty(new UnifiedCallPropertyMetaData(name, value));
- }
- }
-
- public void importStandardXml(Element root, UnifiedPortComponentRefMetaData pcref)
- {
- pcref.setServiceEndpointInterface(getOptionalElementContent(root,
"service-endpoint-interface"));
- pcref.setPortComponentLink(getOptionalElementContent(root,
"port-component-link"));
- }
-
- public void importJBossXml(Element root, UnifiedPortComponentRefMetaData pcref)
- {
- // Look for call-property elements
- Iterator iterator = DOMUtils.getChildElements(root, "call-property");
- while (iterator.hasNext())
- {
- Element propElement = (Element)iterator.next();
- String name = getElementContent(propElement, "prop-name");
- String value = getElementContent(propElement, "prop-value");
- pcref.addCallProperty(new UnifiedCallPropertyMetaData(name, value));
- }
-
- // Look for stub-property elements
- iterator = DOMUtils.getChildElements(root, "stub-property");
- while (iterator.hasNext())
- {
- Element propElement = (Element)iterator.next();
- String name = getElementContent(propElement, "prop-name");
- String value = getElementContent(propElement, "prop-value");
- UnifiedStubPropertyMetaData propMetaData = new UnifiedStubPropertyMetaData();
- propMetaData.setPropName(name);
- propMetaData.setPropValue(value);
- pcref.addStubProperty(propMetaData);
- }
-
- // portQName
- QName portQName = getOptionalElementContentAsQName(root, "port-qname");
- if (portQName != null)
- pcref.setPortQName(portQName);
-
- // config
- Element configName = DOMUtils.getFirstChildElement(root, "config-name");
- if (configName != null)
- pcref.setConfigName(getTextContent(configName));
-
- Element configFile = DOMUtils.getFirstChildElement(root, "config-file");
- if (configFile != null)
- pcref.setConfigFile(getTextContent(configFile));
-
- // service-endpoint-interface
- Element sei = DOMUtils.getFirstChildElement(root,
"service-endpoint-interface");
- if (sei != null)
- pcref.setServiceEndpointInterface(getTextContent(sei));
-
- }
-
- public void importStandardXml(Element root, UnifiedHandlerMetaData href)
- {
- href.setHandlerName(getElementContent(root, "handler-name"));
- href.setHandlerClass(getElementContent(root, "handler-class"));
-
- // 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(getElementContent(paramElement, "param-name"));
- param.setParamValue(getElementContent(paramElement, "param-value"));
- href.addInitParam(param);
- }
-
- // Parse the soap-header elements
- iterator = DOMUtils.getChildElements(root, "soap-header");
- while (iterator.hasNext())
- {
- Element headerElement = (Element)iterator.next();
- String content = getTextContent(headerElement);
- QName qname = DOMUtils.resolveQName(headerElement, content);
- href.addSoapHeader(qname);
- }
-
- // Parse the soap-role elements
- iterator = DOMUtils.getChildElements(root, "soap-role");
- while (iterator.hasNext())
- {
- Element roleElement = (Element)iterator.next();
- String content = getTextContent(roleElement);
- href.addSoapRole(content);
- }
-
- // Parse the port-name elements
- iterator = DOMUtils.getChildElements(root, "port-name");
- while (iterator.hasNext())
- {
- Element portElement = (Element)iterator.next();
- String content = getTextContent(portElement);
- href.addPortName(content);
- }
- }
-
- private String getElementContent(Element element, String childName)
- {
- String childValue = getOptionalElementContent(element, childName);
- if (childValue == null || childValue.length() == 0)
- throw new IllegalStateException("Invalid null element content: " +
childName);
-
- return childValue;
- }
-
- private String getOptionalElementContent(Element element, String childName)
- {
- return getTextContent(DOMUtils.getFirstChildElement(element, childName));
- }
-
- private QName getOptionalElementContentAsQName(Element element, String childName)
- {
- QName qname = null;
- String value = getOptionalElementContent(element, childName);
- if (value != null)
- {
- qname = (value.startsWith("{") ? QName.valueOf(value) :
DOMUtils.resolveQName(element, value));
- }
- return qname;
- }
-
- private String getTextContent(Element element)
- {
- String content = null;
- if (element != null)
- {
- content = DOMUtils.getTextContent(element);
- if (content != null)
- content = content.trim();
- }
- return content;
- }
-}
Deleted:
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParserFactory.java
===================================================================
---
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParserFactory.java 2010-10-13
14:19:06 UTC (rev 13113)
+++
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/DefaultServiceRefMetaDataParserFactory.java 2010-10-13
14:20:40 UTC (rev 13114)
@@ -1,37 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.wsf.framework.serviceref;
-
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.ServiceRefMetaDataParser;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.ServiceRefMetaDataParserFactory;
-
-/**
- * @author Thomas.Diesler(a)jboss.org
- * @since 02-Aug-2007
- */
-public class DefaultServiceRefMetaDataParserFactory implements
ServiceRefMetaDataParserFactory
-{
- public ServiceRefMetaDataParser getServiceRefMetaDataParser()
- {
- return new DefaultServiceRefMetaDataParser();
- }
-}
Deleted:
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/ServiceRefObjectFactory.java
===================================================================
---
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/ServiceRefObjectFactory.java 2010-10-13
14:19:06 UTC (rev 13113)
+++
framework/trunk/src/main/java/org/jboss/wsf/framework/serviceref/ServiceRefObjectFactory.java 2010-10-13
14:20:40 UTC (rev 13114)
@@ -1,313 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.wsf.framework.serviceref;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedCallPropertyMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedStubPropertyMetaData;
-import org.jboss.wsf.spi.serviceref.ServiceRefElement;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-import java.util.Set;
-
-/**
- * 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 UnifiedCallPropertyMetaData)
- setValue((UnifiedCallPropertyMetaData)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(getQNameValue(navigator, value));
- }
- else if (localName.equals("injection-target-class"))
- {
- ref.registerInjectionTarget(value);
- }
- else if (localName.equals("injection-target-name"))
- {
- ref.finalizeInjectionTarget(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 pcref, UnmarshallingContext
navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-endpoint-interface"))
- {
- pcref.setServiceEndpointInterface(value);
- }
- else if (localName.equals("enable-mtom"))
- {
- pcref.setEnableMTOM(Boolean.valueOf(value));
- }
- else if (localName.equals("port-component-link"))
- {
- pcref.setPortComponentLink(value);
- }
- else if (localName.equals("port-qname"))
- {
- pcref.setPortQName(getQNameValue(navigator, value));
- }
- else if (localName.equals("config-name"))
- {
- pcref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- pcref.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(getQNameValue(navigator, value));
- }
- else if (localName.equals("port-name-pattern"))
- {
- ref.setPortNamePattern(getQNameValue(navigator, 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(getQNameValue(navigator, 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);
- }
- }
-
- private QName getQNameValue(UnmarshallingContext navigator, String value)
- {
- QName qname = (value.startsWith("{") ? QName.valueOf(value) :
navigator.resolveQName(value));
- return qname;
- }
-}