tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sl...@apache.org
Subject svn commit: r1041088 - /tuscany/sca-java-2.x/trunk/unreleased/samples/implementation-sample-async/src/test/java/sampleasync/impl/UpperSampleAsyncServiceImpl.java
Date Wed, 01 Dec 2010 17:15:58 GMT
Author: slaws
Date: Wed Dec  1 17:15:58 2010
New Revision: 1041088

URL: http://svn.apache.org/viewvc?rev=1041088&view=rev
Log:
Correct the implementation of the service to expect/produce elements

Modified:
    tuscany/sca-java-2.x/trunk/unreleased/samples/implementation-sample-async/src/test/java/sampleasync/impl/UpperSampleAsyncServiceImpl.java

Modified: tuscany/sca-java-2.x/trunk/unreleased/samples/implementation-sample-async/src/test/java/sampleasync/impl/UpperSampleAsyncServiceImpl.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/unreleased/samples/implementation-sample-async/src/test/java/sampleasync/impl/UpperSampleAsyncServiceImpl.java?rev=1041088&r1=1041087&r2=1041088&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/unreleased/samples/implementation-sample-async/src/test/java/sampleasync/impl/UpperSampleAsyncServiceImpl.java
(original)
+++ tuscany/sca-java-2.x/trunk/unreleased/samples/implementation-sample-async/src/test/java/sampleasync/impl/UpperSampleAsyncServiceImpl.java
Wed Dec  1 17:15:58 2010
@@ -20,6 +20,11 @@
 package sampleasync.impl;
 
 import static java.lang.System.out;
+import static sample.Xutil.elem;
+import static sample.Xutil.text;
+import static sample.Xutil.xdom;
+
+import org.w3c.dom.Element;
 
 import sample.api.WSDL;
 
@@ -31,8 +36,10 @@ import sample.api.WSDL;
 @WSDL("http://sample/upper#Upper")
 public class UpperSampleAsyncServiceImpl {
 
-    public String upper(String s) {
-        out.println("UpperSampleAsyncServiceImpl.upper(" + s + ")");
-        return s.toUpperCase();
+    public Element call(String op, Element e) {
+        String input = e.getTextContent();
+        out.println("UpperSampleAsyncServiceImpl.upper(" + input + ")");
+        String output = input.toUpperCase();
+        return xdom("http://sample/upper", "upperResponse", elem("result", text(output)));
     }
 }



Mime
View raw message