Package ru.slie.luna.issue.workflow
Interface WorkflowManager
public interface WorkflowManager
-
Method Summary
Modifier and TypeMethodDescriptionaddActionSource(Workflow workflow, int actionId, Status source) addCondition(Workflow workflow, int actionId, String className, Map<String, String> params, String containerGroupId) addGlobalAction(Workflow workflow, String name, Status target) voidvoidvoidchangeActionSource(Workflow workflow, int actionId, Status oldSource, Status newSource) changeActionTarget(Workflow workflow, int actionId, Status target) createSchema(String name, String description, Workflow defaultWorkflow) createWorkflow(User user, String name, String description, Status initStatus) voiddeleteAction(Workflow workflow, int actionId) deleteSchema(WorkflowSchema workflowSchema) voiddeleteStatus(Workflow workflow, Status status) deleteWorkflow(Workflow workflow) findWorkflows(String term, SearchParams params) findWorkflowSchemas(String term, SearchParams params) getOrCreateDraft(User user, Workflow workflow) getSchemaById(Long id) getSchemaByName(String name) getSchemasForIssueType(IssueType... issueTypes) getSchemasForWorkflow(Workflow... workflows) getSchemasForWorkflows(List<Workflow> workflows) getWorkflow(IssueContext issueContext) getWorkflowById(Long id) getWorkflowByName(String name) getWorkflowsByIds(Collection<Long> ids) getWorkflowsForScreen(Screen... screens) getWorkflowsForStatus(Status... statuses) moveConditionGroup(Workflow workflow, int actionId, String conditionGroupId, String containerGroupId, String afterConditionGroupId) movePostfunction(Workflow workflow, int actionId, String postfunctionId, String afterPostfunctionId) moveValidator(Workflow workflow, int actionId, String validatorId, String afterValidatorId) voidremoveActionSource(Workflow workflow, int actionId, Status source) removeCondition(Workflow workflow, int actionId, String groupId) removePostfunction(Workflow workflow, int actionId, String postfunctionId) removeValidator(Workflow workflow, int actionId, String validatorId) voidsetActionSourcePort(Workflow workflow, String actionKey, NodePort source) voidsetActionTargetPort(Workflow workflow, String actionKey, NodePort target) voidsetCanvasPosition(Workflow workflow, Position position) setConditionGroupOperator(Workflow workflow, int actionId, String conditionGroupId, WorkflowActionConditionGroupOperator operator) voidsetStatusNodePosition(Workflow workflow, Long statusId, Position position) updateAction(Workflow workflow, int actionId, String name) updateAction(Workflow workflow, int actionId, Screen screen) updatePostfunction(Workflow workflow, int actionId, String postfunctionId, Map<String, String> params) voidupdateWorkflow(Workflow workflow, String name, String description) voidupdateWorkflowSchema(WorkflowSchema workflowSchema, String name, String description) voidupdateWorkflowSchema(WorkflowSchema workflowSchema, IssueType issueType, Workflow workflow) voidupdateWorkflowSchema(WorkflowSchema workflowSchema, Workflow defaultWorkflow)
-
Method Details
-
getWorkflow
-
getWorkflowById
-
getWorkflowsByIds
-
getWorkflowByName
-
createWorkflow
Workflow createWorkflow(User user, String name, String description, Status initStatus) throws ValidateException - Throws:
ValidateException
-
updateWorkflow
- Throws:
ValidateException
-
deleteWorkflow
- Throws:
DeleteException
-
findWorkflows
-
getWorkflowsForStatus
-
getWorkflowsForScreen
-
getSchemasForWorkflow
-
getSchemasForWorkflows
-
getSchemasForIssueType
-
getAllWorkflows
-
addStatus
- Throws:
ValidateException
-
deleteStatus
- Throws:
ValidateException
-
addAction
WorkflowAction addAction(Workflow workflow, String name, Status source, Status target) throws ValidateException - Throws:
ValidateException
-
addGlobalAction
WorkflowAction addGlobalAction(Workflow workflow, String name, Status target) throws ValidateException - Throws:
ValidateException
-
addActionSource
WorkflowAction addActionSource(Workflow workflow, int actionId, Status source) throws ValidateException - Throws:
ValidateException
-
updateAction
- Throws:
ValidateException
-
updateAction
WorkflowAction updateAction(Workflow workflow, int actionId, Screen screen) throws ValidateException - Throws:
ValidateException
-
changeActionTarget
WorkflowAction changeActionTarget(Workflow workflow, int actionId, Status target) throws ValidateException - Throws:
ValidateException
-
addPostfunction
WorkflowAction addPostfunction(Workflow workflow, int actionId, String className, Map<String, String> params) throws ValidateException- Throws:
ValidateException
-
addValidator
WorkflowAction addValidator(Workflow workflow, int actionId, String className, Map<String, String> params) throws ValidateException- Throws:
ValidateException
-
movePostfunction
WorkflowAction movePostfunction(Workflow workflow, int actionId, String postfunctionId, String afterPostfunctionId) throws ValidateException - Throws:
ValidateException
-
moveValidator
WorkflowAction moveValidator(Workflow workflow, int actionId, String validatorId, String afterValidatorId) throws ValidateException - Throws:
ValidateException
-
removePostfunction
WorkflowAction removePostfunction(Workflow workflow, int actionId, String postfunctionId) throws ValidateException - Throws:
ValidateException
-
updatePostfunction
WorkflowAction updatePostfunction(Workflow workflow, int actionId, String postfunctionId, Map<String, String> params) throws ValidateException- Throws:
ValidateException
-
removeValidator
WorkflowAction removeValidator(Workflow workflow, int actionId, String validatorId) throws ValidateException - Throws:
ValidateException
-
updateValidator
WorkflowAction updateValidator(Workflow workflow, int actionId, String validatorId, Map<String, String> params) throws ValidateException- Throws:
ValidateException
-
removeCondition
WorkflowAction removeCondition(Workflow workflow, int actionId, String groupId) throws ValidateException - Throws:
ValidateException
-
updateCondition
WorkflowAction updateCondition(Workflow workflow, int actionId, String groupId, Map<String, String> params) throws ValidateException- Throws:
ValidateException
-
addCondition
WorkflowAction addCondition(Workflow workflow, int actionId, String className, Map<String, String> params, String containerGroupId) throws ValidateException- Throws:
ValidateException
-
setConditionGroupOperator
WorkflowAction setConditionGroupOperator(Workflow workflow, int actionId, String conditionGroupId, WorkflowActionConditionGroupOperator operator) throws ValidateException - Throws:
ValidateException
-
moveConditionGroup
WorkflowAction moveConditionGroup(Workflow workflow, int actionId, String conditionGroupId, String containerGroupId, String afterConditionGroupId) throws ValidateException - Throws:
ValidateException
-
deleteAction
- Throws:
ValidateException
-
removeActionSource
- Throws:
ValidateException
-
changeActionSource
void changeActionSource(Workflow workflow, int actionId, Status oldSource, Status newSource) throws ValidateException - Throws:
ValidateException
-
setStatusNodePosition
-
setCanvasPosition
-
setActionSourcePort
void setActionSourcePort(Workflow workflow, String actionKey, NodePort source) throws ValidateException - Throws:
ValidateException
-
setActionTargetPort
void setActionTargetPort(Workflow workflow, String actionKey, NodePort target) throws ValidateException - Throws:
ValidateException
-
getSchemaById
-
getSchemaByName
-
createSchema
WorkflowSchema createSchema(String name, String description, Workflow defaultWorkflow) throws ValidateException - Throws:
ValidateException
-
deleteSchema
- Throws:
DeleteException
-
updateWorkflowSchema
void updateWorkflowSchema(WorkflowSchema workflowSchema, String name, String description) throws ValidateException - Throws:
ValidateException
-
updateWorkflowSchema
-
updateWorkflowSchema
-
findWorkflowSchemas
-
getDraft
-
getDrafts
-
getOrCreateDraft
-
applyDraft
void applyDraft(User user, Workflow originalWorkflow, Map<Long, Status> statusMapping) throws ValidateException- Throws:
ValidateException
-
getPostfunctions
List<WorkflowFunctionDescriptor<WorkflowPostfunction>> getPostfunctions() -
getConditions
List<WorkflowFunctionDescriptor<WorkflowCondition>> getConditions() -
getValidators
List<WorkflowFunctionDescriptor<WorkflowValidator>> getValidators()
-