Author: slaws
Date: Tue Aug 21 06:38:33 2007
New Revision: 568124

URL: http://svn.apache.org/viewvc?rev=568124&view=rev
Log:
Add some detail to the unit tests

Added:
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldClient.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceLocal.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote2.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientLocalImpl.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemote2Impl.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemoteImpl.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceLocalImpl.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceMultipleServicesImpl.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceRemoteImpl.java
Removed:
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorld.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldRemote.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClient.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldService.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceRemote.java
Modified:
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/BaseTest.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/SimpleTestCase.java
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeA/HelloWorld.composite
    
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeB/HelloWorld.composite

Modified: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/BaseTest.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/BaseTest.java?rev=568124&r1=568123&r2=568124&view=diff
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/BaseTest.java
 (original)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/BaseTest.java
 Tue Aug 21 06:38:33 2007
@@ -21,7 +21,7 @@
 import java.net.URL;
 
 import org.apache.tuscany.sca.assembly.Composite;
-import org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorld;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceLocal;
 import org.apache.tuscany.sca.contribution.Contribution;
 import org.apache.tuscany.sca.contribution.service.ContributionService;
 import org.apache.tuscany.sca.distributed.domain.DistributedSCADomain;
@@ -37,8 +37,6 @@
     public static DistributedSCADomain distributedDomainB;
     public static EmbeddedSCADomain domainA;
     public static EmbeddedSCADomain domainB;
-    public static HelloWorld helloWorldClientA;
-    public static HelloWorld helloWorldClientB;
 
     @BeforeClass
     public static void init() throws Exception {
@@ -122,12 +120,7 @@
             System.err.println("Exception when creating domain " + 
ex.getMessage());
             ex.printStackTrace(System.err);
             throw ex;
-        }
-
-        // get a reference to the calculator service from domainA
-        // which will be running this component
-        helloWorldClientA = domainA.getService(HelloWorld.class, 
"HelloWorldClientRemote");
-        helloWorldClientB = domainB.getService(HelloWorld.class, 
"HelloWorldClientLocal");       
+        }     
 
     }
 

Modified: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/SimpleTestCase.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/SimpleTestCase.java?rev=568124&r1=568123&r2=568124&view=diff
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/SimpleTestCase.java
 (original)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/SimpleTestCase.java
 Tue Aug 21 06:38:33 2007
@@ -20,23 +20,44 @@
 
 import junit.framework.Assert;
 
+import org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldClient;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceLocal;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote;
 import org.junit.Test;
 
 public class SimpleTestCase extends BaseTest {
     
     @Test
-    public void testHelloWorldRemote() throws Exception {    
-        
-        //System.out.println(helloWorldClientA.getGreetings("fred"));
-        
+    public void testHelloWorldLocal() throws Exception {  
+        HelloWorldClient helloWorldClientA = 
domainA.getService(HelloWorldClient.class, "AHelloWorldClientLocal");
         Assert.assertEquals(helloWorldClientA.getGreetings("fred"), "Hello 
fred");
         
     }
     
     @Test
-    public void testHelloWorldLocalAndRemote() throws Exception {    
-                
+    public void testHelloWorldRemote() throws Exception {  
+        HelloWorldClient helloWorldClientA;
+        helloWorldClientA = domainA.getService(HelloWorldClient.class, 
"AHelloWorldClientRemote");
+        Assert.assertEquals(helloWorldClientA.getGreetings("fred"), "Hello 
fred");
+        
+    }    
+    
+    @Test
+    public void testHelloWorldLocalAndRemote() throws Exception {
+        HelloWorldClient helloWorldClientA = 
domainA.getService(HelloWorldClient.class, "AHelloWorldClientLocalAndRemote"); 
+        HelloWorldClient helloWorldClientB = 
domainB.getService(HelloWorldClient.class, "BHelloWorldClientLocalAndRemote"); 
+        Assert.assertEquals(helloWorldClientA.getGreetings("fred"), "Hello 
fred");
+        Assert.assertEquals(helloWorldClientB.getGreetings("fred"), "Hello 
fred");
+    }   
+    
+    @Test
+    public void testHelloWorldMultipleServices() throws Exception {
+        HelloWorldClient helloWorldClientA = 
domainA.getService(HelloWorldClient.class, 
"AHelloWorldClientMultipleServices"); 
+        HelloWorldClient helloWorldClientA2 = 
domainA.getService(HelloWorldClient.class, 
"AHelloWorldClientMultipleServices2");
+        HelloWorldClient helloWorldClientB = 
domainB.getService(HelloWorldClient.class, 
"BHelloWorldClientMultipleServices");        
         Assert.assertEquals(helloWorldClientA.getGreetings("fred"), "Hello 
fred");
+        Assert.assertEquals(helloWorldClientA2.getGreetings("fred"), "Hello 
fred");
+        Assert.assertEquals(helloWorldClientB.getGreetings("fred"), "Hello 
fred");
     }    
   
 }

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldClient.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldClient.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldClient.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldClient.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld;
+
+
+public interface HelloWorldClient {
+    
+    public String getGreetings(String s);
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceLocal.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceLocal.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceLocal.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceLocal.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld;
+
+
+public interface HelloWorldServiceLocal {
+    
+    public String getGreetingsLocal(String s);
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld;
+
+import org.osoa.sca.annotations.Remotable;
+
[EMAIL PROTECTED]
+public interface HelloWorldServiceRemote {
+    
+    public String getGreetingsRemote(String s);
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote2.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote2.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote2.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/HelloWorldServiceRemote2.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld;
+
+import org.osoa.sca.annotations.Remotable;
+
[EMAIL PROTECTED]
+public interface HelloWorldServiceRemote2 {
+    
+    public String getGreetingsRemote2(String s);
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientLocalImpl.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientLocalImpl.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientLocalImpl.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientLocalImpl.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,36 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl;
+
+import org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldClient;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceLocal;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote;
+import org.osoa.sca.annotations.Reference;
+
+public class HelloWorldClientLocalImpl implements HelloWorldClient {
+
+    @Reference
+    public HelloWorldServiceLocal helloWorldService;
+    
+    public String getGreetings(String s) {
+        return helloWorldService.getGreetingsLocal(s);
+    }
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemote2Impl.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemote2Impl.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemote2Impl.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemote2Impl.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,37 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl;
+
+import org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldClient;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceLocal;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote2;
+import org.osoa.sca.annotations.Reference;
+
+public class HelloWorldClientRemote2Impl implements HelloWorldClient {
+
+    @Reference
+    public HelloWorldServiceRemote2 helloWorldService;
+    
+    public String getGreetings(String s) {
+        return helloWorldService.getGreetingsRemote2(s);
+    }
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemoteImpl.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemoteImpl.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemoteImpl.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldClientRemoteImpl.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,36 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl;
+
+import org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldClient;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceLocal;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote;
+import org.osoa.sca.annotations.Reference;
+
+public class HelloWorldClientRemoteImpl implements HelloWorldClient {
+
+    @Reference
+    public HelloWorldServiceRemote helloWorldService;
+    
+    public String getGreetings(String s) {
+        return helloWorldService.getGreetingsRemote(s);
+    }
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceLocalImpl.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceLocalImpl.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceLocalImpl.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceLocalImpl.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl;
+
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceLocal;
+
+public class HelloWorldServiceLocalImpl implements HelloWorldServiceLocal {
+
+    public String getGreetingsLocal(String s) {
+        return "Hello " + s;
+    }
+
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceMultipleServicesImpl.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceMultipleServicesImpl.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceMultipleServicesImpl.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceMultipleServicesImpl.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl;
+
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceLocal;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote;
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote2;
+import org.osoa.sca.annotations.Service;
+
[EMAIL PROTECTED](interfaces={HelloWorldServiceRemote.class, 
HelloWorldServiceRemote2.class, HelloWorldServiceLocal.class} )
+public class HelloWorldServiceMultipleServicesImpl implements 
HelloWorldServiceLocal, HelloWorldServiceRemote, HelloWorldServiceRemote2  {
+
+    public String getGreetingsLocal(String s) {
+        return "Hello " + s;
+    }
+    
+    public String getGreetingsRemote(String s) {
+        return "Hello " + s;
+    }    
+
+    public String getGreetingsRemote2(String s) {
+        return "Hello " + s;
+    } 
+}

Added: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceRemoteImpl.java
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceRemoteImpl.java?rev=568124&view=auto
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceRemoteImpl.java
 (added)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/java/org/apache/tuscany/sca/binding/sca/axis2/helloworld/impl/HelloWorldServiceRemoteImpl.java
 Tue Aug 21 06:38:33 2007
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.    
+ */
+
+package org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl;
+
+import 
org.apache.tuscany.sca.binding.sca.axis2.helloworld.HelloWorldServiceRemote;
+
+public class HelloWorldServiceRemoteImpl implements HelloWorldServiceRemote {
+
+    public String getGreetingsRemote(String s) {
+        return "Hello " + s;
+    }
+
+}

Modified: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeA/HelloWorld.composite
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeA/HelloWorld.composite?rev=568124&r1=568123&r2=568124&view=diff
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeA/HelloWorld.composite
 (original)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeA/HelloWorld.composite
 Tue Aug 21 06:38:33 2007
@@ -22,9 +22,38 @@
            xmlns:sample="http://sample";
            name="HelloWorld">
 
-    <component name="HelloWorldClientRemote">
-               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClient"
 />
-        <reference name="helloWorldService" target="HelloWorldServiceRemote" />
+    <!-- local only wire -->
+    <component name="AHelloWorldClientLocal">
+               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClientLocalImpl"
 />
+        <reference name="helloWorldService" target="AHelloWorldServiceLocal" />
     </component>
+    
+    <component name="AHelloWorldServiceLocal">
+        <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldServiceLocalImpl"
 />
+    </component> 
+    
+    <!-- unresolved remote wire -->   
+    <component name="AHelloWorldClientRemote">
+               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClientRemoteImpl"
 />
+        <reference name="helloWorldService" target="BHelloWorldServiceRemote" 
/>
+    </component>
+    
+    <!-- local and remote wires -->    
+    <component name="AHelloWorldClientLocalAndRemote">
+               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClientRemoteImpl"
 />
+        <reference name="helloWorldService" 
target="BHelloWorldServiceLocalAndRemote" />
+    </component>  
+    
+    <!-- multiple services -->
+    <component name="AHelloWorldClientMultipleServices">
+               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClientRemoteImpl"
 />
+        <reference name="helloWorldService" 
target="BHelloWorldServiceMultipleServices/HelloWorldServiceRemote" />
+    </component>  
+    
+    <component name="AHelloWorldClientMultipleServices2">
+               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClientRemote2Impl"
 />
+        <reference name="helloWorldService" 
target="BHelloWorldServiceMultipleServices/HelloWorldServiceRemote2" />
+    </component> 
+    
 
 </composite>

Modified: 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeB/HelloWorld.composite
URL: 
http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeB/HelloWorld.composite?rev=568124&r1=568123&r2=568124&view=diff
==============================================================================
--- 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeB/HelloWorld.composite
 (original)
+++ 
incubator/tuscany/java/sca/modules/binding-sca-axis2/src/test/resources/nodeB/HelloWorld.composite
 Tue Aug 21 06:38:33 2007
@@ -22,17 +22,33 @@
            xmlns:sample="http://sample";
            name="HelloWorld">
            
-    <component name="HelloWorldServiceLocal">
-        <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldService"
 />
+
+    <!-- local only wire -->
+     
+     
+    <!-- unresolved remote wire --> 
+    <component name="BHelloWorldServiceRemote">
+        <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldServiceRemoteImpl"
 />
     </component>
-               
-    <component name="HelloWorldServiceRemote">
-        <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldServiceRemote"
 />
+    
+    <!-- local and remote wires -->
+    <component name="BHelloWorldServiceLocalAndRemote">
+        <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldServiceRemoteImpl"
 />
+    </component>
+    
+    <component name="BHelloWorldClientLocalAndRemote">
+               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClientRemoteImpl"
 />
+        <reference name="helloWorldService" 
target="BHelloWorldServiceLocalAndRemote" />
+    </component>
+    
+    <!-- multiple services -->
+    <component name="BHelloWorldServiceMultipleServices">
+        <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldServiceMultipleServicesImpl"
 />
     </component>
     
-    <component name="HelloWorldClientLocal">
-               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClient"
 />
-        <reference name="helloWorldService" target="HelloWorldService" />
+    <component name="BHelloWorldClientMultipleServices">
+               <implementation.java 
class="org.apache.tuscany.sca.binding.sca.axis2.helloworld.impl.HelloWorldClientLocalImpl"
 />
+        <reference name="helloWorldService" 
target="BHelloWorldServiceMultipleServices/HelloWorldServiceLocal" />
     </component>
     
 </composite>



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to