Class AnalyticController

java.lang.Object
org.imixs.workflow.office.forms.AnalyticController
All Implemented Interfaces:
Serializable

@Named @ConversationScoped public class AnalyticController extends Object implements Serializable
The AnalyticController is a conversationScoped controller that provides values for the analytic-custom parts.

A custom implementation can react on AnalyticEvent to compute values and datasets.

The controller implements a caching mechanism to avoid repeated calls for new analytic values. If the analytic value is already stored in the current workitem, no new value will be fired.

Author:
rsoika
See Also:
  • Field Details

    • analyticEvents

      @Inject protected jakarta.enterprise.event.Event<AnalyticEvent> analyticEvents
    • workflowController

      @Inject protected org.imixs.workflow.faces.data.WorkflowController workflowController
  • Constructor Details

    • AnalyticController

      public AnalyticController()
  • Method Details

    • getAsString

      public String getAsString(String key)
      Returns a analytic value as a String for a given key.
      Parameters:
      key -
      Returns:
    • getAsJson

      public String getAsJson(String key)
      Returns a analytic value as a Json String for a given key.
      Parameters:
      key -
      Returns:
    • getAsDouble

      public double getAsDouble(String key)
      Returns a analytic value as a Double for a given key.
      Parameters:
      key -
      Returns:
    • getLabel

      public String getLabel(String key)
      Returns the analytic label for a given key
      Parameters:
      key -
      Returns:
    • getLink

      public String getLink(String key)
      Returns the analytic optional link for a given key
      Parameters:
      key -
      Returns:
    • getDescription

      public String getDescription(String key)
      Returns the analytic description for a given key
      Parameters:
      key -
      Returns:
    • computeValue

      protected org.imixs.workflow.ItemCollection computeValue(String key)
      Computes an analytic value. The method cache the value in the item key. An observer controller is responsible to cache or reset the cached values if needed.
      Parameters:
      key -
      Returns: