fr.paris.lutece.plugins.jsr168.pluto.services.factorymanager
Class FactoryManagerServiceImpl
java.lang.Object
org.apache.pluto.portalImpl.services.Service
org.apache.pluto.portalImpl.services.factorymanager.FactoryManagerService
fr.paris.lutece.plugins.jsr168.pluto.services.factorymanager.FactoryManagerServiceImpl
- All Implemented Interfaces:
- org.apache.pluto.services.ContainerService, org.apache.pluto.services.factory.FactoryManagerService
public class FactoryManagerServiceImpl
- extends org.apache.pluto.portalImpl.services.factorymanager.FactoryManagerService
- implements org.apache.pluto.services.factory.FactoryManagerService
Manages the life-time of factories registered during container startup.
A service has to derive from Factory
and implement the
init()
and destroy()
methods as appropriate.
- See Also:
Factory
Method Summary |
void |
destroy(javax.servlet.ServletConfig config)
Destroys all services. |
org.apache.pluto.factory.Factory |
getFactory(java.lang.Class theClass)
Returns the service implementation for the given service class, or
null if no such service is registered. |
void |
init(javax.servlet.ServletConfig config,
org.apache.pluto.portalImpl.util.Properties aProperties)
Initializes all factories specified in the configuration beginning with 'factory.'. |
Methods inherited from class org.apache.pluto.portalImpl.services.Service |
destroy, init, init, postInit, postInit |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FactoryManagerServiceImpl
public FactoryManagerServiceImpl()
init
public void init(javax.servlet.ServletConfig config,
org.apache.pluto.portalImpl.util.Properties aProperties)
throws java.lang.Exception
- Initializes all factories specified in the configuration beginning with 'factory.'.
By specifying a different implementation of the factory the behaviour
of the portlet container can be modified.
- Overrides:
init
in class org.apache.pluto.portalImpl.services.Service
- Parameters:
config
- the servlet configurationaProperties
- Defined properties for the factory manager
- Throws:
java.lang.Exception
- if initializing any of the factories fails
destroy
public void destroy(javax.servlet.ServletConfig config)
- Destroys all services.
- Overrides:
destroy
in class org.apache.pluto.portalImpl.services.Service
- Parameters:
config
- the servlet configuration
getFactory
public org.apache.pluto.factory.Factory getFactory(java.lang.Class theClass)
- Returns the service implementation for the given service class, or
null
if no such service is registered.
- Specified by:
getFactory
in interface org.apache.pluto.services.factory.FactoryManagerService
- Specified by:
getFactory
in class org.apache.pluto.portalImpl.services.factorymanager.FactoryManagerService
- Parameters:
theClass
- the service class
- Returns:
- the service implementation
Copyright © 2008 Mairie de Paris. All Rights Reserved.