openwebbeans-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gerdo...@apache.org
Subject svn commit: r907113 - /openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/context/creational/CreationalContextImpl.java
Date Fri, 05 Feb 2010 22:09:36 GMT
Author: gerdogdu
Date: Fri Feb  5 22:09:35 2010
New Revision: 907113

URL: http://svn.apache.org/viewvc?rev=907113&view=rev
Log:
[OWB-6] Update creational context on passiavation capable

Modified:
    openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/context/creational/CreationalContextImpl.java

Modified: openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/context/creational/CreationalContextImpl.java
URL: http://svn.apache.org/viewvc/openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/context/creational/CreationalContextImpl.java?rev=907113&r1=907112&r2=907113&view=diff
==============================================================================
--- openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/context/creational/CreationalContextImpl.java
(original)
+++ openwebbeans/trunk/webbeans-impl/src/main/java/org/apache/webbeans/context/creational/CreationalContextImpl.java
Fri Feb  5 22:09:35 2010
@@ -21,10 +21,10 @@
 
 import javax.enterprise.context.spi.Contextual;
 import javax.enterprise.context.spi.CreationalContext;
-import javax.enterprise.inject.spi.PassivationCapable;
 
 import org.apache.webbeans.container.BeanManagerImpl;
 import org.apache.webbeans.util.Asserts;
+import org.apache.webbeans.util.WebBeansUtil;
 
 /** {@inheritDoc} */
 public class CreationalContextImpl<T> implements CreationalContext<T>, Serializable
@@ -219,9 +219,10 @@
                 = new HashMap<Object, DependentCreationalContext<?>>(dependentObjects);
         s.writeObject(depo);
 
-        if (contextual != null && contextual instanceof PassivationCapable)
+        String id = null;
+        if (contextual != null && (id = WebBeansUtil.isPassivationCapable(contextual))
!= null)
         {
-            s.writeObject(((PassivationCapable)contextual).getId());
+            s.writeObject(id);
         }
         else
         {



Mime
View raw message