Package org.nuxeo.ecm.core.event.impl
Class EventContextImpl
- java.lang.Object
-
- org.nuxeo.ecm.core.event.impl.AbstractEventContext
-
- org.nuxeo.ecm.core.event.impl.EventContextImpl
-
- All Implemented Interfaces:
Serializable
,EventContext
- Direct Known Subclasses:
BlobEventContext
,DocumentDomainEventContext
,DocumentEventContext
,InlineEventContext
,UnboundEventContext
public class EventContextImpl extends AbstractEventContext
Default implementation- Author:
- Bogdan Stefanescu
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected NuxeoPrincipal
principal
protected CoreSession
session
-
Fields inherited from class org.nuxeo.ecm.core.event.impl.AbstractEventContext
args, EMPTY, properties, repositoryName
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
EventContextImpl()
Constructor to be used by derived classesEventContextImpl(Object... args)
EventContextImpl(CoreSession session, NuxeoPrincipal principal)
EventContextImpl(CoreSession session, NuxeoPrincipal principal, Object... args)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CoreSession
getCoreSession()
Gets the current core session if any.NuxeoPrincipal
getPrincipal()
Gets the current principal.void
setArgs(Object[] args)
void
setCoreSession(CoreSession session)
Sets the core session.void
setPrincipal(NuxeoPrincipal principal)
Sets the principal.protected void
updateRepositoryName()
-
Methods inherited from class org.nuxeo.ecm.core.event.impl.AbstractEventContext
getArguments, getProperties, getProperty, getRepositoryName, hasProperty, newEvent, newEvent, setProperties, setProperty, setRepositoryName
-
-
-
-
Field Detail
-
session
protected transient CoreSession session
-
principal
protected NuxeoPrincipal principal
-
-
Constructor Detail
-
EventContextImpl
protected EventContextImpl()
Constructor to be used by derived classes
-
EventContextImpl
public EventContextImpl(Object... args)
-
EventContextImpl
public EventContextImpl(CoreSession session, NuxeoPrincipal principal, Object... args)
-
EventContextImpl
public EventContextImpl(CoreSession session, NuxeoPrincipal principal)
-
-
Method Detail
-
setArgs
public void setArgs(Object[] args)
-
getCoreSession
public CoreSession getCoreSession()
Description copied from interface:EventContext
Gets the current core session if any.- Returns:
- the core session, or null if none
-
getPrincipal
public NuxeoPrincipal getPrincipal()
Description copied from interface:EventContext
Gets the current principal.- Returns:
- the principal. Cannot be null.
-
setCoreSession
public void setCoreSession(CoreSession session)
Description copied from interface:EventContext
Sets the core session.
-
updateRepositoryName
protected void updateRepositoryName()
-
setPrincipal
public void setPrincipal(NuxeoPrincipal principal)
Description copied from interface:EventContext
Sets the principal.
-
-