Class WorkflowServiceImpl

    • Constructor Detail

      • WorkflowServiceImpl

        public WorkflowServiceImpl()
        Deprecated, for removal: This API element is subject to removal in a future version.
    • Method Detail

      • addComment

        public void addComment​(java.lang.Object comment,
                               WorkflowActionModel action)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        addComment in interface WorkflowService
      • evaluteActivationScripts

        public void evaluteActivationScripts​(ItemModel itemModel,
                                             java.util.Map currentValues,
                                             java.util.Map initialValues,
                                             java.lang.String action)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        evaluteActivationScripts in interface WorkflowService
      • getInterpreter

        protected bsh.Interpreter getInterpreter()
        Deprecated, for removal: This API element is subject to removal in a future version.
      • createWorkflow

        public WorkflowModel createWorkflow​(java.lang.String workflowName,
                                            WorkflowTemplateModel template,
                                            java.util.List<ItemModel> itemsToAdd)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Creates workflow out of given template with given name but does NOT start it. Given list of items is attached to it.
        Specified by:
        createWorkflow in interface WorkflowService
      • isAutomatedComment

        @Deprecated(since="ages",
                    forRemoval=true)
        public boolean isAutomatedComment​(WorkflowActionCommentModel comment)
        Deprecated, for removal: This API element is subject to removal in a future version.
        since ages
        Specified by:
        isAutomatedComment in interface WorkflowService
      • getAllWorkflows

        public java.util.List<WorkflowModel> getAllWorkflows​(int workflowsStatuses,
                                                             int adhocWorkflowsStatuses,
                                                             java.util.Date dateFrom,
                                                             java.util.Date dateTo,
                                                             java.util.Date adhocDateFrom,
                                                             java.util.Date adhocDateTo)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        getAllWorkflows in interface WorkflowService
        Parameters:
        workflowsStatuses - 0 - all, see WorkflowConstants.WorkflowStatus for other values
        adhocWorkflowsStatuses - 0 - all, see WorkflowConstants.WorkflowStatus for other values
        Returns:
        List of workflows fulfilling given criteria, e.g. if only planned and running workflows should be returned then put 3 as workflowsStatuses and 0 for adhocWorkflowsStatuses.
      • getWorkflowDao

        public WorkflowDAO getWorkflowDao()
        Deprecated, for removal: This API element is subject to removal in a future version.
      • createAdhocWorkflow

        public WorkflowModel createAdhocWorkflow​(java.lang.String defaultName,
                                                 java.util.List<ItemModel> itemsToAdd)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        createAdhocWorkflow in interface WorkflowService
        Parameters:
        defaultName - of adhoc workflow
        itemsToAdd - list of items to add
        Returns:
        created adhoc workflow
      • setWorkflowDao

        public void setWorkflowDao​(WorkflowDAO workflowDao)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Parameters:
        workflowDao - the workflowDao to set
      • assignUser

        public void assignUser​(PrincipalModel principalModel,
                               WorkflowModel workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        assignUser in interface WorkflowService
        Parameters:
        principalModel - to assign to given workflow
      • setModelService

        public void setModelService​(ModelService modelService)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Parameters:
        modelService - the modelService to set
      • getAllVisibleWorkflowTemplates

        public java.util.List<WorkflowTemplateModel> getAllVisibleWorkflowTemplates()
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        getAllVisibleWorkflowTemplates in interface WorkflowService
        Returns:
        all visible workflow templates for current session user, including templates that user is owner of, excluding special adhoc-workflow template
      • getUserService

        public UserService getUserService()
        Deprecated, for removal: This API element is subject to removal in a future version.
        Returns:
        the userService
      • setUserService

        public void setUserService​(UserService userService)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Parameters:
        userService - the userService to set
      • isPaused

        public boolean isPaused​(java.lang.Object workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        isPaused in interface WorkflowService
        Parameters:
        workflowModel - or adhoc workflow model
        Returns:
        true if workflow is paused
      • startWorkflow

        public void startWorkflow​(ItemModel workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        startWorkflow in interface WorkflowService
      • isTerminated

        public boolean isTerminated​(java.lang.Object workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        isTerminated in interface WorkflowService
        Parameters:
        workflowModel - or adhoc workflow model
        Returns:
        true if workflow is terminated
      • isPlanned

        public boolean isPlanned​(java.lang.Object workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        isPlanned in interface WorkflowService
        Parameters:
        workflowModel - or adhoc workflow model
        Returns:
        true if workflow is planned
      • isRunning

        public boolean isRunning​(java.lang.Object workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Description copied from interface: WorkflowService
        * @deprecated as of release 4.3, please use WorkflowService.isRunning(WorkflowModel)
        Specified by:
        isRunning in interface WorkflowService
        Parameters:
        workflowModel - or adhoc workflow model
        Returns:
        true if workflow is running
      • isFinished

        public boolean isFinished​(java.lang.Object workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        isFinished in interface WorkflowService
        Parameters:
        workflowModel - or adhoc workflow model
        Returns:
        true if workflow is finished
      • addItems

        public void addItems​(ItemModel workflowModel,
                             java.util.List<ItemModel> itemsToAdd)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        addItems in interface WorkflowService
      • containsItem

        public ItemModel containsItem​(ItemModel workflowModel,
                                      java.util.List<ItemModel> itemsToAdd)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        containsItem in interface WorkflowService
        Returns:
        first item from given list found in workflow, null otherwise
      • isAdhocWorkflow

        public boolean isAdhocWorkflow​(WorkflowModel workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        isAdhocWorkflow in interface WorkflowService
        Returns:
        true if given workflow was created out of adhoc-workflow template
      • canBeStarted

        public boolean canBeStarted​(WorkflowModel workf)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        canBeStarted in interface WorkflowService
        Returns:
        true if given workflow can be started, false otherwise (e.g. when there are is no user assigned)
      • getStartTime

        public java.util.Date getStartTime​(WorkflowModel workflow)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        getStartTime in interface WorkflowService
        Returns:
        start time of given workflow
      • unassignUser

        public void unassignUser​(PrincipalModel principalModel,
                                 WorkflowModel workflowModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Specified by:
        unassignUser in interface WorkflowService
        Parameters:
        principalModel - to unassign from given adhoc workflow