|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface DefinitionsFactory
Tiles Definition factory. This interface replace old ComponentDefinitionsFactory. Main method getDefinition() is exactly the same. Initialization method change. This interface allows to retrieve a definition by its name, independently of the factory implementation. Object life cycle is as follow:
Method Summary | |
---|---|
void |
destroy()
Receive notification that the factory is being shut down. |
DefinitionsFactoryConfig |
getConfig()
Get factory configuration. |
ComponentDefinition |
getDefinition(String name,
ServletRequest request,
ServletContext servletContext)
Get a definition by its name. |
void |
init(DefinitionsFactoryConfig config,
ServletContext servletContext)
Init definition factory. |
void |
setConfig(DefinitionsFactoryConfig config,
ServletContext servletContext)
Set factory configuration. |
Method Detail |
---|
ComponentDefinition getDefinition(String name, ServletRequest request, ServletContext servletContext) throws NoSuchDefinitionException, DefinitionsFactoryException
name
- Name of requested definition.request
- Current servelet requestservletContext
- current servlet context
DefinitionsFactoryException
- An error occur while getting definition.
NoSuchDefinitionException
- No definition found for specified name
Implementation can throw more accurate exception as a subclass of this exceptionvoid init(DefinitionsFactoryConfig config, ServletContext servletContext) throws DefinitionsFactoryException
config
- Configuration object used to set factory configuration.servletContext
- Servlet Context passed to factory.
DefinitionsFactoryException
- An error occur during initialization.void destroy()
Receive notification that the factory is being shut down.
void setConfig(DefinitionsFactoryConfig config, ServletContext servletContext) throws DefinitionsFactoryException
config
- Configuration object used to set factory configuration.servletContext
- Servlet Context passed to factory.
DefinitionsFactoryException
- An error occur during initialization.DefinitionsFactoryConfig getConfig()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |