Class PilotageStatusCheckCondition
java.lang.Object
org.ametys.plugins.workflow.AbstractWorkflowComponent
org.ametys.plugins.odfpilotage.workflow.PilotageStatusCheckCondition
- All Implemented Interfaces:
com.opensymphony.workflow.Condition
,Disposable
,Initializable
,LogEnabled
,Serviceable
public class PilotageStatusCheckCondition
extends AbstractWorkflowComponent
implements com.opensymphony.workflow.Condition, Initializable, Disposable
Check the pilotage status and check if we try to edit the structure
-
Field Summary
Fields inherited from class org.ametys.plugins.workflow.AbstractWorkflowComponent
_logger, _manager, CONTEXT_PARAMETERS_KEY, FAIL_CONDITIONS_KEY, RESULT_MAP_KEY, WORKFLOW_ERRORS_KEY, WORKFLOW_WARNS_KEY
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
dispose()
protected WorkflowAwareContent
getContent
(Map transientVars) Retrieve the content associated with the workflow.void
boolean
passesCondition
(Map transientVars, Map args, com.opensymphony.module.propertyset.PropertySet ps) protected boolean
passesPilotageStatusCondition
(Map transientVars) Return true if the pilotage status passes conditionsMethods inherited from class org.ametys.plugins.workflow.AbstractWorkflowComponent
addWorkflowError, addWorkflowWarning, enableLogging, getConditionFailures, getContextParameters, getResultsMap, getUser, service
-
Field Details
-
_pilotageStatusHelper
The pilotage status helper
-
-
Constructor Details
-
PilotageStatusCheckCondition
public PilotageStatusCheckCondition()
-
-
Method Details
-
initialize
- Specified by:
initialize
in interfaceInitializable
- Throws:
Exception
-
passesCondition
public boolean passesCondition(Map transientVars, Map args, com.opensymphony.module.propertyset.PropertySet ps) throws com.opensymphony.workflow.WorkflowException - Specified by:
passesCondition
in interfacecom.opensymphony.workflow.Condition
- Throws:
com.opensymphony.workflow.WorkflowException
-
passesPilotageStatusCondition
protected boolean passesPilotageStatusCondition(Map transientVars) throws com.opensymphony.workflow.WorkflowException Return true if the pilotage status passes conditions- Parameters:
transientVars
- the transient vars- Returns:
- true if the pilotage status passes conditions
- Throws:
com.opensymphony.workflow.WorkflowException
- if an error occurred
-
getContent
protected WorkflowAwareContent getContent(Map transientVars) throws com.opensymphony.workflow.WorkflowException Retrieve the content associated with the workflow.- Parameters:
transientVars
- the parameters from the call.- Returns:
- the content.
- Throws:
com.opensymphony.workflow.WorkflowException
- if the content is not found.
-
dispose
- Specified by:
dispose
in interfaceDisposable
-