[seam-commits] Seam SVN: r9249 - trunk/src/main/org/jboss/seam.

seam-commits at lists.jboss.org seam-commits at lists.jboss.org
Fri Oct 10 03:23:48 EDT 2008


Author: dan.j.allen
Date: 2008-10-10 03:23:48 -0400 (Fri, 10 Oct 2008)
New Revision: 9249

Modified:
   trunk/src/main/org/jboss/seam/Component.java
Log:
rename getTopInitialValue() to getInitialValueHonoringExceptions() so it is clear what the method does
explain the reason why we ignore expressions on org.jboss.seam.core.init


Modified: trunk/src/main/org/jboss/seam/Component.java
===================================================================
--- trunk/src/main/org/jboss/seam/Component.java	2008-10-09 20:28:51 UTC (rev 9248)
+++ trunk/src/main/org/jboss/seam/Component.java	2008-10-10 07:23:48 UTC (rev 9249)
@@ -474,7 +474,7 @@
                if ( !setterMethod.isAccessible() ) setterMethod.setAccessible(true);
                Class parameterClass = setterMethod.getParameterTypes()[0];
                Type parameterType = setterMethod.getGenericParameterTypes()[0];
-               initializerSetters.put( setterMethod, getTopInitialValue(propertyValue, parameterClass, parameterType) );
+               initializerSetters.put( setterMethod, getInitialValueHonoringExceptions(propertyName, propertyValue, parameterClass, parameterType) );
             }
             else
             {
@@ -487,10 +487,11 @@
       }
    }
 
-   private InitialValue getTopInitialValue(Conversions.PropertyValue propertyValue, Class parameterClass, Type parameterType)
+   private InitialValue getInitialValueHonoringExceptions(String propertyName, Conversions.PropertyValue propertyValue, Class parameterClass, Type parameterType)
    {
-      //note that org.jboss.seam.core.init.jndiPattern looks like an EL expression but is not one!
-      if ( propertyValue.isExpression() && getBeanClass().equals(Init.class) )
+      // the org.jboss.seam.core.init component cannot accomodate EL expressions because of startup order
+      // note that org.jboss.seam.core.init.jndiPattern looks like an EL expression but is not one!
+      if ("org.jboss.seam.core.init".equals(getName()))
       {
          return new ConstantInitialValue(propertyValue, parameterClass, parameterType);
       }




More information about the seam-commits mailing list