Package org.nuxeo.ecm.platform.actions
Class AbstractActionContext
java.lang.Object
org.nuxeo.ecm.platform.actions.AbstractActionContext
- All Implemented Interfaces:
Serializable
,ActionContext
- Direct Known Subclasses:
ELActionContext
- Since:
- 5.7.3
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionprotected DocumentModel
protected NuxeoPrincipal
protected CoreSession
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract boolean
checkCondition
(String expression) Returns true if given expression resolves to true in this context.boolean
Returns true if expressions evaluation should not be cached globallyfinal DocumentModel
Returns the current document to use for filter evaluationfinal NuxeoPrincipal
Returns the current principal to use for filter evaluationfinal CoreSession
Returns the core session to use for filter evaluationgetLocalVariable
(String key) Returns a local variable put in the contextvoid
putAllLocalVariables
(Map<String, Object> vars) Sets local variables, to put in the context so that expressions can reference them.putLocalVariable
(String key, Object value) Sets a local variable, to put in the context so that expressions can reference it.final void
Sets the current document to use for filter evaluationfinal void
setCurrentPrincipal
(NuxeoPrincipal currentPrincipal) Sets the current principal to use for filter evaluationfinal void
setDocumentManager
(CoreSession docMgr) Sets the core session to use for filter evaluationint
size()
Returns the number of local variablesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.nuxeo.ecm.platform.actions.ActionContext
evalExpression
-
Field Details
-
currentDocument
-
docMgr
-
currentPrincipal
-
localVariables
-
-
Constructor Details
-
AbstractActionContext
public AbstractActionContext()
-
-
Method Details
-
checkCondition
Description copied from interface:ActionContext
Returns true if given expression resolves to true in this context.Returns false if expression is blank (null or empty).
- Specified by:
checkCondition
in interfaceActionContext
- Throws:
javax.el.ELException
-
setCurrentDocument
Description copied from interface:ActionContext
Sets the current document to use for filter evaluation- Specified by:
setCurrentDocument
in interfaceActionContext
-
getCurrentDocument
Description copied from interface:ActionContext
Returns the current document to use for filter evaluation- Specified by:
getCurrentDocument
in interfaceActionContext
-
getDocumentManager
Description copied from interface:ActionContext
Returns the core session to use for filter evaluation- Specified by:
getDocumentManager
in interfaceActionContext
-
setDocumentManager
Description copied from interface:ActionContext
Sets the core session to use for filter evaluation- Specified by:
setDocumentManager
in interfaceActionContext
-
getCurrentPrincipal
Description copied from interface:ActionContext
Returns the current principal to use for filter evaluation- Specified by:
getCurrentPrincipal
in interfaceActionContext
-
setCurrentPrincipal
Description copied from interface:ActionContext
Sets the current principal to use for filter evaluation- Specified by:
setCurrentPrincipal
in interfaceActionContext
-
getLocalVariable
Description copied from interface:ActionContext
Returns a local variable put in the context- Specified by:
getLocalVariable
in interfaceActionContext
-
putLocalVariable
Description copied from interface:ActionContext
Sets a local variable, to put in the context so that expressions can reference it.- Specified by:
putLocalVariable
in interfaceActionContext
-
putAllLocalVariables
Description copied from interface:ActionContext
Sets local variables, to put in the context so that expressions can reference them.- Specified by:
putAllLocalVariables
in interfaceActionContext
-
size
public int size()Description copied from interface:ActionContext
Returns the number of local variables- Specified by:
size
in interfaceActionContext
-
disableGlobalCaching
public boolean disableGlobalCaching()Description copied from interface:ActionContext
Returns true if expressions evaluation should not be cached globally- Specified by:
disableGlobalCaching
in interfaceActionContext
-