JBossWS SVN: r1946 - in trunk: jbossws-core/src/main/java/org/jboss/ws/tools/helpers and 3 other directories.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2007-01-12 09:57:54 -0500 (Fri, 12 Jan 2007)
New Revision: 1946
Added:
trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/
trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Person.java
trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/TelephoneNumber.java
trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Wrapped.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wrapped-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wstools-config.xml
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDLToJava.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ReturnTypeUnwrapper.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java
Log:
JBWS-1260 - Added JAX-RPC spec section numbers to exceptions thrown.
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDLToJava.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDLToJava.java 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDLToJava.java 2007-01-12 14:57:54 UTC (rev 1946)
@@ -412,13 +412,13 @@
{
int inputs = in.getWsdlOperation().getInputs().length;
if (inputs > 1)
- throw new WSException("Can not unwrap parameters for operation with mutliple inputs. inputs=" + inputs);
+ throw new WSException("[JAX-RPC - 2.3.1.2] Can not unwrap parameters for operation with mutliple inputs. inputs=" + inputs);
String operationName = in.getWsdlOperation().getName().toString();
String elementName = in.getElement().getLocalPart();
if (elementName.equals(operationName) == false)
- throw new WSException("Unable to unwrap parameters, wrapper element name must match operation name. operationName=" + operationName + " elementName="
+ throw new WSException("[JAX-RPC - 2.3.1.2] Unable to unwrap parameters, wrapper element name must match operation name. operationName=" + operationName + " elementName="
+ elementName);
wrapped = unwrapElementParameters(buf, containingElement, xt);
@@ -446,7 +446,7 @@
boolean hasAttributes = wrapper.getAttributeUses().getLength() > 0;
if (hasAttributes)
- throw new WSException("Can not unwrap, complex type contains attributes.");
+ throw new WSException("[JAX-RPC 2.3.1.2] Can not unwrap, complex type contains attributes.");
boolean unwrappedElement = false;
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ReturnTypeUnwrapper.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ReturnTypeUnwrapper.java 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ReturnTypeUnwrapper.java 2007-01-12 14:57:54 UTC (rev 1946)
@@ -63,13 +63,13 @@
XSTypeDefinition xt = xsmodel.getTypeDefinition(xmlType.getLocalPart(), xmlType.getNamespaceURI());
if (xt instanceof XSComplexTypeDefinition == false)
- throw new WSException("Tried to unwrap a non-complex type.");
+ throw new WSException("[JAX-RPC 2.3.1.2] Tried to unwrap a non-complex type.");
XSComplexTypeDefinition wrapper = (XSComplexTypeDefinition)xt;
boolean hasAttributes = wrapper.getAttributeUses().getLength() > 0;
if (hasAttributes)
- throw new WSException("Can not unwrap, complex type contains attributes.");
+ throw new WSException("[JAX-RPC 2.3.1.2] Can not unwrap, complex type contains attributes.");
boolean unwrapped = false;
@@ -79,7 +79,7 @@
XSTerm term = particle.getTerm();
if (term instanceof XSModelGroup == false)
- throw new WSException("Expected model group, could not unwrap");
+ throw new WSException("[JAX-RPC 2.3.1.2] Expected model group, could not unwrap");
XSModelGroup group = (XSModelGroup)term;
@@ -115,7 +115,7 @@
}
else
{
- throw new WSException("Unable to unwrap model group with multiple particles.");
+ throw new WSException("[JAX-RPC 2.3.1.2] Unable to unwrap model group with multiple particles.");
}
return unwrappedElement != null;
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java 2007-01-12 14:57:54 UTC (rev 1946)
@@ -841,6 +841,33 @@
{
}
}
+
+ /**
+ * Test scenario where unwrapping should not occur as thre are
+ * multiple parts in each message.
+ *
+ * <message name='PhoneBook_lookup'>
+ * <part element='ns1:lookup' name='parameters'/>
+ * <part element='ns1:anotherPerson' name='anotherPerson'/>
+ * </message>
+ *
+ * <message name='PhoneBook_lookupResponse'>
+ * <part element='ns1:lookupResponse' name='result'/>
+ * <part element='ns1:anotherResponse' name='anotherTelephoneNumber'/>
+ * </message>
+ *
+ */
+ public void testScenario_AH() throws Exception
+ {
+ try
+ {
+ generateScenario("AH");
+ fail("Expected exception not thrown.");
+ }
+ catch (WSException e)
+ {
+ }
+ }
protected void generateScenario(final String scenario) throws Exception
{
Added: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Person.java
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Person.java 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Person.java 2007-01-12 14:57:54 UTC (rev 1946)
@@ -0,0 +1,26 @@
+// This class was generated by the JAXRPC SI, do not edit.
+// Contents subject to change without notice.
+// JAX-RPC Standard Implementation (1.1.3, build R1)
+// Generated source version: 1.1.3
+
+package org.jboss.test.ws.jbws1260;
+
+
+public class Person {
+ protected java.lang.String surname;
+
+ public Person() {
+ }
+
+ public Person(java.lang.String surname) {
+ this.surname = surname;
+ }
+
+ public java.lang.String getSurname() {
+ return surname;
+ }
+
+ public void setSurname(java.lang.String surname) {
+ this.surname = surname;
+ }
+}
Property changes on: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Person.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/PhoneBook_PortType.java
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/PhoneBook_PortType.java 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/PhoneBook_PortType.java 2007-01-12 14:57:54 UTC (rev 1946)
@@ -0,0 +1,11 @@
+// This class was generated by the JAXRPC SI, do not edit.
+// Contents subject to change without notice.
+// JAX-RPC Standard Implementation (1.1.3, build R1)
+// Generated source version: 1.1.3
+
+package org.jboss.test.ws.jbws1260;
+
+public interface PhoneBook_PortType extends java.rmi.Remote {
+ public void lookup(org.jboss.test.ws.jbws1260.Person parameters, org.jboss.test.ws.jbws1260.Person anotherPerson, org.jboss.test.ws.jbws1260.holders.TelephoneNumberHolder result, org.jboss.test.ws.jbws1260.holders.TelephoneNumberHolder anotherTelephoneNumber) throws
+ java.rmi.RemoteException;
+}
Property changes on: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/PhoneBook_PortType.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/TelephoneNumber.java
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/TelephoneNumber.java 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/TelephoneNumber.java 2007-01-12 14:57:54 UTC (rev 1946)
@@ -0,0 +1,26 @@
+// This class was generated by the JAXRPC SI, do not edit.
+// Contents subject to change without notice.
+// JAX-RPC Standard Implementation (1.1.3, build R1)
+// Generated source version: 1.1.3
+
+package org.jboss.test.ws.jbws1260;
+
+
+public class TelephoneNumber {
+ protected java.lang.String number;
+
+ public TelephoneNumber() {
+ }
+
+ public TelephoneNumber(java.lang.String number) {
+ this.number = number;
+ }
+
+ public java.lang.String getNumber() {
+ return number;
+ }
+
+ public void setNumber(java.lang.String number) {
+ this.number = number;
+ }
+}
Property changes on: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/TelephoneNumber.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Wrapped.wsdl
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Wrapped.wsdl 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Wrapped.wsdl 2007-01-12 14:57:54 UTC (rev 1946)
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<definitions name='PhoneBook' targetNamespace='http://test.jboss.org/ws/jbws1260' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:ns1='http://test.jboss.org/ws/jbws1260/types' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://test.jboss.org/ws/jbws1260' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
+ <types>
+ <schema targetNamespace='http://test.jboss.org/ws/jbws1260/types' xmlns='http://www.w3.org/2001/XMLSchema' xmlns:soap11-enc='http://schemas.xmlsoap.org/soap/encoding/' xmlns:tns='http://test.jboss.org/ws/jbws1260/types' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
+
+ <complexType name='Person'>
+ <sequence>
+ <element name='surname' nillable='true' type='string'/>
+ </sequence>
+ </complexType>
+
+ <complexType name='TelephoneNumber'>
+ <sequence>
+ <element name='number' nillable='true' type='string'/>
+ </sequence>
+ </complexType>
+
+ <element name='lookupPerson' type='tns:Person'/>
+ <element name='anotherPerson' type='tns:Person'/>
+ <element name='lookupResponse' type='tns:TelephoneNumber'/>
+ <element name='anotherResponse' type='tns:TelephoneNumber'/>
+ </schema>
+ </types>
+ <message name='PhoneBook_lookup'>
+ <part element='ns1:lookupPerson' name='parameters'/>
+ <part element='ns1:anotherPerson' name='anotherPerson'/>
+ </message>
+ <message name='PhoneBook_lookupResponse'>
+ <part element='ns1:lookupResponse' name='result'/>
+ <part element='ns1:anotherResponse' name='anotherTelephoneNumber'/>
+ </message>
+ <portType name='PhoneBook'>
+ <operation name='lookup'>
+ <input message='tns:PhoneBook_lookup'/>
+ <output message='tns:PhoneBook_lookupResponse'/>
+ </operation>
+ </portType>
+ <binding name='PhoneBookBinding' type='tns:PhoneBook'>
+ <soap:binding style='document' transport='http://schemas.xmlsoap.org/soap/http'/>
+ <operation name='lookup'>
+ <soap:operation soapAction=''/>
+ <input>
+ <soap:body use='literal'/>
+ </input>
+ <output>
+ <soap:body use='literal'/>
+ </output>
+ </operation>
+ </binding>
+ <service name='PhoneBook'>
+ <port binding='tns:PhoneBookBinding' name='PhoneBookPort'>
+ <soap:address location='REPLACE_WITH_ACTUAL_URL'/>
+ </port>
+ </service>
+</definitions>
\ No newline at end of file
Property changes on: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/Wrapped.wsdl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wrapped-mapping.xml
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wrapped-mapping.xml 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wrapped-mapping.xml 2007-01-12 14:57:54 UTC (rev 1946)
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jbws1260</package-type>
+ <namespaceURI>http://test.jboss.org/ws/jbws1260</namespaceURI>
+ </package-mapping>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jbws1260</package-type>
+ <namespaceURI>http://test.jboss.org/ws/jbws1260/types</namespaceURI>
+ </package-mapping>
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jbws1260.TelephoneNumber</java-type>
+ <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1260/types">typeNS:TelephoneNumber</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>number</java-variable-name>
+ <xml-element-name>number</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jbws1260.Person</java-type>
+ <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1260/types">typeNS:Person</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>surname</java-variable-name>
+ <xml-element-name>surname</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+ <service-interface-mapping>
+ <service-interface>org.jboss.test.ws.jbws1260.PhoneBook_Service</service-interface>
+ <wsdl-service-name xmlns:serviceNS="http://test.jboss.org/ws/jbws1260">serviceNS:PhoneBook</wsdl-service-name>
+ <port-mapping>
+ <port-name>PhoneBookPort</port-name>
+ <java-port-name>PhoneBookPort</java-port-name>
+ </port-mapping>
+ </service-interface-mapping>
+ <service-endpoint-interface-mapping>
+ <service-endpoint-interface>org.jboss.test.ws.jbws1260.PhoneBook_PortType</service-endpoint-interface>
+ <wsdl-port-type xmlns:portTypeNS="http://test.jboss.org/ws/jbws1260">portTypeNS:PhoneBook</wsdl-port-type>
+ <wsdl-binding xmlns:bindingNS="http://test.jboss.org/ws/jbws1260">bindingNS:PhoneBookBinding</wsdl-binding>
+ <service-endpoint-method-mapping>
+ <java-method-name>lookup</java-method-name>
+ <wsdl-operation>lookup</wsdl-operation>
+ <method-param-parts-mapping>
+ <param-position>0</param-position>
+ <param-type>org.jboss.test.ws.jbws1260.Person</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1260">wsdlMsgNS:PhoneBook_lookup</wsdl-message>
+ <wsdl-message-part-name>parameters</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>1</param-position>
+ <param-type>org.jboss.test.ws.jbws1260.Person</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1260">wsdlMsgNS:PhoneBook_lookup</wsdl-message>
+ <wsdl-message-part-name>anotherPerson</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>2</param-position>
+ <param-type>org.jboss.test.ws.jbws1260.TelephoneNumber</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1260">wsdlMsgNS:PhoneBook_lookupResponse</wsdl-message>
+ <wsdl-message-part-name>result</wsdl-message-part-name>
+ <parameter-mode>OUT</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>3</param-position>
+ <param-type>org.jboss.test.ws.jbws1260.TelephoneNumber</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1260">wsdlMsgNS:PhoneBook_lookupResponse</wsdl-message>
+ <wsdl-message-part-name>anotherTelephoneNumber</wsdl-message-part-name>
+ <parameter-mode>OUT</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ </service-endpoint-method-mapping>
+ </service-endpoint-interface-mapping>
+</java-wsdl-mapping>
Property changes on: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wrapped-mapping.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wstools-config.xml
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wstools-config.xml 2007-01-12 13:49:58 UTC (rev 1945)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wstools-config.xml 2007-01-12 14:57:54 UTC (rev 1946)
@@ -0,0 +1,5 @@
+<configuration>
+ <wsdl-java location="resources/tools/jbws1260/scenario_AH/Wrapped.wsdl" parameter-style="wrapped">
+ <mapping file="wrapped-mapping.xml"/>
+ </wsdl-java>
+</configuration>
Property changes on: trunk/jbossws-tests/src/main/resources/tools/jbws1260/scenario_AH/wstools-config.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
18 years
JBossWS SVN: r1945 - in trunk: integration-jboss50 and 3 other directories.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-01-12 08:49:58 -0500 (Fri, 12 Jan 2007)
New Revision: 1945
Modified:
trunk/build/ant-import/build-thirdparty.xml
trunk/integration-jboss50/.classpath
trunk/jbossws-core/.classpath
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserType.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeMarshallerTestCase.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeUnmarshallerTestCase.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/WSToolsTest.java
Log:
Add test for [JBWS-800] ClassCastException when trying to marshal a SybaseTimestamp
Fetch sources for common-core, vfs, xb
Modified: trunk/build/ant-import/build-thirdparty.xml
===================================================================
--- trunk/build/ant-import/build-thirdparty.xml 2007-01-12 12:50:18 UTC (rev 1944)
+++ trunk/build/ant-import/build-thirdparty.xml 2007-01-12 13:49:58 UTC (rev 1945)
@@ -38,13 +38,16 @@
<get src="${jboss.repository}/javassist/${javassist}/lib/javassist.jar" dest="${thirdparty.dir}/javassist.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/backport-concurrent/${jboss-backport-concurrent}/lib/jboss-backport-concurrent.jar" dest="${thirdparty.dir}/jboss-backport-concurrent.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/common-core/${jboss-common-core}/lib/jboss-common-core.jar" dest="${thirdparty.dir}/jboss-common-core.jar" usetimestamp="true" verbose="true"/>
+ <get src="${jboss.repository}/jboss/common-core/${jboss-common-core}/lib/jboss-common-core-sources.jar" dest="${thirdparty.dir}/jboss-common-core-sources.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/common-logging-log4j/${jboss-common-logging-log4j}/lib/jboss-logging-log4j.jar" dest="${thirdparty.dir}/jboss-logging-log4j.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/common-logging-spi/${jboss-common-logging-spi}/lib/jboss-logging-spi.jar" dest="${thirdparty.dir}/jboss-logging-spi.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/ejb3/${jboss-ejb3}/bin/ejb3.deployer" dest="${thirdparty.dir}/ejb3.deployer.zip" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/jboss-vfs/${jboss-vfs}/lib/jboss-vfs.jar" dest="${thirdparty.dir}/jboss-vfs.jar" usetimestamp="true" verbose="true"/>
+ <get src="${jboss.repository}/jboss/jboss-vfs/${jboss-vfs}/lib/jboss-vfs-sources.jar" dest="${thirdparty.dir}/jboss-vfs-sources.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/jbossretro/${jboss-jbossretro}/lib/jbossretro.jar" dest="${thirdparty.dir}/jbossretro.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/jbossretro/${jboss-jbossretro}/lib/jbossretro-rt.jar" dest="${thirdparty.dir}/jbossretro-rt.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/jbossxb/${jboss-jbossxb}/lib/jboss-xml-binding.jar" dest="${thirdparty.dir}/jboss-xml-binding.jar" usetimestamp="true" verbose="true"/>
+ <get src="${jboss.repository}/jboss/jbossxb/${jboss-jbossxb}/lib/jboss-xml-binding-src.zip" dest="${thirdparty.dir}/jboss-xml-binding-src.zip" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-container.jar" dest="${thirdparty.dir}/jboss-container.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-dependency.jar" dest="${thirdparty.dir}/jboss-dependency.jar" usetimestamp="true" verbose="true"/>
<get src="${jboss.repository}/jboss/microcontainer/${jboss-microcontainer}/lib/jboss-deployers.jar" dest="${thirdparty.dir}/jboss-deployers.jar" usetimestamp="true" verbose="true"/>
Modified: trunk/integration-jboss50/.classpath
===================================================================
--- trunk/integration-jboss50/.classpath 2007-01-12 12:50:18 UTC (rev 1944)
+++ trunk/integration-jboss50/.classpath 2007-01-12 13:49:58 UTC (rev 1945)
@@ -6,7 +6,7 @@
<classpathentry combineaccessrules="false" kind="src" path="/jbossws-core"/>
<classpathentry kind="lib" path="/build/thirdparty/ejb3.deployer/jboss-ejb3.jar" sourcepath="/home/tdiesler/svn/jbossas/trunk/ejb3/src/main"/>
<classpathentry kind="lib" path="/build/thirdparty/jboss-deployers.jar"/>
- <classpathentry kind="lib" path="/build/thirdparty/jboss-vfs.jar"/>
+ <classpathentry kind="lib" path="/build/thirdparty/jboss-vfs.jar" sourcepath="/build/thirdparty/jboss-vfs-sources.jar"/>
<classpathentry kind="lib" path="/build/thirdparty/ant.jar"/>
<classpathentry kind="lib" path="/build/thirdparty/activation.jar"/>
<classpathentry kind="lib" path="/build/thirdparty/commons-logging.jar"/>
Modified: trunk/jbossws-core/.classpath
===================================================================
--- trunk/jbossws-core/.classpath 2007-01-12 12:50:18 UTC (rev 1944)
+++ trunk/jbossws-core/.classpath 2007-01-12 13:49:58 UTC (rev 1945)
@@ -16,7 +16,7 @@
<classpathentry kind="lib" path="/build/thirdparty/jboss-logging-spi.jar"/>
<classpathentry kind="lib" path="/build/thirdparty/jboss-remoting.jar"/>
<classpathentry kind="lib" path="/build/thirdparty/jboss-security-spi.jar"/>
- <classpathentry kind="lib" path="/build/thirdparty/jboss-xml-binding.jar"/>
+ <classpathentry kind="lib" path="/build/thirdparty/jboss-xml-binding.jar" sourcepath="/build/thirdparty/jboss-xml-binding-src.zip"/>
<classpathentry kind="lib" path="/build/thirdparty/wsdl4j.jar" sourcepath="/build/thirdparty/wsdl4j-1_5_2.zip"/>
<classpathentry kind="lib" path="/build/thirdparty/xmlsec.jar"/>
<classpathentry kind="lib" path="/build/thirdparty/ejb3.deployer/jboss-annotations-ejb3.jar"/>
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserType.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserType.java 2007-01-12 12:50:18 UTC (rev 1944)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserType.java 2007-01-12 13:49:58 UTC (rev 1945)
@@ -21,6 +21,8 @@
*/
package org.jboss.test.ws.common.jbossxb.simple;
+import java.util.Date;
+
/**
* @author Thomas.Diesler(a)jboss.org
* @since 29-Apr-2005
@@ -29,15 +31,17 @@
{
public int a;
private int b;
+ private Date d;
public SimpleUserType()
{
}
- public SimpleUserType(int a, int b)
+ public SimpleUserType(int a, int b, Date d)
{
this.a = a;
this.b = b;
+ this.d = d;
}
public int getB()
@@ -50,29 +54,40 @@
this.b = b;
}
+ public Date getD()
+ {
+ return d;
+ }
+
+ public void setD(Date d)
+ {
+ this.d = d;
+ }
+
public boolean equals(Object o)
{
if (this == o) return true;
if (!(o instanceof SimpleUserType)) return false;
- final SimpleUserType simpleUserType = (SimpleUserType)o;
+ SimpleUserType other = (SimpleUserType)o;
- if (a != simpleUserType.a) return false;
- if (b != simpleUserType.b) return false;
+ if (a != other.a) return false;
+ if (b != other.b) return false;
+ if (d == null && other.d != null) return false;
+ if (d != null && other.d == null) return false;
+ if (d != null && other.d != null && d.getTime() != other.d.getTime()) return false;
- return true;
+ return toString().equals(other.toString());
}
public int hashCode()
{
- int result;
- result = a;
- result = 29 * result + b;
- return result;
+ return toString().hashCode();
}
public String toString()
{
- return "[a=" + a + ",b=" + b + "]";
+ long time = d != null ? d.getTime() : 0;
+ return "[a=" + a + ",b=" + b + ",d=" + time + "]";
}
}
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeMarshallerTestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeMarshallerTestCase.java 2007-01-12 12:50:18 UTC (rev 1944)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeMarshallerTestCase.java 2007-01-12 13:49:58 UTC (rev 1945)
@@ -22,6 +22,8 @@
package org.jboss.test.ws.common.jbossxb.simple;
import java.io.StringWriter;
+import java.util.Date;
+import java.util.GregorianCalendar;
import javax.xml.namespace.QName;
@@ -29,6 +31,7 @@
import org.jboss.test.ws.tools.WSToolsTest;
import org.jboss.ws.core.jaxrpc.binding.jbossxb.JBossXBConstants;
import org.jboss.ws.core.jaxrpc.binding.jbossxb.JBossXBMarshallerImpl;
+import org.jboss.ws.core.jaxrpc.binding.jbossxb.MarshalException;
import org.jboss.ws.core.utils.DOMUtils;
import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
import org.jboss.ws.metadata.jaxrpcmapping.PackageMapping;
@@ -55,6 +58,7 @@
" <sequence>" +
" <element name='a' type='int'/>" +
" <element name='b' type='int'/>" +
+ " <element name='d' nillable='true' type='dateTime'/>" +
" </sequence>" +
" </complexType>" +
"</schema>";
@@ -66,6 +70,61 @@
{
SimpleUserType obj = new SimpleUserType();
+ String exp =
+ "<ns1:SimpleUser xmlns:ns1='" + TARGET_NAMESPACE + "' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>" +
+ " <a>0</a>" +
+ " <b>0</b>" +
+ " <d xsi:nil='1'/>" +
+ "</ns1:SimpleUser>";
+
+ String was = marshalSimpleType(obj);
+ assertEquals(DOMUtils.parse(exp), DOMUtils.parse(was));
+ }
+
+ public void testMarshallSimpleUserTypeWithDate() throws Exception
+ {
+ GregorianCalendar cal = new GregorianCalendar(1968, 11, 16);
+ SimpleUserType obj = new SimpleUserType(1, 2, cal.getTime());
+
+ String exp =
+ "<ns1:SimpleUser xmlns:ns1='" + TARGET_NAMESPACE + "' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>" +
+ " <a>1</a>" +
+ " <b>2</b>" +
+ " <d>1968-12-15T23:00:00.000Z</d>" +
+ "</ns1:SimpleUser>";
+
+ String was = marshalSimpleType(obj);
+ assertEquals(DOMUtils.parse(exp), DOMUtils.parse(was));
+ }
+
+ public void testMarshallSimpleUserTypeWithUserDate() throws Exception
+ {
+ class UserDate extends Date
+ {
+ public UserDate(long date)
+ {
+ super(date);
+ }
+ }
+
+ GregorianCalendar cal = new GregorianCalendar(1968, 11, 16);
+ UserDate userDate = new UserDate(cal.getTime().getTime());
+ SimpleUserType obj = new SimpleUserType(1, 2, userDate);
+
+ String exp =
+ "<ns1:SimpleUser xmlns:ns1='" + TARGET_NAMESPACE + "' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>" +
+ " <a>1</a>" +
+ " <b>2</b>" +
+ " <d>1968-12-15T23:00:00.000Z</d>" +
+ "</ns1:SimpleUser>";
+
+ System.out.println("FIXME: [JBWS-800] ClassCastException when trying to marshal a SybaseTimestamp");
+ //String was = marshalSimpleType(obj);
+ //assertEquals(DOMUtils.parse(exp), DOMUtils.parse(was));
+ }
+
+ private String marshalSimpleType(SimpleUserType obj) throws Exception, MarshalException
+ {
QName xmlName = new QName(TARGET_NAMESPACE, "SimpleUser", "ns1");
QName xmlType = new QName(TARGET_NAMESPACE, "SimpleUserType", "ns1");
@@ -83,14 +142,7 @@
String was = strwr.toString();
assertNotNull("Resulting fragment cannot be null", was);
assertTrue("Resulting fragment cannot be empty", was.length() > 0);
-
- String exp =
- "<ns1:SimpleUser xmlns:ns1='" + TARGET_NAMESPACE + "' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>" +
- " <a>0</a>" +
- " <b>0</b>" +
- "</ns1:SimpleUser>";
-
- assertEquals(DOMUtils.parse(exp), DOMUtils.parse(was));
+ return was;
}
public void testMarshallSimpleUserTypeNoPrefix() throws Exception
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeUnmarshallerTestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeUnmarshallerTestCase.java 2007-01-12 12:50:18 UTC (rev 1944)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/common/jbossxb/simple/SimpleUserTypeUnmarshallerTestCase.java 2007-01-12 13:49:58 UTC (rev 1945)
@@ -55,6 +55,7 @@
" <sequence>" +
" <element name='a' type='int'/>" +
" <element name='b' type='int'/>" +
+ " <element name='d' nillable='true' type='dateTime'/>" +
" </sequence>" +
" </complexType>" +
"</schema>";
@@ -77,10 +78,11 @@
unmarshaller.setProperty(JBossXBConstants.JBXB_JAVA_MAPPING, getJavaWSDLMapping());
String xml =
- "<ns1:SimpleUser xmlns:ns1='" + TARGET_NAMESPACE + "'>" +
- " <a>0</a>" +
- " <b>0</b>" +
- "</ns1:SimpleUser>";
+ "<ns1:SimpleUser xmlns:ns1='" + TARGET_NAMESPACE + "' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>" +
+ " <a>0</a>" +
+ " <b>0</b>" +
+ " <d xsi:nil='1'/>" +
+ "</ns1:SimpleUser>";
obj = (SimpleUserType)unmarshaller.unmarshal(new ByteArrayInputStream(xml.getBytes()));
@@ -103,7 +105,12 @@
unmarshaller.setProperty(JBossXBConstants.JBXB_TYPE_QNAME, xmlType);
unmarshaller.setProperty(JBossXBConstants.JBXB_JAVA_MAPPING, getJavaWSDLMapping());
- String xml = "<SimpleUser xmlns='" + TARGET_NAMESPACE + "'>" + " <a xmlns=''>0</a>" + " <b xmlns=''>0</b>" + "</SimpleUser>";
+ String xml =
+ "<ns1:SimpleUser xmlns:ns1='" + TARGET_NAMESPACE + "' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>" +
+ " <a>0</a>" +
+ " <b>0</b>" +
+ " <d xsi:nil='1'/>" +
+ "</ns1:SimpleUser>";
obj = (SimpleUserType)unmarshaller.unmarshal(new ByteArrayInputStream(xml.getBytes()));
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/WSToolsTest.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/WSToolsTest.java 2007-01-12 12:50:18 UTC (rev 1944)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/WSToolsTest.java 2007-01-12 13:49:58 UTC (rev 1945)
@@ -22,7 +22,6 @@
package org.jboss.test.ws.tools;
import java.io.File;
-import java.io.FileWriter;
import java.io.IOException;
import java.net.MalformedURLException;
import java.net.URL;
@@ -39,12 +38,9 @@
import org.jboss.test.ws.tools.validation.WSDL11Validator;
import org.jboss.test.ws.tools.validation.WSDLValidator;
import org.jboss.ws.Constants;
-import org.jboss.ws.core.jaxrpc.LiteralTypeMapping;
import org.jboss.ws.core.jaxrpc.Style;
import org.jboss.ws.core.utils.DOMUtils;
-import org.jboss.ws.core.utils.DOMWriter;
import org.jboss.ws.core.utils.JavaUtils;
-import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
import org.jboss.ws.metadata.wsdl.xmlschema.JBossXSModel;
import org.jboss.ws.tools.JavaToWSDL;
@@ -52,7 +48,6 @@
import org.jboss.ws.tools.WSToolsConstants;
import org.jboss.ws.tools.client.ServiceCreator;
import org.jboss.ws.tools.exceptions.JBossWSToolsException;
-import org.jboss.ws.tools.mapping.MappingFileGenerator;
import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
import org.w3c.dom.Element;
18 years
JBossWS SVN: r1944 - in trunk: jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410 and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-01-12 07:50:18 -0500 (Fri, 12 Jan 2007)
New Revision: 1944
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java
Log:
Propagate WSTimeoutException to client
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 12:48:02 UTC (rev 1943)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 12:50:18 UTC (rev 1944)
@@ -51,6 +51,7 @@
import org.jboss.ws.Constants;
import org.jboss.ws.core.CommonClient;
import org.jboss.ws.core.CommonMessageContext;
+import org.jboss.ws.core.WSTimeoutException;
import org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializerFactory;
import org.jboss.ws.core.jaxrpc.binding.JBossXBSerializerFactory;
import org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl;
@@ -616,6 +617,10 @@
{
throw rex;
}
+ catch (WSTimeoutException toex)
+ {
+ throw toex;
+ }
catch (Exception ex)
{
throw new RemoteException("Call invocation failed", ex);
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java 2007-01-12 12:48:02 UTC (rev 1943)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java 2007-01-12 12:50:18 UTC (rev 1944)
@@ -23,7 +23,6 @@
import java.io.File;
import java.net.URL;
-import java.rmi.RemoteException;
import javax.xml.namespace.QName;
import javax.xml.rpc.Service;
@@ -34,7 +33,6 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.WSException;
import org.jboss.ws.core.WSTimeoutException;
import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
import org.jboss.ws.core.jaxrpc.StubExt;
@@ -85,11 +83,9 @@
port.echoSimple("500");
fail("socket timeout expected");
}
- catch (RemoteException ex)
+ catch (WSTimeoutException ex)
{
- assertTrue ("WSTimeoutException expected", ex.getCause() instanceof WSTimeoutException);
- WSTimeoutException toex = (WSTimeoutException)ex.getCause();
- assertEquals(100, toex.getTimeout());
+ assertEquals(100, ex.getTimeout());
}
}
}
18 years
JBossWS SVN: r1943 - in trunk: jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc and 16 other directories.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-01-12 07:48:02 -0500 (Fri, 12 Jan 2007)
New Revision: 1943
Added:
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WebservicesXMLCreatorImpl.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java
trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParameters_Service.java
trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParameters_Service.java
Removed:
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java
trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java
trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java
trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml
trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml
trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl
trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml
Log:
[JBWS-1384] - Attachment parts with doclit message
Change generate service interface name to end with 'Service'
Fix WSTools public API
Format generated webservices.xml
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -242,6 +242,9 @@
// Bind the request message
SOAPMessage reqMessage = (SOAPMessage)binding.bindRequestMessage(opMetaData, epInv, unboundHeaders);
+
+ // Add possible attachment parts
+ addAttachmentParts(reqMessage);
setOutboundContextProperties();
@@ -295,7 +298,7 @@
// at pivot the message context might be replaced
msgContext = processPivot(msgContext);
- // Associate current message with message context
+ // Associate response message with message context
msgContext.setSOAPMessage(resMessage);
}
@@ -342,6 +345,11 @@
}
}
+ protected void addAttachmentParts(SOAPMessage reqMessage)
+ {
+ // By default do nothing
+ }
+
protected abstract CommonMessageContext processPivot(CommonMessageContext requestContext);
protected CommonBindingProvider getCommonBindingProvider()
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -42,7 +42,10 @@
import javax.xml.rpc.Stub;
import javax.xml.rpc.encoding.SerializerFactory;
import javax.xml.rpc.soap.SOAPFaultException;
+import javax.xml.soap.AttachmentPart;
+import javax.xml.soap.MessageFactory;
import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPMessage;
import org.jboss.logging.Logger;
import org.jboss.ws.Constants;
@@ -85,6 +88,8 @@
private Map<QName, UnboundHeader> unboundHeaders = new LinkedHashMap<QName, UnboundHeader>();
// A Map<String,Object> of Call properties
private Map<String, Object> properties = new HashMap<String, Object>();
+ // A List<AttachmentPart> of attachment parts set through the proxy
+ private List<AttachmentPart> attachmentParts = new ArrayList<AttachmentPart>();
// The set of supported properties
private static final Set<String> standardProperties = new HashSet<String>();
@@ -219,7 +224,40 @@
{
return unboundHeaders.keySet().iterator();
}
+
+ /**
+ * Adds the given AttachmentPart object to the outgoing SOAPMessage.
+ * An AttachmentPart object must be created before it can be added to a message.
+ */
+ public void addAttachmentPart(AttachmentPart part)
+ {
+ attachmentParts.add(part);
+ }
+ /**
+ * Clears the list of attachment parts.
+ */
+ public void clearAttachmentParts()
+ {
+ attachmentParts.clear();
+ }
+
+ /**
+ * Creates a new empty AttachmentPart object.
+ */
+ public AttachmentPart createAttachmentPart()
+ {
+ try
+ {
+ MessageFactory factory = MessageFactory.newInstance();
+ return factory.createMessage().createAttachmentPart();
+ }
+ catch (SOAPException ex)
+ {
+ throw new JAXRPCException("Cannot create attachment part");
+ }
+ }
+
/** Gets the address of a target service endpoint.
*/
public String getTargetEndpointAddress()
@@ -590,6 +628,16 @@
}
@Override
+ protected void addAttachmentParts(SOAPMessage reqMessage)
+ {
+ for (AttachmentPart part : attachmentParts)
+ {
+ log.debug("Adding attachment part: " + part.getContentId());
+ reqMessage.addAttachmentPart(part);
+ }
+ }
+
+ @Override
protected boolean callRequestHandlerChain(QName portName, HandlerType type)
{
SOAPMessageContextJAXRPC msgContext = (SOAPMessageContextJAXRPC)MessageContextAssociation.peekMessageContext();
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -25,6 +25,7 @@
import javax.xml.namespace.QName;
import javax.xml.rpc.ParameterMode;
+import javax.xml.soap.AttachmentPart;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
@@ -109,7 +110,23 @@
* A propriatory extension, that is not part of JAXRPC.
*/
Iterator getUnboundHeaders();
+
+ /**
+ * Adds the given AttachmentPart object to the outgoing SOAPMessage.
+ * An AttachmentPart object must be created before it can be added to a message.
+ */
+ void addAttachmentPart(AttachmentPart attachmentpart);
+ /**
+ * Clears the list of attachment parts.
+ */
+ void clearAttachmentParts();
+
+ /**
+ * Creates a new empty AttachmentPart object.
+ */
+ AttachmentPart createAttachmentPart();
+
/**
* Get the current port configuration file
* A propriatory extension, that is not part of JAXRPC.
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -200,6 +200,11 @@
this.serviceEndpointInvokerJSE = invoker;
}
+ public String getImplementationVersion()
+ {
+ return UnifiedMetaData.getImplementationVersion();
+ }
+
public List<ObjectName> getServiceEndpoints()
{
ArrayList<ObjectName> list = new ArrayList<ObjectName>();
@@ -616,7 +621,7 @@
public void create() throws Exception
{
- log.info(UnifiedMetaData.getImplementationVersion());
+ log.info(getImplementationVersion());
MBeanServer server = getJMXServer();
if (server != null)
{
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -38,6 +38,8 @@
// default object name
static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.ws:service=ServiceEndpointManager");
+ String getImplementationVersion();
+
String getWebServiceHost();
void setWebServiceHost(String host) throws UnknownHostException;
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -386,15 +386,20 @@
pmd.setInHeader(true);
}
- for (WSDLMIMEPart mimePart : bindingInput.getMimeParts())
+ // we don't support swa binding parameters in document style
+ // http://jira.jboss.org/jira/browse/JBWS-1384
+ if (opMetaData.getStyle() == Style.RPC)
{
- String partName = mimePart.getPartName();
- QName xmlName = new QName(partName);
- QName xmlType = mimePart.getXmlType();
+ for (WSDLMIMEPart mimePart : bindingInput.getMimeParts())
+ {
+ String partName = mimePart.getPartName();
+ QName xmlName = new QName(partName);
+ QName xmlType = mimePart.getXmlType();
- ParameterMetaData pmd = buildInputParameter(opMetaData, wsdlOperation, seiMethodMapping, typeMapping, partName, xmlName, xmlType, wsdlPosition++, false);
- pmd.setSwA(true);
- pmd.setMimeTypes(mimePart.getMimeTypes());
+ ParameterMetaData pmd = buildInputParameter(opMetaData, wsdlOperation, seiMethodMapping, typeMapping, partName, xmlName, xmlType, wsdlPosition++, false);
+ pmd.setSwA(true);
+ pmd.setMimeTypes(mimePart.getMimeTypes());
+ }
}
return wsdlPosition;
@@ -638,7 +643,7 @@
throw new IllegalArgumentException("wsdl-message-message mapping required for document/literal wrapped");
String elementName = wsdlMessageMapping.getWsdlMessagePartName();
- String variable = variableMap.get(wsdlMessageMapping.getWsdlMessagePartName());
+ String variable = variableMap.get(elementName);
if (variable == null)
throw new IllegalArgumentException("Could not determine variable name for element: " + elementName);
Deleted: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,231 +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.tools;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.io.InputStream;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.WSException;
-import org.jboss.ws.metadata.webservices.PortComponentMetaData;
-import org.jboss.ws.metadata.webservices.WebserviceDescriptionMetaData;
-import org.jboss.ws.metadata.webservices.WebservicesFactory;
-import org.jboss.ws.metadata.webservices.WebservicesMetaData;
-import org.jboss.ws.tools.interfaces.WSDotXMLCreatorIntf;
-import org.jboss.xb.binding.JBossXBException;
-import org.jboss.xb.binding.ObjectModelFactory;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-
-/**
- * Creates the webservices.xml deployment descriptor
- * @author <mailto:Anil.Saldhana@jboss.org>Anil Saldhana
- * @since Jun 20, 2005
- */
-public class WSDotXMLCreator implements WSDotXMLCreatorIntf
-{
- // provide logging
- protected static final Logger log = Logger.getLogger(WSDotXMLCreator.class);
- protected String targetNamespace = null;
-
- protected String seiName = null;
-
- protected String portName = null;
-
- protected String serviceName = null;
-
- protected String servletLink = null;
-
- protected String ejbLink = null;
-
- protected String wsdlFile = null;
- protected String mappingFile = null;
-
- protected boolean append = false;
-
- public WSDotXMLCreator()
- {
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setTargetNamespace(java.lang.String)
- */
- public void setTargetNamespace(String targetNamespace)
- {
- this.targetNamespace = targetNamespace;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setSeiName(java.lang.String)
- */
- public void setSeiName(String seiName)
- {
- this.seiName = seiName;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setPortName(java.lang.String)
- */
- public void setPortName(String portName)
- {
- this.portName = portName;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setServiceName(java.lang.String)
- */
- public void setServiceName(String serviceName)
- {
- this.serviceName = serviceName;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setEjbLink(java.lang.String)
- */
- public void setEjbLink(String ejbLink)
- {
- this.ejbLink = ejbLink;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setServletLink(java.lang.String)
- */
- public void setServletLink(String servletLink)
- {
- this.servletLink = servletLink;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setMappingFile(java.lang.String)
- */
- public void setMappingFile(String mappingFile)
- {
- this.mappingFile = mappingFile;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setWsdlFile(java.lang.String)
- */
- public void setWsdlFile(String wsdlFile)
- {
- this.wsdlFile = wsdlFile;
- }
-
- public void setAppend(boolean append)
- {
- this.append = append;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#generateWSXMLDescriptor(java.io.File)
- */
- public void generateWSXMLDescriptor(File wsXmlFile) throws IOException
- {
- WebservicesMetaData webservices = constructWSMetaData();
-
- // handle append flag
- if (append && wsXmlFile.exists())
- {
- WebservicesMetaData existingWebservices;
-
- // parse existing webservices descriptor
- InputStream wsXmlStream = new FileInputStream(wsXmlFile);
- try
- {
- Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
- ObjectModelFactory factory = new WebservicesFactory(wsXmlFile.toURL());
- existingWebservices = (WebservicesMetaData)unmarshaller.unmarshal(wsXmlStream, factory, null);
- }
- catch (JBossXBException e)
- {
- throw new WSException("Could not unmarshal existing webservices descriptor: " + wsXmlFile, e);
- }
- finally
- {
- wsXmlStream.close();
- }
-
- // append generated webservice-descriptions to existing descriptor
- for (WebserviceDescriptionMetaData webserviceDescription : webservices.getWebserviceDescriptions())
- existingWebservices.addWebserviceDescription(webserviceDescription);
-
- webservices = existingWebservices;
- }
-
- // (re-)write generated webservices descriptor to file
- FileWriter fw = new FileWriter(wsXmlFile);
- fw.write(webservices.serialize());
- fw.close();
- }
-
- //PRIVATE METHODS
-
- private WebservicesMetaData constructWSMetaData()
- {
- WebservicesMetaData wm = new WebservicesMetaData();
- WebserviceDescriptionMetaData wsdm = new WebserviceDescriptionMetaData(wm);
- populateWebserviceDescriptionMetaData(wsdm);
- wm.addWebserviceDescription(wsdm);
- return wm;
- }
-
- private void populateWebserviceDescriptionMetaData(WebserviceDescriptionMetaData wsdm)
- {
- checkEssentials();
- wsdm.setWebserviceDescriptionName(this.serviceName);
- wsdm.setWsdlFile(this.wsdlFile);
- wsdm.setJaxrpcMappingFile(this.mappingFile);
- PortComponentMetaData pm1 = new PortComponentMetaData(wsdm);
- pm1.setPortComponentName(portName);
- pm1.setWsdlPort(new QName(this.targetNamespace, portName, "portNS"));
- pm1.setServiceEndpointInterface(seiName);
- if (this.servletLink != null && this.servletLink.length() > 0)
- pm1.setServletLink(this.servletLink);
- else pm1.setEjbLink(this.ejbLink);
- wsdm.addPortComponent(pm1);
- }
-
- private void checkEssentials()
- {
- if (serviceName == null)
- throw new WSException("serviceName is null");
- if (wsdlFile == null)
- throw new WSException("wsdlFile is null");
- if (mappingFile == null)
- throw new WSException("mappingFile is null");
- if (targetNamespace == null)
- throw new WSException("targetNamespace is null");
- if (portName == null)
- throw new WSException("portName is null");
- if (seiName == null)
- throw new WSException("seiName is null");
- if (servletLink == null && ejbLink == null)
- throw new WSException("Either servletLink or ejbLink should not be null");
- if (servletLink != null && ejbLink != null)
- throw new WSException("One of servletLink or ejbLink should be null");
- }
-}
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -45,9 +45,6 @@
{
private static Logger log = Logger.getLogger(WSTools.class);
- private Configuration config;
- private String outputDir = ".";
-
/**
* Entry point for the command line scripts.
* Just passes the arguments to
@@ -63,28 +60,35 @@
/**
* Entry point for the programmatic use
- *
- * @param args
- * @throws IOException
*/
- public void generate(String[] args) throws IOException
+ public boolean generate(String configLocation, String outputDir) throws IOException
{
- boolean knownArgument = false;
+ ToolsSchemaConfigReader configReader = new ToolsSchemaConfigReader();
+ Configuration config = configReader.readConfig(configLocation);
+
+ return process(config, outputDir);
+ }
+
+ /**
+ * Entry point for the programmatic use
+ */
+ public boolean generate(String[] args) throws IOException
+ {
+ String configLocation = null;
+ String outputDir = null;
for (int i = 0; i < args.length; i++)
{
String arg = args[i];
if ("-config".equals(arg))
{
- readToolsConfiguration(args[i + 1]);
- knownArgument = true;
+ configLocation = args[i + 1];
i++;
}
else if ("-dest".equals(arg))
{
outputDir = args[i + 1];
- knownArgument = true;
i++;
}
@@ -94,7 +98,7 @@
int tokens = st.countTokens();
URL[] urls = new URL[tokens];
- for(int j = 0; j < tokens; j++)
+ for (int j = 0; j < tokens; j++)
{
String token = st.nextToken();
urls[j] = new File(token).toURL();
@@ -103,50 +107,39 @@
ClassLoader ctxLoader = Thread.currentThread().getContextClassLoader();
URLClassLoader urlLoader = new URLClassLoader(urls, ctxLoader);
Thread.currentThread().setContextClassLoader(urlLoader);
- knownArgument = true;
i++;
}
+ else
+ {
+ System.out.println("Usage: wstools (-classpath|-cp) <classpath> -config <config> [-dest <destination path>]");
+ System.exit(1);
+ }
}
- if (! knownArgument)
- {
- System.out.println("Usage: wstools (-classpath|-cp) <classpath> -config <config> [-dest <destination path>]");
- System.exit(1);
- }
-
- if (config == null)
- throw new IllegalArgumentException("wstools config not found");
-
- process();
+ return generate(configLocation, outputDir);
}
- private void process() throws IOException
+ private boolean process(Configuration config, String outputDir) throws IOException
{
- ToolsHelper helper = new ToolsHelper();
if (config == null)
- throw new WSException("Configuration is null");
-
- boolean processed = false;
+ throw new IllegalArgumentException("Configuration is null");
+
+ if (outputDir == null)
+ outputDir = ".";
+
+ ToolsHelper helper = new ToolsHelper();
if (config.getJavaToWSDLConfig(false) != null)
{
helper.handleJavaToWSDLGeneration(config, outputDir);
- processed = true;
}
-
- if (config.getWSDLToJavaConfig(false) != null)
+ else if (config.getWSDLToJavaConfig(false) != null)
{
helper.handleWSDLToJavaGeneration(config, outputDir);
- processed = true;
}
-
- if (!processed)
+ else
+ {
throw new WSException("Nothing done, Configuration source must have JavaToWSDL or WSDLToJava specified");
+ }
+ return true;
}
-
- private void readToolsConfiguration(String filename) throws IOException
- {
- log.debug("Config file name=" + filename);
- ToolsSchemaConfigReader configReader = new ToolsSchemaConfigReader();
- config = configReader.readConfig(filename);
- }
}
Copied: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WebservicesXMLCreatorImpl.java (from rev 1938, branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WebservicesXMLCreatorImpl.java)
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -210,9 +210,12 @@
private void generateServiceFile(WSDLService wsdlService) throws IOException
{
String serviceName = wsdlService.getName().toString();
+ if (serviceName.endsWith("Service") == false)
+ serviceName = serviceName + "Service";
+
//Check if the serviceName conflicts with a portType or interface name
if(wsdl.getInterface(new NCName(serviceName)) != null )
- serviceName += "_Service";
+ serviceName = new StringBuilder(serviceName).insert(serviceName.lastIndexOf("Service"), '_').toString();
StringBuilder buf = new StringBuilder();
generateHeader(buf);
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -60,13 +60,13 @@
import org.jboss.ws.tools.JavaWriter;
import org.jboss.ws.tools.NamespacePackageMapping;
import org.jboss.ws.tools.WSDLToJava;
-import org.jboss.ws.tools.WSDotXMLCreator;
+import org.jboss.ws.tools.WebservicesXMLCreatorImpl;
import org.jboss.ws.tools.Configuration.GlobalConfig;
import org.jboss.ws.tools.Configuration.JavaToWSDLConfig;
import org.jboss.ws.tools.Configuration.WSDLToJavaConfig;
import org.jboss.ws.tools.XSDTypeToJava.VAR;
import org.jboss.ws.tools.client.ServiceCreator;
-import org.jboss.ws.tools.interfaces.WSDotXMLCreatorIntf;
+import org.jboss.ws.tools.interfaces.WebservicesXMLCreator;
import org.jboss.ws.tools.mapping.MappingFileGenerator;
import org.jboss.ws.tools.wsdl.WSDLWriter;
@@ -145,7 +145,7 @@
//Generate the webservices.xml file
if (j2wc.wsxmlFileNeeded)
{
- WSDotXMLCreatorIntf wscr = new WSDotXMLCreator();
+ WebservicesXMLCreator wscr = new WebservicesXMLCreatorImpl();
wscr.setTargetNamespace(j2wc.targetNamespace);
//wscr.setLocation(new File(outDir).toURL());
wscr.setSeiName(j2wc.endpointName);
@@ -336,7 +336,7 @@
seiName = seiPackage + "." + wsdlToJava.getServiceEndpointInterfaceName(wsdl.getInterfaces()[0]);
}
- WSDotXMLCreatorIntf wscr = new WSDotXMLCreator();
+ WebservicesXMLCreator wscr = new WebservicesXMLCreatorImpl();
wscr.setTargetNamespace(wsdl.getTargetNamespace());
wscr.setSeiName(seiName);
wscr.setServiceName(serviceName);
Deleted: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,88 +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.tools.interfaces;
-
-import java.io.File;
-import java.io.IOException;
-
-/**
- * Defines the contract for webservices.xml creating agents
- * @author <mailto:Anil.Saldhana@jboss.org>Anil Saldhana
- * @since Jul 23, 2005
- */
-
-public interface WSDotXMLCreatorIntf
-{
-
- /**
- * Generate the webservices.xml file
- * @throws IOException
- */
- public void generateWSXMLDescriptor(File file) throws IOException;
-
- /**
- * @param targetNamespace The targetNamespace to set.
- */
- public void setTargetNamespace(String targetNamespace);
-
- /**
- * @param seiName The seiName to set.
- */
- public void setSeiName(String seiName);
-
- /**
- * @param portName The portName to set.
- */
- public void setPortName(String portName);
-
- /**
- * @param serviceName The serviceName to set.
- */
- public void setServiceName(String serviceName);
-
- /**
- * @param ejbLink The ejbLink to set.
- */
- public void setEjbLink(String ejbLink);
-
- /**
- * @param servletLink The servletLink to set.
- */
- public void setServletLink(String servletLink);
-
- /**
- * @param mappingFileEntry The mapping file entry
- */
- public void setMappingFile(String mappingFileEntry);
-
- /**
- *
- * @param wsdlFileEntry The wsdl-file entry
- */
- public void setWsdlFile(String wsdlFileEntry);
-
- /**
- *
- * @param append add ws descriptions to existing webservices.xml file, if any
- */
- public void setAppend(boolean append);
-}
Copied: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java (from rev 1938, branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java)
Copied: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java (from rev 1938, branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java)
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -28,15 +28,18 @@
import javax.xml.rpc.Service;
import javax.xml.rpc.ServiceFactory;
import javax.xml.rpc.Stub;
+import javax.xml.soap.AttachmentPart;
import junit.framework.Test;
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.StubExt;
+import org.jboss.ws.tools.WSTools;
/**
- * Cannot obtain java/xml type mapping for attachment part
+ * Attachment parts with doclit message
*
* http://jira.jboss.org/jira/browse/JBWS-1384
*
@@ -55,7 +58,7 @@
protected void setUp() throws Exception
{
super.setUp();
- if (port == null && false)
+ if (port == null)
{
ServiceFactoryImpl factory = (ServiceFactoryImpl)ServiceFactory.newInstance();
URL wsdlURL = new File("resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl").toURL();
@@ -67,15 +70,21 @@
}
}
+ public void testWsdlToJava() throws Exception
+ {
+ WSTools wstools = new WSTools();
+ boolean ret = wstools.generate("resources/jaxrpc/jbws1384/wstools-config.xml", "./wstools/jbws1384");
+ assertTrue("wstools success", ret);
+ }
+
public void testEndpoint() throws Exception
{
- if (true)
- {
- System.out.println("FIXME: [JBWS-1384] - Cannot obtain java/xml type mapping for attachment part");
- return;
- }
+ StubExt stub = (StubExt)port;
+ AttachmentPart part = stub.createAttachmentPart();
+ part.setContent("attached-string", "text/plain");
+ stub.addAttachmentPart(part);
- String retStr = port.invokeAttach("user", "pass", "op", "<root/>", "attach");
- assertEquals("attach", retStr);
+ String retStr = port.invokeAttach("user", "pass", "op", "<root/>");
+ assertEquals("[user=user,pass=pass,op=op,xml=<root/>] attached-string", retStr);
}
}
Deleted: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,56 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jaxrpc.jbws1384;
-
-
-public class ParaListType {
- protected java.lang.String username;
- protected java.lang.String password;
- protected java.lang.String operationName;
- protected java.lang.String inputXML;
-
- public ParaListType() {
- }
-
- public ParaListType(java.lang.String username, java.lang.String password, java.lang.String operationName, java.lang.String inputXML) {
- this.username = username;
- this.password = password;
- this.operationName = operationName;
- this.inputXML = inputXML;
- }
-
- public java.lang.String getUsername() {
- return username;
- }
-
- public void setUsername(java.lang.String username) {
- this.username = username;
- }
-
- public java.lang.String getPassword() {
- return password;
- }
-
- public void setPassword(java.lang.String password) {
- this.password = password;
- }
-
- public java.lang.String getOperationName() {
- return operationName;
- }
-
- public void setOperationName(java.lang.String operationName) {
- this.operationName = operationName;
- }
-
- public java.lang.String getInputXML() {
- return inputXML;
- }
-
- public void setInputXML(java.lang.String inputXML) {
- this.inputXML = inputXML;
- }
-}
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,26 +1,27 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
+/*
+ * JBossWS WS-Tools Generated Source
+ *
+ * Generation Date: Fri Jan 12 10:48:13 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ */
package org.jboss.test.ws.jaxrpc.jbws1384;
-public class ResponseType {
- protected java.lang.String result;
-
- public ResponseType() {
- }
-
- public ResponseType(java.lang.String result) {
- this.result = result;
- }
-
- public java.lang.String getResult() {
- return result;
- }
-
- public void setResult(java.lang.String result) {
- this.result = result;
- }
+public class ResponseType
+{
+
+protected java.lang.String result;
+public ResponseType(){}
+
+public ResponseType(java.lang.String result){
+this.result=result;
}
+public java.lang.String getResult() { return result ;}
+
+public void setResult(java.lang.String result){ this.result=result; }
+
+}
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -21,15 +21,48 @@
*/
package org.jboss.test.ws.jaxrpc.jbws1384;
+import javax.xml.rpc.ServiceException;
+import javax.xml.rpc.handler.soap.SOAPMessageContext;
+import javax.xml.rpc.server.ServiceLifecycle;
+import javax.xml.rpc.server.ServletEndpointContext;
+import javax.xml.soap.AttachmentPart;
+import javax.xml.soap.SOAPException;
+
import org.jboss.logging.Logger;
-public class TranslatorBean implements TransmulatorInterface
+public class TranslatorBean implements TransmulatorInterface, ServiceLifecycle
{
private Logger log = Logger.getLogger(TranslatorBean.class);
- public String invokeAttach(String username, String password, String operationName, String inputXML, String attachmentContents)
+ private ServletEndpointContext sepCtx;
+
+ public String invokeAttach(String username, String password, String operationName, String inputXML)
{
- log.info("[user=" + username + ",pass=" + password + ",op=" + operationName + ",xml=" + inputXML + ",attach=" + attachmentContents + "]");
- return attachmentContents;
+ String reqMessage = "[user=" + username + ",pass=" + password + ",op=" + operationName + ",xml=" + inputXML + "]";
+
+ // Get attached string
+ String attachedStr = null;
+ try
+ {
+ SOAPMessageContext msgContext = (SOAPMessageContext)sepCtx.getMessageContext();
+ AttachmentPart part = (AttachmentPart)msgContext.getMessage().getAttachments().next();
+ attachedStr = (String)part.getContent();
+ }
+ catch (SOAPException ex)
+ {
+ throw new RuntimeException(ex);
+ }
+
+ log.info(reqMessage + " " + attachedStr);
+ return reqMessage + " " + attachedStr;
}
+
+ public void init(Object context) throws ServiceException
+ {
+ this.sepCtx = (ServletEndpointContext)context;
+ }
+
+ public void destroy()
+ {
+ }
}
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,14 +1,15 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
+/*
+ * JBossWS WS-Tools Generated Source
+ *
+ * Generation Date: Fri Jan 12 10:48:13 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ */
package org.jboss.test.ws.jaxrpc.jbws1384;
+public interface TransmulatorInterface extends java.rmi.Remote
+{
-import java.rmi.Remote;
-import java.rmi.RemoteException;
-
-public interface TransmulatorInterface extends Remote
-{
- public String invokeAttach(String username, String password, String operationName, String inputXML, String attachmentContents) throws RemoteException;
+ public java.lang.String invokeAttach(java.lang.String username, java.lang.String password, java.lang.String operationName, java.lang.String inputXML) throws java.rmi.RemoteException;
}
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -162,7 +162,7 @@
{
String currentFile = generatedFiles[i];
- boolean matched = "PhoneBook_Service.java".equals(currentFile);
+ boolean matched = "PhoneBookService.java".equals(currentFile);
for (int j = 0; j < expectedFiles.length && (matched == false); j++)
matched = currentFile.equals(expectedFiles[j]);
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -877,7 +877,7 @@
{
String currentFile = generatedFiles[i];
- boolean matched = "PhoneBook_Service.java".equals(currentFile);
+ boolean matched = "PhoneBookService.java".equals(currentFile);
for (int j = 0; j < expectedFiles.length && (matched == false); j++)
matched = currentFile.equals(expectedFiles[j]);
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -48,7 +48,7 @@
public String getServiceName()
{
- return "InOutParametersService_Service";
+ return "InOutParameters_Service";
}
public void checkGeneratedUserTypes()
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -47,7 +47,7 @@
public String getServiceName()
{
- return "OutParametersService_Service";
+ return "OutParameters_Service";
}
public void checkGeneratedUserTypes() throws Exception
Modified: trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml
===================================================================
--- trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,110 +1,99 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1"
- xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
- <package-mapping>
- <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
- <namespaceURI>http://org.jboss.test.webservice/samples2</namespaceURI>
- </package-mapping>
- <package-mapping>
- <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
- <namespaceURI>http://org.jboss.test.webservice/samples2/types</namespaceURI>
- </package-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jaxrpc.jbws1384.ParaListType</java-type>
- <root-type-qname xmlns:typeNS="http://org.jboss.test.webservice/samples2/types">typeNS:paraListType</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>username</java-variable-name>
- <xml-element-name>username</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>password</java-variable-name>
- <xml-element-name>password</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>operationName</java-variable-name>
- <xml-element-name>operationName</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>inputXML</java-variable-name>
- <xml-element-name>inputXML</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jaxrpc.jbws1384.ResponseType</java-type>
- <root-type-qname xmlns:typeNS="http://org.jboss.test.webservice/samples2/types">typeNS:responseType</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>result</java-variable-name>
- <xml-element-name>result</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <service-interface-mapping>
- <service-interface>org.jboss.test.ws.jaxrpc.jbws1384.Gasherbrum</service-interface>
- <wsdl-service-name xmlns:serviceNS="http://org.jboss.test.webservice/samples2">serviceNS:Gasherbrum</wsdl-service-name>
- <port-mapping>
- <port-name>TransmulatorInterfacePort</port-name>
- <java-port-name>TransmulatorInterfacePort</java-port-name>
- </port-mapping>
- </service-interface-mapping>
- <service-endpoint-interface-mapping>
- <service-endpoint-interface>org.jboss.test.ws.jaxrpc.jbws1384.TransmulatorInterface</service-endpoint-interface>
- <wsdl-port-type xmlns:portTypeNS="http://org.jboss.test.webservice/samples2">portTypeNS:TransmulatorInterface</wsdl-port-type>
- <wsdl-binding xmlns:bindingNS="http://org.jboss.test.webservice/samples2">bindingNS:TransmulatorInterfaceBinding</wsdl-binding>
- <service-endpoint-method-mapping>
- <java-method-name>invokeAttach</java-method-name>
- <wsdl-operation>invokeAttach</wsdl-operation>
- <wrapped-element/>
- <method-param-parts-mapping>
- <param-position>0</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>username</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>1</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>password</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>2</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>operationName</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>3</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>inputXML</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>4</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>attachmentContents</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <wsdl-return-value-mapping>
- <method-return-value>java.lang.String</method-return-value>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachResponse</wsdl-message>
- <wsdl-message-part-name>result</wsdl-message-part-name>
- </wsdl-return-value-mapping>
- </service-endpoint-method-mapping>
- </service-endpoint-interface-mapping>
+<?xml version='1.0' encoding='UTF-8'?><java-wsdl-mapping version='1.1' xmlns='http://java.sun.com/xml/ns/j2ee' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd'>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
+ <namespaceURI>http://org.jboss.test.webservice/samples2/types</namespaceURI>
+ </package-mapping>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
+ <namespaceURI>http://org.jboss.test.webservice/samples2</namespaceURI>
+ </package-mapping>
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jaxrpc.jbws1384.InvokeAttachType</java-type>
+ <root-type-qname xmlns:typeNS='http://org.jboss.test.webservice/samples2/types'>typeNS:invokeAttachType</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>username</java-variable-name>
+ <xml-element-name>username</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>password</java-variable-name>
+ <xml-element-name>password</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>operationName</java-variable-name>
+ <xml-element-name>operationName</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>inputXML</java-variable-name>
+ <xml-element-name>inputXML</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jaxrpc.jbws1384.ResponseType</java-type>
+ <root-type-qname xmlns:typeNS='http://org.jboss.test.webservice/samples2/types'>typeNS:responseType</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>result</java-variable-name>
+ <xml-element-name>result</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+ <service-interface-mapping>
+ <service-interface>org.jboss.test.ws.jaxrpc.jbws1384.Gasherbrum</service-interface>
+ <wsdl-service-name xmlns:serviceNS='http://org.jboss.test.webservice/samples2'>serviceNS:Gasherbrum</wsdl-service-name>
+ <port-mapping>
+ <port-name>TransmulatorInterfacePort</port-name>
+ <java-port-name>TransmulatorInterfacePort</java-port-name>
+ </port-mapping>
+ </service-interface-mapping>
+ <service-endpoint-interface-mapping>
+ <service-endpoint-interface>org.jboss.test.ws.jaxrpc.jbws1384.TransmulatorInterface</service-endpoint-interface>
+ <wsdl-port-type xmlns:portTypeNS='http://org.jboss.test.webservice/samples2'>portTypeNS:TransmulatorInterface</wsdl-port-type>
+ <wsdl-binding xmlns:bindingNS='http://org.jboss.test.webservice/samples2'>bindingNS:TransmulatorInterfaceBinding</wsdl-binding>
+ <service-endpoint-method-mapping>
+ <java-method-name>invokeAttach</java-method-name>
+ <wsdl-operation>invokeAttach</wsdl-operation>
+ <wrapped-element/>
+ <method-param-parts-mapping>
+ <param-position>0</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>username</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>1</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>password</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>2</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>operationName</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>3</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>inputXML</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <wsdl-return-value-mapping>
+ <method-return-value>java.lang.String</method-return-value>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachResponse</wsdl-message>
+ <wsdl-message-part-name>result</wsdl-message-part-name>
+ </wsdl-return-value-mapping>
+ </service-endpoint-method-mapping>
+ </service-endpoint-interface-mapping>
</java-wsdl-mapping>
\ No newline at end of file
Modified: trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml
===================================================================
--- trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml 2007-01-12 12:48:02 UTC (rev 1943)
@@ -4,12 +4,12 @@
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<servlet>
- <servlet-name>TestEndpoint</servlet-name>
+ <servlet-name>ExampleService</servlet-name>
<servlet-class>org.jboss.test.ws.jaxrpc.jbws1384.TranslatorBean</servlet-class>
</servlet>
<servlet-mapping>
- <servlet-name>TestEndpoint</servlet-name>
+ <servlet-name>ExampleService</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>
Modified: trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml
===================================================================
--- trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,7 +1,7 @@
<webservices xmlns='http://java.sun.com/xml/ns/j2ee' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_web_services_1_1.xsd' version='1.1'>
<webservice-description>
- <webservice-description-name>ExampleService</webservice-description-name>
+ <webservice-description-name>Gasherbrum</webservice-description-name>
<wsdl-file>WEB-INF/wsdl/ExampleService.wsdl</wsdl-file>
<jaxrpc-mapping-file>WEB-INF/jaxrpc-mapping.xml</jaxrpc-mapping-file>
<port-component>
@@ -9,7 +9,7 @@
<wsdl-port xmlns:portNS='http://org.jboss.test.webservice/samples2'>portNS:TransmulatorInterfacePort</wsdl-port>
<service-endpoint-interface>org.jboss.test.ws.jaxrpc.jbws1384.TransmulatorInterface</service-endpoint-interface>
<service-impl-bean>
- <servlet-link>TestEndpoint</servlet-link>
+ <servlet-link>ExampleService</servlet-link>
</service-impl-bean>
</port-component>
</webservice-description>
Modified: trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl
===================================================================
--- trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl 2007-01-12 12:48:02 UTC (rev 1943)
@@ -5,7 +5,7 @@
<schema targetNamespace="http://org.jboss.test.webservice/samples2/types" xmlns:tns="http://org.jboss.test.webservice/samples2/types"
xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns="http://www.w3.org/2001/XMLSchema">
- <complexType name="paraListType">
+ <complexType name="invokeAttachType">
<sequence>
<element name="username" type="string" nillable="true"/>
<element name="password" type="string" nillable="true"/>
@@ -18,12 +18,12 @@
<element name="result" type="string" nillable="true"/>
</sequence>
</complexType>
- <element name="paraList2" type="tns:paraListType"/>
+ <element name="invokeAttach" type="tns:invokeAttachType"/>
<element name="responseXML" type="tns:responseType"/>
</schema>
</types>
<message name="attachRequest">
- <part name="parameters" element="ns2:paraList2"/>
+ <part name="parameters" element="ns2:invokeAttach"/>
<part name="attachmentContents" type="xsd:string"/>
</message>
<message name="attachResponse">
Modified: trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml
===================================================================
--- trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml 2007-01-12 12:48:02 UTC (rev 1943)
@@ -13,7 +13,7 @@
<package-namespace package="org.jboss.test.ws.jaxrpc.jbws1384" namespace="http://org.jboss.test.webservice/samples2"/>
</global>
- <wsdl-java location="./WEB-INF/wsdl/ExampleService.wsdl">
+ <wsdl-java location="resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl">
<mapping file="jaxrpc-mapping.xml" />
<webservices servlet-link="ExampleService" />
</wsdl-java>
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,12 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.webservice.inoutparameters;
-
-import javax.xml.rpc.*;
-
-public interface InOutParametersService_Service extends javax.xml.rpc.Service {
- public org.jboss.test.webservice.inoutparameters.InOutParametersService_PortType getInOutParametersServicePort() throws ServiceException;
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParameters_Service.java (from rev 1941, branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParameters_Service.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java
===================================================================
--- trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java 2007-01-12 12:38:06 UTC (rev 1942)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java 2007-01-12 12:48:02 UTC (rev 1943)
@@ -1,12 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.webservice.outparameters;
-
-import javax.xml.rpc.*;
-
-public interface OutParametersService_Service extends javax.xml.rpc.Service {
- public org.jboss.test.webservice.outparameters.OutParametersService_PortType getOutParametersServicePort() throws ServiceException;
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParameters_Service.java (from rev 1941, branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParameters_Service.java)
18 years
JBossWS SVN: r1942 - in branches/tdiesler/trunk: jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410 and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-01-12 07:38:06 -0500 (Fri, 12 Jan 2007)
New Revision: 1942
Modified:
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java
Log:
Propagate WSTimeoutException to client
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 12:20:33 UTC (rev 1941)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 12:38:06 UTC (rev 1942)
@@ -51,6 +51,7 @@
import org.jboss.ws.Constants;
import org.jboss.ws.core.CommonClient;
import org.jboss.ws.core.CommonMessageContext;
+import org.jboss.ws.core.WSTimeoutException;
import org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializerFactory;
import org.jboss.ws.core.jaxrpc.binding.JBossXBSerializerFactory;
import org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl;
@@ -616,6 +617,10 @@
{
throw rex;
}
+ catch (WSTimeoutException toex)
+ {
+ throw toex;
+ }
catch (Exception ex)
{
throw new RemoteException("Call invocation failed", ex);
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java 2007-01-12 12:20:33 UTC (rev 1941)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java 2007-01-12 12:38:06 UTC (rev 1942)
@@ -23,7 +23,6 @@
import java.io.File;
import java.net.URL;
-import java.rmi.RemoteException;
import javax.xml.namespace.QName;
import javax.xml.rpc.Service;
@@ -34,7 +33,6 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.WSException;
import org.jboss.ws.core.WSTimeoutException;
import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
import org.jboss.ws.core.jaxrpc.StubExt;
@@ -85,11 +83,9 @@
port.echoSimple("500");
fail("socket timeout expected");
}
- catch (RemoteException ex)
+ catch (WSTimeoutException ex)
{
- assertTrue ("WSTimeoutException expected", ex.getCause() instanceof WSTimeoutException);
- WSTimeoutException toex = (WSTimeoutException)ex.getCause();
- assertEquals(100, toex.getTimeout());
+ assertEquals(100, ex.getTimeout());
}
}
}
18 years
JBossWS SVN: r1941 - in branches/tdiesler/trunk: jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260 and 4 other directories.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-01-12 07:20:33 -0500 (Fri, 12 Jan 2007)
New Revision: 1941
Added:
branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParameters_Service.java
branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParameters_Service.java
Removed:
branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java
branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java
Modified:
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java
Log:
Fix tools regression
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java 2007-01-12 12:03:59 UTC (rev 1940)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -210,7 +210,7 @@
private void generateServiceFile(WSDLService wsdlService) throws IOException
{
String serviceName = wsdlService.getName().toString();
- if (serviceName.endsWith("Service") == false);
+ if (serviceName.endsWith("Service") == false)
serviceName = serviceName + "Service";
//Check if the serviceName conflicts with a portType or interface name
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java 2007-01-12 12:03:59 UTC (rev 1940)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1260/JBWS1260TestCase.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -877,7 +877,7 @@
{
String currentFile = generatedFiles[i];
- boolean matched = "PhoneBook_Service.java".equals(currentFile);
+ boolean matched = "PhoneBookService.java".equals(currentFile);
for (int j = 0; j < expectedFiles.length && (matched == false); j++)
matched = currentFile.equals(expectedFiles[j]);
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java 2007-01-12 12:03:59 UTC (rev 1940)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/InOutParameters/InOutParametersWSDL2JavaTestCase.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -48,7 +48,7 @@
public String getServiceName()
{
- return "InOutParametersService_Service";
+ return "InOutParameters_Service";
}
public void checkGeneratedUserTypes()
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java 2007-01-12 12:03:59 UTC (rev 1940)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws_206/tests/OutParameters/OutParametersWSDL2JavaTestCase.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -47,7 +47,7 @@
public String getServiceName()
{
- return "OutParametersService_Service";
+ return "OutParameters_Service";
}
public void checkGeneratedUserTypes() throws Exception
Deleted: branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java 2007-01-12 12:03:59 UTC (rev 1940)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -1,12 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.webservice.inoutparameters;
-
-import javax.xml.rpc.*;
-
-public interface InOutParametersService_Service extends javax.xml.rpc.Service {
- public org.jboss.test.webservice.inoutparameters.InOutParametersService_PortType getInOutParametersServicePort() throws ServiceException;
-}
Copied: branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParameters_Service.java (from rev 1938, branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java)
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParametersService_Service.java 2007-01-12 11:17:14 UTC (rev 1938)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/InOutParameters/service/InOutParameters_Service.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -0,0 +1,12 @@
+// This class was generated by the JAXRPC SI, do not edit.
+// Contents subject to change without notice.
+// JAX-RPC Standard Implementation (1.1.3, build R1)
+// Generated source version: 1.1.3
+
+package org.jboss.test.webservice.inoutparameters;
+
+import javax.xml.rpc.*;
+
+public interface InOutParameters_Service extends javax.xml.rpc.Service {
+ public org.jboss.test.webservice.inoutparameters.InOutParametersService_PortType getInOutParametersServicePort() throws ServiceException;
+}
Deleted: branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java 2007-01-12 12:03:59 UTC (rev 1940)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -1,12 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.webservice.outparameters;
-
-import javax.xml.rpc.*;
-
-public interface OutParametersService_Service extends javax.xml.rpc.Service {
- public org.jboss.test.webservice.outparameters.OutParametersService_PortType getOutParametersServicePort() throws ServiceException;
-}
Copied: branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParameters_Service.java (from rev 1938, branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java)
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParametersService_Service.java 2007-01-12 11:17:14 UTC (rev 1938)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/tools/jbws-206/wscompileArtifacts/OutParameters/service/OutParameters_Service.java 2007-01-12 12:20:33 UTC (rev 1941)
@@ -0,0 +1,12 @@
+// This class was generated by the JAXRPC SI, do not edit.
+// Contents subject to change without notice.
+// JAX-RPC Standard Implementation (1.1.3, build R1)
+// Generated source version: 1.1.3
+
+package org.jboss.test.webservice.outparameters;
+
+import javax.xml.rpc.*;
+
+public interface OutParameters_Service extends javax.xml.rpc.Service {
+ public org.jboss.test.webservice.outparameters.OutParametersService_PortType getOutParametersServicePort() throws ServiceException;
+}
18 years
JBossWS SVN: r1940 - branches/dlofthouse.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2007-01-12 07:03:59 -0500 (Fri, 12 Jan 2007)
New Revision: 1940
Removed:
branches/dlofthouse/JBWS-1259/
Log:
Branch no longer required.
18 years
JBossWS SVN: r1939 - in trunk: jbossws-core/src/main/java/org/jboss/ws/tools and 10 other directories.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2007-01-12 07:03:04 -0500 (Fri, 12 Jan 2007)
New Revision: 1939
Added:
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/Lookup.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/LookupResponse.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/wstools-config.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/Person.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/TelephoneNumber.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/wstools-config.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Comment.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Person.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/TelephoneNumber.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/wstools-config.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Comment.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Person.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/TelephoneNumber.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/wstools-config.xml
trunk/jbossws-tests/src/main/resources/tools/wsdl11/jaxrpc-mapping.xml
Removed:
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/Lookup.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/LookupResponse.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/wstools-config.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/Person.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/TelephoneNumber.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/wstools-config.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Comment.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Person.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/TelephoneNumber.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/wstools-config.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Comment.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Person.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook.wsdl
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook_PortType.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/TelephoneNumber.java
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/jaxrpc-mapping.xml
trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/wstools-config.xml
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/WSSchemaUtils.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/XSDTypeToJava.java
trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/MappingFileGeneratorHelper.java
Log:
JBWS-1259 - WSDL to Java, handling of cyclic element references with anonymous complex types.
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/WSSchemaUtils.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/WSSchemaUtils.java 2007-01-12 11:17:14 UTC (rev 1938)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsdl/xmlschema/WSSchemaUtils.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,24 +1,24 @@
/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
package org.jboss.ws.metadata.wsdl.xmlschema;
import java.io.IOException;
@@ -77,7 +77,6 @@
this.targetNamespace = targetNamespace;
}
-
/**
* Checks whether given a targetNS and other regular schema namespaces,
* the passed "checkNS" is a custom namespace
@@ -87,15 +86,14 @@
*/
public boolean checkCustomNamespace(String targetNS, String checkNS)
{
- String[] nsarr = new String[] {xsNS,Constants.NS_SCHEMA_XSI };
+ String[] nsarr = new String[] { xsNS, Constants.NS_SCHEMA_XSI };
List<String> knownNamespaces = Arrays.asList(nsarr);
boolean isCustom = false;
- if(xsNS.equals(targetNS))
- throw new IllegalArgumentException("targetNamespace cannot be "+xsNS );
- if(checkNS == null)
+ if (xsNS.equals(targetNS))
+ throw new IllegalArgumentException("targetNamespace cannot be " + xsNS);
+ if (checkNS == null)
throw new IllegalArgumentException("checkNS is null");
- if(knownNamespaces.contains(checkNS) == false &&
- targetNS.equals(checkNS) == false)
+ if (knownNamespaces.contains(checkNS) == false && targetNS.equals(checkNS) == false)
isCustom = true;
return isCustom;
}
@@ -108,8 +106,7 @@
* @return
*/
- public JBossXSElementDeclaration createGlobalXSElementDeclaration(String name, XSTypeDefinition xstype,
- String targetNS)
+ public JBossXSElementDeclaration createGlobalXSElementDeclaration(String name, XSTypeDefinition xstype, String targetNS)
{
JBossXSElementDeclaration xsel = new JBossXSElementDeclaration();
xsel.setName(name);
@@ -130,11 +127,10 @@
return new JBossXSModel();
}
- public JBossXSComplexTypeDefinition createXSComplexTypeDefinition( String name,
- XSTypeDefinition baseType, List<XSParticle> xsparts, String typens)
+ public JBossXSComplexTypeDefinition createXSComplexTypeDefinition(String name, XSTypeDefinition baseType, List<XSParticle> xsparts, String typens)
{
//No complex type if particles are null
- if(xsparts == null)
+ if (xsparts == null)
return null;
JBossXSComplexTypeDefinition ct = new JBossXSComplexTypeDefinition();
@@ -147,18 +143,17 @@
// Plug the particle array into the modelgroup
JBossXSParticle xspa = new JBossXSParticle(null, typens);
xspa.setTerm(group);
- ((JBossXSComplexTypeDefinition) ct).setParticle(xspa);
+ ((JBossXSComplexTypeDefinition)ct).setParticle(xspa);
if (baseType != null)
{
- ((JBossXSComplexTypeDefinition) ct).setDerivationMethod(XSConstants.DERIVATION_EXTENSION);
- ((JBossXSComplexTypeDefinition) ct).setBaseType(baseType);
+ ((JBossXSComplexTypeDefinition)ct).setDerivationMethod(XSConstants.DERIVATION_EXTENSION);
+ ((JBossXSComplexTypeDefinition)ct).setBaseType(baseType);
}
return ct;
}
-
/**
* Create a local XSElementDeclaration object
* @param name
@@ -168,7 +163,7 @@
* @return
*/
- public JBossXSElementDeclaration createXSElementDeclaration(String name, XSTypeDefinition xstype,boolean isNillable)
+ public JBossXSElementDeclaration createXSElementDeclaration(String name, XSTypeDefinition xstype, boolean isNillable)
{
JBossXSElementDeclaration xsel = new JBossXSElementDeclaration();
xsel.setName(name);
@@ -186,7 +181,6 @@
return xsp;
}
-
/**
* Creates a XSTypeDefinition object given a QName
*
@@ -201,7 +195,6 @@
return jbxs;
}
-
/**
* Generate a complex type for a custom exception
* @param exname
@@ -213,12 +206,11 @@
{
JBossXSParticle xsp = new JBossXSParticle();
/*xsp.setType(XSConstants.ELEMENT_DECLARATION);
- xsp.setMaxOccurs(-1);
- JBossXSElementDeclaration xsel = (JBossXSElementDeclaration)createXSElementDeclaration("name", utils.getSchemaBasicType("string"), true);
+ xsp.setMaxOccurs(-1);
+ JBossXSElementDeclaration xsel = (JBossXSElementDeclaration)createXSElementDeclaration("name", utils.getSchemaBasicType("string"), true);
- xsp.setTerm(xsel); */
- XSComplexTypeDefinition ct =
- new JBossXSComplexTypeDefinition(exname, ns);
+ xsp.setTerm(xsel); */
+ XSComplexTypeDefinition ct = new JBossXSComplexTypeDefinition(exname, ns);
((JBossXSComplexTypeDefinition)ct).setParticle(xsp);
return ct;
@@ -233,10 +225,10 @@
*/
public JBossXSModel getJBossXSModel(XSModel xsmodel)
{
- if(xsmodel instanceof JBossXSModel)
+ if (xsmodel instanceof JBossXSModel)
return (JBossXSModel)xsmodel;
JBossXSModel jbxs = new JBossXSModel();
- copyXSModel(xsmodel,jbxs);
+ copyXSModel(xsmodel, jbxs);
return jbxs;
}
@@ -248,18 +240,21 @@
*/
public boolean isEmptySchema(JBossXSModel xsmodel, String namespace)
{
- if(xsmodel == null) return true;
- if(namespace == null) throw new WSException("Target Namespace of xsmodel is null");
+ if (xsmodel == null)
+ return true;
+ if (namespace == null)
+ throw new WSException("Target Namespace of xsmodel is null");
XSNamedMap tmap = xsmodel.getComponentsByNamespace(XSConstants.TYPE_DEFINITION, namespace);
XSNamedMap emap = xsmodel.getComponentsByNamespace(XSConstants.ELEMENT_DECLARATION, namespace);
- if (tmap != null && tmap.getLength() > 0) return false;
- if (emap != null && emap.getLength() > 0) return false;
+ if (tmap != null && tmap.getLength() > 0)
+ return false;
+ if (emap != null && emap.getLength() > 0)
+ return false;
return true;
}
-
/**
* Serialize the SchemaModel into a Writer
* @param xsmodel Schema Model which needs to be serialized
@@ -269,7 +264,7 @@
public void serialize(XSModel xsmodel, Writer writer) throws IOException
{
StringBuilder buffer = new StringBuilder();
- if(xsmodel instanceof JBossXSModel)
+ if (xsmodel instanceof JBossXSModel)
{
String str = ((JBossXSModel)xsmodel).serialize();
buffer.append(str);
@@ -286,7 +281,6 @@
writer.write(buffer.toString());
}
-
/**
* Serialize the SchemaModel (with no types and elements) into a Writer
* @param xsmodel Schema Model which needs to be serialized
@@ -316,7 +310,7 @@
public String write(XSElementDeclaration xsel, XSParticle xsp)
{
XSTypeDefinition xst = xsel.getTypeDefinition();
- if(xst == null)
+ if (xst == null)
throw new IllegalStateException("Type xst is null");
boolean isGlobalRef = (xsel.getScope() == XSConstants.SCOPE_GLOBAL);
@@ -326,7 +320,7 @@
String elname = xsel.getName();
String prefix = null;
- if(isGlobalRef)
+ if (isGlobalRef)
{
String namespace = xsel.getNamespace();
prefix = getPrefix(namespace);
@@ -337,14 +331,14 @@
String namespace = xst.getNamespace();
String typename = xst.getName();
- if (! Constants.NS_SCHEMA_XSD.equals(namespace))
+ if (!Constants.NS_SCHEMA_XSD.equals(namespace))
{
prefix = getPrefix(namespace);
typename = prefix + ":" + typename;
}
buf.append("<element name='" + elname + "'");
- if(! isAnonType)
+ if (!isAnonType)
buf.append(" type='" + typename + "' ");
}
@@ -357,16 +351,14 @@
{
if (xsp.getMaxOccursUnbounded())
buf.append(" maxOccurs='unbounded' ");
- else
- buf.append(" maxOccurs='" + xsp.getMaxOccurs() + "'");
+ else buf.append(" maxOccurs='" + xsp.getMaxOccurs() + "'");
buf.append(" minOccurs='" + xsp.getMinOccurs() + "'");
}
- if(! isAnonType)
+ if (isAnonType == false || isGlobalRef == true)
buf.append("/>");
- else
- buf.append(">").append(write(xst)).append("</element>");
+ else buf.append(">").append(write(xst)).append("</element>");
return buf.toString();
}
@@ -374,7 +366,7 @@
public String write(XSAttributeDeclaration decl)
{
XSTypeDefinition xst = decl.getTypeDefinition();
- if(xst == null)
+ if (xst == null)
throw new IllegalStateException("Type xst is null");
boolean isGlobalRef = (decl.getScope() == XSConstants.SCOPE_GLOBAL);
@@ -395,21 +387,20 @@
String namespace = xst.getNamespace();
String typename = xst.getName();
- if (! Constants.NS_SCHEMA_XSD.equals(namespace))
+ if (!Constants.NS_SCHEMA_XSD.equals(namespace))
{
prefix = getPrefix(namespace);
typename = prefix + ":" + typename;
}
buf.append("<attribute name='" + name + "'");
- if(! isAnonType)
+ if (!isAnonType)
buf.append(" type='" + typename + "' ");
}
- if(! isAnonType)
+ if (!isAnonType)
buf.append("/>");
- else
- buf.append(">").append(write(xst)).append("</attribute>");
+ else buf.append(">").append(write(xst)).append("</attribute>");
return buf.toString();
}
@@ -434,25 +425,22 @@
String namespace = xst.getNamespace();
String prefix = null;
- if (! Constants.NS_SCHEMA_XSD.equals(namespace))
+ if (!Constants.NS_SCHEMA_XSD.equals(namespace))
{
prefix = getPrefix(namespace);
typename = prefix + ":" + typename;
}
buf.append("<element name='" + elname + "'");
- if(!isAnonType)
+ if (!isAnonType)
buf.append(" type='" + typename + "' ");
- else
- buf.append(">").append(write(xst));
+ else buf.append(">").append(write(xst));
- if (xsel.getNillable() &&
- xsel.getScope() != XSConstants.SCOPE_GLOBAL)
+ if (xsel.getNillable() && xsel.getScope() != XSConstants.SCOPE_GLOBAL)
buf.append(" nillable='true' ");
- if(!isAnonType)
+ if (!isAnonType)
buf.append("/>");
- else
- buf.append("</element>");
+ else buf.append("</element>");
return buf.toString();
}
@@ -474,13 +462,12 @@
XSParticle jxsp = (XSParticle)objlist.item(i);
XSTerm xterm = jxsp.getTerm();
short termType = xterm.getType();
- if(termType == XSConstants.ELEMENT_DECLARATION)
+ if (termType == XSConstants.ELEMENT_DECLARATION)
{
XSElementDeclaration xsel = (XSElementDeclaration)jxsp.getTerm();
buf.append(this.write(xsel, jxsp));
}
- else
- if ( termType == XSConstants.MODEL_GROUP)
+ else if (termType == XSConstants.MODEL_GROUP)
{
XSObjectList olist = ((XSModelGroup)xterm).getParticles();
int lobj = olist != null ? olist.getLength() : 0;
@@ -489,18 +476,16 @@
XSParticle jxp = (XSParticle)olist.item(k);
XSTerm xsterm = jxp.getTerm();
termType = xsterm.getType();
- if(termType == XSConstants.ELEMENT_DECLARATION)
+ if (termType == XSConstants.ELEMENT_DECLARATION)
buf.append(write((XSElementDeclaration)xsterm, jxsp));
- else
- if(termType == XSConstants.MODEL_GROUP && k > 0)
- buf.append(write((XSModelGroup)xsterm));
+ else if (termType == XSConstants.MODEL_GROUP && k > 0)
+ buf.append(write((XSModelGroup)xsterm));
}
}
}
return buf.toString();
}
-
/**
* Return a string for the xs type
* @param xstype
@@ -517,9 +502,9 @@
String jxsTypeName = jxstype.getName();
boolean isSimple = jxstype.getContentType() == XSComplexTypeDefinition.CONTENTTYPE_SIMPLE;
- if(xstype.getAnonymous()) buf.append("<complexType>");
- else
- buf.append("<complexType name='" + jxsTypeName + "'>");
+ if (xstype.getAnonymous())
+ buf.append("<complexType>");
+ else buf.append("<complexType name='" + jxsTypeName + "'>");
XSTypeDefinition xsbase = (XSTypeDefinition)jxstype.getBaseType();
String baseType = null;
@@ -533,12 +518,13 @@
}
XSParticle xsp = jxstype.getParticle();
- if (xsp != null) appendComplexTypeDefinition(buf,jxstype);
+ if (xsp != null)
+ appendComplexTypeDefinition(buf, jxstype);
XSObjectList list = jxstype.getAttributeUses();
for (int i = 0; i < list.getLength(); i++)
{
- XSAttributeUse use = (XSAttributeUse) list.item(i);
+ XSAttributeUse use = (XSAttributeUse)list.item(i);
XSAttributeDeclaration decl = use.getAttrDeclaration();
buf.append(write(decl));
}
@@ -560,7 +546,7 @@
{
String baseType = xsbase.getName();
String ns = xsbase.getNamespace();
- if (! Constants.NS_SCHEMA_XSD.equals(ns))
+ if (!Constants.NS_SCHEMA_XSD.equals(ns))
{
String prefix = getPrefix(ns);
baseType = prefix + ":" + baseType;
@@ -572,7 +558,7 @@
for (int i = 0; i < list.getLength(); i++)
{
String listItem = DOMWriter.normalize(list.item(i), false);
- buf.append("<enumeration value='" + listItem +"'/>");
+ buf.append("<enumeration value='" + listItem + "'/>");
}
buf.append("</restriction>");
}
@@ -582,7 +568,7 @@
return buf.toString();
}
-// Private methods
+ // Private methods
private void appendSchemaDefinitions(StringBuilder buffer, XSNamespaceItemList itemlist)
{
@@ -594,13 +580,14 @@
String ns = nsitem.getSchemaNamespace();
//Ignore the one for xsd
- if (Constants.NS_SCHEMA_XSD.equals(ns)) continue;
+ if (Constants.NS_SCHEMA_XSD.equals(ns))
+ continue;
buffer.append(utils.getSchemaDefinitions(ns));
} //end for
}
- private void appendComplexTypeDefinition(StringBuilder buf , XSComplexTypeDefinition jxstype)
+ private void appendComplexTypeDefinition(StringBuilder buf, XSComplexTypeDefinition jxstype)
{
XSParticle xsp = jxstype.getParticle();
XSTerm xsterm = xsp.getTerm();
@@ -651,10 +638,11 @@
}
else if (xterm instanceof XSModelGroup)
{
- if(deriveMethod == XSConstants.DERIVATION_EXTENSION && i != lenobj -1)
+ if (deriveMethod == XSConstants.DERIVATION_EXTENSION && i != lenobj - 1)
continue;
- if (i == 0) continue;//Ignore as it provides the baseclass sequence of elements
+ if (i == 0)
+ continue;//Ignore as it provides the baseclass sequence of elements
XSObjectList olist = ((XSModelGroup)xterm).getParticles();
int lobj = olist != null ? olist.getLength() : 0;
for (int k = 0; k < lobj; k++)
@@ -662,11 +650,10 @@
XSParticle jxp = (XSParticle)olist.item(k);
XSTerm jxpterm = jxp.getTerm();
short termType = jxpterm.getType();
- if(termType == XSConstants.ELEMENT_DECLARATION)
+ if (termType == XSConstants.ELEMENT_DECLARATION)
buf.append(write((XSElementDeclaration)jxpterm, jxsp));
- else
- if(termType == XSConstants.MODEL_GROUP)
- buf.append(write((XSModelGroup)jxpterm));
+ else if (termType == XSConstants.MODEL_GROUP)
+ buf.append(write((XSModelGroup)jxpterm));
}
}
}
@@ -682,12 +669,12 @@
for (int i = 0; i < len; i++)
{
XSTypeDefinition xstype = (XSTypeDefinition)xsmap.item(i);
- if (Constants.NS_SCHEMA_XSD.equals(xstype.getNamespace())) continue;
+ if (Constants.NS_SCHEMA_XSD.equals(xstype.getNamespace()))
+ continue;
buffer.append(this.write(xstype));
}
}
-
private void appendGlobalElements(StringBuilder buffer, XSModel xsmodel)
{
XSNamedMap xsmap = xsmodel.getComponents(XSConstants.ELEMENT_DECLARATION);
@@ -695,7 +682,8 @@
for (int i = 0; i < len; i++)
{
XSElementDeclaration xsel = (XSElementDeclaration)xsmap.item(i);
- if (Constants.NS_SCHEMA_XSD.equals(xsel.getNamespace())) continue;
+ if (Constants.NS_SCHEMA_XSD.equals(xsel.getNamespace()))
+ continue;
buffer.append(this.write(xsel));
}
}
@@ -703,9 +691,9 @@
//Copy the Xerces implementation of XSModel into JBossXSModel
public void copyXSModel(XSModel xsmodel, JBossXSModel jb)
{
- if(xsmodel == null)
+ if (xsmodel == null)
throw new IllegalArgumentException("Illegal Null Argument:xsmodel");
- if(jb == null)
+ if (jb == null)
throw new IllegalArgumentException("Illegal Null Argument:jb");
//Copy all the Namespace Items
jb.setXSNamespaceItemList(xsmodel.getNamespaceItems());
@@ -724,7 +712,8 @@
for (int i = 0; i < len; i++)
{
XSTypeDefinition xstype = (XSTypeDefinition)xsmp.item(i);
- if (!this.xsNS.equals(xstype.getNamespace())) jb.addXSTypeDefinition(xstype);
+ if (!this.xsNS.equals(xstype.getNamespace()))
+ jb.addXSTypeDefinition(xstype);
}
//Copy all the attributes
@@ -739,7 +728,7 @@
//copy all the global annotations
//xsmp = xsmodel.getComponents(XSConstants.ANNOTATION);
XSObjectList xo = xsmodel.getAnnotations();
- len = xo != null ? xo.getLength():0;
+ len = xo != null ? xo.getLength() : 0;
//len = xsmp != null ? xsmp.getLength() : 0;
for (int i = 0; i < len; i++)
{
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/XSDTypeToJava.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/XSDTypeToJava.java 2007-01-12 11:17:14 UTC (rev 1938)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/XSDTypeToJava.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -563,11 +563,25 @@
if (containingElement == null || containingElement.length() == 0)
containingElement = origType.getName();
- String anonName = containingElement + subname;
+ String anonName;
+ if (elem.getScope() == XSConstants.SCOPE_GLOBAL)
+ {
+ anonName = subname;
+ }
+ else
+ {
+ anonName = containingElement + subname;
+ }
+
anonName = utils.firstLetterUpperCase(anonName);
this.fname = anonName;
- this.createJavaFile((XSComplexTypeDefinition)xstypedef, schema, false);
+ if (!generatedFiles.contains(this.fname))
+ {
+ generatedFiles.add(this.fname);
+ this.createJavaFile((XSComplexTypeDefinition)xstypedef, schema, false);
+ }
+
// Restore the fname
this.fname = tempfname;
// Bypass rest of processing
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/MappingFileGeneratorHelper.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/MappingFileGeneratorHelper.java 2007-01-12 11:17:14 UTC (rev 1938)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/MappingFileGeneratorHelper.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -33,6 +33,7 @@
import org.apache.xerces.xs.XSAttributeDeclaration;
import org.apache.xerces.xs.XSAttributeUse;
import org.apache.xerces.xs.XSComplexTypeDefinition;
+import org.apache.xerces.xs.XSConstants;
import org.apache.xerces.xs.XSElementDeclaration;
import org.apache.xerces.xs.XSModelGroup;
import org.apache.xerces.xs.XSObjectList;
@@ -745,8 +746,15 @@
{
XSElementDeclaration xe = (XSElementDeclaration)xsterm;
XSTypeDefinition typeDefinition = xe.getTypeDefinition();
- //XSTypeDefinition xt, String name, String containingElement, JavaWsdlMapping jwm, boolean skipWrapperArray
- addJavaXMLTypeMap(typeDefinition, xe.getName(), containingElement, containingType, jwm, !isDocStyle());
+ String tempContainingElement = "";
+ String tempContainingType = "";
+ if (xe.getScope() != XSConstants.SCOPE_GLOBAL)
+ {
+ tempContainingElement = containingElement;
+ tempContainingType = containingType;
+ }
+
+ addJavaXMLTypeMap(typeDefinition, xe.getName(), tempContainingElement, tempContainingType, jwm, !isDocStyle());
}
}
}
Copied: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259 (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259)
Deleted: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,186 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2007, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.ws.tools.jbws1259;
-
-import java.io.File;
-import java.io.FilenameFilter;
-
-import org.jboss.test.ws.JBossWSTest;
-import org.jboss.test.ws.tools.fixture.JBossSourceComparator;
-import org.jboss.test.ws.tools.validation.JaxrpcMappingValidator;
-import org.jboss.ws.tools.WSTools;
-
-/**
- *
- * @author darran.lofthouse(a)jboss.com
- * @since 10 Jan 2007
- */
-public class JBWS1259TestCase extends JBossWSTest
-{
-
- /**
- *
- * <element name='lookupResponse'>
- * <complexType>
- * <sequence>
- * <element name='areaCode' nillable='true' type='string'/>
- * <element name='number' nillable='true' type='string'/>
- * <element ref='tns:lookupResponse'/>
- * </sequence>
- * </complexType>
- * </element>
- *
- */
- public void testScenario_A() throws Exception
- {
- generateScenario("A");
- }
-
- /**
- *
- * <element name='lookupResponse' type='tns:TelephoneNumber'/>
- *
- * <complexType name='TelephoneNumber'>
- * <sequence>
- * <element name='areaCode' nillable='true' type='string'/>
- * <element name='number' nillable='true' type='string'/>
- * <element ref='tns:lookupResponse'/>
- * </sequence>
- * </complexType>
- *
- */
- public void testScenario_B() throws Exception
- {
- generateScenario("B");
- }
-
- /**
- *
- * <element name='lookupResponse' type='tns:TelephoneNumber'/>
- *
- * <complexType name='TelephoneNumber'>
- * <sequence>
- * <element name='areaCode' nillable='true' type='string'/>
- * <element name='number' nillable='true' type='string'/>
- * <element ref='tns:comment'/>
- * </sequence>
- * </complexType>
- *
- * <element name='comment'>
- * <complexType>
- * <sequence>
- * <element name='test' type='string' />
- * <element ref='tns:comment' />
- * </sequence>
- * </complexType>
- * </element>
- *
- */
- public void testScenario_C() throws Exception
- {
- generateScenario("C");
- }
-
- /**
- *
- * <element name='lookupResponse' type='tns:TelephoneNumber'/>
- *
- * <complexType name='TelephoneNumber'>
- * <sequence>
- * <element name='areaCode' nillable='true' type='string'/>
- * <element name='number' nillable='true' type='string'/>
- * <element ref='tns:comment'/>
- * </sequence>
- * </complexType>
- *
- * <element name='comment' type='tns:Comment' />
- *
- * <complexType name='Comment'>
- * <sequence>
- * <element name='test' type='string' />
- * <element ref='tns:comment' />
- * </sequence>
- * </complexType>
- *
- */
- public void testScenario_D() throws Exception
- {
- generateScenario("D");
- }
-
- protected void generateScenario(final String scenario) throws Exception
- {
- String resourceDir = "resources/tools/jbws1259/scenario_" + scenario;
- String toolsDir = "tools/jbws1259/scenario_" + scenario;
- String[] args = new String[] { "-dest", toolsDir, "-config", resourceDir + "/wstools-config.xml" };
- new WSTools().generate(args);
-
- File resourceDirFile = new File(resourceDir);
- String[] expectedFiles = resourceDirFile.list(new FilenameFilter() {
- public boolean accept(File dir, String name)
- {
- return name.endsWith(".java");
- }
- });
-
- for (int i = 0; i < expectedFiles.length; i++)
- {
- String currentFile = expectedFiles[i];
-
- try
- {
- compareSource(resourceDir + "/" + currentFile, toolsDir + "/org/jboss/test/ws/jbws1259/" + currentFile);
- }
- catch (Exception e)
- {
- throw new Exception("Validation of '" + currentFile + "' failed.", e);
- }
- }
-
- File packageDir = new File(toolsDir + "/org/jboss/test/ws/jbws1259");
- String[] generatedFiles = packageDir.list();
- for (int i = 0; i < generatedFiles.length; i++)
- {
- String currentFile = generatedFiles[i];
-
- boolean matched = "PhoneBook_Service.java".equals(currentFile);
-
- for (int j = 0; j < expectedFiles.length && (matched == false); j++)
- matched = currentFile.equals(expectedFiles[j]);
-
- assertTrue("File '" + currentFile + "' was not expected to be generated", matched);
- }
-
- JaxrpcMappingValidator mappingValidator = new JaxrpcMappingValidator();
- mappingValidator.validate(resourceDir + "/jaxrpc-mapping.xml", toolsDir + "/jaxrpc-mapping.xml");
- }
-
- private static void compareSource(final String expectedName, final String generatedName) throws Exception
- {
- File expected = new File(expectedName);
- File generated = new File(generatedName);
-
- JBossSourceComparator sc = new JBossSourceComparator(expected, generated);
- sc.validate();
- sc.validateImports();
- }
-}
Copied: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/java/org/jboss/test/ws/tools/jbws1259/JBWS1259TestCase.java)
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259 (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259)
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/Lookup.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/Lookup.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/Lookup.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class Lookup {
- protected java.lang.String firstName;
- protected java.lang.String surname;
- protected org.jboss.test.ws.jbws1259.Lookup lookup;
-
- public Lookup() {
- }
-
- public Lookup(java.lang.String firstName, java.lang.String surname, org.jboss.test.ws.jbws1259.Lookup lookup) {
- this.firstName = firstName;
- this.surname = surname;
- this.lookup = lookup;
- }
-
- public java.lang.String getFirstName() {
- return firstName;
- }
-
- public void setFirstName(java.lang.String firstName) {
- this.firstName = firstName;
- }
-
- public java.lang.String getSurname() {
- return surname;
- }
-
- public void setSurname(java.lang.String surname) {
- this.surname = surname;
- }
-
- public org.jboss.test.ws.jbws1259.Lookup getLookup() {
- return lookup;
- }
-
- public void setLookup(org.jboss.test.ws.jbws1259.Lookup lookup) {
- this.lookup = lookup;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/Lookup.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/Lookup.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/LookupResponse.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/LookupResponse.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/LookupResponse.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class LookupResponse {
- protected java.lang.String areaCode;
- protected java.lang.String number;
- protected org.jboss.test.ws.jbws1259.LookupResponse lookupResponse;
-
- public LookupResponse() {
- }
-
- public LookupResponse(java.lang.String areaCode, java.lang.String number, org.jboss.test.ws.jbws1259.LookupResponse lookupResponse) {
- this.areaCode = areaCode;
- this.number = number;
- this.lookupResponse = lookupResponse;
- }
-
- public java.lang.String getAreaCode() {
- return areaCode;
- }
-
- public void setAreaCode(java.lang.String areaCode) {
- this.areaCode = areaCode;
- }
-
- public java.lang.String getNumber() {
- return number;
- }
-
- public void setNumber(java.lang.String number) {
- this.number = number;
- }
-
- public org.jboss.test.ws.jbws1259.LookupResponse getLookupResponse() {
- return lookupResponse;
- }
-
- public void setLookupResponse(org.jboss.test.ws.jbws1259.LookupResponse lookupResponse) {
- this.lookupResponse = lookupResponse;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/LookupResponse.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/LookupResponse.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook.wsdl
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook.wsdl 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook.wsdl 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,57 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<definitions name='PhoneBook' targetNamespace='http://test.jboss.org/ws/jbws1259' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:ns1='http://test.jboss.org/ws/jbws1259/types' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://test.jboss.org/ws/jbws1259' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
- <types>
- <schema targetNamespace='http://test.jboss.org/ws/jbws1259/types' xmlns='http://www.w3.org/2001/XMLSchema' xmlns:soap11-enc='http://schemas.xmlsoap.org/soap/encoding/' xmlns:tns='http://test.jboss.org/ws/jbws1259/types' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
-
- <element name='lookup'>
- <complexType>
- <sequence>
- <element name='firstName' nillable='true' type='string'/>
- <element name='surname' nillable='true' type='string'/>
- <element ref='tns:lookup'/>
- </sequence>
- </complexType>
- </element>
-
- <element name='lookupResponse'>
- <complexType>
- <sequence>
- <element name='areaCode' nillable='true' type='string'/>
- <element name='number' nillable='true' type='string'/>
- <element ref='tns:lookupResponse'/>
- </sequence>
- </complexType>
- </element>
-
- </schema>
- </types>
- <message name='PhoneBook_lookup'>
- <part element='ns1:lookup' name='parameters'/>
- </message>
- <message name='PhoneBook_lookupResponse'>
- <part element='ns1:lookupResponse' name='result'/>
- </message>
- <portType name='PhoneBook'>
- <operation name='lookup'>
- <input message='tns:PhoneBook_lookup'/>
- <output message='tns:PhoneBook_lookupResponse'/>
- </operation>
- </portType>
- <binding name='PhoneBookBinding' type='tns:PhoneBook'>
- <soap:binding style='document' transport='http://schemas.xmlsoap.org/soap/http'/>
- <operation name='lookup'>
- <soap:operation soapAction=''/>
- <input>
- <soap:body use='literal'/>
- </input>
- <output>
- <soap:body use='literal'/>
- </output>
- </operation>
- </binding>
- <service name='PhoneBook'>
- <port binding='tns:PhoneBookBinding' name='PhoneBookPort'>
- <soap:address location='REPLACE_WITH_ACTUAL_URL'/>
- </port>
- </service>
-</definitions>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook.wsdl (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook.wsdl)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook_PortType.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook_PortType.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook_PortType.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,11 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-public interface PhoneBook_PortType extends java.rmi.Remote {
- public org.jboss.test.ws.jbws1259.LookupResponse lookup(org.jboss.test.ws.jbws1259.Lookup parameters) throws
- java.rmi.RemoteException;
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook_PortType.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/PhoneBook_PortType.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/jaxrpc-mapping.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/jaxrpc-mapping.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/jaxrpc-mapping.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,76 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259</namespaceURI>
- </package-mapping>
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259/types</namespaceURI>
- </package-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.LookupResponse</java-type>
- <anonymous-type-qname>http://test.jboss.org/ws/jbws1259/types:>lookupResponse</anonymous-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>areaCode</java-variable-name>
- <xml-element-name>areaCode</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>number</java-variable-name>
- <xml-element-name>number</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>lookupResponse</java-variable-name>
- <xml-element-name>lookupResponse</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.Lookup</java-type>
- <anonymous-type-qname>http://test.jboss.org/ws/jbws1259/types:>lookup</anonymous-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>firstName</java-variable-name>
- <xml-element-name>firstName</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>surname</java-variable-name>
- <xml-element-name>surname</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>lookup</java-variable-name>
- <xml-element-name>lookup</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <service-interface-mapping>
- <service-interface>org.jboss.test.ws.jbws1259.PhoneBook_Service</service-interface>
- <wsdl-service-name xmlns:serviceNS="http://test.jboss.org/ws/jbws1259">serviceNS:PhoneBook</wsdl-service-name>
- <port-mapping>
- <port-name>PhoneBookPort</port-name>
- <java-port-name>PhoneBookPort</java-port-name>
- </port-mapping>
- </service-interface-mapping>
- <service-endpoint-interface-mapping>
- <service-endpoint-interface>org.jboss.test.ws.jbws1259.PhoneBook_PortType</service-endpoint-interface>
- <wsdl-port-type xmlns:portTypeNS="http://test.jboss.org/ws/jbws1259">portTypeNS:PhoneBook</wsdl-port-type>
- <wsdl-binding xmlns:bindingNS="http://test.jboss.org/ws/jbws1259">bindingNS:PhoneBookBinding</wsdl-binding>
- <service-endpoint-method-mapping>
- <java-method-name>lookup</java-method-name>
- <wsdl-operation>lookup</wsdl-operation>
- <method-param-parts-mapping>
- <param-position>0</param-position>
- <param-type>org.jboss.test.ws.jbws1259.Lookup</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookup</wsdl-message>
- <wsdl-message-part-name>parameters</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <wsdl-return-value-mapping>
- <method-return-value>org.jboss.test.ws.jbws1259.LookupResponse</method-return-value>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookupResponse</wsdl-message>
- <wsdl-message-part-name>result</wsdl-message-part-name>
- </wsdl-return-value-mapping>
- </service-endpoint-method-mapping>
- </service-endpoint-interface-mapping>
-</java-wsdl-mapping>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/jaxrpc-mapping.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/jaxrpc-mapping.xml)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/wstools-config.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/wstools-config.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/wstools-config.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,5 +0,0 @@
-<configuration>
- <wsdl-java location="resources/tools/jbws1259/scenario_A/PhoneBook.wsdl" parameter-style="bare">
- <mapping file="jaxrpc-mapping.xml"/>
- </wsdl-java>
-</configuration>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/wstools-config.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_A/wstools-config.xml)
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/Person.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/Person.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/Person.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class Person {
- protected java.lang.String firstName;
- protected java.lang.String surname;
- protected org.jboss.test.ws.jbws1259.Person lookup;
-
- public Person() {
- }
-
- public Person(java.lang.String firstName, java.lang.String surname, org.jboss.test.ws.jbws1259.Person lookup) {
- this.firstName = firstName;
- this.surname = surname;
- this.lookup = lookup;
- }
-
- public java.lang.String getFirstName() {
- return firstName;
- }
-
- public void setFirstName(java.lang.String firstName) {
- this.firstName = firstName;
- }
-
- public java.lang.String getSurname() {
- return surname;
- }
-
- public void setSurname(java.lang.String surname) {
- this.surname = surname;
- }
-
- public org.jboss.test.ws.jbws1259.Person getLookup() {
- return lookup;
- }
-
- public void setLookup(org.jboss.test.ws.jbws1259.Person lookup) {
- this.lookup = lookup;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/Person.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/Person.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook.wsdl
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook.wsdl 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook.wsdl 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<definitions name='PhoneBook' targetNamespace='http://test.jboss.org/ws/jbws1259' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:ns1='http://test.jboss.org/ws/jbws1259/types' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://test.jboss.org/ws/jbws1259' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
- <types>
- <schema targetNamespace='http://test.jboss.org/ws/jbws1259/types' xmlns='http://www.w3.org/2001/XMLSchema' xmlns:soap11-enc='http://schemas.xmlsoap.org/soap/encoding/' xmlns:tns='http://test.jboss.org/ws/jbws1259/types' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
-
- <complexType name='Person'>
- <sequence>
- <element name='firstName' nillable='true' type='string'/>
- <element name='surname' nillable='true' type='string'/>
- <element ref='tns:lookup'/>
- </sequence>
- </complexType>
-
- <complexType name='TelephoneNumber'>
- <sequence>
- <element name='areaCode' nillable='true' type='string'/>
- <element name='number' nillable='true' type='string'/>
- <element ref='tns:lookupResponse'/>
- </sequence>
- </complexType>
-
- <element name='lookup' type='tns:Person' />
- <element name='lookupResponse' type='tns:TelephoneNumber'/>
- </schema>
- </types>
- <message name='PhoneBook_lookup'>
- <part element='ns1:lookup' name='parameters'/>
- </message>
- <message name='PhoneBook_lookupResponse'>
- <part element='ns1:lookupResponse' name='result'/>
- </message>
- <portType name='PhoneBook'>
- <operation name='lookup'>
- <input message='tns:PhoneBook_lookup'/>
- <output message='tns:PhoneBook_lookupResponse'/>
- </operation>
- </portType>
- <binding name='PhoneBookBinding' type='tns:PhoneBook'>
- <soap:binding style='document' transport='http://schemas.xmlsoap.org/soap/http'/>
- <operation name='lookup'>
- <soap:operation soapAction=''/>
- <input>
- <soap:body use='literal'/>
- </input>
- <output>
- <soap:body use='literal'/>
- </output>
- </operation>
- </binding>
- <service name='PhoneBook'>
- <port binding='tns:PhoneBookBinding' name='PhoneBookPort'>
- <soap:address location='REPLACE_WITH_ACTUAL_URL'/>
- </port>
- </service>
-</definitions>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook.wsdl (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook.wsdl)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook_PortType.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook_PortType.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook_PortType.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,11 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-public interface PhoneBook_PortType extends java.rmi.Remote {
- public org.jboss.test.ws.jbws1259.TelephoneNumber lookup(org.jboss.test.ws.jbws1259.Person parameters) throws
- java.rmi.RemoteException;
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook_PortType.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/PhoneBook_PortType.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/TelephoneNumber.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/TelephoneNumber.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/TelephoneNumber.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class TelephoneNumber {
- protected java.lang.String areaCode;
- protected java.lang.String number;
- protected org.jboss.test.ws.jbws1259.TelephoneNumber lookupResponse;
-
- public TelephoneNumber() {
- }
-
- public TelephoneNumber(java.lang.String areaCode, java.lang.String number, org.jboss.test.ws.jbws1259.TelephoneNumber lookupResponse) {
- this.areaCode = areaCode;
- this.number = number;
- this.lookupResponse = lookupResponse;
- }
-
- public java.lang.String getAreaCode() {
- return areaCode;
- }
-
- public void setAreaCode(java.lang.String areaCode) {
- this.areaCode = areaCode;
- }
-
- public java.lang.String getNumber() {
- return number;
- }
-
- public void setNumber(java.lang.String number) {
- this.number = number;
- }
-
- public org.jboss.test.ws.jbws1259.TelephoneNumber getLookupResponse() {
- return lookupResponse;
- }
-
- public void setLookupResponse(org.jboss.test.ws.jbws1259.TelephoneNumber lookupResponse) {
- this.lookupResponse = lookupResponse;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/TelephoneNumber.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/TelephoneNumber.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/jaxrpc-mapping.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/jaxrpc-mapping.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/jaxrpc-mapping.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,76 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259</namespaceURI>
- </package-mapping>
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259/types</namespaceURI>
- </package-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.TelephoneNumber</java-type>
- <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:TelephoneNumber</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>areaCode</java-variable-name>
- <xml-element-name>areaCode</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>number</java-variable-name>
- <xml-element-name>number</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>lookupResponse</java-variable-name>
- <xml-element-name>lookupResponse</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.Person</java-type>
- <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:Person</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>firstName</java-variable-name>
- <xml-element-name>firstName</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>surname</java-variable-name>
- <xml-element-name>surname</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>lookup</java-variable-name>
- <xml-element-name>lookup</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <service-interface-mapping>
- <service-interface>org.jboss.test.ws.jbws1259.PhoneBook_Service</service-interface>
- <wsdl-service-name xmlns:serviceNS="http://test.jboss.org/ws/jbws1259">serviceNS:PhoneBook</wsdl-service-name>
- <port-mapping>
- <port-name>PhoneBookPort</port-name>
- <java-port-name>PhoneBookPort</java-port-name>
- </port-mapping>
- </service-interface-mapping>
- <service-endpoint-interface-mapping>
- <service-endpoint-interface>org.jboss.test.ws.jbws1259.PhoneBook_PortType</service-endpoint-interface>
- <wsdl-port-type xmlns:portTypeNS="http://test.jboss.org/ws/jbws1259">portTypeNS:PhoneBook</wsdl-port-type>
- <wsdl-binding xmlns:bindingNS="http://test.jboss.org/ws/jbws1259">bindingNS:PhoneBookBinding</wsdl-binding>
- <service-endpoint-method-mapping>
- <java-method-name>lookup</java-method-name>
- <wsdl-operation>lookup</wsdl-operation>
- <method-param-parts-mapping>
- <param-position>0</param-position>
- <param-type>org.jboss.test.ws.jbws1259.Person</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookup</wsdl-message>
- <wsdl-message-part-name>parameters</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <wsdl-return-value-mapping>
- <method-return-value>org.jboss.test.ws.jbws1259.TelephoneNumber</method-return-value>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookupResponse</wsdl-message>
- <wsdl-message-part-name>result</wsdl-message-part-name>
- </wsdl-return-value-mapping>
- </service-endpoint-method-mapping>
- </service-endpoint-interface-mapping>
-</java-wsdl-mapping>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/jaxrpc-mapping.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/jaxrpc-mapping.xml)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/wstools-config.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/wstools-config.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/wstools-config.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,5 +0,0 @@
-<configuration>
- <wsdl-java location="resources/tools/jbws1259/scenario_B/PhoneBook.wsdl" parameter-style="bare">
- <mapping file="jaxrpc-mapping.xml"/>
- </wsdl-java>
-</configuration>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/wstools-config.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_B/wstools-config.xml)
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Comment.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Comment.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Comment.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,36 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class Comment {
- protected java.lang.String test;
- protected org.jboss.test.ws.jbws1259.Comment comment;
-
- public Comment() {
- }
-
- public Comment(java.lang.String test, org.jboss.test.ws.jbws1259.Comment comment) {
- this.test = test;
- this.comment = comment;
- }
-
- public java.lang.String getTest() {
- return test;
- }
-
- public void setTest(java.lang.String test) {
- this.test = test;
- }
-
- public org.jboss.test.ws.jbws1259.Comment getComment() {
- return comment;
- }
-
- public void setComment(org.jboss.test.ws.jbws1259.Comment comment) {
- this.comment = comment;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Comment.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Comment.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Person.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Person.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Person.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class Person {
- protected java.lang.String firstName;
- protected java.lang.String surname;
- protected org.jboss.test.ws.jbws1259.Comment comment;
-
- public Person() {
- }
-
- public Person(java.lang.String firstName, java.lang.String surname, org.jboss.test.ws.jbws1259.Comment comment) {
- this.firstName = firstName;
- this.surname = surname;
- this.comment = comment;
- }
-
- public java.lang.String getFirstName() {
- return firstName;
- }
-
- public void setFirstName(java.lang.String firstName) {
- this.firstName = firstName;
- }
-
- public java.lang.String getSurname() {
- return surname;
- }
-
- public void setSurname(java.lang.String surname) {
- this.surname = surname;
- }
-
- public org.jboss.test.ws.jbws1259.Comment getComment() {
- return comment;
- }
-
- public void setComment(org.jboss.test.ws.jbws1259.Comment comment) {
- this.comment = comment;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Person.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/Person.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook.wsdl
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook.wsdl 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook.wsdl 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<definitions name='PhoneBook' targetNamespace='http://test.jboss.org/ws/jbws1259' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:ns1='http://test.jboss.org/ws/jbws1259/types' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://test.jboss.org/ws/jbws1259' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
- <types>
- <schema targetNamespace='http://test.jboss.org/ws/jbws1259/types' xmlns='http://www.w3.org/2001/XMLSchema' xmlns:soap11-enc='http://schemas.xmlsoap.org/soap/encoding/' xmlns:tns='http://test.jboss.org/ws/jbws1259/types' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
-
- <complexType name='Person'>
- <sequence>
- <element name='firstName' nillable='true' type='string'/>
- <element name='surname' nillable='true' type='string'/>
- <element ref='tns:comment'/>
- </sequence>
- </complexType>
-
- <complexType name='TelephoneNumber'>
- <sequence>
- <element name='areaCode' nillable='true' type='string'/>
- <element name='number' nillable='true' type='string'/>
- <element ref='tns:comment'/>
- </sequence>
- </complexType>
-
- <element name='comment'>
- <complexType>
- <sequence>
- <element name='test' type='string' />
- <element ref='tns:comment' />
- </sequence>
- </complexType>
- </element>
-
- <element name='lookup' type='tns:Person' />
- <element name='lookupResponse' type='tns:TelephoneNumber'/>
- </schema>
- </types>
- <message name='PhoneBook_lookup'>
- <part element='ns1:lookup' name='parameters'/>
- </message>
- <message name='PhoneBook_lookupResponse'>
- <part element='ns1:lookupResponse' name='result'/>
- </message>
- <portType name='PhoneBook'>
- <operation name='lookup'>
- <input message='tns:PhoneBook_lookup'/>
- <output message='tns:PhoneBook_lookupResponse'/>
- </operation>
- </portType>
- <binding name='PhoneBookBinding' type='tns:PhoneBook'>
- <soap:binding style='document' transport='http://schemas.xmlsoap.org/soap/http'/>
- <operation name='lookup'>
- <soap:operation soapAction=''/>
- <input>
- <soap:body use='literal'/>
- </input>
- <output>
- <soap:body use='literal'/>
- </output>
- </operation>
- </binding>
- <service name='PhoneBook'>
- <port binding='tns:PhoneBookBinding' name='PhoneBookPort'>
- <soap:address location='REPLACE_WITH_ACTUAL_URL'/>
- </port>
- </service>
-</definitions>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook.wsdl (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook.wsdl)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook_PortType.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook_PortType.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook_PortType.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,11 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-public interface PhoneBook_PortType extends java.rmi.Remote {
- public org.jboss.test.ws.jbws1259.TelephoneNumber lookup(org.jboss.test.ws.jbws1259.Person parameters) throws
- java.rmi.RemoteException;
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook_PortType.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/PhoneBook_PortType.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/TelephoneNumber.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/TelephoneNumber.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/TelephoneNumber.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class TelephoneNumber {
- protected java.lang.String areaCode;
- protected java.lang.String number;
- protected org.jboss.test.ws.jbws1259.Comment comment;
-
- public TelephoneNumber() {
- }
-
- public TelephoneNumber(java.lang.String areaCode, java.lang.String number, org.jboss.test.ws.jbws1259.Comment comment) {
- this.areaCode = areaCode;
- this.number = number;
- this.comment = comment;
- }
-
- public java.lang.String getAreaCode() {
- return areaCode;
- }
-
- public void setAreaCode(java.lang.String areaCode) {
- this.areaCode = areaCode;
- }
-
- public java.lang.String getNumber() {
- return number;
- }
-
- public void setNumber(java.lang.String number) {
- this.number = number;
- }
-
- public org.jboss.test.ws.jbws1259.Comment getComment() {
- return comment;
- }
-
- public void setComment(org.jboss.test.ws.jbws1259.Comment comment) {
- this.comment = comment;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/TelephoneNumber.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/TelephoneNumber.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,89 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259</namespaceURI>
- </package-mapping>
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259/types</namespaceURI>
- </package-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.TelephoneNumber</java-type>
- <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:TelephoneNumber</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>areaCode</java-variable-name>
- <xml-element-name>areaCode</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>number</java-variable-name>
- <xml-element-name>number</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>comment</java-variable-name>
- <xml-element-name>comment</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.Comment</java-type>
- <anonymous-type-qname>http://test.jboss.org/ws/jbws1259/types:>TelephoneNumber>comment</anonymous-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>test</java-variable-name>
- <xml-element-name>test</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>comment</java-variable-name>
- <xml-element-name>comment</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.Person</java-type>
- <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:Person</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>firstName</java-variable-name>
- <xml-element-name>firstName</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>surname</java-variable-name>
- <xml-element-name>surname</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>comment</java-variable-name>
- <xml-element-name>comment</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <service-interface-mapping>
- <service-interface>org.jboss.test.ws.jbws1259.PhoneBook_Service</service-interface>
- <wsdl-service-name xmlns:serviceNS="http://test.jboss.org/ws/jbws1259">serviceNS:PhoneBook</wsdl-service-name>
- <port-mapping>
- <port-name>PhoneBookPort</port-name>
- <java-port-name>PhoneBookPort</java-port-name>
- </port-mapping>
- </service-interface-mapping>
- <service-endpoint-interface-mapping>
- <service-endpoint-interface>org.jboss.test.ws.jbws1259.PhoneBook_PortType</service-endpoint-interface>
- <wsdl-port-type xmlns:portTypeNS="http://test.jboss.org/ws/jbws1259">portTypeNS:PhoneBook</wsdl-port-type>
- <wsdl-binding xmlns:bindingNS="http://test.jboss.org/ws/jbws1259">bindingNS:PhoneBookBinding</wsdl-binding>
- <service-endpoint-method-mapping>
- <java-method-name>lookup</java-method-name>
- <wsdl-operation>lookup</wsdl-operation>
- <method-param-parts-mapping>
- <param-position>0</param-position>
- <param-type>org.jboss.test.ws.jbws1259.Person</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookup</wsdl-message>
- <wsdl-message-part-name>parameters</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <wsdl-return-value-mapping>
- <method-return-value>org.jboss.test.ws.jbws1259.TelephoneNumber</method-return-value>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookupResponse</wsdl-message>
- <wsdl-message-part-name>result</wsdl-message-part-name>
- </wsdl-return-value-mapping>
- </service-endpoint-method-mapping>
- </service-endpoint-interface-mapping>
-</java-wsdl-mapping>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml)
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/jaxrpc-mapping.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jbws1259</package-type>
+ <namespaceURI>http://test.jboss.org/ws/jbws1259</namespaceURI>
+ </package-mapping>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jbws1259</package-type>
+ <namespaceURI>http://test.jboss.org/ws/jbws1259/types</namespaceURI>
+ </package-mapping>
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jbws1259.TelephoneNumber</java-type>
+ <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:TelephoneNumber</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>areaCode</java-variable-name>
+ <xml-element-name>areaCode</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>number</java-variable-name>
+ <xml-element-name>number</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>comment</java-variable-name>
+ <xml-element-name>comment</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+
+ <!-- The QName generated by wscompile is not correct. -->
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jbws1259.Comment</java-type>
+
+ <!-- This is according to use case 4 from section 7.3.2.2 of the Web Services for J2EE specification -->
+
+ <anonymous-type-qname>http://test.jboss.org/ws/jbws1259/types:>comment</anonymous-type-qname>
+
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>test</java-variable-name>
+ <xml-element-name>test</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>comment</java-variable-name>
+ <xml-element-name>comment</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jbws1259.Person</java-type>
+ <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:Person</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>firstName</java-variable-name>
+ <xml-element-name>firstName</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>surname</java-variable-name>
+ <xml-element-name>surname</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>comment</java-variable-name>
+ <xml-element-name>comment</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+ <service-interface-mapping>
+ <service-interface>org.jboss.test.ws.jbws1259.PhoneBook_Service</service-interface>
+ <wsdl-service-name xmlns:serviceNS="http://test.jboss.org/ws/jbws1259">serviceNS:PhoneBook</wsdl-service-name>
+ <port-mapping>
+ <port-name>PhoneBookPort</port-name>
+ <java-port-name>PhoneBookPort</java-port-name>
+ </port-mapping>
+ </service-interface-mapping>
+ <service-endpoint-interface-mapping>
+ <service-endpoint-interface>org.jboss.test.ws.jbws1259.PhoneBook_PortType</service-endpoint-interface>
+ <wsdl-port-type xmlns:portTypeNS="http://test.jboss.org/ws/jbws1259">portTypeNS:PhoneBook</wsdl-port-type>
+ <wsdl-binding xmlns:bindingNS="http://test.jboss.org/ws/jbws1259">bindingNS:PhoneBookBinding</wsdl-binding>
+ <service-endpoint-method-mapping>
+ <java-method-name>lookup</java-method-name>
+ <wsdl-operation>lookup</wsdl-operation>
+ <method-param-parts-mapping>
+ <param-position>0</param-position>
+ <param-type>org.jboss.test.ws.jbws1259.Person</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookup</wsdl-message>
+ <wsdl-message-part-name>parameters</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <wsdl-return-value-mapping>
+ <method-return-value>org.jboss.test.ws.jbws1259.TelephoneNumber</method-return-value>
+ <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookupResponse</wsdl-message>
+ <wsdl-message-part-name>result</wsdl-message-part-name>
+ </wsdl-return-value-mapping>
+ </service-endpoint-method-mapping>
+ </service-endpoint-interface-mapping>
+</java-wsdl-mapping>
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/wstools-config.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/wstools-config.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/wstools-config.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,5 +0,0 @@
-<configuration>
- <wsdl-java location="resources/tools/jbws1259/scenario_C/PhoneBook.wsdl" parameter-style="bare">
- <mapping file="jaxrpc-mapping.xml"/>
- </wsdl-java>
-</configuration>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/wstools-config.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_C/wstools-config.xml)
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Comment.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Comment.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Comment.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,36 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class Comment {
- protected java.lang.String test;
- protected org.jboss.test.ws.jbws1259.Comment comment;
-
- public Comment() {
- }
-
- public Comment(java.lang.String test, org.jboss.test.ws.jbws1259.Comment comment) {
- this.test = test;
- this.comment = comment;
- }
-
- public java.lang.String getTest() {
- return test;
- }
-
- public void setTest(java.lang.String test) {
- this.test = test;
- }
-
- public org.jboss.test.ws.jbws1259.Comment getComment() {
- return comment;
- }
-
- public void setComment(org.jboss.test.ws.jbws1259.Comment comment) {
- this.comment = comment;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Comment.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Comment.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Person.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Person.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Person.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class Person {
- protected java.lang.String firstName;
- protected java.lang.String surname;
- protected org.jboss.test.ws.jbws1259.Comment comment;
-
- public Person() {
- }
-
- public Person(java.lang.String firstName, java.lang.String surname, org.jboss.test.ws.jbws1259.Comment comment) {
- this.firstName = firstName;
- this.surname = surname;
- this.comment = comment;
- }
-
- public java.lang.String getFirstName() {
- return firstName;
- }
-
- public void setFirstName(java.lang.String firstName) {
- this.firstName = firstName;
- }
-
- public java.lang.String getSurname() {
- return surname;
- }
-
- public void setSurname(java.lang.String surname) {
- this.surname = surname;
- }
-
- public org.jboss.test.ws.jbws1259.Comment getComment() {
- return comment;
- }
-
- public void setComment(org.jboss.test.ws.jbws1259.Comment comment) {
- this.comment = comment;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Person.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/Person.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook.wsdl
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook.wsdl 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook.wsdl 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<definitions name='PhoneBook' targetNamespace='http://test.jboss.org/ws/jbws1259' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:ns1='http://test.jboss.org/ws/jbws1259/types' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://test.jboss.org/ws/jbws1259' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
- <types>
- <schema targetNamespace='http://test.jboss.org/ws/jbws1259/types' xmlns='http://www.w3.org/2001/XMLSchema' xmlns:soap11-enc='http://schemas.xmlsoap.org/soap/encoding/' xmlns:tns='http://test.jboss.org/ws/jbws1259/types' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
-
- <complexType name='Person'>
- <sequence>
- <element name='firstName' nillable='true' type='string'/>
- <element name='surname' nillable='true' type='string'/>
- <element ref='tns:comment'/>
- </sequence>
- </complexType>
-
- <complexType name='TelephoneNumber'>
- <sequence>
- <element name='areaCode' nillable='true' type='string'/>
- <element name='number' nillable='true' type='string'/>
- <element ref='tns:comment'/>
- </sequence>
- </complexType>
-
- <complexType name='Comment'>
- <sequence>
- <element name='test' type='string' />
- <element ref='tns:comment' />
- </sequence>
- </complexType>
-
- <element name='comment' type='tns:Comment' />
-
- <element name='lookup' type='tns:Person' />
- <element name='lookupResponse' type='tns:TelephoneNumber'/>
- </schema>
- </types>
- <message name='PhoneBook_lookup'>
- <part element='ns1:lookup' name='parameters'/>
- </message>
- <message name='PhoneBook_lookupResponse'>
- <part element='ns1:lookupResponse' name='result'/>
- </message>
- <portType name='PhoneBook'>
- <operation name='lookup'>
- <input message='tns:PhoneBook_lookup'/>
- <output message='tns:PhoneBook_lookupResponse'/>
- </operation>
- </portType>
- <binding name='PhoneBookBinding' type='tns:PhoneBook'>
- <soap:binding style='document' transport='http://schemas.xmlsoap.org/soap/http'/>
- <operation name='lookup'>
- <soap:operation soapAction=''/>
- <input>
- <soap:body use='literal'/>
- </input>
- <output>
- <soap:body use='literal'/>
- </output>
- </operation>
- </binding>
- <service name='PhoneBook'>
- <port binding='tns:PhoneBookBinding' name='PhoneBookPort'>
- <soap:address location='REPLACE_WITH_ACTUAL_URL'/>
- </port>
- </service>
-</definitions>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook.wsdl (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook.wsdl)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook_PortType.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook_PortType.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook_PortType.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,11 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-public interface PhoneBook_PortType extends java.rmi.Remote {
- public org.jboss.test.ws.jbws1259.TelephoneNumber lookup(org.jboss.test.ws.jbws1259.Person parameters) throws
- java.rmi.RemoteException;
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook_PortType.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/PhoneBook_PortType.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/TelephoneNumber.java
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/TelephoneNumber.java 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/TelephoneNumber.java 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,46 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jbws1259;
-
-
-public class TelephoneNumber {
- protected java.lang.String areaCode;
- protected java.lang.String number;
- protected org.jboss.test.ws.jbws1259.Comment comment;
-
- public TelephoneNumber() {
- }
-
- public TelephoneNumber(java.lang.String areaCode, java.lang.String number, org.jboss.test.ws.jbws1259.Comment comment) {
- this.areaCode = areaCode;
- this.number = number;
- this.comment = comment;
- }
-
- public java.lang.String getAreaCode() {
- return areaCode;
- }
-
- public void setAreaCode(java.lang.String areaCode) {
- this.areaCode = areaCode;
- }
-
- public java.lang.String getNumber() {
- return number;
- }
-
- public void setNumber(java.lang.String number) {
- this.number = number;
- }
-
- public org.jboss.test.ws.jbws1259.Comment getComment() {
- return comment;
- }
-
- public void setComment(org.jboss.test.ws.jbws1259.Comment comment) {
- this.comment = comment;
- }
-}
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/TelephoneNumber.java (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/TelephoneNumber.java)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/jaxrpc-mapping.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/jaxrpc-mapping.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/jaxrpc-mapping.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,89 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259</namespaceURI>
- </package-mapping>
- <package-mapping>
- <package-type>org.jboss.test.ws.jbws1259</package-type>
- <namespaceURI>http://test.jboss.org/ws/jbws1259/types</namespaceURI>
- </package-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.TelephoneNumber</java-type>
- <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:TelephoneNumber</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>areaCode</java-variable-name>
- <xml-element-name>areaCode</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>number</java-variable-name>
- <xml-element-name>number</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>comment</java-variable-name>
- <xml-element-name>comment</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.Comment</java-type>
- <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:Comment</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>test</java-variable-name>
- <xml-element-name>test</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>comment</java-variable-name>
- <xml-element-name>comment</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jbws1259.Person</java-type>
- <root-type-qname xmlns:typeNS="http://test.jboss.org/ws/jbws1259/types">typeNS:Person</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>firstName</java-variable-name>
- <xml-element-name>firstName</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>surname</java-variable-name>
- <xml-element-name>surname</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>comment</java-variable-name>
- <xml-element-name>comment</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <service-interface-mapping>
- <service-interface>org.jboss.test.ws.jbws1259.PhoneBook_Service</service-interface>
- <wsdl-service-name xmlns:serviceNS="http://test.jboss.org/ws/jbws1259">serviceNS:PhoneBook</wsdl-service-name>
- <port-mapping>
- <port-name>PhoneBookPort</port-name>
- <java-port-name>PhoneBookPort</java-port-name>
- </port-mapping>
- </service-interface-mapping>
- <service-endpoint-interface-mapping>
- <service-endpoint-interface>org.jboss.test.ws.jbws1259.PhoneBook_PortType</service-endpoint-interface>
- <wsdl-port-type xmlns:portTypeNS="http://test.jboss.org/ws/jbws1259">portTypeNS:PhoneBook</wsdl-port-type>
- <wsdl-binding xmlns:bindingNS="http://test.jboss.org/ws/jbws1259">bindingNS:PhoneBookBinding</wsdl-binding>
- <service-endpoint-method-mapping>
- <java-method-name>lookup</java-method-name>
- <wsdl-operation>lookup</wsdl-operation>
- <method-param-parts-mapping>
- <param-position>0</param-position>
- <param-type>org.jboss.test.ws.jbws1259.Person</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookup</wsdl-message>
- <wsdl-message-part-name>parameters</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <wsdl-return-value-mapping>
- <method-return-value>org.jboss.test.ws.jbws1259.TelephoneNumber</method-return-value>
- <wsdl-message xmlns:wsdlMsgNS="http://test.jboss.org/ws/jbws1259">wsdlMsgNS:PhoneBook_lookupResponse</wsdl-message>
- <wsdl-message-part-name>result</wsdl-message-part-name>
- </wsdl-return-value-mapping>
- </service-endpoint-method-mapping>
- </service-endpoint-interface-mapping>
-</java-wsdl-mapping>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/jaxrpc-mapping.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/jaxrpc-mapping.xml)
Deleted: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/wstools-config.xml
===================================================================
--- branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/wstools-config.xml 2007-01-11 15:00:58 UTC (rev 1927)
+++ trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/wstools-config.xml 2007-01-12 12:03:04 UTC (rev 1939)
@@ -1,5 +0,0 @@
-<configuration>
- <wsdl-java location="resources/tools/jbws1259/scenario_D/PhoneBook.wsdl" parameter-style="bare">
- <mapping file="jaxrpc-mapping.xml"/>
- </wsdl-java>
-</configuration>
Copied: trunk/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/wstools-config.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/jbws1259/scenario_D/wstools-config.xml)
Copied: trunk/jbossws-tests/src/main/resources/tools/wsdl11/jaxrpc-mapping.xml (from rev 1927, branches/dlofthouse/JBWS-1259/jbossws-tests/src/main/resources/tools/wsdl11/jaxrpc-mapping.xml)
18 years
JBossWS SVN: r1938 - in branches/tdiesler/trunk: jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc and 10 other directories.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-01-12 06:17:14 -0500 (Fri, 12 Jan 2007)
New Revision: 1938
Added:
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WebservicesXMLCreatorImpl.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java
Removed:
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java
Modified:
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java
branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java
branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml
branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml
branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml
branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl
branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml
Log:
[JBWS-1384] - Attachment parts with doclit message
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/CommonClient.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -242,6 +242,9 @@
// Bind the request message
SOAPMessage reqMessage = (SOAPMessage)binding.bindRequestMessage(opMetaData, epInv, unboundHeaders);
+
+ // Add possible attachment parts
+ addAttachmentParts(reqMessage);
setOutboundContextProperties();
@@ -295,7 +298,7 @@
// at pivot the message context might be replaced
msgContext = processPivot(msgContext);
- // Associate current message with message context
+ // Associate response message with message context
msgContext.setSOAPMessage(resMessage);
}
@@ -342,6 +345,11 @@
}
}
+ protected void addAttachmentParts(SOAPMessage reqMessage)
+ {
+ // By default do nothing
+ }
+
protected abstract CommonMessageContext processPivot(CommonMessageContext requestContext);
protected CommonBindingProvider getCommonBindingProvider()
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -42,7 +42,10 @@
import javax.xml.rpc.Stub;
import javax.xml.rpc.encoding.SerializerFactory;
import javax.xml.rpc.soap.SOAPFaultException;
+import javax.xml.soap.AttachmentPart;
+import javax.xml.soap.MessageFactory;
import javax.xml.soap.SOAPException;
+import javax.xml.soap.SOAPMessage;
import org.jboss.logging.Logger;
import org.jboss.ws.Constants;
@@ -85,6 +88,8 @@
private Map<QName, UnboundHeader> unboundHeaders = new LinkedHashMap<QName, UnboundHeader>();
// A Map<String,Object> of Call properties
private Map<String, Object> properties = new HashMap<String, Object>();
+ // A List<AttachmentPart> of attachment parts set through the proxy
+ private List<AttachmentPart> attachmentParts = new ArrayList<AttachmentPart>();
// The set of supported properties
private static final Set<String> standardProperties = new HashSet<String>();
@@ -219,7 +224,40 @@
{
return unboundHeaders.keySet().iterator();
}
+
+ /**
+ * Adds the given AttachmentPart object to the outgoing SOAPMessage.
+ * An AttachmentPart object must be created before it can be added to a message.
+ */
+ public void addAttachmentPart(AttachmentPart part)
+ {
+ attachmentParts.add(part);
+ }
+ /**
+ * Clears the list of attachment parts.
+ */
+ public void clearAttachmentParts()
+ {
+ attachmentParts.clear();
+ }
+
+ /**
+ * Creates a new empty AttachmentPart object.
+ */
+ public AttachmentPart createAttachmentPart()
+ {
+ try
+ {
+ MessageFactory factory = MessageFactory.newInstance();
+ return factory.createMessage().createAttachmentPart();
+ }
+ catch (SOAPException ex)
+ {
+ throw new JAXRPCException("Cannot create attachment part");
+ }
+ }
+
/** Gets the address of a target service endpoint.
*/
public String getTargetEndpointAddress()
@@ -590,6 +628,16 @@
}
@Override
+ protected void addAttachmentParts(SOAPMessage reqMessage)
+ {
+ for (AttachmentPart part : attachmentParts)
+ {
+ log.debug("Adding attachment part: " + part.getContentId());
+ reqMessage.addAttachmentPart(part);
+ }
+ }
+
+ @Override
protected boolean callRequestHandlerChain(QName portName, HandlerType type)
{
SOAPMessageContextJAXRPC msgContext = (SOAPMessageContextJAXRPC)MessageContextAssociation.peekMessageContext();
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/StubExt.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -25,6 +25,7 @@
import javax.xml.namespace.QName;
import javax.xml.rpc.ParameterMode;
+import javax.xml.soap.AttachmentPart;
import org.jboss.ws.metadata.umdm.EndpointMetaData;
@@ -109,7 +110,23 @@
* A propriatory extension, that is not part of JAXRPC.
*/
Iterator getUnboundHeaders();
+
+ /**
+ * Adds the given AttachmentPart object to the outgoing SOAPMessage.
+ * An AttachmentPart object must be created before it can be added to a message.
+ */
+ void addAttachmentPart(AttachmentPart attachmentpart);
+ /**
+ * Clears the list of attachment parts.
+ */
+ void clearAttachmentParts();
+
+ /**
+ * Creates a new empty AttachmentPart object.
+ */
+ AttachmentPart createAttachmentPart();
+
/**
* Get the current port configuration file
* A propriatory extension, that is not part of JAXRPC.
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManager.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -200,6 +200,11 @@
this.serviceEndpointInvokerJSE = invoker;
}
+ public String getImplementationVersion()
+ {
+ return UnifiedMetaData.getImplementationVersion();
+ }
+
public List<ObjectName> getServiceEndpoints()
{
ArrayList<ObjectName> list = new ArrayList<ObjectName>();
@@ -616,7 +621,7 @@
public void create() throws Exception
{
- log.info(UnifiedMetaData.getImplementationVersion());
+ log.info(getImplementationVersion());
MBeanServer server = getJMXServer();
if (server != null)
{
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/server/ServiceEndpointManagerMBean.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -38,6 +38,8 @@
// default object name
static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.ws:service=ServiceEndpointManager");
+ String getImplementationVersion();
+
String getWebServiceHost();
void setWebServiceHost(String host) throws UnknownHostException;
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/builder/jaxrpc/JAXRPCMetaDataBuilder.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -386,15 +386,20 @@
pmd.setInHeader(true);
}
- for (WSDLMIMEPart mimePart : bindingInput.getMimeParts())
+ // we don't support swa binding parameters in document style
+ // http://jira.jboss.org/jira/browse/JBWS-1384
+ if (opMetaData.getStyle() == Style.RPC)
{
- String partName = mimePart.getPartName();
- QName xmlName = new QName(partName);
- QName xmlType = mimePart.getXmlType();
+ for (WSDLMIMEPart mimePart : bindingInput.getMimeParts())
+ {
+ String partName = mimePart.getPartName();
+ QName xmlName = new QName(partName);
+ QName xmlType = mimePart.getXmlType();
- ParameterMetaData pmd = buildInputParameter(opMetaData, wsdlOperation, seiMethodMapping, typeMapping, partName, xmlName, xmlType, wsdlPosition++, false);
- pmd.setSwA(true);
- pmd.setMimeTypes(mimePart.getMimeTypes());
+ ParameterMetaData pmd = buildInputParameter(opMetaData, wsdlOperation, seiMethodMapping, typeMapping, partName, xmlName, xmlType, wsdlPosition++, false);
+ pmd.setSwA(true);
+ pmd.setMimeTypes(mimePart.getMimeTypes());
+ }
}
return wsdlPosition;
@@ -638,7 +643,7 @@
throw new IllegalArgumentException("wsdl-message-message mapping required for document/literal wrapped");
String elementName = wsdlMessageMapping.getWsdlMessagePartName();
- String variable = variableMap.get(wsdlMessageMapping.getWsdlMessagePartName());
+ String variable = variableMap.get(elementName);
if (variable == null)
throw new IllegalArgumentException("Could not determine variable name for element: " + elementName);
Deleted: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -1,231 +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.tools;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.io.InputStream;
-
-import javax.xml.namespace.QName;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.WSException;
-import org.jboss.ws.metadata.webservices.PortComponentMetaData;
-import org.jboss.ws.metadata.webservices.WebserviceDescriptionMetaData;
-import org.jboss.ws.metadata.webservices.WebservicesFactory;
-import org.jboss.ws.metadata.webservices.WebservicesMetaData;
-import org.jboss.ws.tools.interfaces.WSDotXMLCreatorIntf;
-import org.jboss.xb.binding.JBossXBException;
-import org.jboss.xb.binding.ObjectModelFactory;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-
-/**
- * Creates the webservices.xml deployment descriptor
- * @author <mailto:Anil.Saldhana@jboss.org>Anil Saldhana
- * @since Jun 20, 2005
- */
-public class WSDotXMLCreator implements WSDotXMLCreatorIntf
-{
- // provide logging
- protected static final Logger log = Logger.getLogger(WSDotXMLCreator.class);
- protected String targetNamespace = null;
-
- protected String seiName = null;
-
- protected String portName = null;
-
- protected String serviceName = null;
-
- protected String servletLink = null;
-
- protected String ejbLink = null;
-
- protected String wsdlFile = null;
- protected String mappingFile = null;
-
- protected boolean append = false;
-
- public WSDotXMLCreator()
- {
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setTargetNamespace(java.lang.String)
- */
- public void setTargetNamespace(String targetNamespace)
- {
- this.targetNamespace = targetNamespace;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setSeiName(java.lang.String)
- */
- public void setSeiName(String seiName)
- {
- this.seiName = seiName;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setPortName(java.lang.String)
- */
- public void setPortName(String portName)
- {
- this.portName = portName;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setServiceName(java.lang.String)
- */
- public void setServiceName(String serviceName)
- {
- this.serviceName = serviceName;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setEjbLink(java.lang.String)
- */
- public void setEjbLink(String ejbLink)
- {
- this.ejbLink = ejbLink;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setServletLink(java.lang.String)
- */
- public void setServletLink(String servletLink)
- {
- this.servletLink = servletLink;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setMappingFile(java.lang.String)
- */
- public void setMappingFile(String mappingFile)
- {
- this.mappingFile = mappingFile;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#setWsdlFile(java.lang.String)
- */
- public void setWsdlFile(String wsdlFile)
- {
- this.wsdlFile = wsdlFile;
- }
-
- public void setAppend(boolean append)
- {
- this.append = append;
- }
-
- /* (non-Javadoc)
- * @see org.jboss.ws.tools.WSDotXMLCreatorIntf#generateWSXMLDescriptor(java.io.File)
- */
- public void generateWSXMLDescriptor(File wsXmlFile) throws IOException
- {
- WebservicesMetaData webservices = constructWSMetaData();
-
- // handle append flag
- if (append && wsXmlFile.exists())
- {
- WebservicesMetaData existingWebservices;
-
- // parse existing webservices descriptor
- InputStream wsXmlStream = new FileInputStream(wsXmlFile);
- try
- {
- Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
- ObjectModelFactory factory = new WebservicesFactory(wsXmlFile.toURL());
- existingWebservices = (WebservicesMetaData)unmarshaller.unmarshal(wsXmlStream, factory, null);
- }
- catch (JBossXBException e)
- {
- throw new WSException("Could not unmarshal existing webservices descriptor: " + wsXmlFile, e);
- }
- finally
- {
- wsXmlStream.close();
- }
-
- // append generated webservice-descriptions to existing descriptor
- for (WebserviceDescriptionMetaData webserviceDescription : webservices.getWebserviceDescriptions())
- existingWebservices.addWebserviceDescription(webserviceDescription);
-
- webservices = existingWebservices;
- }
-
- // (re-)write generated webservices descriptor to file
- FileWriter fw = new FileWriter(wsXmlFile);
- fw.write(webservices.serialize());
- fw.close();
- }
-
- //PRIVATE METHODS
-
- private WebservicesMetaData constructWSMetaData()
- {
- WebservicesMetaData wm = new WebservicesMetaData();
- WebserviceDescriptionMetaData wsdm = new WebserviceDescriptionMetaData(wm);
- populateWebserviceDescriptionMetaData(wsdm);
- wm.addWebserviceDescription(wsdm);
- return wm;
- }
-
- private void populateWebserviceDescriptionMetaData(WebserviceDescriptionMetaData wsdm)
- {
- checkEssentials();
- wsdm.setWebserviceDescriptionName(this.serviceName);
- wsdm.setWsdlFile(this.wsdlFile);
- wsdm.setJaxrpcMappingFile(this.mappingFile);
- PortComponentMetaData pm1 = new PortComponentMetaData(wsdm);
- pm1.setPortComponentName(portName);
- pm1.setWsdlPort(new QName(this.targetNamespace, portName, "portNS"));
- pm1.setServiceEndpointInterface(seiName);
- if (this.servletLink != null && this.servletLink.length() > 0)
- pm1.setServletLink(this.servletLink);
- else pm1.setEjbLink(this.ejbLink);
- wsdm.addPortComponent(pm1);
- }
-
- private void checkEssentials()
- {
- if (serviceName == null)
- throw new WSException("serviceName is null");
- if (wsdlFile == null)
- throw new WSException("wsdlFile is null");
- if (mappingFile == null)
- throw new WSException("mappingFile is null");
- if (targetNamespace == null)
- throw new WSException("targetNamespace is null");
- if (portName == null)
- throw new WSException("portName is null");
- if (seiName == null)
- throw new WSException("seiName is null");
- if (servletLink == null && ejbLink == null)
- throw new WSException("Either servletLink or ejbLink should not be null");
- if (servletLink != null && ejbLink != null)
- throw new WSException("One of servletLink or ejbLink should be null");
- }
-}
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSTools.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -45,9 +45,6 @@
{
private static Logger log = Logger.getLogger(WSTools.class);
- private Configuration config;
- private String outputDir = ".";
-
/**
* Entry point for the command line scripts.
* Just passes the arguments to
@@ -63,28 +60,35 @@
/**
* Entry point for the programmatic use
- *
- * @param args
- * @throws IOException
*/
- public void generate(String[] args) throws IOException
+ public boolean generate(String configLocation, String outputDir) throws IOException
{
- boolean knownArgument = false;
+ ToolsSchemaConfigReader configReader = new ToolsSchemaConfigReader();
+ Configuration config = configReader.readConfig(configLocation);
+
+ return process(config, outputDir);
+ }
+
+ /**
+ * Entry point for the programmatic use
+ */
+ public boolean generate(String[] args) throws IOException
+ {
+ String configLocation = null;
+ String outputDir = null;
for (int i = 0; i < args.length; i++)
{
String arg = args[i];
if ("-config".equals(arg))
{
- readToolsConfiguration(args[i + 1]);
- knownArgument = true;
+ configLocation = args[i + 1];
i++;
}
else if ("-dest".equals(arg))
{
outputDir = args[i + 1];
- knownArgument = true;
i++;
}
@@ -94,7 +98,7 @@
int tokens = st.countTokens();
URL[] urls = new URL[tokens];
- for(int j = 0; j < tokens; j++)
+ for (int j = 0; j < tokens; j++)
{
String token = st.nextToken();
urls[j] = new File(token).toURL();
@@ -103,50 +107,39 @@
ClassLoader ctxLoader = Thread.currentThread().getContextClassLoader();
URLClassLoader urlLoader = new URLClassLoader(urls, ctxLoader);
Thread.currentThread().setContextClassLoader(urlLoader);
- knownArgument = true;
i++;
}
+ else
+ {
+ System.out.println("Usage: wstools (-classpath|-cp) <classpath> -config <config> [-dest <destination path>]");
+ System.exit(1);
+ }
}
- if (! knownArgument)
- {
- System.out.println("Usage: wstools (-classpath|-cp) <classpath> -config <config> [-dest <destination path>]");
- System.exit(1);
- }
-
- if (config == null)
- throw new IllegalArgumentException("wstools config not found");
-
- process();
+ return generate(configLocation, outputDir);
}
- private void process() throws IOException
+ private boolean process(Configuration config, String outputDir) throws IOException
{
- ToolsHelper helper = new ToolsHelper();
if (config == null)
- throw new WSException("Configuration is null");
-
- boolean processed = false;
+ throw new IllegalArgumentException("Configuration is null");
+
+ if (outputDir == null)
+ outputDir = ".";
+
+ ToolsHelper helper = new ToolsHelper();
if (config.getJavaToWSDLConfig(false) != null)
{
helper.handleJavaToWSDLGeneration(config, outputDir);
- processed = true;
}
-
- if (config.getWSDLToJavaConfig(false) != null)
+ else if (config.getWSDLToJavaConfig(false) != null)
{
helper.handleWSDLToJavaGeneration(config, outputDir);
- processed = true;
}
-
- if (!processed)
+ else
+ {
throw new WSException("Nothing done, Configuration source must have JavaToWSDL or WSDLToJava specified");
+ }
+ return true;
}
-
- private void readToolsConfiguration(String filename) throws IOException
- {
- log.debug("Config file name=" + filename);
- ToolsSchemaConfigReader configReader = new ToolsSchemaConfigReader();
- config = configReader.readConfig(filename);
- }
}
Copied: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WebservicesXMLCreatorImpl.java (from rev 1932, branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java)
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WSDotXMLCreator.java 2007-01-11 15:14:41 UTC (rev 1932)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/WebservicesXMLCreatorImpl.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -0,0 +1,209 @@
+/*
+ * 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.tools;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileWriter;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.StringWriter;
+
+import javax.xml.namespace.QName;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.WSException;
+import org.jboss.ws.core.utils.DOMUtils;
+import org.jboss.ws.core.utils.DOMWriter;
+import org.jboss.ws.metadata.webservices.PortComponentMetaData;
+import org.jboss.ws.metadata.webservices.WebserviceDescriptionMetaData;
+import org.jboss.ws.metadata.webservices.WebservicesFactory;
+import org.jboss.ws.metadata.webservices.WebservicesMetaData;
+import org.jboss.ws.tools.interfaces.WebservicesXMLCreator;
+import org.jboss.xb.binding.JBossXBException;
+import org.jboss.xb.binding.ObjectModelFactory;
+import org.jboss.xb.binding.Unmarshaller;
+import org.jboss.xb.binding.UnmarshallerFactory;
+import org.w3c.dom.Element;
+
+/**
+ * Creates the webservices.xml deployment descriptor
+ * @author <mailto:Anil.Saldhana@jboss.org>Anil Saldhana
+ * @since Jun 20, 2005
+ */
+public class WebservicesXMLCreatorImpl implements WebservicesXMLCreator
+{
+ // provide logging
+ protected static final Logger log = Logger.getLogger(WebservicesXMLCreatorImpl.class);
+ protected String targetNamespace = null;
+
+ protected String seiName = null;
+
+ protected String portName = null;
+
+ protected String serviceName = null;
+
+ protected String servletLink = null;
+
+ protected String ejbLink = null;
+
+ protected String wsdlFile = null;
+ protected String mappingFile = null;
+
+ protected boolean append = false;
+
+ public WebservicesXMLCreatorImpl()
+ {
+ }
+
+ public void setTargetNamespace(String targetNamespace)
+ {
+ this.targetNamespace = targetNamespace;
+ }
+
+ public void setSeiName(String seiName)
+ {
+ this.seiName = seiName;
+ }
+
+ public void setPortName(String portName)
+ {
+ this.portName = portName;
+ }
+
+ public void setServiceName(String serviceName)
+ {
+ this.serviceName = serviceName;
+ }
+
+ public void setEjbLink(String ejbLink)
+ {
+ this.ejbLink = ejbLink;
+ }
+
+ public void setServletLink(String servletLink)
+ {
+ this.servletLink = servletLink;
+ }
+
+ public void setMappingFile(String mappingFile)
+ {
+ this.mappingFile = mappingFile;
+ }
+
+ public void setWsdlFile(String wsdlFile)
+ {
+ this.wsdlFile = wsdlFile;
+ }
+
+ public void setAppend(boolean append)
+ {
+ this.append = append;
+ }
+
+ public void generateWSXMLDescriptor(File wsXmlFile) throws IOException
+ {
+ WebservicesMetaData webservices = constructWSMetaData();
+
+ // handle append flag
+ if (append && wsXmlFile.exists())
+ {
+ WebservicesMetaData existingWebservices;
+
+ // parse existing webservices descriptor
+ InputStream wsXmlStream = new FileInputStream(wsXmlFile);
+ try
+ {
+ Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
+ ObjectModelFactory factory = new WebservicesFactory(wsXmlFile.toURL());
+ existingWebservices = (WebservicesMetaData)unmarshaller.unmarshal(wsXmlStream, factory, null);
+ }
+ catch (JBossXBException e)
+ {
+ throw new WSException("Could not unmarshal existing webservices descriptor: " + wsXmlFile, e);
+ }
+ finally
+ {
+ wsXmlStream.close();
+ }
+
+ // append generated webservice-descriptions to existing descriptor
+ for (WebserviceDescriptionMetaData webserviceDescription : webservices.getWebserviceDescriptions())
+ existingWebservices.addWebserviceDescription(webserviceDescription);
+
+ webservices = existingWebservices;
+ }
+
+ // (re-)write generated webservices descriptor to file
+ Element root = DOMUtils.parse(webservices.serialize());
+ FileWriter fwriter = new FileWriter(wsXmlFile);
+ new DOMWriter(fwriter).setPrettyprint(true).print(root);
+ fwriter.close();
+ }
+
+ //PRIVATE METHODS
+
+ private WebservicesMetaData constructWSMetaData()
+ {
+ WebservicesMetaData wm = new WebservicesMetaData();
+ WebserviceDescriptionMetaData wsdm = new WebserviceDescriptionMetaData(wm);
+ populateWebserviceDescriptionMetaData(wsdm);
+ wm.addWebserviceDescription(wsdm);
+ return wm;
+ }
+
+ private void populateWebserviceDescriptionMetaData(WebserviceDescriptionMetaData wsdm)
+ {
+ checkEssentials();
+ wsdm.setWebserviceDescriptionName(this.serviceName);
+ wsdm.setWsdlFile(this.wsdlFile);
+ wsdm.setJaxrpcMappingFile(this.mappingFile);
+ PortComponentMetaData pm1 = new PortComponentMetaData(wsdm);
+ pm1.setPortComponentName(portName);
+ pm1.setWsdlPort(new QName(this.targetNamespace, portName, "portNS"));
+ pm1.setServiceEndpointInterface(seiName);
+ if (this.servletLink != null && this.servletLink.length() > 0)
+ pm1.setServletLink(this.servletLink);
+ else pm1.setEjbLink(this.ejbLink);
+ wsdm.addPortComponent(pm1);
+ }
+
+ private void checkEssentials()
+ {
+ if (serviceName == null)
+ throw new WSException("serviceName is null");
+ if (wsdlFile == null)
+ throw new WSException("wsdlFile is null");
+ if (mappingFile == null)
+ throw new WSException("mappingFile is null");
+ if (targetNamespace == null)
+ throw new WSException("targetNamespace is null");
+ if (portName == null)
+ throw new WSException("portName is null");
+ if (seiName == null)
+ throw new WSException("seiName is null");
+ if (servletLink == null && ejbLink == null)
+ throw new WSException("Either servletLink or ejbLink should not be null");
+ if (servletLink != null && ejbLink != null)
+ throw new WSException("One of servletLink or ejbLink should be null");
+ }
+}
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/client/ServiceCreator.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -210,9 +210,12 @@
private void generateServiceFile(WSDLService wsdlService) throws IOException
{
String serviceName = wsdlService.getName().toString();
+ if (serviceName.endsWith("Service") == false);
+ serviceName = serviceName + "Service";
+
//Check if the serviceName conflicts with a portType or interface name
if(wsdl.getInterface(new NCName(serviceName)) != null )
- serviceName += "_Service";
+ serviceName = new StringBuilder(serviceName).insert(serviceName.lastIndexOf("Service"), '_').toString();
StringBuilder buf = new StringBuilder();
generateHeader(buf);
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/helpers/ToolsHelper.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -60,13 +60,13 @@
import org.jboss.ws.tools.JavaWriter;
import org.jboss.ws.tools.NamespacePackageMapping;
import org.jboss.ws.tools.WSDLToJava;
-import org.jboss.ws.tools.WSDotXMLCreator;
+import org.jboss.ws.tools.WebservicesXMLCreatorImpl;
import org.jboss.ws.tools.Configuration.GlobalConfig;
import org.jboss.ws.tools.Configuration.JavaToWSDLConfig;
import org.jboss.ws.tools.Configuration.WSDLToJavaConfig;
import org.jboss.ws.tools.XSDTypeToJava.VAR;
import org.jboss.ws.tools.client.ServiceCreator;
-import org.jboss.ws.tools.interfaces.WSDotXMLCreatorIntf;
+import org.jboss.ws.tools.interfaces.WebservicesXMLCreator;
import org.jboss.ws.tools.mapping.MappingFileGenerator;
import org.jboss.ws.tools.wsdl.WSDLWriter;
@@ -145,7 +145,7 @@
//Generate the webservices.xml file
if (j2wc.wsxmlFileNeeded)
{
- WSDotXMLCreatorIntf wscr = new WSDotXMLCreator();
+ WebservicesXMLCreator wscr = new WebservicesXMLCreatorImpl();
wscr.setTargetNamespace(j2wc.targetNamespace);
//wscr.setLocation(new File(outDir).toURL());
wscr.setSeiName(j2wc.endpointName);
@@ -336,7 +336,7 @@
seiName = seiPackage + "." + wsdlToJava.getServiceEndpointInterfaceName(wsdl.getInterfaces()[0]);
}
- WSDotXMLCreatorIntf wscr = new WSDotXMLCreator();
+ WebservicesXMLCreator wscr = new WebservicesXMLCreatorImpl();
wscr.setTargetNamespace(wsdl.getTargetNamespace());
wscr.setSeiName(seiName);
wscr.setServiceName(serviceName);
Deleted: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WSDotXMLCreatorIntf.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -1,88 +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.tools.interfaces;
-
-import java.io.File;
-import java.io.IOException;
-
-/**
- * Defines the contract for webservices.xml creating agents
- * @author <mailto:Anil.Saldhana@jboss.org>Anil Saldhana
- * @since Jul 23, 2005
- */
-
-public interface WSDotXMLCreatorIntf
-{
-
- /**
- * Generate the webservices.xml file
- * @throws IOException
- */
- public void generateWSXMLDescriptor(File file) throws IOException;
-
- /**
- * @param targetNamespace The targetNamespace to set.
- */
- public void setTargetNamespace(String targetNamespace);
-
- /**
- * @param seiName The seiName to set.
- */
- public void setSeiName(String seiName);
-
- /**
- * @param portName The portName to set.
- */
- public void setPortName(String portName);
-
- /**
- * @param serviceName The serviceName to set.
- */
- public void setServiceName(String serviceName);
-
- /**
- * @param ejbLink The ejbLink to set.
- */
- public void setEjbLink(String ejbLink);
-
- /**
- * @param servletLink The servletLink to set.
- */
- public void setServletLink(String servletLink);
-
- /**
- * @param mappingFileEntry The mapping file entry
- */
- public void setMappingFile(String mappingFileEntry);
-
- /**
- *
- * @param wsdlFileEntry The wsdl-file entry
- */
- public void setWsdlFile(String wsdlFileEntry);
-
- /**
- *
- * @param append add ws descriptions to existing webservices.xml file, if any
- */
- public void setAppend(boolean append);
-}
Added: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -0,0 +1,88 @@
+/*
+ * 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.tools.interfaces;
+
+import java.io.File;
+import java.io.IOException;
+
+/**
+ * Defines the contract for webservices.xml creating agents
+ * @author <mailto:Anil.Saldhana@jboss.org>Anil Saldhana
+ * @since Jul 23, 2005
+ */
+
+public interface WebservicesXMLCreator
+{
+
+ /**
+ * Generate the webservices.xml file
+ * @throws IOException
+ */
+ public void generateWSXMLDescriptor(File file) throws IOException;
+
+ /**
+ * @param targetNamespace The targetNamespace to set.
+ */
+ public void setTargetNamespace(String targetNamespace);
+
+ /**
+ * @param seiName The seiName to set.
+ */
+ public void setSeiName(String seiName);
+
+ /**
+ * @param portName The portName to set.
+ */
+ public void setPortName(String portName);
+
+ /**
+ * @param serviceName The serviceName to set.
+ */
+ public void setServiceName(String serviceName);
+
+ /**
+ * @param ejbLink The ejbLink to set.
+ */
+ public void setEjbLink(String ejbLink);
+
+ /**
+ * @param servletLink The servletLink to set.
+ */
+ public void setServletLink(String servletLink);
+
+ /**
+ * @param mappingFileEntry The mapping file entry
+ */
+ public void setMappingFile(String mappingFileEntry);
+
+ /**
+ *
+ * @param wsdlFileEntry The wsdl-file entry
+ */
+ public void setWsdlFile(String wsdlFileEntry);
+
+ /**
+ *
+ * @param append add ws descriptions to existing webservices.xml file, if any
+ */
+ public void setAppend(boolean append);
+}
Property changes on: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/tools/interfaces/WebservicesXMLCreator.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -0,0 +1,48 @@
+/*
+ * JBossWS WS-Tools Generated Source
+ *
+ * Generation Date: Fri Jan 12 10:48:13 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ */
+
+package org.jboss.test.ws.jaxrpc.jbws1384;
+
+
+public class InvokeAttachType
+{
+
+protected java.lang.String username;
+
+protected java.lang.String password;
+
+protected java.lang.String operationName;
+
+protected java.lang.String inputXML;
+public InvokeAttachType(){}
+
+public InvokeAttachType(java.lang.String username, java.lang.String password, java.lang.String operationName, java.lang.String inputXML){
+this.username=username;
+this.password=password;
+this.operationName=operationName;
+this.inputXML=inputXML;
+}
+public java.lang.String getUsername() { return username ;}
+
+public void setUsername(java.lang.String username){ this.username=username; }
+
+public java.lang.String getPassword() { return password ;}
+
+public void setPassword(java.lang.String password){ this.password=password; }
+
+public java.lang.String getOperationName() { return operationName ;}
+
+public void setOperationName(java.lang.String operationName){ this.operationName=operationName; }
+
+public java.lang.String getInputXML() { return inputXML ;}
+
+public void setInputXML(java.lang.String inputXML){ this.inputXML=inputXML; }
+
+}
Property changes on: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/InvokeAttachType.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -28,15 +28,18 @@
import javax.xml.rpc.Service;
import javax.xml.rpc.ServiceFactory;
import javax.xml.rpc.Stub;
+import javax.xml.soap.AttachmentPart;
import junit.framework.Test;
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.StubExt;
+import org.jboss.ws.tools.WSTools;
/**
- * Cannot obtain java/xml type mapping for attachment part
+ * Attachment parts with doclit message
*
* http://jira.jboss.org/jira/browse/JBWS-1384
*
@@ -55,7 +58,7 @@
protected void setUp() throws Exception
{
super.setUp();
- if (port == null && false)
+ if (port == null)
{
ServiceFactoryImpl factory = (ServiceFactoryImpl)ServiceFactory.newInstance();
URL wsdlURL = new File("resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl").toURL();
@@ -67,15 +70,21 @@
}
}
+ public void testWsdlToJava() throws Exception
+ {
+ WSTools wstools = new WSTools();
+ boolean ret = wstools.generate("resources/jaxrpc/jbws1384/wstools-config.xml", "./wstools/jbws1384");
+ assertTrue("wstools success", ret);
+ }
+
public void testEndpoint() throws Exception
{
- if (true)
- {
- System.out.println("FIXME: [JBWS-1384] - Cannot obtain java/xml type mapping for attachment part");
- return;
- }
+ StubExt stub = (StubExt)port;
+ AttachmentPart part = stub.createAttachmentPart();
+ part.setContent("attached-string", "text/plain");
+ stub.addAttachmentPart(part);
- String retStr = port.invokeAttach("user", "pass", "op", "<root/>", "attach");
- assertEquals("attach", retStr);
+ String retStr = port.invokeAttach("user", "pass", "op", "<root/>");
+ assertEquals("[user=user,pass=pass,op=op,xml=<root/>] attached-string", retStr);
}
}
Deleted: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ParaListType.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -1,56 +0,0 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
-package org.jboss.test.ws.jaxrpc.jbws1384;
-
-
-public class ParaListType {
- protected java.lang.String username;
- protected java.lang.String password;
- protected java.lang.String operationName;
- protected java.lang.String inputXML;
-
- public ParaListType() {
- }
-
- public ParaListType(java.lang.String username, java.lang.String password, java.lang.String operationName, java.lang.String inputXML) {
- this.username = username;
- this.password = password;
- this.operationName = operationName;
- this.inputXML = inputXML;
- }
-
- public java.lang.String getUsername() {
- return username;
- }
-
- public void setUsername(java.lang.String username) {
- this.username = username;
- }
-
- public java.lang.String getPassword() {
- return password;
- }
-
- public void setPassword(java.lang.String password) {
- this.password = password;
- }
-
- public java.lang.String getOperationName() {
- return operationName;
- }
-
- public void setOperationName(java.lang.String operationName) {
- this.operationName = operationName;
- }
-
- public java.lang.String getInputXML() {
- return inputXML;
- }
-
- public void setInputXML(java.lang.String inputXML) {
- this.inputXML = inputXML;
- }
-}
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/ResponseType.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -1,26 +1,27 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
+/*
+ * JBossWS WS-Tools Generated Source
+ *
+ * Generation Date: Fri Jan 12 10:48:13 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ */
package org.jboss.test.ws.jaxrpc.jbws1384;
-public class ResponseType {
- protected java.lang.String result;
-
- public ResponseType() {
- }
-
- public ResponseType(java.lang.String result) {
- this.result = result;
- }
-
- public java.lang.String getResult() {
- return result;
- }
-
- public void setResult(java.lang.String result) {
- this.result = result;
- }
+public class ResponseType
+{
+
+protected java.lang.String result;
+public ResponseType(){}
+
+public ResponseType(java.lang.String result){
+this.result=result;
}
+public java.lang.String getResult() { return result ;}
+
+public void setResult(java.lang.String result){ this.result=result; }
+
+}
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TranslatorBean.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -21,15 +21,48 @@
*/
package org.jboss.test.ws.jaxrpc.jbws1384;
+import javax.xml.rpc.ServiceException;
+import javax.xml.rpc.handler.soap.SOAPMessageContext;
+import javax.xml.rpc.server.ServiceLifecycle;
+import javax.xml.rpc.server.ServletEndpointContext;
+import javax.xml.soap.AttachmentPart;
+import javax.xml.soap.SOAPException;
+
import org.jboss.logging.Logger;
-public class TranslatorBean implements TransmulatorInterface
+public class TranslatorBean implements TransmulatorInterface, ServiceLifecycle
{
private Logger log = Logger.getLogger(TranslatorBean.class);
- public String invokeAttach(String username, String password, String operationName, String inputXML, String attachmentContents)
+ private ServletEndpointContext sepCtx;
+
+ public String invokeAttach(String username, String password, String operationName, String inputXML)
{
- log.info("[user=" + username + ",pass=" + password + ",op=" + operationName + ",xml=" + inputXML + ",attach=" + attachmentContents + "]");
- return attachmentContents;
+ String reqMessage = "[user=" + username + ",pass=" + password + ",op=" + operationName + ",xml=" + inputXML + "]";
+
+ // Get attached string
+ String attachedStr = null;
+ try
+ {
+ SOAPMessageContext msgContext = (SOAPMessageContext)sepCtx.getMessageContext();
+ AttachmentPart part = (AttachmentPart)msgContext.getMessage().getAttachments().next();
+ attachedStr = (String)part.getContent();
+ }
+ catch (SOAPException ex)
+ {
+ throw new RuntimeException(ex);
+ }
+
+ log.info(reqMessage + " " + attachedStr);
+ return reqMessage + " " + attachedStr;
}
+
+ public void init(Object context) throws ServiceException
+ {
+ this.sepCtx = (ServletEndpointContext)context;
+ }
+
+ public void destroy()
+ {
+ }
}
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/TransmulatorInterface.java 2007-01-12 11:17:14 UTC (rev 1938)
@@ -1,14 +1,15 @@
-// This class was generated by the JAXRPC SI, do not edit.
-// Contents subject to change without notice.
-// JAX-RPC Standard Implementation (1.1.3, build R1)
-// Generated source version: 1.1.3
-
+/*
+ * JBossWS WS-Tools Generated Source
+ *
+ * Generation Date: Fri Jan 12 10:48:13 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ */
package org.jboss.test.ws.jaxrpc.jbws1384;
+public interface TransmulatorInterface extends java.rmi.Remote
+{
-import java.rmi.Remote;
-import java.rmi.RemoteException;
-
-public interface TransmulatorInterface extends Remote
-{
- public String invokeAttach(String username, String password, String operationName, String inputXML, String attachmentContents) throws RemoteException;
+ public java.lang.String invokeAttach(java.lang.String username, java.lang.String password, java.lang.String operationName, java.lang.String inputXML) throws java.rmi.RemoteException;
}
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/jaxrpc-mapping.xml 2007-01-12 11:17:14 UTC (rev 1938)
@@ -1,110 +1,99 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1"
- xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
- <package-mapping>
- <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
- <namespaceURI>http://org.jboss.test.webservice/samples2</namespaceURI>
- </package-mapping>
- <package-mapping>
- <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
- <namespaceURI>http://org.jboss.test.webservice/samples2/types</namespaceURI>
- </package-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jaxrpc.jbws1384.ParaListType</java-type>
- <root-type-qname xmlns:typeNS="http://org.jboss.test.webservice/samples2/types">typeNS:paraListType</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>username</java-variable-name>
- <xml-element-name>username</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>password</java-variable-name>
- <xml-element-name>password</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>operationName</java-variable-name>
- <xml-element-name>operationName</xml-element-name>
- </variable-mapping>
- <variable-mapping>
- <java-variable-name>inputXML</java-variable-name>
- <xml-element-name>inputXML</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <java-xml-type-mapping>
- <java-type>org.jboss.test.ws.jaxrpc.jbws1384.ResponseType</java-type>
- <root-type-qname xmlns:typeNS="http://org.jboss.test.webservice/samples2/types">typeNS:responseType</root-type-qname>
- <qname-scope>complexType</qname-scope>
- <variable-mapping>
- <java-variable-name>result</java-variable-name>
- <xml-element-name>result</xml-element-name>
- </variable-mapping>
- </java-xml-type-mapping>
- <service-interface-mapping>
- <service-interface>org.jboss.test.ws.jaxrpc.jbws1384.Gasherbrum</service-interface>
- <wsdl-service-name xmlns:serviceNS="http://org.jboss.test.webservice/samples2">serviceNS:Gasherbrum</wsdl-service-name>
- <port-mapping>
- <port-name>TransmulatorInterfacePort</port-name>
- <java-port-name>TransmulatorInterfacePort</java-port-name>
- </port-mapping>
- </service-interface-mapping>
- <service-endpoint-interface-mapping>
- <service-endpoint-interface>org.jboss.test.ws.jaxrpc.jbws1384.TransmulatorInterface</service-endpoint-interface>
- <wsdl-port-type xmlns:portTypeNS="http://org.jboss.test.webservice/samples2">portTypeNS:TransmulatorInterface</wsdl-port-type>
- <wsdl-binding xmlns:bindingNS="http://org.jboss.test.webservice/samples2">bindingNS:TransmulatorInterfaceBinding</wsdl-binding>
- <service-endpoint-method-mapping>
- <java-method-name>invokeAttach</java-method-name>
- <wsdl-operation>invokeAttach</wsdl-operation>
- <wrapped-element/>
- <method-param-parts-mapping>
- <param-position>0</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>username</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>1</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>password</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>2</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>operationName</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>3</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>inputXML</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <method-param-parts-mapping>
- <param-position>4</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachRequest</wsdl-message>
- <wsdl-message-part-name>attachmentContents</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <wsdl-return-value-mapping>
- <method-return-value>java.lang.String</method-return-value>
- <wsdl-message xmlns:wsdlMsgNS="http://org.jboss.test.webservice/samples2">wsdlMsgNS:attachResponse</wsdl-message>
- <wsdl-message-part-name>result</wsdl-message-part-name>
- </wsdl-return-value-mapping>
- </service-endpoint-method-mapping>
- </service-endpoint-interface-mapping>
+<?xml version='1.0' encoding='UTF-8'?><java-wsdl-mapping version='1.1' xmlns='http://java.sun.com/xml/ns/j2ee' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd'>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
+ <namespaceURI>http://org.jboss.test.webservice/samples2/types</namespaceURI>
+ </package-mapping>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jaxrpc.jbws1384</package-type>
+ <namespaceURI>http://org.jboss.test.webservice/samples2</namespaceURI>
+ </package-mapping>
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jaxrpc.jbws1384.InvokeAttachType</java-type>
+ <root-type-qname xmlns:typeNS='http://org.jboss.test.webservice/samples2/types'>typeNS:invokeAttachType</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>username</java-variable-name>
+ <xml-element-name>username</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>password</java-variable-name>
+ <xml-element-name>password</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>operationName</java-variable-name>
+ <xml-element-name>operationName</xml-element-name>
+ </variable-mapping>
+ <variable-mapping>
+ <java-variable-name>inputXML</java-variable-name>
+ <xml-element-name>inputXML</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+ <java-xml-type-mapping>
+ <java-type>org.jboss.test.ws.jaxrpc.jbws1384.ResponseType</java-type>
+ <root-type-qname xmlns:typeNS='http://org.jboss.test.webservice/samples2/types'>typeNS:responseType</root-type-qname>
+ <qname-scope>complexType</qname-scope>
+ <variable-mapping>
+ <java-variable-name>result</java-variable-name>
+ <xml-element-name>result</xml-element-name>
+ </variable-mapping>
+ </java-xml-type-mapping>
+ <service-interface-mapping>
+ <service-interface>org.jboss.test.ws.jaxrpc.jbws1384.Gasherbrum</service-interface>
+ <wsdl-service-name xmlns:serviceNS='http://org.jboss.test.webservice/samples2'>serviceNS:Gasherbrum</wsdl-service-name>
+ <port-mapping>
+ <port-name>TransmulatorInterfacePort</port-name>
+ <java-port-name>TransmulatorInterfacePort</java-port-name>
+ </port-mapping>
+ </service-interface-mapping>
+ <service-endpoint-interface-mapping>
+ <service-endpoint-interface>org.jboss.test.ws.jaxrpc.jbws1384.TransmulatorInterface</service-endpoint-interface>
+ <wsdl-port-type xmlns:portTypeNS='http://org.jboss.test.webservice/samples2'>portTypeNS:TransmulatorInterface</wsdl-port-type>
+ <wsdl-binding xmlns:bindingNS='http://org.jboss.test.webservice/samples2'>bindingNS:TransmulatorInterfaceBinding</wsdl-binding>
+ <service-endpoint-method-mapping>
+ <java-method-name>invokeAttach</java-method-name>
+ <wsdl-operation>invokeAttach</wsdl-operation>
+ <wrapped-element/>
+ <method-param-parts-mapping>
+ <param-position>0</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>username</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>1</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>password</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>2</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>operationName</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <method-param-parts-mapping>
+ <param-position>3</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachRequest</wsdl-message>
+ <wsdl-message-part-name>inputXML</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <wsdl-return-value-mapping>
+ <method-return-value>java.lang.String</method-return-value>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.test.webservice/samples2'>wsdlMsgNS:attachResponse</wsdl-message>
+ <wsdl-message-part-name>result</wsdl-message-part-name>
+ </wsdl-return-value-mapping>
+ </service-endpoint-method-mapping>
+ </service-endpoint-interface-mapping>
</java-wsdl-mapping>
\ No newline at end of file
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/web.xml 2007-01-12 11:17:14 UTC (rev 1938)
@@ -4,12 +4,12 @@
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<servlet>
- <servlet-name>TestEndpoint</servlet-name>
+ <servlet-name>ExampleService</servlet-name>
<servlet-class>org.jboss.test.ws.jaxrpc.jbws1384.TranslatorBean</servlet-class>
</servlet>
<servlet-mapping>
- <servlet-name>TestEndpoint</servlet-name>
+ <servlet-name>ExampleService</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/webservices.xml 2007-01-12 11:17:14 UTC (rev 1938)
@@ -1,7 +1,7 @@
<webservices xmlns='http://java.sun.com/xml/ns/j2ee' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_web_services_1_1.xsd' version='1.1'>
<webservice-description>
- <webservice-description-name>ExampleService</webservice-description-name>
+ <webservice-description-name>Gasherbrum</webservice-description-name>
<wsdl-file>WEB-INF/wsdl/ExampleService.wsdl</wsdl-file>
<jaxrpc-mapping-file>WEB-INF/jaxrpc-mapping.xml</jaxrpc-mapping-file>
<port-component>
@@ -9,7 +9,7 @@
<wsdl-port xmlns:portNS='http://org.jboss.test.webservice/samples2'>portNS:TransmulatorInterfacePort</wsdl-port>
<service-endpoint-interface>org.jboss.test.ws.jaxrpc.jbws1384.TransmulatorInterface</service-endpoint-interface>
<service-impl-bean>
- <servlet-link>TestEndpoint</servlet-link>
+ <servlet-link>ExampleService</servlet-link>
</service-impl-bean>
</port-component>
</webservice-description>
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl 2007-01-12 11:17:14 UTC (rev 1938)
@@ -5,7 +5,7 @@
<schema targetNamespace="http://org.jboss.test.webservice/samples2/types" xmlns:tns="http://org.jboss.test.webservice/samples2/types"
xmlns:soap11-enc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns="http://www.w3.org/2001/XMLSchema">
- <complexType name="paraListType">
+ <complexType name="invokeAttachType">
<sequence>
<element name="username" type="string" nillable="true"/>
<element name="password" type="string" nillable="true"/>
@@ -18,12 +18,12 @@
<element name="result" type="string" nillable="true"/>
</sequence>
</complexType>
- <element name="paraList2" type="tns:paraListType"/>
+ <element name="invokeAttach" type="tns:invokeAttachType"/>
<element name="responseXML" type="tns:responseType"/>
</schema>
</types>
<message name="attachRequest">
- <part name="parameters" element="ns2:paraList2"/>
+ <part name="parameters" element="ns2:invokeAttach"/>
<part name="attachmentContents" type="xsd:string"/>
</message>
<message name="attachResponse">
Modified: branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml
===================================================================
--- branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml 2007-01-12 11:16:16 UTC (rev 1937)
+++ branches/tdiesler/trunk/jbossws-tests/src/main/resources/jaxrpc/jbws1384/wstools-config.xml 2007-01-12 11:17:14 UTC (rev 1938)
@@ -13,7 +13,7 @@
<package-namespace package="org.jboss.test.ws.jaxrpc.jbws1384" namespace="http://org.jboss.test.webservice/samples2"/>
</global>
- <wsdl-java location="./WEB-INF/wsdl/ExampleService.wsdl">
+ <wsdl-java location="resources/jaxrpc/jbws1384/WEB-INF/wsdl/ExampleService.wsdl">
<mapping file="jaxrpc-mapping.xml" />
<webservices servlet-link="ExampleService" />
</wsdl-java>
18 years
JBossWS SVN: r1937 - in trunk: jbossws-tests and 1 other directories.
by jbossws-commits@lists.jboss.org
Author: darran.lofthouse(a)jboss.com
Date: 2007-01-12 06:16:16 -0500 (Fri, 12 Jan 2007)
New Revision: 1937
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java
trunk/jbossws-tests/build.xml
trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1121/JBWS1121TestCase.java
Log:
JBWS-1328 - Fix loading of security resources when deployed as ear to jboss-5.0.x
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java 2007-01-12 06:19:37 UTC (rev 1936)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/metadata/wsse/WSSecurityConfigFactory.java 2007-01-12 11:16:16 UTC (rev 1937)
@@ -4,6 +4,7 @@
import org.jboss.ws.metadata.j2ee.UnifiedWebMetaData;
import java.io.IOException;
+import java.io.InputStream;
import java.net.URL;
/**
@@ -13,7 +14,8 @@
* Time: 16:17:02
* To change this template use File | Settings | File Templates.
*/
-public class WSSecurityConfigFactory {
+public class WSSecurityConfigFactory
+{
public static WSSecurityConfigFactory newInstance()
{
@@ -34,7 +36,8 @@
resource = "META-INF/" + resource;
}
- URL location = udi.classLoader.getResource(resource);
+ URL location = getResource(udi, resource);
+
if (location != null)
{
config = WSSecurityOMFactory.newInstance().parse(location);
@@ -42,14 +45,14 @@
// Get and set deployment path to the keystore file
if (config.getKeyStoreFile() != null)
{
- location = udi.classLoader.getResource(config.getKeyStoreFile());
+ location = getResource(udi, config.getKeyStoreFile());
if (location != null)
config.setKeyStoreURL(location);
}
if (config.getTrustStoreFile() != null)
{
- location = udi.classLoader.getResource(config.getTrustStoreFile());
+ location = getResource(udi, config.getTrustStoreFile());
if (location != null)
config.setTrustStoreURL(location);
}
@@ -58,4 +61,20 @@
return config;
}
+ private URL getResource(UnifiedDeploymentInfo udi, String resource)
+ {
+ try
+ {
+ URL url = udi.getMetaDataFileURL(resource);
+ InputStream inputStream = url.openStream();
+ inputStream.close();
+
+ return url;
+ }
+ catch (IOException e)
+ {
+ return null;
+ }
+ }
+
}
Modified: trunk/jbossws-tests/build.xml
===================================================================
--- trunk/jbossws-tests/build.xml 2007-01-12 06:19:37 UTC (rev 1936)
+++ trunk/jbossws-tests/build.xml 2007-01-12 11:16:16 UTC (rev 1937)
@@ -179,6 +179,7 @@
<pathelement location="${integration.jboss50.dir}/output/lib/jbossws-jboss50-integration.jar"/>
<pathelement location="${integration.jboss42.dir}/output/lib/jbossws-jboss42-integration.jar"/>
<pathelement location="${integration.tomcat.dir}/output/lib/jbossws-tomcat-integration.jar"/>
+ <pathelement location="${thirdparty.dir}/commons-logging.jar"/>
<pathelement location="${thirdparty.dir}/log4j.jar"/>
<path refid="javac.classpath"/>
</path>
Modified: trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1121/JBWS1121TestCase.java
===================================================================
--- trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1121/JBWS1121TestCase.java 2007-01-12 06:19:37 UTC (rev 1936)
+++ trunk/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1121/JBWS1121TestCase.java 2007-01-12 11:16:16 UTC (rev 1937)
@@ -50,7 +50,6 @@
return JBossWSTestSetup.newTestSetup(JBWS1121TestCase.class, "jaxrpc-jbws1121.ear");
}
- /*
public void setUp() throws Exception
{
super.setUp();
@@ -61,13 +60,9 @@
port = (HelloWorld)service.getPort(HelloWorld.class);
}
}
- */
public void testCall() throws Exception
{
- System.out.println("FIXME: [JBWS-1328] Client security configuration not loaded when client deployed with issolated classloader");
- if (true) return;
-
String response = port.echo("Hello");
assertEquals("Hello", response);
}
18 years