public abstract class AbstractExecutionContext extends Object implements ExecutionContext
| Modifier and Type | Field and Description |
|---|---|
protected Deque<Object> |
contextObjectStack
LIFO stack of context objects
|
protected Map<String,ExtendSectionSegment> |
definingSections
Map of defining/overriding sections
|
protected List<Resolver> |
resolvers
Immutable ordered list of resolvers
|
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractExecutionContext(List<Resolver> resolvers) |
| Modifier and Type | Method and Description |
|---|---|
void |
addDefiningSection(String name,
ExtendSectionSegment segment)
Associate the specified defining section with the context, but only if no
defining section with the same name is associated.
|
ExtendSectionSegment |
getDefiningSection(String name) |
protected boolean |
isCompoundKey(String key) |
Object |
pop()
Removes the context object at the top of context stack.
|
void |
push(Object contextObject)
Push the context object on the context stack.
|
protected Object |
resolve(Object contextObject,
String name) |
protected Object |
resolveLeadingContextObject(String name)
Resolve the leading context object (the first part of the key).
|
protected String[] |
splitKey(String key) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetValueprotected Map<String,ExtendSectionSegment> definingSections
public void push(Object contextObject)
ExecutionContextpush in interface ExecutionContextpublic Object pop()
ExecutionContextpop in interface ExecutionContextpublic void addDefiningSection(String name, ExtendSectionSegment segment)
ExecutionContextaddDefiningSection in interface ExecutionContextExtendSegmentpublic ExtendSectionSegment getDefiningSection(String name)
getDefiningSection in interface ExecutionContextnull
if no such associated with the contextExtendSegmentprotected Object resolveLeadingContextObject(String name)
foo in {{foo.bar.name}} may identify a property
of some context object on the stack (passed data, section iteration, nested
context, ...), or some context and data unrelated object (e.g. CDI bean).name - protected Object resolve(Object contextObject, String name)
contextObject - name - protected boolean isCompoundKey(String key)
Copyright © 2013. All Rights Reserved.