org.infinispan.factories
Class AbstractComponentFactory

java.lang.Object
  extended by org.infinispan.factories.AbstractComponentFactory
Direct Known Subclasses:
AbstractNamedCacheComponentFactory, EmptyConstructorFactory, NamedComponentFactory, TransportFactory

public abstract class AbstractComponentFactory
extends Object

Factory that creates components used internally within Infinispan, and also wires dependencies into the components.

The InternalCacheFactory is a special subclass of this, which bootstraps the construction of other components. When this class is loaded, it maintains a static list of known default factories for known components, which it then delegates to, when actually performing the construction.

Since:
4.0
Author:
Manik Surtani (manik@jboss.org)
See Also:
Inject, ComponentRegistry

Field Summary
protected  GlobalComponentRegistry globalComponentRegistry
           
protected  GlobalConfiguration globalConfiguration
           
protected  Log log
           
 
Constructor Summary
AbstractComponentFactory()
          Constructs a new ComponentFactory.
 
Method Summary
protected  void assertTypeConstructable(Class requestedType, Class... ableToConstruct)
           
abstract
<T> T
construct(Class<T> componentType)
          Constructs a component.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected final Log log

globalComponentRegistry

protected GlobalComponentRegistry globalComponentRegistry

globalConfiguration

protected GlobalConfiguration globalConfiguration
Constructor Detail

AbstractComponentFactory

public AbstractComponentFactory()
Constructs a new ComponentFactory.

Method Detail

construct

public abstract <T> T construct(Class<T> componentType)
Constructs a component.

Parameters:
componentType - type of component
Returns:
a component

assertTypeConstructable

protected void assertTypeConstructable(Class requestedType,
                                       Class... ableToConstruct)

-->

Copyright © 2011 JBoss, a division of Red Hat. All Rights Reserved.