Author: thomas.diesler(a)jboss.com
Date: 2007-04-10 11:56:19 -0400 (Tue, 10 Apr 2007)
New Revision: 2784
Modified:
trunk/jbossws-tests/src/java/org/jboss/test/ws/jaxrpc/samples/handler/ClientSideHandler.java
Log:
Layout code
Modified:
trunk/jbossws-tests/src/java/org/jboss/test/ws/jaxrpc/samples/handler/ClientSideHandler.java
===================================================================
---
trunk/jbossws-tests/src/java/org/jboss/test/ws/jaxrpc/samples/handler/ClientSideHandler.java 2007-04-10
15:55:26 UTC (rev 2783)
+++
trunk/jbossws-tests/src/java/org/jboss/test/ws/jaxrpc/samples/handler/ClientSideHandler.java 2007-04-10
15:56:19 UTC (rev 2784)
@@ -21,17 +21,12 @@
*/
package org.jboss.test.ws.jaxrpc.samples.handler;
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-
import javax.xml.namespace.QName;
import javax.xml.rpc.JAXRPCException;
import javax.xml.rpc.handler.GenericHandler;
import javax.xml.rpc.handler.HandlerInfo;
import javax.xml.rpc.handler.MessageContext;
import javax.xml.rpc.handler.soap.SOAPMessageContext;
-import javax.xml.soap.MimeHeader;
import javax.xml.soap.MimeHeaders;
import javax.xml.soap.SOAPBody;
import javax.xml.soap.SOAPBodyElement;
@@ -67,9 +62,9 @@
QName[] headers = getHeaders();
if (headers == null || headers.length != 3)
throw new IllegalStateException("Invalid number of headers");
-
+
try
- {
+ {
SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
SOAPHeader soapHeader = soapMessage.getSOAPHeader();
@@ -79,7 +74,7 @@
MimeHeaders mimeHeaders = soapMessage.getMimeHeaders();
mimeHeaders.setHeader("Cookie", "client-cookie=true");
-
+
// testInHeader
if (rpcName.equals("testInHeader"))
{
@@ -111,7 +106,7 @@
}
catch (SOAPException e)
{
- throw new JAXRPCException(e);
+ throw new JAXRPCException(e);
}
return true;
@@ -123,7 +118,7 @@
SOAPMessage soapMessage = ((SOAPMessageContext)msgContext).getMessage();
MimeHeaders mimeHeaders = soapMessage.getMimeHeaders();
-
+
String[] cookies = mimeHeaders.getHeader("Set-Cookie");
if (cookies == null || cookies.length != 1 ||
!cookies[0].equals("server-cookie=true"))
throw new IllegalStateException("Unexpected cookie list: " +
mimeHeaders);