Skip to content

Commit

Permalink
Add wrapExpressionFactory
Browse files Browse the repository at this point in the history
git-svn-id: http://anonsvn.jboss.org/repos/weld/ri/trunk@3663 1c488680-804c-0410-94cd-c6b725194a0e
  • Loading branch information
pmuir committed Sep 14, 2009
1 parent 370f0a5 commit 70d4378
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
Expand Up @@ -23,6 +23,7 @@
import java.util.Set;

import javax.el.ELResolver;
import javax.el.ExpressionFactory;
import javax.enterprise.context.ContextNotActiveException;
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
Expand Down Expand Up @@ -260,6 +261,14 @@ public interface BeanManager
*/
public ELResolver getELResolver();

/**
* Returns an ExpressionFactory
*
* @param expressionFactory
* @return
*/
public ExpressionFactory wrapExpressionFactory(ExpressionFactory expressionFactory);

/**
* Get an {@link AnnotatedType} for the given class
* @param <T> the type
Expand Down
9 changes: 8 additions & 1 deletion impl/src/main/java/org/jboss/webbeans/BeanManagerImpl.java
Expand Up @@ -38,6 +38,7 @@
import java.util.concurrent.atomic.AtomicInteger;

import javax.el.ELResolver;
import javax.el.ExpressionFactory;
import javax.enterprise.context.ContextNotActiveException;
import javax.enterprise.context.spi.Context;
import javax.enterprise.context.spi.Contextual;
Expand All @@ -57,8 +58,8 @@
import javax.inject.Qualifier;

import org.jboss.webbeans.bean.DecoratorImpl;
import org.jboss.webbeans.bean.SessionBean;
import org.jboss.webbeans.bean.RIBean;
import org.jboss.webbeans.bean.SessionBean;
import org.jboss.webbeans.bean.proxy.ClientProxyProvider;
import org.jboss.webbeans.bootstrap.api.ServiceRegistry;
import org.jboss.webbeans.context.CreationalContextImpl;
Expand All @@ -67,6 +68,7 @@
import org.jboss.webbeans.ejb.spi.EjbDescriptor;
import org.jboss.webbeans.el.Namespace;
import org.jboss.webbeans.el.WebBeansELResolver;
import org.jboss.webbeans.el.WebBeansExpressionFactory;
import org.jboss.webbeans.introspector.WBAnnotated;
import org.jboss.webbeans.literal.AnyLiteral;
import org.jboss.webbeans.literal.DefaultLiteral;
Expand Down Expand Up @@ -1324,6 +1326,11 @@ public ELResolver getELResolver()
return webbeansELResolver;
}

public ExpressionFactory wrapExpressionFactory(ExpressionFactory expressionFactory)
{
return new WebBeansExpressionFactory(expressionFactory);
}

public <T> WBCreationalContext<T> createCreationalContext(Contextual<T> contextual)
{
return new CreationalContextImpl<T>(contextual);
Expand Down

0 comments on commit 70d4378

Please sign in to comment.