[jboss-cvs] jboss-seam/src/main/org/jboss/seam/intercept ...
Gavin King
gavin.king at jboss.com
Sun Feb 25 14:06:23 EST 2007
User: gavin
Date: 07/02/25 14:06:23
Modified: src/main/org/jboss/seam/intercept
SessionBeanInterceptor.java
Log:
EL in EJB-QL :-)
Revision Changes Path
1.12 +9 -0 jboss-seam/src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: SessionBeanInterceptor.java
===================================================================
RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- SessionBeanInterceptor.java 21 Dec 2006 02:38:27 -0000 1.11
+++ SessionBeanInterceptor.java 25 Feb 2007 19:06:23 -0000 1.12
@@ -12,12 +12,15 @@
import javax.ejb.PrePassivate;
import javax.interceptor.AroundInvoke;
import javax.interceptor.InvocationContext;
+import javax.persistence.EntityManager;
import org.jboss.seam.log.LogProvider;
import org.jboss.seam.log.Logging;
+import org.jboss.seam.persistence.EntityManagerProxy;
import org.jboss.seam.Component;
import org.jboss.seam.InterceptorType;
import org.jboss.seam.Seam;
+import org.jboss.seam.Component.BijectedAttribute;
import org.jboss.seam.annotations.Name;
/**
@@ -110,6 +113,12 @@
initNonSeamComponent();
}
+ //wrap any @PersistenceContext attributes in our proxy
+ for ( BijectedAttribute ba: invokingComponent.getPersistenceContextAttributes() )
+ {
+ ba.set( bean, new EntityManagerProxy( (EntityManager) ba.get(bean) ) );
+ }
+
postConstruct(bean);
invokeAndHandle( new EJBInvocationContext(invocation), EventType.POST_CONSTRUCT );
}
More information about the jboss-cvs-commits
mailing list