org.jboss.weld.extensions.beanManager
Class BeanManagerAccessor

java.lang.Object
  extended by org.jboss.weld.extensions.beanManager.BeanManagerAccessor

public class BeanManagerAccessor
extends Object

Static accessors for objects not able to obtain CDI injection that need a reference to the BeanManager. BeanManagerProviders can be registered to allow third parties to register custom methods of looking up the BeanManager.

**WARNING** This class is NOT a clever way to get the BeanManager, and should be avoided at all costs. If you need a handle to the BeanManager you should probably register an Extension instead of using this class; have you tried using @Inject?

If you think you need to use this class, chat to the community and make sure you aren't missing an trick!

Author:
Pete Muir, Nicklas Karlsson
See Also:
BeanManagerProvider, BeanManagerAware

Method Summary
static javax.enterprise.inject.spi.BeanManager getBeanManager()
          Obtain the BeanManager from the BeanManagerProviders
static boolean isBeanManagerAvailable()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getBeanManager

public static javax.enterprise.inject.spi.BeanManager getBeanManager()
Obtain the BeanManager from the BeanManagerProviders

Returns:
the current bean manager for the bean archive

isBeanManagerAvailable

public static boolean isBeanManagerAvailable()


Copyright © 2008-2010 Seam Framework. All Rights Reserved.