Class WorkflowStreamingAccumulator

java.lang.Object
com.scivicslab.pojoactor.core.accumulator.StreamingAccumulator
com.scivicslab.turingworkflow.plugins.logoutput.WorkflowStreamingAccumulator
All Implemented Interfaces:
com.scivicslab.pojoactor.core.accumulator.Accumulator

public class WorkflowStreamingAccumulator extends com.scivicslab.pojoactor.core.accumulator.StreamingAccumulator
StreamingAccumulator with cowsay display support for Turing-workflow.

This accumulator extends StreamingAccumulator to add cowsay ASCII art visualization for workflow step transitions.

Since:
1.0
Author:
devteam@scivicslab.com
  • Constructor Details

    • WorkflowStreamingAccumulator

      public WorkflowStreamingAccumulator()
      Constructs a new WorkflowStreamingAccumulator with the default cow character.
  • Method Details

    • setCowfile

      public void setCowfile(String cowfile)
      Sets the cowfile name for cowsay output.
      Parameters:
      cowfile - the cowfile name (e.g., "tux", "dragon"), or null for default cow
    • getCowfile

      public String getCowfile()
      Returns the current cowfile name.
      Returns:
      the cowfile name, or null if the default cow is used
    • renderCowsay

      public String renderCowsay(String workflowName, String stepYaml)
      Renders a workflow step as cowsay ASCII art and returns the result.
      Parameters:
      workflowName - the name of the workflow
      stepYaml - the YAML representation of the step
      Returns:
      the rendered cowsay ASCII art string
    • listCowfiles

      public static String[] listCowfiles()
      Lists all available cowfile names.
      Returns:
      array of available cowfile names