geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vamsic...@apache.org
Subject svn commit: r719261 - in /geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main: java/sample/HelloworldImpl.java resources/META-INF/sca-deployables/Helloworld.composite
Date Thu, 20 Nov 2008 15:52:37 GMT
Author: vamsic007
Date: Thu Nov 20 07:52:37 2008
New Revision: 719261

URL: http://svn.apache.org/viewvc?rev=719261&view=rev
Log:
Changed the impl a little bit and added two more components to the composite.

Modified:
    geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/java/sample/HelloworldImpl.java
    geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/resources/META-INF/sca-deployables/Helloworld.composite

Modified: geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/java/sample/HelloworldImpl.java
URL: http://svn.apache.org/viewvc/geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/java/sample/HelloworldImpl.java?rev=719261&r1=719260&r2=719261&view=diff
==============================================================================
--- geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/java/sample/HelloworldImpl.java
(original)
+++ geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/java/sample/HelloworldImpl.java
Thu Nov 20 07:52:37 2008
@@ -19,11 +19,18 @@
 
 package sample;
 
-public class HelloworldImpl implements Helloworld {
+import org.osoa.sca.annotations.ComponentName;
 
+public class HelloworldImpl implements Helloworld {
+    
+    protected String greetingPrefix = "Hello";
+    
+    @ComponentName
+    protected String componentName;
+    
     public String sayHello(String name) {
-        System.out.println("HelloworldImpl.sayHello: " + name);
-        return "Hello " + name;
+        System.out.println(componentName+": HelloworldImpl.sayHello: " + name);
+        return greetingPrefix + " " + name;
     }
 
 }

Modified: geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/resources/META-INF/sca-deployables/Helloworld.composite
URL: http://svn.apache.org/viewvc/geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/resources/META-INF/sca-deployables/Helloworld.composite?rev=719261&r1=719260&r2=719261&view=diff
==============================================================================
--- geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/resources/META-INF/sca-deployables/Helloworld.composite
(original)
+++ geronimo/plugins/tuscany/trunk/samples/helloworld-service/src/main/resources/META-INF/sca-deployables/Helloworld.composite
Thu Nov 20 07:52:37 2008
@@ -25,4 +25,13 @@
         <implementation.java class="sample.HelloworldImpl"/>
     </component>
 
+    <component name="HelloworldTeluguComponent">
+        <implementation.java class="sample.HelloworldImpl"/>
+        <property name="greetingPrefix">Namaskaaram</property>
+    </component>
+
+    <component name="HelloworldFrenchComponent">
+        <implementation.java class="sample.HelloworldImpl"/>
+        <property name="greetingPrefix">Bonjour</property>
+    </component>
 </composite>



Mime
View raw message