OGNL is the Object Graph Navigation Language (see http://www.ognl.org/ for the full documentation of OGNL). Here, we will cover a few examples of OGNL features that co-exist with the framework. To review basic concepts, refer to OGNL Basics.
The framework uses a standard naming context to evaluate OGNL expressions. The top level object dealing with OGNL is a Map (usually referred as a context map or context). OGNL has a notion of there being a root (or default) object within the context. In expression, the properties of the root object can be referenced without any special "marker" notion. References to other objects are marked with a pound sign (#
).
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
<s:property value="#session.mySessionPropKey"/> or <s:property value="#session[WW:"mySessionPropKey"]"/> or <s:property value="#request[WW:"mySessionPropKey"]/> |
The ActionContext is also exposed to Action classes via a static method.
...