cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r730095 - /cxf/sandbox/dosgi/samples/greeter/client/src/main/java/org/apache/cxf/dosgi/samples/greeter/client/Activator.java
Date Tue, 30 Dec 2008 11:14:42 GMT
Author: sergeyb
Date: Tue Dec 30 03:14:41 2008
New Revision: 730095

URL: http://svn.apache.org/viewvc?rev=730095&view=rev
Log:
DOSGI : fixing compilation problem for greeter client

Modified:
    cxf/sandbox/dosgi/samples/greeter/client/src/main/java/org/apache/cxf/dosgi/samples/greeter/client/Activator.java

Modified: cxf/sandbox/dosgi/samples/greeter/client/src/main/java/org/apache/cxf/dosgi/samples/greeter/client/Activator.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/greeter/client/src/main/java/org/apache/cxf/dosgi/samples/greeter/client/Activator.java?rev=730095&r1=730094&r2=730095&view=diff
==============================================================================
--- cxf/sandbox/dosgi/samples/greeter/client/src/main/java/org/apache/cxf/dosgi/samples/greeter/client/Activator.java
(original)
+++ cxf/sandbox/dosgi/samples/greeter/client/src/main/java/org/apache/cxf/dosgi/samples/greeter/client/Activator.java
Tue Dec 30 03:14:41 2008
@@ -22,7 +22,7 @@
 
 import javax.swing.JOptionPane;
 
-
+import org.apache.cxf.dosgi.samples.greeter.GreeterException;
 import org.apache.cxf.dosgi.samples.greeter.GreeterService;
 import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
 import org.osgi.framework.BundleActivator;
@@ -70,12 +70,16 @@
                 break;
             } else {
                 System.out.println("*** Invoking greeter ***");
-                Map<GreetingPhrase, String> result = greeter.greetMe(name);
-
-                System.out.println("greetMe(\"" + name + "\") returns:");
-                for (Map.Entry<GreetingPhrase, String> greeting : result.entrySet())
{
-                    System.out.println("  " + greeting.getKey().getPhrase() 
-                            + " " + greeting.getValue());
+                try {
+                    Map<GreetingPhrase, String> result = greeter.greetMe(name);
+    
+                    System.out.println("greetMe(\"" + name + "\") returns:");
+                    for (Map.Entry<GreetingPhrase, String> greeting : result.entrySet())
{
+                        System.out.println("  " + greeting.getKey().getPhrase() 
+                                + " " + greeting.getValue());
+                    }
+                } catch (GreeterException ex) {
+                    System.out.println("GreeterException : " + ex.getMessage());
                 }
             }
         }



Mime
View raw message