|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.velocity.context.ChainedInternalContextAdapter org.apache.velocity.runtime.directive.Foreach.NullHolderContext
protected static class Foreach.NullHolderContext
A special context to use when the foreach iterator returns a null. This is required since the standard context may not support nulls. All puts and gets are passed through, except for the foreach iterator key.
Field Summary |
---|
Fields inherited from class org.apache.velocity.context.ChainedInternalContextAdapter |
---|
innerContext |
Method Summary | |
---|---|
Object |
get(String key)
Get an object from the context, or null if the key is equal to the loop variable |
Object |
localPut(String key,
Object value)
Allows callers to explicitly put objects in the local context. |
Object |
put(String key,
Object value)
Put method also stores values in parent context |
Object |
remove(Object key)
Remove an object from the context |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public Object get(String key) throws MethodInvocationException
get
in interface Context
get
in class ChainedInternalContextAdapter
key
- name of item to get
MethodInvocationException
- passes on potential exception from reference method callContext.get(java.lang.String)
public Object put(String key, Object value)
ChainedInternalContextAdapter
put
in interface Context
put
in class ChainedInternalContextAdapter
key
- name of item to setvalue
- object to set to key
Context.put(java.lang.String key, java.lang.Object value)
public Object localPut(String key, Object value)
localPut
in interface InternalWrapperContext
localPut
in class ChainedInternalContextAdapter
key
- name of item to set.value
- object to set to key.
InternalWrapperContext.localPut(String, Object)
public Object remove(Object key)
remove
in interface Context
remove
in class ChainedInternalContextAdapter
key
- The name of the value to remove.
null
if unmapped.Context.remove(java.lang.Object key)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |