|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TemplateContext
TemplateContext is a template engine independent interface to contexts. It supports chaining of contexts through parent contexts.
Method Summary | |
---|---|
boolean |
addParent(int index,
TemplateContext context)
Adds a parent context to a specied index. |
boolean |
addParent(TemplateContext context)
Adds a parent context. |
void |
clear()
Clears the context but not its parents. |
void |
clearParents()
Clears all parents from this context. |
boolean |
containsKey(String key)
Checks whether a key is in the context or in its parents. |
Object |
get(String key)
Gets an object from the context or from its parents. |
Content |
getContent()
Gets the content of this context. |
ContextToolFilter |
getContextToolFilter()
Gets the context tool filter of this context. |
HttpFilterChain |
getFilterChain()
Gets the filter chain of this context. |
MBeanServer |
getMBeanServer()
Gets the MBean server. |
TemplateContext |
getParent(int index)
Gets the indexed parent from the context. |
List<TemplateContext> |
getParents()
Gets a read-only list of parents. |
Set<String> |
keySet()
Gets a set of all keys in the context and in its parents. |
int |
numberOfParents()
Returns the number of parents. |
Object |
put(String key,
Object value)
Puts an object into the context. |
Object |
remove(String key)
Removes an object from the context. |
TemplateContext |
removeParent(int index)
Removes an indexed parent context. |
boolean |
removeParent(TemplateContext context)
Removes a parent context. |
void |
set(String key,
Object value)
Sets an object int the context. |
TemplateContext |
setParent(int index,
TemplateContext context)
Sets a parent context to a specied index. |
int |
size()
Gets the size of the context including its parents. |
Collection<Object> |
values()
Gets a collection of all values in the context and in its parents. |
Method Detail |
---|
List<TemplateContext> getParents()
TemplateContext getParent(int index)
index
- the index.
IndexOutOfBoundsException
- for invalid index.TemplateContext setParent(int index, TemplateContext context)
context
- a parent context.index
- the index.
IndexOutOfBoundsException
- for invalid index.boolean addParent(TemplateContext context)
context
- a parent context.
boolean addParent(int index, TemplateContext context)
index
- the index.context
- a parent context.
IndexOutOfBoundsException
- for invalid index.boolean removeParent(TemplateContext context)
context
- a parent context.
TemplateContext removeParent(int index)
index
- the index.
IndexOutOfBoundsException
- for invalid index.int numberOfParents()
void clearParents()
Content getContent()
HttpFilterChain getFilterChain()
Object get(String key)
key
- the key.
void set(String key, Object value)
key
- the key.value
- the value.Object put(String key, Object value)
key
- the key.value
- the value.
Object remove(String key)
key
- the key.
boolean containsKey(String key)
key
- the key.
Set<String> keySet()
Collection<Object> values()
int size()
void clear()
ContextToolFilter getContextToolFilter()
IllegalStateException
- if not available.MBeanServer getMBeanServer()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |