Package org.ametys.web.workflow
Class WebAmetysObjectWorkflowStore
java.lang.Object
org.ametys.plugins.workflow.store.AbstractJackrabbitWorkflowStore
org.ametys.plugins.workflow.store.AmetysObjectWorkflowStore
org.ametys.web.workflow.WebAmetysObjectWorkflowStore
- All Implemented Interfaces:
com.opensymphony.workflow.spi.WorkflowStore
,AmetysWorkflowStore
Web ametys object workflow store which ensures that the session used operates
on the default workspace.
-
Field Summary
Fields inherited from class org.ametys.plugins.workflow.store.AmetysObjectWorkflowStore
_ametysObject, _inMemoryEntry
Fields inherited from class org.ametys.plugins.workflow.store.AbstractJackrabbitWorkflowStore
__NAMESPACE, __NAMESPACE_PREFIX, __NM_PREFIX, __ROOT_NT, _log, _repository
-
Constructor Summary
ConstructorDescriptionWebAmetysObjectWorkflowStore
(javax.jcr.Repository repository, WorkflowAwareAmetysObject ametysObject) Creates a workflow store for Web Ametys object.WebAmetysObjectWorkflowStore
(javax.jcr.Repository repository, WorkflowAwareAmetysObject ametysObject, boolean preserveHistory) Creates a workflow store for Web Ametys object. -
Method Summary
Modifier and TypeMethodDescriptionprotected javax.jcr.Node
Provides the ametys object node in the current sessionprotected javax.jcr.Session
Open a session to the _repository.protected void
_release
(javax.jcr.Session session) Release a session.Methods inherited from class org.ametys.plugins.workflow.store.AmetysObjectWorkflowStore
_createRootNode, _getNextEntryId, _getOrCreateParentEntryNode, _getRootNode, bindAmetysObject, getAmetysObject, shouldClearHistory, storeNewEntry
Methods inherited from class org.ametys.plugins.workflow.store.AbstractJackrabbitWorkflowStore
__toCalendar, _getNextStepId, buildFieldExpression, buildNestedExpression, clearHistory, createCurrentStep, createEntry, deleteInstance, findCurrentSteps, findEntry, findHistorySteps, getCondition, getEntryNode, getFirstFieldExpression, getPredicate, getPropertyName, getPropertySet, getSortCriteria, init, markFinished, moveToHistory, query, query, removeEntry, setEntryState, translateValue
-
Field Details
-
_session
Internal session
-
-
Constructor Details
-
WebAmetysObjectWorkflowStore
public WebAmetysObjectWorkflowStore(javax.jcr.Repository repository, WorkflowAwareAmetysObject ametysObject) Creates a workflow store for Web Ametys object. The history steps will be clear on workflow completion.- Parameters:
repository
- the JCR Repository to use.ametysObject
- The ametys object for this store. Can be null in case of an object creation.
-
WebAmetysObjectWorkflowStore
public WebAmetysObjectWorkflowStore(javax.jcr.Repository repository, WorkflowAwareAmetysObject ametysObject, boolean preserveHistory) Creates a workflow store for Web Ametys object.- Parameters:
repository
- The repositoryametysObject
- The ametys object for this store. Can be null in case of an object creation.preserveHistory
- Set to true to preserve history steps when workflow is complete.
-
-
Method Details
-
_getSession
Description copied from class:AbstractJackrabbitWorkflowStore
Open a session to the _repository.- Overrides:
_getSession
in classAmetysObjectWorkflowStore
- Returns:
- the session opened.
- Throws:
javax.jcr.RepositoryException
- if an error occurs.
-
_release
Description copied from class:AbstractJackrabbitWorkflowStore
Release a session.Default implementation calls logout on the session.
- Overrides:
_release
in classAmetysObjectWorkflowStore
- Parameters:
session
- the session to release.
-
_getAmetysObjectNode
Description copied from class:AmetysObjectWorkflowStore
Provides the ametys object node in the current session- Overrides:
_getAmetysObjectNode
in classAmetysObjectWorkflowStore
- Returns:
- node
- Throws:
javax.jcr.RepositoryException
- on repository error
-