pt.digitalis.utils.ioc
Class AbstractIoCRegistryImpl
java.lang.Object
pt.digitalis.utils.ioc.AbstractIoCRegistryImpl
- All Implemented Interfaces:
- IIoCRegistry
- Direct Known Subclasses:
- IoCRegistryGuiceImpl
public abstract class AbstractIoCRegistryImpl
- extends Object
- implements IIoCRegistry
This class provides common implementations for some interface methods. It's not possible do use IoC to provide an
abstraction of itself, so the Bridge DP was used to decouple the abstraction from it's implementation. The actual
registry is created with the proper implementation according to the default DiF core configuration.
- Author:
- Pedro Viegas pviegas@digitalis.pt, Rodrigo Gonçalves rgoncalves@digitalis.pt
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
instance
protected static IIoCRegistry instance
- The IoC registry instance.
AbstractIoCRegistryImpl
public AbstractIoCRegistryImpl()
discoverModules
public void discoverModules(ModuleParser searchMode)
throws ResourceNotFoundException
- Finds and returns the declared Modules.
- Parameters:
searchMode
- module parsing mode
- Throws:
ResourceNotFoundException
- if the configuration files can't be found
getImplementations
public <T> List<T> getImplementations(Class<T> serviceClass)
- Description copied from interface:
IIoCRegistry
- Returns the list of implementations for the given interface.
- Specified by:
getImplementations
in interface IIoCRegistry
- Type Parameters:
T
- the service's class- Parameters:
serviceClass
- the service's interface type
- Returns:
- the list of instances for each service's implementation
- See Also:
IIoCRegistry.getImplementations(java.lang.Class)
Copyright © 2012 Digitalis Informática Lda. All Rights Reserved.