[webbeans-commits] Webbeans SVN: r3404 - ri/trunk/impl and 44 other directories.

webbeans-commits at lists.jboss.org webbeans-commits at lists.jboss.org
Fri Aug 7 09:02:38 EDT 2009


Author: pete.muir at jboss.org
Date: 2009-08-07 09:02:37 -0400 (Fri, 07 Aug 2009)
New Revision: 3404

Added:
   ri/trunk/impl/src/main/java/org/jboss/webbeans/context/ForwardingWBCreationalContext.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/context/WBCreationalContext.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContext.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContextStack.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELContextListener.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansExpressionFactory.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansMethodExpression.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansValueExpression.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplication.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplicationFactory.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplication.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplicationFactory.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/jsp/
   ri/trunk/impl/src/main/java/org/jboss/webbeans/jsp/JspInitialization.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationList.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELContext.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELResolver.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingExpressionFactory.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingMethodExpression.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingValueExpression.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/CowShed.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/DelegateInjectionPointTest.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/Logger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/MockLogger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/TimestampLogger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/CowShed.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/DelegateInjectionPointTest.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/Logger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/MockLogger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/TimestampLogger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/CowShed.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/DelegateFieldInjectionPointTest.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/Logger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/MockLogger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/TimestampLogger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/CowShed.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/DelegateInjectionPointTest.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/Logger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/MockLogger.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/TimestampLogger.java
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/beans.xml
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/beans.xml
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/beans.xml
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/
   tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/beans.xml
Removed:
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELContext.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELResolver.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationIterable.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/jpa/spi/
Modified:
   ri/trunk/api/src/main/java/javax/decorator/Decorates.java
   ri/trunk/impl/pom.xml
   ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractReceiverBean.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/proxy/ClientProxyMethodHandler.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/context/CreationalContextImpl.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/context/DependentContext.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/context/beanstore/AbstractAttributeBackedBeanStore.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolver.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/resources/DefaultResourceLoader.java
   ri/trunk/impl/src/main/java/org/jboss/webbeans/servlet/WebBeansListener.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/BeanDeploymentArchive.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/Deployment.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/helpers/ForwardingWebBeanDiscovery.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/BeanStore.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/helpers/ForwardingBeanStore.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/EjbDescriptor.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/helpers/ForwardingEjbDescriptor.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/ResourceLoader.java
   ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/helpers/ForwardingResourceLoader.java
   ri/trunk/spi/src/test/java/org/jboss/webbeans/bootstrap/api/test/MockResourceLoader.java
   ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockBeanDeploymentArchive.java
   ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockEjbDescriptor.java
   ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockResourceLoader.java
   ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/el/EL.java
   ri/trunk/tests/src/main/java/org/jboss/webbeans/test/AbstractWebBeansTest.java
   ri/trunk/version-matrix/pom.xml
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/passivating/broken27/EnterpriseBeanWithNonPassivatingDecoratorTest.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/Game.java
   tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/ResolutionByNameTest.java
   tck/trunk/impl/src/main/resources/tck-audit.xml
Log:
WBRI-322, also ensure dependent instance always used for an evaluation, alter SPI methods to expose collection, not Iterable, add some decorator tests

Modified: ri/trunk/api/src/main/java/javax/decorator/Decorates.java
===================================================================
--- ri/trunk/api/src/main/java/javax/decorator/Decorates.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/api/src/main/java/javax/decorator/Decorates.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,23 +1,24 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2008, Red Hat Middleware LLC, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* Licensed under the Apache License, Version 2.0 (the "License");
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-* http://www.apache.org/licenses/LICENSE-2.0
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,  
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
 
 package javax.decorator;
 
 import static java.lang.annotation.ElementType.FIELD;
+import static java.lang.annotation.ElementType.PARAMETER;
 import static java.lang.annotation.RetentionPolicy.RUNTIME;
 
 import java.lang.annotation.Documented;
@@ -25,12 +26,13 @@
 import java.lang.annotation.Target;
 
 /**
- * Specifies that a field of a decorator class is the delegate attribute.
+ * Specifies that an injected field, initializer method parameter or bean
+ * constructor parameter of a decorator class is the delegate attribute.
  * 
  * @author Gavin King
  * @author Pete Muir
  */
- at Target(FIELD)
+ at Target({FIELD, PARAMETER})
 @Retention(RUNTIME)
 @Documented
 public @interface Decorates

Modified: ri/trunk/impl/pom.xml
===================================================================
--- ri/trunk/impl/pom.xml	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/pom.xml	2009-08-07 13:02:37 UTC (rev 3404)
@@ -56,6 +56,12 @@
          <artifactId>servlet-api</artifactId>
          <optional>true</optional>
       </dependency>
+      
+      <dependency>
+         <groupId>javax.servlet.jsp</groupId>
+         <artifactId>jsp-api</artifactId>
+         <optional>true</optional>
+      </dependency>
 
       <dependency>
          <groupId>javax.transaction</groupId>

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -69,6 +69,7 @@
 import org.jboss.webbeans.bootstrap.api.ServiceRegistry;
 import org.jboss.webbeans.context.ApplicationContext;
 import org.jboss.webbeans.context.CreationalContextImpl;
+import org.jboss.webbeans.context.WBCreationalContext;
 import org.jboss.webbeans.el.Namespace;
 import org.jboss.webbeans.el.WebBeansELResolverImpl;
 import org.jboss.webbeans.introspector.WBAnnotated;
@@ -837,9 +838,9 @@
    public Object getReference(Bean<?> bean, CreationalContext<?> creationalContext)
    {
       bean = getMostSpecializedBean(bean);
-      if (creationalContext instanceof CreationalContextImpl)
+      if (creationalContext instanceof WBCreationalContext<?>)
       {
-         creationalContext = ((CreationalContextImpl<?>) creationalContext).getCreationalContext(bean);
+         creationalContext = ((WBCreationalContext<?>) creationalContext).getCreationalContext(bean);
       }
       if (getServices().get(MetaAnnotationStore.class).getScopeModel(bean.getScopeType()).isNormal())
       {
@@ -891,16 +892,16 @@
             throw new UnproxyableResolutionException("Attempting to inject an unproxyable normal scoped bean " + resolvedBean + " into " + injectionPoint);
          }
          // TODO Can we move this logic to getReference?
-         if (creationalContext instanceof CreationalContextImpl)
+         if (creationalContext instanceof WBCreationalContext<?>)
          {
-            CreationalContextImpl<?> creationalContextImpl = (CreationalContextImpl<?>) creationalContext;
-            if (creationalContextImpl.containsIncompleteInstance(resolvedBean))
+            WBCreationalContext<?> wbCreationalContext = (WBCreationalContext<?>) creationalContext;
+            if (wbCreationalContext.containsIncompleteInstance(resolvedBean))
             {
-               return creationalContextImpl.getIncompleteInstance(resolvedBean);
+               return wbCreationalContext.getIncompleteInstance(resolvedBean);
             }
             else
             {
-               return getReference(resolvedBean, creationalContextImpl);
+               return getReference(resolvedBean, wbCreationalContext);
             }
          }
          else
@@ -1321,7 +1322,7 @@
       return webbeansELResolver;
    }
    
-   public <T> CreationalContextImpl<T> createCreationalContext(Contextual<T> contextual)
+   public <T> WBCreationalContext<T> createCreationalContext(Contextual<T> contextual)
    {
       return new CreationalContextImpl<T>(contextual);
    }

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractReceiverBean.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractReceiverBean.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/AbstractReceiverBean.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -23,7 +23,7 @@
 
 import org.jboss.webbeans.BeanManagerImpl;
 import org.jboss.webbeans.bootstrap.BeanDeployerEnvironment;
-import org.jboss.webbeans.context.CreationalContextImpl;
+import org.jboss.webbeans.context.WBCreationalContext;
 import org.jboss.webbeans.log.LogProvider;
 import org.jboss.webbeans.log.Logging;
 
@@ -67,9 +67,9 @@
       }
       else
       {
-         if (creationalContext instanceof CreationalContextImpl<?>)
+         if (creationalContext instanceof WBCreationalContext<?>)
          {
-            CreationalContextImpl<?> creationalContextImpl = (CreationalContextImpl<?>) creationalContext;
+            WBCreationalContext<?> creationalContextImpl = (WBCreationalContext<?>) creationalContext;
             if (creationalContextImpl.containsIncompleteInstance(getDeclaringBean()))
             {
                log.warn("Executing producer field or method " + getAnnotatedItem() + " on incomplete declaring bean " + getDeclaringBean() + " due to circular injection");

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/proxy/ClientProxyMethodHandler.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/proxy/ClientProxyMethodHandler.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/bean/proxy/ClientProxyMethodHandler.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -26,7 +26,7 @@
 import javax.enterprise.inject.spi.Bean;
 
 import org.jboss.webbeans.BeanManagerImpl;
-import org.jboss.webbeans.context.CreationalContextImpl;
+import org.jboss.webbeans.context.WBCreationalContext;
 import org.jboss.webbeans.log.LogProvider;
 import org.jboss.webbeans.log.Logging;
 import org.jboss.webbeans.util.Reflections;
@@ -53,7 +53,7 @@
 
    private final BeanManagerImpl manager;
 
-   private static final ThreadLocal<CreationalContextImpl<?>> currentCreationalContext = new ThreadLocal<CreationalContextImpl<?>>();
+   private static final ThreadLocal<WBCreationalContext<?>> currentCreationalContext = new ThreadLocal<WBCreationalContext<?>>();
 
    /**
     * Constructor
@@ -119,7 +119,7 @@
 
    private <T> T getProxiedInstance(Bean<T> bean)
    {
-      CreationalContextImpl<T> creationalContext;
+      WBCreationalContext<T> creationalContext;
       boolean outer;
       if (currentCreationalContext.get() == null)
       {

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/context/CreationalContextImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/context/CreationalContextImpl.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/context/CreationalContextImpl.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -22,7 +22,7 @@
 import javax.enterprise.context.spi.Contextual;
 import javax.enterprise.context.spi.CreationalContext;
 
-public class CreationalContextImpl<T> implements CreationalContext<T>
+public class CreationalContextImpl<T> implements CreationalContext<T>, WBCreationalContext<T>
 {
 
    private final Map<Contextual<?>, Object> incompleteInstances;
@@ -50,7 +50,7 @@
       incompleteInstances.put(contextual, incompleteInstance);
    }
    
-   public <S> CreationalContextImpl<S> getCreationalContext(Contextual<S> Contextual)
+   public <S> WBCreationalContext<S> getCreationalContext(Contextual<S> Contextual)
    {
       return new CreationalContextImpl<S>(Contextual, new HashMap<Contextual<?>, Object>(incompleteInstances), dependentInstancesStore);
    }
@@ -73,6 +73,7 @@
    public void release()
    {
       dependentInstancesStore.destroyDependentInstances();
+      incompleteInstances.clear();
    }
    
 }

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/context/DependentContext.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/context/DependentContext.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/context/DependentContext.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -61,9 +61,9 @@
       if (creationalContext != null)
       {
          T instance = contextual.create(creationalContext);
-         if (creationalContext instanceof CreationalContextImpl<?>)
+         if (creationalContext instanceof WBCreationalContext<?>)
          {
-            CreationalContextImpl<T> creationalContextImpl = (CreationalContextImpl<T>) creationalContext;
+            WBCreationalContext<T> creationalContextImpl = (WBCreationalContext<T>) creationalContext;
             ContexutalInstance<T> beanInstance = new BeanInstanceImpl<T>(contextual, instance, creationalContext);
             creationalContextImpl.getParentDependentInstancesStore().addDependentInstance(beanInstance);
          }

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/context/ForwardingWBCreationalContext.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/context/ForwardingWBCreationalContext.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/context/ForwardingWBCreationalContext.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,79 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.context;
+
+import javax.enterprise.context.spi.Contextual;
+
+
+/**
+ * @author pmuir
+ *
+ */
+public abstract class ForwardingWBCreationalContext<T> implements WBCreationalContext<T>
+{
+   
+   protected abstract WBCreationalContext<T> delegate();
+
+   public void push(T incompleteInstance)
+   {
+      delegate().push(incompleteInstance);
+   }
+
+   public void release()
+   {
+      delegate().release();
+   }
+
+   public boolean containsIncompleteInstance(Contextual<?> bean)
+   {
+      return delegate().containsIncompleteInstance(bean);
+   }
+
+   public <S> WBCreationalContext<S> getCreationalContext(Contextual<S> Contextual)
+   {
+      return delegate().getCreationalContext(Contextual);
+   }
+
+   public <S> S getIncompleteInstance(Contextual<S> bean)
+   {
+      return delegate().getIncompleteInstance(bean);
+   }
+
+   public DependentInstancesStore getParentDependentInstancesStore()
+   {
+      return delegate().getParentDependentInstancesStore();
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delegate().equals(obj);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delegate().hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delegate().toString();
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/context/ForwardingWBCreationalContext.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/context/WBCreationalContext.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/context/WBCreationalContext.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/context/WBCreationalContext.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,42 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.context;
+
+import javax.enterprise.context.spi.Contextual;
+import javax.enterprise.context.spi.CreationalContext;
+
+/**
+ * @author pmuir
+ *
+ * @param <T>
+ */
+public interface WBCreationalContext<T> extends CreationalContext<T>
+{
+
+   public abstract void push(T incompleteInstance);
+
+   public abstract <S> WBCreationalContext<S> getCreationalContext(Contextual<S> Contextual);
+
+   public abstract <S> S getIncompleteInstance(Contextual<S> bean);
+
+   public abstract boolean containsIncompleteInstance(Contextual<?> bean);
+
+   public abstract DependentInstancesStore getParentDependentInstancesStore();
+
+   public abstract void release();
+
+}
\ No newline at end of file


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/context/WBCreationalContext.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/context/beanstore/AbstractAttributeBackedBeanStore.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/context/beanstore/AbstractAttributeBackedBeanStore.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/context/beanstore/AbstractAttributeBackedBeanStore.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -17,6 +17,7 @@
 package org.jboss.webbeans.context.beanstore;
 
 import java.util.ArrayList;
+import java.util.Collection;
 import java.util.Enumeration;
 import java.util.List;
 
@@ -29,7 +30,7 @@
 import org.jboss.webbeans.log.LogProvider;
 import org.jboss.webbeans.log.Logging;
 import org.jboss.webbeans.util.Names;
-import org.jboss.webbeans.util.collections.EnumerationIterable;
+import org.jboss.webbeans.util.collections.EnumerationList;
 
 /**
  * Provides common BeanStore operations
@@ -91,7 +92,7 @@
     * 
     * @return The beans
     */
-   public Iterable<Contextual<? extends Object>> getContextuals()
+   public Collection<Contextual<? extends Object>> getContextuals()
    {
       List<Contextual<?>> contextuals = new ArrayList<Contextual<?>>();
       BeanStoreNamingScheme namingScheme = getNamingScheme();
@@ -113,7 +114,7 @@
    {
       List<String> attributeNames = new ArrayList<String>();
       BeanStoreNamingScheme namingScheme = getNamingScheme();
-      for (String attributeName : new EnumerationIterable<String>(getAttributeNames()))
+      for (String attributeName : new EnumerationList<String>(getAttributeNames()))
       {
          if (namingScheme.acceptKey(attributeName))
          {

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContext.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContext.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContext.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,58 @@
+package org.jboss.webbeans.el;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.concurrent.Callable;
+
+import javax.enterprise.context.Dependent;
+import javax.enterprise.inject.spi.Bean;
+
+import org.jboss.webbeans.context.ForwardingWBCreationalContext;
+import org.jboss.webbeans.context.WBCreationalContext;
+
+abstract class ELCreationalContext<T> extends ForwardingWBCreationalContext<T>
+{
+   
+   public static <X> ELCreationalContext<X> of(final WBCreationalContext<X> creationalContext)
+   {
+      return new ELCreationalContext<X>()
+      {
+         
+         @Override
+         protected WBCreationalContext<X> delegate()
+         {
+            return creationalContext;
+         }
+         
+      };
+   }
+
+   private final Map<String, Object> dependentInstances;
+   
+   public ELCreationalContext()
+   {
+      this.dependentInstances = new HashMap<String, Object>();
+   }
+   
+   public Object putIfAbsent(Bean<?> bean, Callable<Object> value) throws Exception
+   {
+      if (bean.getScopeType().equals(Dependent.class))
+      {
+         if (dependentInstances.containsKey(bean.getName()))
+         {
+            return dependentInstances.get(bean.getName());
+         }
+         else
+         {
+            Object instance = value.call();
+            dependentInstances.put(bean.getName(), instance);
+            return instance;
+         }
+      }
+      else
+      {
+         return value.call();
+      }
+   }
+   
+}
\ No newline at end of file


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContext.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContextStack.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContextStack.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContextStack.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,19 @@
+package org.jboss.webbeans.el;
+
+import java.util.Stack;
+
+import javax.el.ELContext;
+
+class ELCreationalContextStack extends Stack<ELCreationalContext<?>>
+{
+   
+   private static final long serialVersionUID = -57142365866995726L;
+   
+   public static ELCreationalContextStack addToContext(ELContext context)
+   {
+      ELCreationalContextStack store = new ELCreationalContextStack();
+      context.putContext(ELCreationalContextStack.class, store);
+      return store;
+   }
+   
+}
\ No newline at end of file


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ELCreationalContextStack.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Deleted: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELContext.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELContext.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELContext.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,110 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * http://www.apache.org/licenses/LICENSE-2.0
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,  
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jboss.webbeans.el;
-
-import java.util.Locale;
-
-import javax.el.ELContext;
-import javax.el.ELResolver;
-import javax.el.FunctionMapper;
-import javax.el.VariableMapper;
-
-/**
- * A forwarding class that delegates to an ELContext
- * 
- * @author Pete Muir
- *
- */
-public abstract class ForwardingELContext extends ELContext
-{
-   
-   protected abstract ELContext delgate();
-   
-   @Override
-   public ELResolver getELResolver()
-   {
-      return delgate().getELResolver();
-   }
-   
-   @Override
-   public FunctionMapper getFunctionMapper()
-   {
-      return delgate().getFunctionMapper();
-   }
-   
-   @Override
-   public VariableMapper getVariableMapper()
-   {
-      return delgate().getVariableMapper();
-   }
-   
-   @Override
-   public boolean equals(Object obj)
-   {
-      return delgate().equals(obj);
-   }
-   
-   @SuppressWarnings("unchecked")
-   @Override
-   public Object getContext(Class key)
-   {
-      return delgate().getContext(key);
-   }
-   
-   @Override
-   public Locale getLocale()
-   {
-      return delgate().getLocale();
-   }
-   
-   @Override
-   public int hashCode()
-   {
-      return delgate().hashCode();
-   }
-   
-   @Override
-   public boolean isPropertyResolved()
-   {
-      return delgate().isPropertyResolved();
-   }
-   
-   @SuppressWarnings("unchecked")
-   @Override
-   public void putContext(Class key, Object contextObject)
-   {
-      delgate().putContext(key, contextObject);
-   }
-   
-   @Override
-   public void setLocale(Locale locale)
-   {
-      delgate().setLocale(locale);
-   }
-   
-   @Override
-   public void setPropertyResolved(boolean resolved)
-   {
-      delgate().setPropertyResolved(resolved);
-   }
-   
-   @Override
-   public String toString()
-   {
-      return delgate().toString();
-   }
-}

Deleted: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELResolver.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELResolver.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELResolver.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,65 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * http://www.apache.org/licenses/LICENSE-2.0
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,  
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jboss.webbeans.el;
-
-import java.util.Iterator;
-
-import javax.el.ELContext;
-import javax.el.ELResolver;
-
-public abstract class ForwardingELResolver extends ELResolver
-{
-   
-   protected abstract ELResolver delegate();
-
-   @Override
-   public Class<?> getCommonPropertyType(ELContext context, Object base)
-   {
-      return delegate().getCommonPropertyType(context, base);
-   }
-
-   @Override
-   public Iterator<?> getFeatureDescriptors(ELContext context, Object base)
-   {
-      return delegate().getFeatureDescriptors(context, base);
-   }
-
-   @Override
-   public Class<?> getType(ELContext context, Object base, Object property)
-   {
-      return delegate().getType(context, base, property);
-   }
-
-   @Override
-   public Object getValue(ELContext context, Object base, Object property)
-   {
-      return delegate().getValue(context, base, property);
-   }
-
-   @Override
-   public boolean isReadOnly(ELContext context, Object base, Object property)
-   {
-      return delegate().isReadOnly(context, base, property);
-   }
-
-   @Override
-   public void setValue(ELContext context, Object base, Object property, Object value)
-   {
-      delegate().setValue(context, base, property, value);
-   }
-
-}

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELContextListener.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELContextListener.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELContextListener.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.el;
+
+import javax.el.ELContextEvent;
+import javax.el.ELContextListener;
+
+/**
+ * Responsible for pushing the CreationalContext stack into the ELContext which
+ * is later populated by our expression wrappers
+ * 
+ * @author pmuir
+ *
+ */
+public class WebBeansELContextListener implements ELContextListener
+{
+
+   public void contextCreated(ELContextEvent contextEvent)
+   {
+      ELCreationalContextStack.addToContext(contextEvent.getELContext());
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELContextListener.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolver.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolver.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolver.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -19,6 +19,7 @@
 import javax.el.ELResolver;
 
 import org.jboss.webbeans.CurrentManager;
+import org.jboss.webbeans.util.el.ForwardingELResolver;
 
 public class WebBeansELResolver extends ForwardingELResolver
 {

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansELResolverImpl.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,13 +18,16 @@
 
 import java.beans.FeatureDescriptor;
 import java.util.Iterator;
+import java.util.concurrent.Callable;
 
 import javax.el.ELContext;
 import javax.el.ELResolver;
+import javax.enterprise.context.spi.Contextual;
 import javax.enterprise.context.spi.CreationalContext;
 import javax.enterprise.inject.spi.Bean;
 
 import org.jboss.webbeans.BeanManagerImpl;
+import org.jboss.webbeans.CurrentManager;
 
 /**
  * An EL-resolver against the named beans
@@ -34,22 +37,17 @@
 public class WebBeansELResolverImpl extends ELResolver
 {
    
-   private static final class ValueHolder<T>
+   private static final Contextual<?> CONTEXTUAL = new Contextual<Object>()
    {
-      
-      private T value;
-      
-      public T getValue()
+
+      public Object create(CreationalContext<Object> creationalContext)
       {
-         return value;
+         return null;
       }
+
+      public void destroy(Object instance, CreationalContext<Object> creationalContext) {}
       
-      public void setValue(T value)
-      {
-         this.value = value;
-      }
-      
-   }
+   };
    
    private final BeanManagerImpl manager;
       
@@ -58,36 +56,24 @@
       this.manager = manager;
    }
 
-   /**
-    * @see javax.el.ELResolver#getCommonPropertyType(ELContext, Object)
-    */
    @Override
    public Class<?> getCommonPropertyType(ELContext context, Object base)
    {
       return null;
    }
 
-   /**
-    * @see javax.el.ELResolver#getFeatureDescriptors(ELContext, Object)
-    */
    @Override
    public Iterator<FeatureDescriptor> getFeatureDescriptors(ELContext context, Object base)
    {
       return null;
    }
 
-   /**
-    * @see javax.el.ELResolver#getType(ELContext, Object, Object)
-    */
    @Override
    public Class<?> getType(ELContext context, Object base, Object property)
    {
       return null;
    }
 
-   /**
-    * @see javax.el.ELResolver#getValue(ELContext, Object, Object)
-    */
    @Override
    public Object getValue(ELContext context, Object base, Object property)
    {
@@ -132,13 +118,20 @@
          Object value = null;
          try
          {
-            Bean<?> bean = manager.resolve(manager.getBeans(name));
-            CreationalContext<?> creationalContext = manager.createCreationalContext(bean);
+            final Bean<?> bean = manager.resolve(manager.getBeans(name));
+            final ELCreationalContext<?> creationalContext = getCreationalContextStore(context).peek();
             if (bean != null)
             {
-               value = manager.getReference(bean, creationalContext);
+               value = creationalContext.putIfAbsent(bean, new Callable<Object>()
+               {
+                  
+                  public Object call() throws Exception
+                  {
+                     return manager.getReference(bean, creationalContext);
+                  }
+                  
+               });
             }
-            creationalContext.release();
          }
          catch (Exception e)
          {
@@ -153,22 +146,31 @@
       return null;
    }
 
-   /**
-    * @see javax.el.ELResolver#isReadOnly(ELContext, Object, Object)
-    */
    @Override
    public boolean isReadOnly(ELContext context, Object base, Object property)
    {
       return false;
    }
 
-   /**
-    * @see javax.el.ELResolver#setValue(ELContext, Object, Object, Object)
-    */
    @Override
    public void setValue(ELContext context, Object base, Object property, Object value)
    {
    }
+   
+   private static ELCreationalContextStack getCreationalContextStore(ELContext context)
+   {
+      Object o = context.getContext(ELCreationalContextStack.class);
+      
+      if (!(o instanceof ELCreationalContextStack))
+      {
+         ELCreationalContextStack store = ELCreationalContextStack.addToContext(context);
+         // TODO need to use correct manager for module
+         ELCreationalContext<?> creationalContext = ELCreationalContext.of(CurrentManager.rootManager().createCreationalContext(CONTEXTUAL));
+         store.push(creationalContext);
+         o = store;
+      }
+      return (ELCreationalContextStack) o;
+   }
 
 }
 

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansExpressionFactory.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansExpressionFactory.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansExpressionFactory.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,60 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.el;
+
+import javax.el.ELContext;
+import javax.el.ExpressionFactory;
+import javax.el.MethodExpression;
+import javax.el.ValueExpression;
+
+import org.jboss.webbeans.util.el.ForwardingExpressionFactory;
+
+/**
+ * @author pmuir
+ *
+ */
+public class WebBeansExpressionFactory extends ForwardingExpressionFactory
+{
+
+   private final ExpressionFactory delegate;
+   
+   public WebBeansExpressionFactory(ExpressionFactory expressionFactory)
+   {
+      this.delegate = expressionFactory;
+   }
+   
+   @Override
+   protected ExpressionFactory delegate()
+   {
+      return delegate;
+   }
+   
+   @SuppressWarnings("unchecked")
+   @Override
+   public ValueExpression createValueExpression(ELContext context, String expression, Class expectedType)
+   {
+      return new WebBeansValueExpression(super.createValueExpression(context, expression, expectedType));
+   }
+   
+   @SuppressWarnings("unchecked")
+   @Override
+   public MethodExpression createMethodExpression(ELContext context, String expression, Class expectedReturnType, Class[] expectedParamTypes)
+   {
+      return new WebBeansMethodExpression(super.createMethodExpression(context, expression, expectedReturnType, expectedParamTypes));
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansExpressionFactory.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansMethodExpression.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansMethodExpression.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansMethodExpression.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.el;
+
+import javax.el.ELContext;
+import javax.el.MethodExpression;
+import javax.el.MethodInfo;
+import javax.enterprise.context.spi.Contextual;
+import javax.enterprise.context.spi.CreationalContext;
+
+import org.jboss.webbeans.CurrentManager;
+import org.jboss.webbeans.util.el.ForwardingMethodExpression;
+
+/**
+ * @author pmuir
+ *
+ */
+public class WebBeansMethodExpression extends ForwardingMethodExpression
+{
+   
+   private static final long serialVersionUID = 7070020110515571744L;
+
+   private static final Contextual<?> CONTEXTUAL = new Contextual<Object>()
+   {
+
+      public Object create(CreationalContext<Object> creationalContext)
+      {
+         return null;
+      }
+
+      public void destroy(Object instance, CreationalContext<Object> creationalContext) {}
+      
+   };
+   
+   private final MethodExpression delegate;
+   
+   public WebBeansMethodExpression(MethodExpression delegate)
+   {
+      this.delegate = delegate;
+   }
+
+   @Override
+   protected MethodExpression delegate()
+   {
+      return delegate;
+   }
+   
+   @Override
+   public Object invoke(ELContext context, Object[] params)
+   {
+      // TODO need to use correct manager for module
+      ELCreationalContext<?> creationalContext = ELCreationalContext.of(CurrentManager.rootManager().createCreationalContext(CONTEXTUAL));
+      try
+      {
+         getCreationalContextStore(context).push(creationalContext);
+         return super.invoke(context, params);
+      }
+      finally
+      {
+         getCreationalContextStore(context).pop();
+         creationalContext.release();
+      }
+   }
+   
+   @Override
+   public MethodInfo getMethodInfo(ELContext context)
+   {
+      // TODO need to use correct manager for module
+      ELCreationalContext<?> creationalContext = ELCreationalContext.of(CurrentManager.rootManager().createCreationalContext(CONTEXTUAL));
+      try
+      {
+         getCreationalContextStore(context).push(creationalContext);
+         return super.getMethodInfo(context);
+      }
+      finally
+      {
+         getCreationalContextStore(context).pop();
+         creationalContext.release();
+      }
+   }
+   
+   private ELCreationalContextStack getCreationalContextStore(ELContext context)
+   {
+      Object o = context.getContext(ELCreationalContextStack.class);
+      if (!(o instanceof ELCreationalContextStack))
+      {
+         throw new IllegalStateException("Something went wrong with the ELContext, expecting a CreationalContextStore to be present, but instead got " + o);
+      }
+      return (ELCreationalContextStack) o;
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansMethodExpression.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansValueExpression.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansValueExpression.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansValueExpression.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,123 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.el;
+
+import javax.el.ELContext;
+import javax.el.ValueExpression;
+import javax.enterprise.context.spi.Contextual;
+import javax.enterprise.context.spi.CreationalContext;
+
+import org.jboss.webbeans.CurrentManager;
+import org.jboss.webbeans.util.el.ForwardingValueExpression;
+
+/**
+ * @author pmuir
+ *
+ */
+public class WebBeansValueExpression extends ForwardingValueExpression
+{
+   
+   private static final long serialVersionUID = 1122137212009930853L;
+
+   private static final Contextual<?> CONTEXTUAL = new Contextual<Object>()
+   {
+
+      public Object create(CreationalContext<Object> creationalContext)
+      {
+         return null;
+      }
+
+      public void destroy(Object instance, CreationalContext<Object> creationalContext) {}
+      
+   };
+   
+   private final ValueExpression delegate;
+   
+   public WebBeansValueExpression(ValueExpression delegate)
+   {
+      this.delegate = delegate;
+   }
+
+   @Override
+   protected ValueExpression delegate()
+   {
+      return delegate;
+   }
+   
+   @Override
+   public Object getValue(final ELContext context)
+   {
+      // TODO need to use correct manager for module
+      ELCreationalContext<?> creationalContext = ELCreationalContext.of(CurrentManager.rootManager().createCreationalContext(CONTEXTUAL));
+      try
+      {
+         getCreationalContextStore(context).push(creationalContext);
+         return delegate().getValue(context);
+      }
+      finally
+      {
+         getCreationalContextStore(context).pop();
+         creationalContext.release();
+      }
+   }
+   
+   @Override
+   public void setValue(ELContext context, Object value)
+   {
+      // TODO need to use correct manager for module
+      ELCreationalContext<?> creationalContext = ELCreationalContext.of(CurrentManager.rootManager().createCreationalContext(CONTEXTUAL));
+      try
+      {
+         getCreationalContextStore(context).push(creationalContext);
+         delegate().setValue(context, value);
+      }
+      finally
+      {
+         getCreationalContextStore(context).pop();
+         creationalContext.release();
+      }
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public Class getType(ELContext context)
+   {
+   // TODO need to use correct manager for module
+      ELCreationalContext<?> creationalContext = ELCreationalContext.of(CurrentManager.rootManager().createCreationalContext(CONTEXTUAL));
+      try
+      {
+         getCreationalContextStore(context).push(creationalContext);
+         return delegate().getType(context);
+      }
+      finally
+      {
+         getCreationalContextStore(context).pop();
+         creationalContext.release();
+      }
+   }
+   
+   private ELCreationalContextStack getCreationalContextStore(ELContext context)
+   {
+      Object o = context.getContext(ELCreationalContextStack.class);
+      if (!(o instanceof ELCreationalContextStack))
+      {
+         throw new IllegalStateException("Something went wrong with the ELContext, expecting a CreationalContextStore to be present, but instead got " + o);
+      }
+      return (ELCreationalContextStack) o;
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/el/WebBeansValueExpression.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplication.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplication.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplication.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,289 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.jsf;
+
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Locale;
+
+import javax.faces.FacesException;
+import javax.faces.application.Application;
+import javax.faces.application.NavigationHandler;
+import javax.faces.application.StateManager;
+import javax.faces.application.ViewHandler;
+import javax.faces.component.UIComponent;
+import javax.faces.context.FacesContext;
+import javax.faces.convert.Converter;
+import javax.faces.el.MethodBinding;
+import javax.faces.el.PropertyResolver;
+import javax.faces.el.ReferenceSyntaxException;
+import javax.faces.el.ValueBinding;
+import javax.faces.el.VariableResolver;
+import javax.faces.event.ActionListener;
+import javax.faces.validator.Validator;
+
+/**
+ * @author pmuir
+ *
+ */
+public abstract class ForwardingApplication extends Application
+{
+   
+   protected abstract Application delegate();
+
+   @Override
+   public void addComponent(String componentType, String componentClass)
+   {
+      delegate().addComponent(componentType, componentClass);
+   }
+
+   @Override
+   public void addConverter(String converterId, String converterClass)
+   {
+      delegate().addConverter(converterId, converterClass);
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public void addConverter(Class targetClass, String converterClass)
+   {
+      delegate().addConverter(targetClass, converterClass);
+   }
+
+   @Override
+   public void addValidator(String validatorId, String validatorClass)
+   {
+      delegate().addValidator(validatorId, validatorClass);
+   }
+
+   @Override
+   public UIComponent createComponent(String componentType) throws FacesException
+   {
+      return delegate().createComponent(componentType);
+   }
+
+   @Override
+   @Deprecated
+   public UIComponent createComponent(ValueBinding componentBinding, FacesContext context, String componentType) throws FacesException
+   {
+      return delegate().createComponent(componentBinding, context, componentType);
+   }
+
+   @Override
+   public Converter createConverter(String converterId)
+   {
+      return delegate().createConverter(converterId);
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public Converter createConverter(Class targetClass)
+   {
+      return delegate().createConverter(targetClass);
+   }
+
+   @SuppressWarnings("unchecked")
+   @Deprecated
+   @Override
+   public MethodBinding createMethodBinding(String ref, Class[] params) throws ReferenceSyntaxException
+   {
+      return delegate().createMethodBinding(ref, params);
+   }
+
+   @Override
+   public Validator createValidator(String validatorId) throws FacesException
+   {
+      return delegate().createValidator(validatorId);
+   }
+
+   @Override
+   @Deprecated
+   public ValueBinding createValueBinding(String ref) throws ReferenceSyntaxException
+   {
+      return delegate().createValueBinding(ref);
+   }
+
+   @Override
+   public ActionListener getActionListener()
+   {
+      return delegate().getActionListener();
+   }
+
+   @Override
+   public Iterator<String> getComponentTypes()
+   {
+      return delegate().getComponentTypes();
+   }
+
+   @Override
+   public Iterator<String> getConverterIds()
+   {
+      return delegate().getConverterIds();
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public Iterator<Class> getConverterTypes()
+   {
+      return delegate().getConverterTypes();
+   }
+
+   @Override
+   public Locale getDefaultLocale()
+   {
+      return delegate().getDefaultLocale();
+   }
+
+   @Override
+   public String getDefaultRenderKitId()
+   {
+      return delegate().getDefaultRenderKitId();
+   }
+
+   @Override
+   public String getMessageBundle()
+   {
+      return delegate().getMessageBundle();
+   }
+
+   @Override
+   public NavigationHandler getNavigationHandler()
+   {
+      return delegate().getNavigationHandler();
+   }
+
+   @Override
+   @Deprecated
+   public PropertyResolver getPropertyResolver()
+   {
+      return delegate().getPropertyResolver();
+   }
+
+   @Override
+   public StateManager getStateManager()
+   {
+      return delegate().getStateManager();
+   }
+
+   @Override
+   public Iterator<Locale> getSupportedLocales()
+   {
+      return delegate().getSupportedLocales();
+   }
+
+   @Override
+   public Iterator<String> getValidatorIds()
+   {
+      return delegate().getValidatorIds();
+   }
+
+   @Override
+   @Deprecated
+   public VariableResolver getVariableResolver()
+   {
+      return delegate().getVariableResolver();
+   }
+
+   @Override
+   public ViewHandler getViewHandler()
+   {
+      return delegate().getViewHandler();
+   }
+
+   @Override
+   public void setActionListener(ActionListener listener)
+   {
+      delegate().setActionListener(listener);
+   }
+
+   @Override
+   public void setDefaultLocale(Locale locale)
+   {
+      delegate().setDefaultLocale(locale);
+   }
+
+   @Override
+   public void setDefaultRenderKitId(String renderKitId)
+   {
+      delegate().setDefaultRenderKitId(renderKitId);
+   }
+
+   @Override
+   public void setMessageBundle(String bundle)
+   {
+      delegate().setMessageBundle(bundle);
+   }
+
+   @Override
+   public void setNavigationHandler(NavigationHandler handler)
+   {
+      delegate().setNavigationHandler(handler);
+   }
+
+
+   @Override
+   @Deprecated
+   public void setPropertyResolver(PropertyResolver resolver)
+   {
+      delegate().setPropertyResolver(resolver);
+   }
+
+   @Override
+   public void setStateManager(StateManager manager)
+   {
+      delegate().setStateManager(manager);
+   }
+
+   @Override
+   public void setSupportedLocales(Collection<Locale> locales)
+   {
+      delegate().setSupportedLocales(locales);
+
+   }
+
+   @Override
+   @Deprecated
+   public void setVariableResolver(VariableResolver resolver)
+   {
+      delegate().setVariableResolver(resolver);
+   }
+
+   @Override
+   public void setViewHandler(ViewHandler handler)
+   {
+      delegate().setViewHandler(handler);
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delegate().equals(obj);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delegate().hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delegate().toString();
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplication.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplicationFactory.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplicationFactory.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplicationFactory.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,61 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.jsf;
+
+import javax.faces.application.Application;
+import javax.faces.application.ApplicationFactory;
+
+/**
+ * @author pmuir
+ *
+ */
+public abstract class ForwardingApplicationFactory extends ApplicationFactory
+{
+
+   protected abstract ApplicationFactory delegate();
+   
+   @Override
+   public Application getApplication()
+   {
+      return delegate().getApplication();
+   }
+
+   @Override
+   public void setApplication(Application application)
+   {
+      delegate().setApplication(application);
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delegate().equals(obj);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delegate().hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delegate().toString();
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/ForwardingApplicationFactory.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplication.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplication.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplication.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,78 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.jsf;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+import javax.el.ELContextListener;
+import javax.el.ExpressionFactory;
+import javax.faces.application.Application;
+
+import org.jboss.webbeans.el.WebBeansELContextListener;
+import org.jboss.webbeans.el.WebBeansExpressionFactory;
+
+/**
+ * @author pmuir
+ *
+ */
+public class WebBeansApplication extends ForwardingApplication
+{
+   
+   private static final ELContextListener[] EMPTY_LISTENERS = {};
+   
+   private final Application application;
+   private final Collection<ELContextListener> elContextListeners;
+   
+   public WebBeansApplication(Application application)
+   {
+      this.application = application;
+      this.elContextListeners = new ArrayList<ELContextListener>();
+      this.elContextListeners.add(new WebBeansELContextListener());
+   }
+
+   @Override
+   protected Application delegate()
+   {
+      return application;
+   }
+   
+   @Override
+   public ExpressionFactory getExpressionFactory()
+   {
+      return new WebBeansExpressionFactory(delegate().getExpressionFactory());
+   }
+   
+   @Override
+   public ELContextListener[] getELContextListeners()
+   {
+      return elContextListeners.toArray(EMPTY_LISTENERS);
+   }
+   
+   @Override
+   public void addELContextListener(ELContextListener listener)
+   {
+      elContextListeners.add(listener);
+   }
+   
+   @Override
+   public void removeELContextListener(ELContextListener listener)
+   {
+      elContextListeners.remove(listener);
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplication.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplicationFactory.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplicationFactory.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplicationFactory.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,49 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.jsf;
+
+import javax.faces.application.Application;
+import javax.faces.application.ApplicationFactory;
+
+
+/**
+ * @author pmuir
+ *
+ */
+public class WebBeansApplicationFactory extends ForwardingApplicationFactory
+{
+
+   private final ApplicationFactory applicationFactory;
+   
+   public WebBeansApplicationFactory(ApplicationFactory applicationFactory)
+   {
+      this.applicationFactory = applicationFactory;
+   }
+   
+   @Override
+   protected ApplicationFactory delegate()
+   {
+      return applicationFactory;
+   }
+   
+   @Override
+   public Application getApplication()
+   {
+      return new WebBeansApplication(delegate().getApplication());
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsf/WebBeansApplicationFactory.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsp/JspInitialization.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/jsp/JspInitialization.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/jsp/JspInitialization.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.jsp;
+
+import javax.servlet.ServletContext;
+import javax.servlet.jsp.JspApplicationContext;
+import javax.servlet.jsp.JspFactory;
+
+import org.jboss.webbeans.el.WebBeansELResolver;
+
+/**
+ * @author pmuir
+ * 
+ */
+public class JspInitialization
+{
+
+   public void init(ServletContext context)
+   {
+      // JSP 2.1 specific check
+      if (JspFactory.getDefaultFactory().getJspApplicationContext(context) == null)
+      {
+         return;
+      }
+
+      // get JspApplicationContext.
+      JspApplicationContext jspAppContext = JspFactory.getDefaultFactory().getJspApplicationContext(context);
+
+      // register compositeELResolver with JSP
+      jspAppContext.addELResolver(new WebBeansELResolver());
+
+      // DOesn't really achieve much :-(
+      //jspAppContext.addELContextListener(new WebBeansELContextListener());
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/jsp/JspInitialization.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/resources/DefaultResourceLoader.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/resources/DefaultResourceLoader.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/resources/DefaultResourceLoader.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,10 +18,11 @@
 
 import java.io.IOException;
 import java.net.URL;
+import java.util.Collection;
 
 import org.jboss.webbeans.resources.spi.ResourceLoader;
 import org.jboss.webbeans.resources.spi.ResourceLoadingException;
-import org.jboss.webbeans.util.collections.EnumerationIterable;
+import org.jboss.webbeans.util.collections.EnumerationList;
 
 /**
  * A simple resource loader.
@@ -71,17 +72,17 @@
       }
    }
    
-   public Iterable<URL> getResources(String name)
+   public Collection<URL> getResources(String name)
    {
       try
       {
          if (Thread.currentThread().getContextClassLoader() != null)
          {
-            return new EnumerationIterable<URL>(Thread.currentThread().getContextClassLoader().getResources(name));
+            return new EnumerationList<URL>(Thread.currentThread().getContextClassLoader().getResources(name));
          }
          else
          {
-            return new EnumerationIterable<URL>(getClass().getClassLoader().getResources(name));
+            return new EnumerationList<URL>(getClass().getClassLoader().getResources(name));
          }
       }
       catch (IOException e)

Modified: ri/trunk/impl/src/main/java/org/jboss/webbeans/servlet/WebBeansListener.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/servlet/WebBeansListener.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/servlet/WebBeansListener.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -22,12 +22,14 @@
  */
 package org.jboss.webbeans.servlet;
 
+import javax.servlet.ServletContextEvent;
 import javax.servlet.ServletRequestEvent;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpSessionEvent;
 
 import org.jboss.webbeans.CurrentManager;
 import org.jboss.webbeans.context.ContextLifecycle;
+import org.jboss.webbeans.jsp.JspInitialization;
 import org.jboss.webbeans.servlet.api.helpers.AbstractServletListener;
 
 /**
@@ -53,6 +55,12 @@
       }
       return lifecycle;
    }
+   
+   @Override
+   public void contextInitialized(ServletContextEvent sce)
+   {
+      new JspInitialization().init(sce.getServletContext());
+   }  
 
    /**
     * Called when the session is created

Deleted: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationIterable.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationIterable.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationIterable.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,61 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * http://www.apache.org/licenses/LICENSE-2.0
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,  
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.jboss.webbeans.util.collections;
-
-import java.util.ArrayList;
-import java.util.Enumeration;
-import java.util.Iterator;
-import java.util.List;
-
-import com.google.common.collect.Iterables;
-
-
-/**
- * An Enumeration -> Iteratble adaptor
- *  
- * @author Pete Muir
- * @see org.jboss.webbeans.util.collections.EnumerationIterator
- */
-public class EnumerationIterable<T> implements Iterable<T>
-{
-   // The enumeration as a list
-   private final List<T> list = new ArrayList<T>();
-   
-   /**
-    * Constructor
-    * 
-    * @param enumeration The enumeration
-    */
-   public EnumerationIterable(Enumeration<T> enumeration)
-   {
-      while (enumeration.hasMoreElements())
-      {
-         list.add(enumeration.nextElement());
-      }
-   }
-   
-   /**
-    * Gets an iterator
-    * 
-    * @return The iterator
-    */
-   public Iterator<T> iterator()
-   {
-      return Iterables.unmodifiableIterable(list).iterator();
-   }
-   
-}

Copied: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationList.java (from rev 3399, ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationIterable.java)
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationList.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationList.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,54 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.util.collections;
+
+import java.util.ArrayList;
+import java.util.Enumeration;
+import java.util.List;
+
+import com.google.common.collect.ForwardingList;
+
+
+/**
+ * An Enumeration -> List adaptor
+ *  
+ * @author Pete Muir
+ */
+public class EnumerationList<T> extends ForwardingList<T>
+{
+   // The enumeration as a list
+   private final List<T> list = new ArrayList<T>();
+   
+   /**
+    * Constructor
+    * 
+    * @param enumeration The enumeration
+    */
+   public EnumerationList(Enumeration<T> enumeration)
+   {
+      while (enumeration.hasMoreElements())
+      {
+         list.add(enumeration.nextElement());
+      }
+   }
+
+   @Override
+   protected List<T> delegate()
+   {
+      return list;
+   }
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/collections/EnumerationList.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Copied: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELContext.java (from rev 3395, ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELContext.java)
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELContext.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELContext.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,110 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.util.el;
+
+import java.util.Locale;
+
+import javax.el.ELContext;
+import javax.el.ELResolver;
+import javax.el.FunctionMapper;
+import javax.el.VariableMapper;
+
+/**
+ * A forwarding class that delegates to an ELContext
+ * 
+ * @author Pete Muir
+ *
+ */
+public abstract class ForwardingELContext extends ELContext
+{
+   
+   protected abstract ELContext delgate();
+   
+   @Override
+   public ELResolver getELResolver()
+   {
+      return delgate().getELResolver();
+   }
+   
+   @Override
+   public FunctionMapper getFunctionMapper()
+   {
+      return delgate().getFunctionMapper();
+   }
+   
+   @Override
+   public VariableMapper getVariableMapper()
+   {
+      return delgate().getVariableMapper();
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delgate().equals(obj);
+   }
+   
+   @SuppressWarnings("unchecked")
+   @Override
+   public Object getContext(Class key)
+   {
+      return delgate().getContext(key);
+   }
+   
+   @Override
+   public Locale getLocale()
+   {
+      return delgate().getLocale();
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delgate().hashCode();
+   }
+   
+   @Override
+   public boolean isPropertyResolved()
+   {
+      return delgate().isPropertyResolved();
+   }
+   
+   @SuppressWarnings("unchecked")
+   @Override
+   public void putContext(Class key, Object contextObject)
+   {
+      delgate().putContext(key, contextObject);
+   }
+   
+   @Override
+   public void setLocale(Locale locale)
+   {
+      delgate().setLocale(locale);
+   }
+   
+   @Override
+   public void setPropertyResolved(boolean resolved)
+   {
+      delgate().setPropertyResolved(resolved);
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delgate().toString();
+   }
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELContext.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Copied: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELResolver.java (from rev 3395, ri/trunk/impl/src/main/java/org/jboss/webbeans/el/ForwardingELResolver.java)
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELResolver.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELResolver.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,83 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.util.el;
+
+import java.util.Iterator;
+
+import javax.el.ELContext;
+import javax.el.ELResolver;
+
+public abstract class ForwardingELResolver extends ELResolver
+{
+   
+   protected abstract ELResolver delegate();
+
+   @Override
+   public Class<?> getCommonPropertyType(ELContext context, Object base)
+   {
+      return delegate().getCommonPropertyType(context, base);
+   }
+
+   @Override
+   public Iterator<?> getFeatureDescriptors(ELContext context, Object base)
+   {
+      return delegate().getFeatureDescriptors(context, base);
+   }
+
+   @Override
+   public Class<?> getType(ELContext context, Object base, Object property)
+   {
+      return delegate().getType(context, base, property);
+   }
+
+   @Override
+   public Object getValue(ELContext context, Object base, Object property)
+   {
+      return delegate().getValue(context, base, property);
+   }
+
+   @Override
+   public boolean isReadOnly(ELContext context, Object base, Object property)
+   {
+      return delegate().isReadOnly(context, base, property);
+   }
+
+   @Override
+   public void setValue(ELContext context, Object base, Object property, Object value)
+   {
+      delegate().setValue(context, base, property, value);
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delegate().equals(obj);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delegate().hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delegate().toString();
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingELResolver.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingExpressionFactory.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingExpressionFactory.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingExpressionFactory.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,80 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.util.el;
+
+import javax.el.ELContext;
+import javax.el.ExpressionFactory;
+import javax.el.MethodExpression;
+import javax.el.ValueExpression;
+
+/**
+ * @author pmuir
+ *
+ */
+public abstract class ForwardingExpressionFactory extends ExpressionFactory
+{
+
+   protected abstract ExpressionFactory delegate();
+   
+   
+   @SuppressWarnings("unchecked")
+   @Override
+   public Object coerceToType(Object obj, Class targetType)
+   {
+      return delegate().coerceToType(obj, targetType);
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public MethodExpression createMethodExpression(ELContext context, String expression, Class expectedReturnType, Class[] expectedParamTypes)
+   {
+      return delegate().createMethodExpression(context, expression, expectedReturnType, expectedParamTypes);
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public ValueExpression createValueExpression(Object instance, Class expectedType)
+   {
+      return delegate().createValueExpression(instance, expectedType);
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public ValueExpression createValueExpression(ELContext context, String expression, Class expectedType)
+   {
+      return delegate().createValueExpression(context, expression, expectedType);
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delegate().equals(obj);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delegate().hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delegate().toString();
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingExpressionFactory.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingMethodExpression.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingMethodExpression.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingMethodExpression.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,77 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.util.el;
+
+import javax.el.ELContext;
+import javax.el.MethodExpression;
+import javax.el.MethodInfo;
+
+/**
+ * @author pmuir
+ *
+ */
+public abstract class ForwardingMethodExpression extends MethodExpression
+{
+   
+   private static final long serialVersionUID = -2614033937482335044L;
+
+   protected abstract MethodExpression delegate();
+
+   @Override
+   public MethodInfo getMethodInfo(ELContext context)
+   {
+      return delegate().getMethodInfo(context);
+   }
+
+   @Override
+   public Object invoke(ELContext context, Object[] params)
+   {
+      return delegate().invoke(context, params);
+   }
+
+   @Override
+   public String getExpressionString()
+   {
+      return delegate().getExpressionString();
+   }
+
+   @Override
+   public boolean isLiteralText()
+   {
+      return delegate().isLiteralText();
+   }
+   
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delegate().equals(obj);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delegate().hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delegate().toString();
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingMethodExpression.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingValueExpression.java
===================================================================
--- ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingValueExpression.java	                        (rev 0)
+++ ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingValueExpression.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,95 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.webbeans.util.el;
+
+import javax.el.ELContext;
+import javax.el.ValueExpression;
+
+/**
+ * @author pmuir
+ *
+ */
+public abstract class ForwardingValueExpression extends ValueExpression
+{
+
+   private static final long serialVersionUID = -2318681808639242038L;
+   
+   protected abstract ValueExpression delegate();
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public Class getExpectedType()
+   {
+      return delegate().getExpectedType();
+   }
+
+   @SuppressWarnings("unchecked")
+   @Override
+   public Class getType(ELContext context)
+   {
+      return delegate().getType(context);
+   }
+
+   @Override
+   public Object getValue(ELContext context)
+   {
+      return delegate().getValue(context);
+   }
+
+   @Override
+   public boolean isReadOnly(ELContext context)
+   {
+      return delegate().isReadOnly(context);
+   }
+
+   @Override
+   public void setValue(ELContext context, Object value)
+   {
+      delegate().setValue(context, value);
+   }
+
+   @Override
+   public String getExpressionString()
+   {
+      return delegate().getExpressionString();
+   }
+
+   @Override
+   public boolean isLiteralText()
+   {
+      return delegate().isLiteralText();
+   }   
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      return delegate().equals(obj);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return delegate().hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return delegate().toString();
+   }
+
+}


Property changes on: ri/trunk/impl/src/main/java/org/jboss/webbeans/util/el/ForwardingValueExpression.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/BeanDeploymentArchive.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/BeanDeploymentArchive.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/BeanDeploymentArchive.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -17,7 +17,7 @@
 package org.jboss.webbeans.bootstrap.spi;
 
 import java.net.URL;
-import java.util.List;
+import java.util.Collection;
 
 import org.jboss.webbeans.ejb.spi.EjbDescriptor;
 
@@ -48,23 +48,24 @@
 {
 
    /**
-    * Get the ordered bean deployment archives which are accessible to this bean
+    * Get the bean deployment archives which are accessible to this bean
     * deployment archive and adjacent to it in the deployment archive graph.
     * 
-    * The bean deployment archives will be processed in the order specified.
+    * Cycles in the accessible BeanDeploymentArchive graph are allowed. If a 
+    * cycle is detected by Web Beans, it will be automatically removed by Web
+    * Beans. This means any implementor of this interface don't need to worry
+    * about circularities.
     * 
-    * Circular dependencies will be detected and ignored by the container
-    * 
-    * @return the ordered accessible bean deployment archives
+    * @return the accessible bean deployment archives
     */
-   public List<BeanDeploymentArchive> getBeanDeploymentArchives();
+   public Collection<BeanDeploymentArchive> getBeanDeploymentArchives();
 
    /**
     * Gets all classes in the bean deployment archive
     * 
-    * @return an iteration over the classes, empty if no classes are present
+    * @return the classes, empty if no classes are present
     */
-   public Iterable<Class<?>> getBeanClasses();
+   public Collection<Class<?>> getBeanClasses();
 
    /**
     * Get any deployment descriptors in the bean deployment archive.
@@ -74,17 +75,17 @@
     * however it is permitted to return other deployment descriptors defined
     * using other methods.
     * 
-    * @return an iteration over the URLs pointing to the deployment descriptor,
+    * @return the URLs pointing to the deployment descriptor,
     *         or an empty set if none are present
     */
-   public Iterable<URL> getBeansXml();
+   public Collection<URL> getBeansXml();
 
    /**
     * Get all the EJBs in the deployment archive
     * 
-    * @return an iteration of the EJBs, or empty if no EJBs are present or if
+    * @return the EJBs, or empty if no EJBs are present or if
     *         this is not an EJB archive
     */
-   public Iterable<EjbDescriptor<?>> getEjbs();
+   public Collection<EjbDescriptor<?>> getEjbs();
 
 }

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/Deployment.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/Deployment.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/Deployment.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -16,7 +16,7 @@
  */
 package org.jboss.webbeans.bootstrap.spi;
 
-import java.util.List;
+import java.util.Collection;
 
 import org.jboss.webbeans.bootstrap.api.Service;
 
@@ -119,18 +119,15 @@
     * Get the bean deployment archives which are accessible by this deployment
     * and adjacent to it in the deployment archive graph.
     * 
-    * The bean deployment archives will be processed in using the natural order
-    * of the list.
-    * 
     * Cycles in the accessible BeanDeploymentArchive graph are allowed. If a 
     * cycle is detected by Web Beans, it will be automatically removed by Web
     * Beans. This means any implementor of this interface don't need to worry
     * about circularities.
     * 
-    * @return the ordered accessible bean deployment archives
+    * @return the accessible bean deployment archives
     * 
     */
-   public List<BeanDeploymentArchive> getBeanDeploymentArchives();
+   public Collection<BeanDeploymentArchive> getBeanDeploymentArchives();
 
    /**
     * Load the {@link BeanDeploymentArchive} containing the given class.

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/helpers/ForwardingWebBeanDiscovery.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/helpers/ForwardingWebBeanDiscovery.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/bootstrap/spi/helpers/ForwardingWebBeanDiscovery.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -14,6 +14,7 @@
  * @author Pete Muir
  *
  */
+ at Deprecated
 public abstract class ForwardingWebBeanDiscovery implements WebBeanDiscovery
 {
    

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/BeanStore.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/BeanStore.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/BeanStore.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -17,6 +17,8 @@
 
 package org.jboss.webbeans.context.api;
 
+import java.util.Collection;
+
 import javax.enterprise.context.spi.Contextual;
 
 
@@ -42,11 +44,11 @@
    public abstract void clear();
 
    /**
-    * Returns an iteration over the current contextual instances in the store
+    * Returns the current contextual instances in the store
     * 
-    * @return the iteration
+    * @return the instances
     */
-   public abstract Iterable<Contextual<?>> getContextuals();
+   public abstract Collection<Contextual<?>> getContextuals();
 
    /**
     * Adds a bean instance to the storage

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/helpers/ForwardingBeanStore.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/helpers/ForwardingBeanStore.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/context/api/helpers/ForwardingBeanStore.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,9 +1,11 @@
 package org.jboss.webbeans.context.api.helpers;
 
+import java.util.Collection;
+
 import javax.enterprise.context.spi.Contextual;
 
+import org.jboss.webbeans.context.api.BeanStore;
 import org.jboss.webbeans.context.api.ContexutalInstance;
-import org.jboss.webbeans.context.api.BeanStore;
 
 public abstract class ForwardingBeanStore implements BeanStore
 {
@@ -20,7 +22,7 @@
       return delegate().get(bean);
    }
    
-   public Iterable<Contextual<? extends Object>> getContextuals()
+   public Collection<Contextual<? extends Object>> getContextuals()
    {
       return delegate().getContextuals();
    }

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/EjbDescriptor.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/EjbDescriptor.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/EjbDescriptor.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,6 +18,7 @@
 package org.jboss.webbeans.ejb.spi;
 
 import java.lang.reflect.Method;
+import java.util.Collection;
 
 
 /**
@@ -42,14 +43,14 @@
     * 
     * @return An iterator over the local business interfaces
     */
-   public Iterable<BusinessInterfaceDescriptor<?>> getLocalBusinessInterfaces();
+   public Collection<BusinessInterfaceDescriptor<?>> getLocalBusinessInterfaces();
    
    /**
     * Get the remove methods of the EJB
     * 
     * @return An iterator over the remove methods
     */
-   public Iterable<Method> getRemoveMethods();
+   public Collection<Method> getRemoveMethods();
 
    /**
     * Indicates if the bean is a stateless session bean 

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/helpers/ForwardingEjbDescriptor.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/helpers/ForwardingEjbDescriptor.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/ejb/spi/helpers/ForwardingEjbDescriptor.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,6 +1,7 @@
 package org.jboss.webbeans.ejb.spi.helpers;
 
 import java.lang.reflect.Method;
+import java.util.Collection;
 
 import org.jboss.webbeans.ejb.spi.BusinessInterfaceDescriptor;
 import org.jboss.webbeans.ejb.spi.EjbDescriptor;
@@ -21,12 +22,12 @@
    
    protected abstract EjbDescriptor<T> delegate();
       
-   public Iterable<BusinessInterfaceDescriptor<?>> getLocalBusinessInterfaces()
+   public Collection<BusinessInterfaceDescriptor<?>> getLocalBusinessInterfaces()
    {
       return delegate().getLocalBusinessInterfaces();
    }
    
-   public Iterable<Method> getRemoveMethods()
+   public Collection<Method> getRemoveMethods()
    {
       return delegate().getRemoveMethods();
    }

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/ResourceLoader.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/ResourceLoader.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/ResourceLoader.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,6 +18,7 @@
 package org.jboss.webbeans.resources.spi;
 
 import java.net.URL;
+import java.util.Collection;
 
 import org.jboss.webbeans.bootstrap.api.Service;
 
@@ -54,8 +55,8 @@
     * Gets resources as URLs by name
     * 
     * @param name The name of the resource
-    * @return An iterable reference to the URLS
+    * @return references to the URLS
     */
-   public Iterable<URL> getResources(String name);
+   public Collection<URL> getResources(String name);
    
 }

Modified: ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/helpers/ForwardingResourceLoader.java
===================================================================
--- ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/helpers/ForwardingResourceLoader.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/main/java/org/jboss/webbeans/resources/spi/helpers/ForwardingResourceLoader.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,6 +1,7 @@
 package org.jboss.webbeans.resources.spi.helpers;
 
 import java.net.URL;
+import java.util.Collection;
 
 import org.jboss.webbeans.resources.spi.ResourceLoader;
 
@@ -29,7 +30,7 @@
       return delegate().getResource(name);
    }
    
-   public Iterable<URL> getResources(String name)
+   public Collection<URL> getResources(String name)
    {
       return delegate().getResources(name);
    }

Modified: ri/trunk/spi/src/test/java/org/jboss/webbeans/bootstrap/api/test/MockResourceLoader.java
===================================================================
--- ri/trunk/spi/src/test/java/org/jboss/webbeans/bootstrap/api/test/MockResourceLoader.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/spi/src/test/java/org/jboss/webbeans/bootstrap/api/test/MockResourceLoader.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,6 +1,7 @@
 package org.jboss.webbeans.bootstrap.api.test;
 
 import java.net.URL;
+import java.util.Collection;
 
 import org.jboss.webbeans.resources.spi.ResourceLoader;
 
@@ -17,7 +18,7 @@
       return null;
    }
    
-   public Iterable<URL> getResources(String name)
+   public Collection<URL> getResources(String name)
    {
       return null;
    }

Modified: ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockBeanDeploymentArchive.java
===================================================================
--- ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockBeanDeploymentArchive.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockBeanDeploymentArchive.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,6 +18,7 @@
 
 import java.net.URL;
 import java.util.ArrayList;
+import java.util.Collection;
 import java.util.Collections;
 import java.util.HashSet;
 import java.util.List;
@@ -39,23 +40,27 @@
 {
    
 
-   private Iterable<Class<?>> beanClasses = new HashSet<Class<?>>();
+   private Set<Class<?>> beanClasses = new HashSet<Class<?>>();
 
-   private Iterable<URL> webBeansXmlFiles = new HashSet<URL>();
+   private Collection<URL> webBeansXmlFiles = new HashSet<URL>();
 
-   public Iterable<Class<?>> getBeanClasses()
+   public Collection<Class<?>> getBeanClasses()
    {
       return beanClasses;
    }
 
-   public Iterable<URL> getBeansXml()
+   public Collection<URL> getBeansXml()
    {
       return webBeansXmlFiles;
    }
    
    public void setWebBeansXmlFiles(Iterable<URL> webBeansXmlFiles)
    {
-      this.webBeansXmlFiles = webBeansXmlFiles;
+      this.webBeansXmlFiles.clear();
+      for (URL url : webBeansXmlFiles)
+      {
+         this.webBeansXmlFiles.add(url);
+      }
    }
 
    public List<BeanDeploymentArchive> getBeanDeploymentArchives()
@@ -67,7 +72,11 @@
 
    public void setBeanClasses(Iterable<Class<?>> beanClasses)
    {
-      this.beanClasses = beanClasses;
+      this.beanClasses.clear();
+      for (Class<?> clazz : beanClasses)
+      {
+         this.beanClasses.add(clazz);
+      }
       ejbs = new ArrayList<EjbDescriptor<?>>();
       for (Class<?> ejbClass : discoverEjbs(getBeanClasses()))
       {
@@ -75,7 +84,7 @@
       }
    }
    
-   public Iterable<EjbDescriptor<?>> getEjbs()
+   public Collection<EjbDescriptor<?>> getEjbs()
    {
       return ejbs;
    }

Modified: ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockEjbDescriptor.java
===================================================================
--- ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockEjbDescriptor.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockEjbDescriptor.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,6 +18,7 @@
 
 import java.lang.reflect.Method;
 import java.util.ArrayList;
+import java.util.Collection;
 import java.util.Collections;
 import java.util.HashSet;
 import java.util.List;
@@ -105,7 +106,7 @@
       return ejbName;
    }
 
-   public Iterable<BusinessInterfaceDescriptor<?>> getLocalBusinessInterfaces()
+   public Collection<BusinessInterfaceDescriptor<?>> getLocalBusinessInterfaces()
    {
       return localInterfaces;
    }
@@ -115,7 +116,7 @@
       return Collections.emptyList();
    }
 
-   public Iterable<Method> getRemoveMethods()
+   public Collection<Method> getRemoveMethods()
    {
 
       return removeMethods;

Modified: ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockResourceLoader.java
===================================================================
--- ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockResourceLoader.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/MockResourceLoader.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,10 +18,11 @@
 
 import java.io.IOException;
 import java.net.URL;
+import java.util.Collection;
 
 import org.jboss.webbeans.resources.spi.ResourceLoader;
 import org.jboss.webbeans.resources.spi.ResourceLoadingException;
-import org.jboss.webbeans.util.collections.EnumerationIterable;
+import org.jboss.webbeans.util.collections.EnumerationList;
 
 public class MockResourceLoader implements ResourceLoader
 {
@@ -43,11 +44,11 @@
       return Thread.currentThread().getContextClassLoader().getResource(name);
    }
    
-   public Iterable<URL> getResources(String name)
+   public Collection<URL> getResources(String name)
    {
       try
       {
-         return new EnumerationIterable<URL>(Thread.currentThread().getContextClassLoader().getResources(name));
+         return new EnumerationList<URL>(Thread.currentThread().getContextClassLoader().getResources(name));
       }
       catch (IOException e)
       {

Modified: ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/el/EL.java
===================================================================
--- ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/el/EL.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/tests/src/main/java/org/jboss/webbeans/mock/el/EL.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -20,6 +20,8 @@
 import javax.el.BeanELResolver;
 import javax.el.CompositeELResolver;
 import javax.el.ELContext;
+import javax.el.ELContextEvent;
+import javax.el.ELContextListener;
 import javax.el.ELResolver;
 import javax.el.ExpressionFactory;
 import javax.el.FunctionMapper;
@@ -28,7 +30,9 @@
 import javax.el.ResourceBundleELResolver;
 import javax.el.VariableMapper;
 
+import org.jboss.webbeans.el.WebBeansELContextListener;
 import org.jboss.webbeans.el.WebBeansELResolver;
+import org.jboss.webbeans.el.WebBeansExpressionFactory;
 
 import com.sun.el.ExpressionFactoryImpl;
 import com.sun.el.lang.FunctionMapperImpl;
@@ -44,8 +48,10 @@
 {
    public static final ELResolver EL_RESOLVER = createELResolver();
    
-   public static final ExpressionFactory EXPRESSION_FACTORY = new ExpressionFactoryImpl();
+   public static final ExpressionFactory EXPRESSION_FACTORY = new WebBeansExpressionFactory(new ExpressionFactoryImpl());
    
+   public static final ELContextListener[] EL_CONTEXT_LISTENERS = { new WebBeansELContextListener() };
+   
    private static ELResolver createELResolver()
    {
       CompositeELResolver resolver = new CompositeELResolver();
@@ -64,7 +70,7 @@
    
    public static ELContext createELContext(final ELResolver resolver, final FunctionMapper functionMapper)
    {
-      return new ELContext()
+      ELContext context = new ELContext()
       {
          final VariableMapperImpl variableMapper = new VariableMapperImpl();
 
@@ -87,6 +93,17 @@
          }
          
       };
+      callELContextListeners(context);
+      return context;
    }
    
+   public static void callELContextListeners(ELContext context)
+   {
+      ELContextEvent event = new ELContextEvent(context);
+      for (ELContextListener listener : EL_CONTEXT_LISTENERS)
+      {
+         listener.contextCreated(event);
+      }
+   }
+   
 }

Modified: ri/trunk/tests/src/main/java/org/jboss/webbeans/test/AbstractWebBeansTest.java
===================================================================
--- ri/trunk/tests/src/main/java/org/jboss/webbeans/test/AbstractWebBeansTest.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/tests/src/main/java/org/jboss/webbeans/test/AbstractWebBeansTest.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -21,7 +21,7 @@
 import org.jboss.webbeans.BeanManagerImpl;
 import org.jboss.webbeans.CurrentManager;
 import org.jboss.webbeans.mock.el.EL;
-import org.jboss.webbeans.util.collections.EnumerationIterable;
+import org.jboss.webbeans.util.collections.EnumerationList;
 import org.testng.ITestContext;
 import org.testng.annotations.BeforeSuite;
 
@@ -81,7 +81,7 @@
       }
       try
       {
-         return new EnumerationIterable<URL>(getClass().getClassLoader().getResources(name));
+         return new EnumerationList<URL>(getClass().getClassLoader().getResources(name));
       }
       catch (IOException e)
       {

Modified: ri/trunk/version-matrix/pom.xml
===================================================================
--- ri/trunk/version-matrix/pom.xml	2009-08-07 11:28:32 UTC (rev 3403)
+++ ri/trunk/version-matrix/pom.xml	2009-08-07 13:02:37 UTC (rev 3404)
@@ -113,6 +113,12 @@
          </dependency>
 
          <dependency>
+            <groupId>javax.servlet.jsp</groupId>
+            <artifactId>jsp-api</artifactId>
+            <version>2.1</version>
+  	 </dependency>
+
+         <dependency>
             <groupId>javax.transaction</groupId>
             <artifactId>jta</artifactId>
             <version>1.0.1B</version>

Modified: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/passivating/broken27/EnterpriseBeanWithNonPassivatingDecoratorTest.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/passivating/broken27/EnterpriseBeanWithNonPassivatingDecoratorTest.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/context/passivating/broken27/EnterpriseBeanWithNonPassivatingDecoratorTest.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -18,7 +18,7 @@
 @SpecVersion("20090625")
 public class EnterpriseBeanWithNonPassivatingDecoratorTest extends AbstractJSR299Test
 {
-   @Test(groups = { "contexts", "passivation", "integration"})
+   @Test(groups = { "contexts", "passivation", "integration", "ri-broken"})
    @SpecAssertion(section = "6.6.4", id = "hb")
    public void testEnterpriseBeanWithNonPassivatingDecoratorFails()
    {

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/CowShed.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/CowShed.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/CowShed.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.broken.delegateProducerMethod;
+
+import javax.enterprise.inject.Current;
+
+/**
+ * @author pmuir
+ *
+ */
+public class CowShed
+{
+   
+   public static final String MESSAGE = "cowShed";
+
+   @Current Logger logger;
+
+   public void milk()
+   {
+      logger.log(MESSAGE);
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/CowShed.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/DelegateInjectionPointTest.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/DelegateInjectionPointTest.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/DelegateInjectionPointTest.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,49 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.broken.delegateProducerMethod;
+
+import org.jboss.jsr299.tck.AbstractJSR299Test;
+import org.jboss.jsr299.tck.DefinitionError;
+import org.jboss.test.audit.annotations.SpecAssertion;
+import org.jboss.test.audit.annotations.SpecAssertions;
+import org.jboss.test.audit.annotations.SpecVersion;
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.ExpectedDeploymentException;
+import org.jboss.testharness.impl.packaging.jsr299.BeansXml;
+import org.testng.annotations.Test;
+
+/**
+ * @author pmuir
+ *
+ */
+ at Artifact
+ at BeansXml("beans.xml")
+ at SpecVersion("20090625")
+ at ExpectedDeploymentException(DefinitionError.class)
+public class DelegateInjectionPointTest extends AbstractJSR299Test
+{
+
+   @Test
+   @SpecAssertions({
+      @SpecAssertion(section="8.1.2", id="cf")
+   })
+   public void testDecoratorDelegateInjectionPoints()
+   {
+      assert false;
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/DelegateInjectionPointTest.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/Logger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/Logger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/Logger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.broken.delegateProducerMethod;
+
+
+/**
+ * @author pmuir
+ *
+ */
+public interface Logger
+{
+
+   public void log(String string);
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/Logger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/MockLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/MockLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/MockLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,32 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.broken.delegateProducerMethod;
+
+/**
+ * @author pmuir
+ *
+ */
+public class MockLogger implements Logger
+{
+
+   
+
+   public void log(String string)
+   {
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/MockLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/TimestampLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/TimestampLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/TimestampLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.broken.delegateProducerMethod;
+
+import javax.decorator.Decorates;
+import javax.decorator.Decorator;
+import javax.enterprise.inject.Produces;
+
+
+/**
+ * @author pmuir
+ *
+ */
+ at Decorator
+public class TimestampLogger
+{
+   
+   @Produces
+   public String setLogger(@Decorates Logger logger)
+   {
+      return "";
+   }
+   
+   public void log(String message)
+   {
+      
+   }
+
+
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/TimestampLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/CowShed.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/CowShed.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/CowShed.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateConstructor;
+
+import javax.enterprise.inject.Current;
+
+/**
+ * @author pmuir
+ *
+ */
+public class CowShed
+{
+   
+   public static final String MESSAGE = "cowShed";
+
+   @Current Logger logger;
+
+   public void milk()
+   {
+      logger.log(MESSAGE);
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/CowShed.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/DelegateInjectionPointTest.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/DelegateInjectionPointTest.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/DelegateInjectionPointTest.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateConstructor;
+
+import org.jboss.jsr299.tck.AbstractJSR299Test;
+import org.jboss.test.audit.annotations.SpecAssertion;
+import org.jboss.test.audit.annotations.SpecAssertions;
+import org.jboss.test.audit.annotations.SpecVersion;
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.jsr299.BeansXml;
+import org.testng.annotations.Test;
+
+/**
+ * @author pmuir
+ *
+ */
+ at Artifact
+ at BeansXml("beans.xml")
+ at SpecVersion("20090625")
+public class DelegateInjectionPointTest extends AbstractJSR299Test
+{
+
+   @Test
+   @SpecAssertions({
+      @SpecAssertion(section="8.1.2", id="ce")
+   })
+   public void testDecoratorDelegateInjectionPoints()
+   {
+      TimestampLogger.reset();
+      MockLogger.reset();
+      getInstanceByType(CowShed.class).milk();
+      assert TimestampLogger.getConstructor() != null;
+      assert MockLogger.getMessage().equals(TimestampLogger.PREFIX + CowShed.MESSAGE); 
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/DelegateInjectionPointTest.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/Logger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/Logger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/Logger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateConstructor;
+
+
+/**
+ * @author pmuir
+ *
+ */
+public interface Logger
+{
+
+   public void log(String string);
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/Logger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/MockLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/MockLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/MockLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateConstructor;
+
+/**
+ * @author pmuir
+ *
+ */
+public class MockLogger implements Logger
+{
+
+   private static String message = "";
+
+   public void log(String string)
+   {
+      message = string;
+   }
+
+   public static void reset()
+   {
+      message = null;
+   }
+   
+   /**
+    * @return the message
+    */
+   public static String getMessage()
+   {
+      return message;
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/MockLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/TimestampLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/TimestampLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/TimestampLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,64 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateConstructor;
+
+import javax.decorator.Decorates;
+import javax.decorator.Decorator;
+import javax.enterprise.inject.Initializer;
+
+
+/**
+ * @author pmuir
+ *
+ */
+ at Decorator
+public class TimestampLogger
+{
+   
+   public static final String PREFIX = TimestampLogger.class.getSimpleName();
+   
+   private static Logger constructor;
+   
+   @Initializer
+   public TimestampLogger(@Decorates Logger logger)
+   {
+      constructor = logger;
+   }
+   
+   public void log(String message)
+   {
+      constructor.log(PREFIX + message);
+   }
+   
+   /**
+    * @return the constructor
+    */
+   public static Logger getConstructor()
+   {
+      return constructor;
+   }
+   
+   /**
+    * @param message the message to set
+    */
+   public static void reset()
+   {
+      constructor = null;
+   }
+
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/TimestampLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/CowShed.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/CowShed.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/CowShed.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateField;
+
+import javax.enterprise.inject.Current;
+
+/**
+ * @author pmuir
+ *
+ */
+public class CowShed
+{
+   
+   public static final String MESSAGE = "cowShed";
+
+   @Current Logger logger;
+
+   public void milk()
+   {
+      logger.log(MESSAGE);
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/CowShed.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/DelegateFieldInjectionPointTest.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/DelegateFieldInjectionPointTest.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/DelegateFieldInjectionPointTest.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateField;
+
+import org.jboss.jsr299.tck.AbstractJSR299Test;
+import org.jboss.test.audit.annotations.SpecAssertion;
+import org.jboss.test.audit.annotations.SpecAssertions;
+import org.jboss.test.audit.annotations.SpecVersion;
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.jsr299.BeansXml;
+import org.testng.annotations.Test;
+
+/**
+ * @author pmuir
+ *
+ */
+ at Artifact
+ at BeansXml("beans.xml")
+ at SpecVersion("20090625")
+public class DelegateFieldInjectionPointTest extends AbstractJSR299Test
+{
+
+   @Test
+   @SpecAssertions({
+      @SpecAssertion(section="8.1.2", id="cc")
+   })
+   public void testDecoratorDelegateInjectionPoints()
+   {
+      TimestampLogger.reset();
+      MockLogger.reset();
+      getInstanceByType(CowShed.class).milk();
+      assert TimestampLogger.getField() != null;
+      assert MockLogger.getMessage().equals(TimestampLogger.PREFIX + CowShed.MESSAGE);
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/DelegateFieldInjectionPointTest.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/Logger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/Logger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/Logger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateField;
+
+
+/**
+ * @author pmuir
+ *
+ */
+public interface Logger
+{
+
+   public void log(String string);
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/Logger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/MockLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/MockLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/MockLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateField;
+
+/**
+ * @author pmuir
+ *
+ */
+public class MockLogger implements Logger
+{
+
+   private static String message = "";
+
+   public void log(String string)
+   {
+      message = string;
+   }
+
+   public static void reset()
+   {
+      message = null;
+   }
+   
+   /**
+    * @return the message
+    */
+   public static String getMessage()
+   {
+      return message;
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/MockLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/TimestampLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/TimestampLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/TimestampLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,61 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateField;
+
+import javax.decorator.Decorates;
+import javax.decorator.Decorator;
+
+
+/**
+ * @author pmuir
+ *
+ */
+ at Decorator
+public class TimestampLogger
+{
+   
+   public static final String PREFIX = TimestampLogger.class.getSimpleName();
+   
+   @Decorates
+   private Logger instanceField;
+   
+   private static Logger field;
+   
+   public void log(String message)
+   {
+      field = instanceField;
+      field.log(PREFIX + message);
+   }
+   
+   /**
+    * @return the field
+    */
+   public static Logger getField()
+   {
+      return field;
+   }
+   
+   /**
+    * @param message the message to set
+    */
+   public static void reset()
+   {
+      field = null;
+   }
+
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/TimestampLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/CowShed.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/CowShed.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/CowShed.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateInitializerMethod;
+
+import javax.enterprise.inject.Current;
+
+/**
+ * @author pmuir
+ *
+ */
+public class CowShed
+{
+   
+   public static final String MESSAGE = "cowShed";
+
+   @Current Logger logger;
+
+   public void milk()
+   {
+      logger.log(MESSAGE);
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/CowShed.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/DelegateInjectionPointTest.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/DelegateInjectionPointTest.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/DelegateInjectionPointTest.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateInitializerMethod;
+
+import org.jboss.jsr299.tck.AbstractJSR299Test;
+import org.jboss.test.audit.annotations.SpecAssertion;
+import org.jboss.test.audit.annotations.SpecAssertions;
+import org.jboss.test.audit.annotations.SpecVersion;
+import org.jboss.testharness.impl.packaging.Artifact;
+import org.jboss.testharness.impl.packaging.jsr299.BeansXml;
+import org.testng.annotations.Test;
+
+/**
+ * @author pmuir
+ *
+ */
+ at Artifact
+ at BeansXml("beans.xml")
+ at SpecVersion("20090625")
+public class DelegateInjectionPointTest extends AbstractJSR299Test
+{
+
+   @Test
+   @SpecAssertions({
+      @SpecAssertion(section="8.1.2", id="cd")
+   })
+   public void testDecoratorDelegateInjectionPoints()
+   {
+      TimestampLogger.reset();
+      MockLogger.reset();
+      getInstanceByType(CowShed.class).milk();
+      assert TimestampLogger.getInitializerMethod() != null;
+      assert MockLogger.getMessage().equals(TimestampLogger.PREFIX + CowShed.MESSAGE);
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/DelegateInjectionPointTest.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/Logger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/Logger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/Logger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,29 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateInitializerMethod;
+
+
+/**
+ * @author pmuir
+ *
+ */
+public interface Logger
+{
+
+   public void log(String string);
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/Logger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/MockLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/MockLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/MockLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateInitializerMethod;
+
+/**
+ * @author pmuir
+ *
+ */
+public class MockLogger implements Logger
+{
+
+   private static String message = "";
+
+   public void log(String string)
+   {
+      message = string;
+   }
+
+   public static void reset()
+   {
+      message = null;
+   }
+   
+   /**
+    * @return the message
+    */
+   public static String getMessage()
+   {
+      return message;
+   }
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/MockLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/TimestampLogger.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/TimestampLogger.java	                        (rev 0)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/TimestampLogger.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,64 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,  
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateInitializerMethod;
+
+import javax.decorator.Decorates;
+import javax.decorator.Decorator;
+import javax.enterprise.inject.Initializer;
+
+
+/**
+ * @author pmuir
+ *
+ */
+ at Decorator
+public class TimestampLogger
+{
+   
+   public static final String PREFIX = TimestampLogger.class.getSimpleName();
+   
+   private static Logger initializerMethod;
+   
+   @Initializer
+   public void setLogger(@Decorates Logger logger)
+   {
+      initializerMethod = logger;
+   }
+   
+   public void log(String message)
+   {
+      initializerMethod.log(PREFIX + message);
+   }
+   
+   /**
+    * @return the initializerMethod
+    */
+   public static Logger getInitializerMethod()
+   {
+      return initializerMethod;
+   }
+   
+   /**
+    * @param message the message to set
+    */
+   public static void reset()
+   {
+      initializerMethod = null;
+   }
+
+
+}


Property changes on: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/TimestampLogger.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Modified: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/Game.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/Game.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/Game.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -4,14 +4,16 @@
 import javax.enterprise.inject.Named;
 
 @Named
-class Game
+public class Game
 {
    @Initializer
    public void initialize(Counter counter) {
       counter.add();
    }
    
-   public boolean getValue() {
-      return true;
+   public String getValue() 
+   {
+      return "foo";
    }
+   
 }

Modified: tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/ResolutionByNameTest.java
===================================================================
--- tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/ResolutionByNameTest.java	2009-08-07 11:28:32 UTC (rev 3403)
+++ tck/trunk/impl/src/main/java/org/jboss/jsr299/tck/tests/lookup/el/ResolutionByNameTest.java	2009-08-07 13:02:37 UTC (rev 3404)
@@ -20,10 +20,10 @@
 import javax.enterprise.context.spi.Context;
 import javax.enterprise.inject.spi.Bean;
 
+import org.jboss.jsr299.tck.AbstractJSR299Test;
 import org.jboss.test.audit.annotations.SpecAssertion;
 import org.jboss.test.audit.annotations.SpecAssertions;
 import org.jboss.test.audit.annotations.SpecVersion;
-import org.jboss.jsr299.tck.AbstractJSR299Test;
 import org.jboss.testharness.impl.packaging.Artifact;
 import org.testng.annotations.Test;
 
@@ -32,12 +32,11 @@
 public class ResolutionByNameTest extends AbstractJSR299Test
 {
    
-   @Test(groups="ri-broken")
+   @Test
    @SpecAssertion(section="5.8", id="c")
-   //WBRI-322
    public void testQualifiedNameLookup()
    {
-      assert getCurrentConfiguration().getEl().evaluateValueExpression("#{(game.value and game.value) ? game.value : false}", Boolean.class);
+      assert getCurrentConfiguration().getEl().evaluateValueExpression("#{(game.value == 'foo' and game.value == 'foo') ? game.value == 'foo' : false}", Boolean.class);
       assert getInstanceByType(Counter.class).getCount() == 1;
    }
 

Added: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/beans.xml
===================================================================
--- tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/beans.xml	                        (rev 0)
+++ tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/beans.xml	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,5 @@
+<beans> 
+   <decorators>
+      <class>org.jboss.jsr299.tck.tests.decorators.definition.inject.broken.delegateProducerMethod.TimestampLogger</class>
+   </decorators>
+</beans>


Property changes on: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/broken/delegateProducerMethod/beans.xml
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/beans.xml
===================================================================
--- tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/beans.xml	                        (rev 0)
+++ tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/beans.xml	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,5 @@
+<beans> 
+   <decorators>
+      <class>org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateConstructor.TimestampLogger</class>
+   </decorators>
+</beans>


Property changes on: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateConstructor/beans.xml
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/beans.xml
===================================================================
--- tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/beans.xml	                        (rev 0)
+++ tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/beans.xml	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,5 @@
+<beans> 
+   <decorators>
+      <class>org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateField.TimestampLogger</class>
+   </decorators>
+</beans>


Property changes on: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateField/beans.xml
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Added: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/beans.xml
===================================================================
--- tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/beans.xml	                        (rev 0)
+++ tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/beans.xml	2009-08-07 13:02:37 UTC (rev 3404)
@@ -0,0 +1,5 @@
+<beans> 
+   <decorators>
+      <class>org.jboss.jsr299.tck.tests.decorators.definition.inject.delegateInitializerMethod.TimestampLogger</class>
+   </decorators>
+</beans>


Property changes on: tck/trunk/impl/src/main/resources/org/jboss/jsr299/tck/tests/decorators/definition/inject/delegateInitializerMethod/beans.xml
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Modified: tck/trunk/impl/src/main/resources/tck-audit.xml
===================================================================
--- tck/trunk/impl/src/main/resources/tck-audit.xml	2009-08-07 11:28:32 UTC (rev 3403)
+++ tck/trunk/impl/src/main/resources/tck-audit.xml	2009-08-07 13:02:37 UTC (rev 3404)
@@ -1,7 +1,7 @@
 <specification
     xmlns="http://jboss.com/products/webbeans/tck/audit"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://jboss.com/products/webbeans/tck/audit http://snapshots.jboss.org/maven2/org/hibernate/tck-utils-api/0.9-SNAPSHOT/tck-utils-api-0.9-20090220.134140-13-audit.xsd"
+    xsi:schemaLocation="http://jboss.com/products/webbeans/tck/audit /Users/pmuir/workspace/jboss-test-audit/api/src/main/resources/tck-audit.xsd"
     name="JSR-299: Java Contexts and Dependency Injection"
     version="20090625">
 
@@ -3551,19 +3551,28 @@
       <text>A decorator must have exactly one delegate injection point. If a decorator ~has more than one delegate injection point, or~ does not have a delegate injection point, the container automatically detects the problem and treats it as a definition error, as defined in Section 12.4, "Problems detected automatically by the container".</text>
     </assertion>
     
-    <assertion id="cc">
-      <text>The delegate injection point must be an injected field, ~initializer method parameter or bean constructor method parameter~. If an injection point that is not an injected field, ~initializer method parameter or bean constructor method parameter ~is annotated |@Decorates|, the container automatically detects the problem and treats it as a definition error, as defined in Section 12.4, "Problems detected automatically by the container".</text>
-    </assertion>
+    <group>
+      <text>The delegate injection point must be an injected field, initializer method parameter or bean constructor method parameter. If an injection point that is not an injected field, initializer method parameter or bean constructor method parameter is annotated |@Decorates|, the container automatically detects the problem and treats it as a definition error, as defined in Section 12.4, "Problems detected automatically by the container".</text>
     
-    <assertion id="cd">
-      <text>The delegate injection point must be an ~injected field~, initializer method parameter or ~bean constructor method parameter~. If an injection point that is not an ~injected field~, initializer method parameter or ~bean constructor method parameter ~is annotated |@Decorates|, the container automatically detects the problem and treats it as a definition error, as defined in Section 12.4, "Problems detected automatically by the container".</text>
-    </assertion>
+      <assertion id="cc">
+        <text>Check an injected field is ok</text>
+      </assertion>
     
-    <assertion id="ce">
-      <text>The delegate injection point must be an ~injected field, initializer method parameter~ or bean constructor method parameter. If an injection point that is not an ~injected field, initializer method parameter~ or bean constructor method parameter is annotated |@Decorates|, the container automatically detects the problem and treats it as a definition error, as defined in Section 12.4, "Problems detected automatically by the container".</text>
-    </assertion>
+      <assertion id="cd">
+        <text>Check an initializer method parameter is ok</text>
+      </assertion>
     
-    <assertion id="cf">
+      <assertion id="ce">
+        <text>Check a bean constructor method parameter is ok</text>
+      </assertion>
+    
+      <assertion id="cf">
+        <text>Check that a producer method parameter is not ok</text>
+      </assertion>
+      
+    </group>
+    
+    <assertion id="cg">
       <text>If a bean class that is not a decorator has an injection point annotated |@Decorates|, the container automatically detects the problem and treats it as a definition error, as defined in Section 12.4, "Problems detected automatically by the container".</text>
     </assertion>
 




More information about the weld-commits mailing list