public abstract class AbstractDecoratorMapper extends Object implements DecoratorMapper
Typically, an implementation would override getNamedDecorator() or getDecorator(). If a Decorator cannot be returned from either of these, then they should delegate to their superclass.
DecoratorMapper| Modifier and Type | Field and Description |
|---|---|
protected Config |
config |
protected DecoratorMapper |
parent
Parent DecoratorMapper.
|
| Constructor and Description |
|---|
AbstractDecoratorMapper() |
| Modifier and Type | Method and Description |
|---|---|
Decorator |
getDecorator(javax.servlet.http.HttpServletRequest request,
Page page)
Delegate to parent.
|
Decorator |
getNamedDecorator(javax.servlet.http.HttpServletRequest request,
String name)
Delegate to parent.
|
void |
init(Config config,
Properties properties,
DecoratorMapper parent)
Set parent.
|
protected DecoratorMapper parent
protected Config config
public void init(Config config, Properties properties, DecoratorMapper parent) throws InstantiationException
init in interface DecoratorMapperconfig - Config supplied by Servlet or Filter.properties - Any initialization properties (specific to implementation).InstantiationException - should be thrown if the implementation
cannot be initialized properly.public Decorator getDecorator(javax.servlet.http.HttpServletRequest request, Page page)
getDecorator in interface DecoratorMapperpublic Decorator getNamedDecorator(javax.servlet.http.HttpServletRequest request, String name)
getNamedDecorator in interface DecoratorMapper