net.sf.mmm.util.context.base
Class AbstractGenericContextFactory
java.lang.Object
net.sf.mmm.util.component.base.AbstractComponent
net.sf.mmm.util.component.base.AbstractLoggableComponent
net.sf.mmm.util.context.base.AbstractGenericContextFactory
- All Implemented Interfaces:
- GenericContextFactory
- Direct Known Subclasses:
- GenericContextFactoryImpl
public abstract class AbstractGenericContextFactory
- extends AbstractLoggableComponent
- implements GenericContextFactory
This is the abstract base-implementation of the GenericContextFactory
interface.
- Since:
- 2.0.0
- Author:
- Joerg Hohwiller (hohwille at users.sourceforge.net)
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractGenericContextFactory
public AbstractGenericContextFactory()
- The constructor.
createContext
public MutableGenericContext createContext()
- This method creates a new instance of a
MutableGenericContext. It
will use a HashMapFactory and
delegate to GenericContextFactory.createContext(MapFactory).
ATTENTION:
Such context is usually suitable even if
child-contexts are created and
passed to other threads while the original thread is modifying the original
context as proved in the according test-case. However
HashMap.get(Object) is not academically thread-safe so if
you need mission-critical safety, you might want to pass
ConcurrentHashMapFactory to
GenericContextFactory.createContext(MapFactory).
- Specified by:
createContext in interface GenericContextFactory
- Returns:
- the new context.
Copyright © 2001-2010 mmm-Team. All Rights Reserved.