Author: jason.greene(a)jboss.com
Date: 2006-10-11 17:37:48 -0400 (Wed, 11 Oct 2006)
New Revision: 1213
Modified:
trunk/src/main/java/org/jboss/ws/tools/jaxws/JAXBWSDLGenerator.java
trunk/src/test/ant/build-jars-jaxws.xml
trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpoint.java
trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpointImpl.java
Log:
Fix jbws-871 test case.
Work around JAXB bug JBWS-1295
Modified: trunk/src/main/java/org/jboss/ws/tools/jaxws/JAXBWSDLGenerator.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/tools/jaxws/JAXBWSDLGenerator.java 2006-10-11
20:28:55 UTC (rev 1212)
+++ trunk/src/main/java/org/jboss/ws/tools/jaxws/JAXBWSDLGenerator.java 2006-10-11
21:37:48 UTC (rev 1213)
@@ -69,6 +69,10 @@
@Override
public Result createOutput(String namespace, String file) throws IOException
{
+ // JBWS-1295, getKnownNamespaceURIs is not accurate
+ if (namespace.length() > 0 && wsdl.getPrefix(namespace) ==
null)
+ wsdl.registerNamespaceURI(namespace, null);
+
// JAXB creates an empty namespace due to type references, ignore it
DOMResult result = new DOMResult((namespace == null || namespace.length()
== 0) ? throwAway : element);
result.setSystemId("replace-me");
Modified: trunk/src/test/ant/build-jars-jaxws.xml
===================================================================
--- trunk/src/test/ant/build-jars-jaxws.xml 2006-10-11 20:28:55 UTC (rev 1212)
+++ trunk/src/test/ant/build-jars-jaxws.xml 2006-10-11 21:37:48 UTC (rev 1213)
@@ -79,6 +79,7 @@
<!-- jaxws-jbws871 -->
<war warfile="${build.test.dir}/libs/jaxws-jbws871-rpc.war"
webxml="${build.test.dir}/resources/jaxws/jbws871/WEB-INF-rpc/web.xml">
<classes dir="${build.test.dir}/classes">
+ <include
name="org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpoint.class"/>
<include
name="org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpointImpl.class"/>
</classes>
</war>
Modified: trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpoint.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpoint.java 2006-10-11
20:28:55 UTC (rev 1212)
+++ trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpoint.java 2006-10-11
21:37:48 UTC (rev 1213)
@@ -8,8 +8,14 @@
* terms of use that apply to this source code.
*/
package org.jboss.test.ws.jaxws.jbws871;
+
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+import javax.jws.soap.SOAPBinding.Style;
+
+@SOAPBinding(style = Style.RPC)
+@WebService(name = "RpcArrayEndpoint")
public interface RpcArrayEndpoint extends java.rmi.Remote
{
-
public java.lang.Integer[] intArr(java.lang.String string_1,java.lang.Integer[]
integer_1) throws java.rmi.RemoteException;
}
Modified: trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpointImpl.java
===================================================================
---
trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpointImpl.java 2006-10-11
20:28:55 UTC (rev 1212)
+++
trunk/src/test/java/org/jboss/test/ws/jaxws/jbws871/RpcArrayEndpointImpl.java 2006-10-11
21:37:48 UTC (rev 1213)
@@ -31,14 +31,12 @@
import org.jboss.logging.Logger;
import org.jboss.ws.WSException;
-@SOAPBinding(style = Style.RPC)
-@WebService(name = "RpcArrayEndpoint")
+(a)WebService(endpointInterface="org.jboss.test.ws.jaxws.jbws871.RpcArrayEndpoint")
public class RpcArrayEndpointImpl
{
// Provide logging
private static Logger log = Logger.getLogger(RpcArrayEndpointImpl.class);
- @WebMethod
public Integer[] intArr(String type, Integer arr[])
{
log.info("intArr: " + type + "," + ((arr == null) ?
"null" : Arrays.asList(arr)));
@@ -79,7 +77,6 @@
return arr;
}
- //@WebMethod
public Integer[][] intMultiArr(Integer arr[][])
{
log.info("intMultiArr: " + arr);