public interface DecoratorMapper
Decorator should be used for a
Page.
Implementations of this are returned by the Factory,
and should be thread-safe.
| Modifier and Type | Method and Description |
|---|---|
Decorator |
getDecorator(javax.servlet.http.HttpServletRequest request,
Page page)
Return appropriate
Decorator for a certain Page. |
Decorator |
getNamedDecorator(javax.servlet.http.HttpServletRequest request,
java.lang.String name)
Return a
Decorator with given name. |
void |
init(Config config,
java.util.Properties properties,
DecoratorMapper parent)
Initialize the mapper.
|
void init(Config config, java.util.Properties properties, DecoratorMapper parent) throws java.lang.InstantiationException
config - Config supplied by Servlet or Filter.properties - Any initialization properties (specific to implementation).java.lang.InstantiationException - should be thrown if the implementation
cannot be initialized properly.Decorator getDecorator(javax.servlet.http.HttpServletRequest request, Page page)
Decorator for a certain Page.
The implementation can determine the result based on the actual request
or the data of the parsed page. Typically this would call getNamedDecorator()
which would delegate to a parent DecoratorMapper.