openwebbeans-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gerdo...@apache.org
Subject svn commit: r932983 - /openwebbeans/trunk/samples/ejb-sample/src/main/java/org/apache/webbeans/sample/bean/EchoManaged.java
Date Sun, 11 Apr 2010 20:07:33 GMT
Author: gerdogdu
Date: Sun Apr 11 20:07:33 2010
New Revision: 932983

URL: http://svn.apache.org/viewvc?rev=932983&view=rev
Log:
[OWB-350] Support Interceptor for non-contextual EJBs

Modified:
    openwebbeans/trunk/samples/ejb-sample/src/main/java/org/apache/webbeans/sample/bean/EchoManaged.java

Modified: openwebbeans/trunk/samples/ejb-sample/src/main/java/org/apache/webbeans/sample/bean/EchoManaged.java
URL: http://svn.apache.org/viewvc/openwebbeans/trunk/samples/ejb-sample/src/main/java/org/apache/webbeans/sample/bean/EchoManaged.java?rev=932983&r1=932982&r2=932983&view=diff
==============================================================================
--- openwebbeans/trunk/samples/ejb-sample/src/main/java/org/apache/webbeans/sample/bean/EchoManaged.java
(original)
+++ openwebbeans/trunk/samples/ejb-sample/src/main/java/org/apache/webbeans/sample/bean/EchoManaged.java
Sun Apr 11 20:07:33 2010
@@ -13,6 +13,7 @@
  */
 package org.apache.webbeans.sample.bean;
 
+import javax.ejb.EJB;
 import javax.enterprise.context.RequestScoped;
 import javax.enterprise.inject.Default;
 import javax.inject.Inject;
@@ -32,7 +33,9 @@ import org.apache.webbeans.sample.inject
 public class EchoManaged
 {
     private @Inject @Default Echo echo;
-        
+    
+    private @EJB(name="EchoBean/org.apache.webbeans.sample.ejb.Echo") Echo nonContextual;
+    
     private String text;
     
     private String name;
@@ -57,7 +60,10 @@ public class EchoManaged
         
         System.out.println("EMF --> " + bean.getFactory().equals(this.emf));
         
+        //Call for contextual
         this.text = echo.echo(name);
+        //Call for noncontextual
+        this.nonContextual.echo(name);
         
         return null;
     }



Mime
View raw message