Class WorkflowInterpreter

java.lang.Object
org.springframework.extensions.surf.util.AbstractLifecycleBean
org.alfresco.repo.admin.BaseInterpreter
org.alfresco.repo.workflow.WorkflowInterpreter
All Implemented Interfaces:
EventListener, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener

public class WorkflowInterpreter extends BaseInterpreter
An interactive console for Workflows.
Author:
davidc
  • Constructor Details

    • WorkflowInterpreter

      public WorkflowInterpreter()
  • Method Details

    • onBootstrap

      protected void onBootstrap(org.springframework.context.ApplicationEvent event)
      Overrides:
      onBootstrap in class BaseInterpreter
    • onShutdown

      protected void onShutdown(org.springframework.context.ApplicationEvent event)
      Overrides:
      onShutdown in class BaseInterpreter
    • setWorkflowService

      public void setWorkflowService(WorkflowService workflowService)
      Parameters:
      workflowService - The Workflow Service
    • setNodeService

      public void setNodeService(NodeService nodeService)
      Parameters:
      nodeService - The Node Service
    • setTenantService

      public void setTenantService(TenantService tenantService)
      Parameters:
      tenantService - The Tenant Service
    • setDictionaryService

      public void setDictionaryService(DictionaryService dictionaryService)
      Parameters:
      dictionaryService - dictionaryService
    • setNamespaceService

      public void setNamespaceService(NamespaceService namespaceService)
      Parameters:
      namespaceService - namespaceService
    • setPersonService

      public void setPersonService(PersonService personService)
      Parameters:
      personService - personService
    • setTransactionService

      public void setTransactionService(TransactionService transactionService)
      Overrides:
      setTransactionService in class BaseInterpreter
      Parameters:
      transactionService - transactionService
    • setAuthorityDAO

      public void setAuthorityDAO(AuthorityDAO authorityDAO)
      Parameters:
      authorityDAO - authorityDAO
    • setFileFolderService

      public void setFileFolderService(FileFolderService fileFolderService)
      Parameters:
      fileFolderService - fileFolderService
    • main

      public static void main(String[] args)
      Main entry point.
    • hasAuthority

      protected boolean hasAuthority(String username)
      Overrides:
      hasAuthority in class BaseInterpreter
    • executeCommand

      protected String executeCommand(String line) throws IOException
      Execute a single command using the BufferedReader passed in for any data needed. TODO: Use decent parser!
      Specified by:
      executeCommand in class BaseInterpreter
      Parameters:
      line - The unparsed command
      Returns:
      The textual output of the command.
      Throws:
      IOException
    • getCurrentWorkflowDef

      public WorkflowDefinition getCurrentWorkflowDef()
      Get currently used workflow definition
      Returns:
      workflow definition