public abstract class AbstractDecoratorMapper extends java.lang.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,
java.lang.String name)
Delegate to parent.
|
void |
init(Config config,
java.util.Properties properties,
DecoratorMapper parent)
Set parent.
|
protected DecoratorMapper parent
protected Config config
public void init(Config config, java.util.Properties properties, DecoratorMapper parent) throws java.lang.InstantiationException
init in interface DecoratorMapperconfig - 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.public Decorator getDecorator(javax.servlet.http.HttpServletRequest request, Page page)
getDecorator in interface DecoratorMapperpublic Decorator getNamedDecorator(javax.servlet.http.HttpServletRequest request, java.lang.String name)
getNamedDecorator in interface DecoratorMapper