tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From antel...@apache.org
Subject svn commit: r1213625 - /tuscany/sca-java-2.x/trunk/testing/itest/dynamicRefURI/src/main/java/org/apache/tuscany/sca/itest/HelloworldClient.java
Date Tue, 13 Dec 2011 09:24:11 GMT
Author: antelder
Date: Tue Dec 13 09:24:11 2011
New Revision: 1213625

URL: http://svn.apache.org/viewvc?rev=1213625&view=rev
Log:
Update to use the new Tuscany ComponentContext and ServiceReference interfaces

Modified:
    tuscany/sca-java-2.x/trunk/testing/itest/dynamicRefURI/src/main/java/org/apache/tuscany/sca/itest/HelloworldClient.java

Modified: tuscany/sca-java-2.x/trunk/testing/itest/dynamicRefURI/src/main/java/org/apache/tuscany/sca/itest/HelloworldClient.java
URL: http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/testing/itest/dynamicRefURI/src/main/java/org/apache/tuscany/sca/itest/HelloworldClient.java?rev=1213625&r1=1213624&r2=1213625&view=diff
==============================================================================
--- tuscany/sca-java-2.x/trunk/testing/itest/dynamicRefURI/src/main/java/org/apache/tuscany/sca/itest/HelloworldClient.java
(original)
+++ tuscany/sca-java-2.x/trunk/testing/itest/dynamicRefURI/src/main/java/org/apache/tuscany/sca/itest/HelloworldClient.java
Tue Dec 13 09:24:11 2011
@@ -21,7 +21,6 @@ package org.apache.tuscany.sca.itest;
 
 import org.apache.tuscany.sca.runtime.TuscanyComponentContext;
 import org.apache.tuscany.sca.runtime.TuscanyServiceReference;
-import org.oasisopen.sca.ComponentContext;
 import org.oasisopen.sca.annotation.Context;
 import org.oasisopen.sca.annotation.Reference;
 
@@ -31,22 +30,14 @@ public class HelloworldClient implements
     public Helloworld helloworldService;
     
     @Context
-    public ComponentContext componentContext;
-    
-    @Context
     public TuscanyComponentContext tuscanyComponentContext;
 
     @Override
     public String sayHello(String name) {
 
-//        ServiceReference<Helloworld> sr = componentContext.getServiceReference(Helloworld.class,
"helloworldService");
-//        ((ServiceReferenceImpl)sr).setBindingURI("http://localhost:8080/HelloworldService/Helloworld");
-
         TuscanyServiceReference<Helloworld> tsr = tuscanyComponentContext.getServiceReference(Helloworld.class,
"helloworldService");
-//        TuscanyServiceReference<Helloworld> tsr = (TuscanyServiceReference<Helloworld>)componentContext.getServiceReference(Helloworld.class,
"helloworldService");
         tsr.setBindingURI("http://localhost:8080/HelloworldService/Helloworld");
 
-        
         return "client: " + tsr.getService().sayHello(name);
     }
 }



Mime
View raw message