Class UIComponent

java.lang.Object
edu.tufts.hrilab.diarc.DiarcComponent
edu.tufts.hrilab.temiv3.UIComponent
All Implemented Interfaces:
ActionListener
Direct Known Subclasses:
FirebaseConnectionComponent

public abstract class UIComponent extends DiarcComponent implements ActionListener
  • Constructor Details

    • UIComponent

      public UIComponent()
  • Method Details

    • init

      protected void init()
      Description copied from class: DiarcComponent
      Perform any component initialization. This should not be used for setting local fields to default values as was the case in DIARC. This method is called after the constructor, and after parseArgs. Setting default values should be done in field declaration or in the constructor.
      Overrides:
      init in class DiarcComponent
    • additionalUsageInfo

      protected List<org.apache.commons.cli.Option> additionalUsageInfo()
      Description copied from class: DiarcComponent
      Command line options available in sub-class. This should be paired with a parseArgs implementation.
      Overrides:
      additionalUsageInfo in class DiarcComponent
      Returns:
    • parseArgs

      protected void parseArgs(org.apache.commons.cli.CommandLine cmdLine)
      Description copied from class: DiarcComponent
      Called directly after construction to pass runtime values that will override default values. This should parse all the options that additionalUsageInfo provides.zs
      Overrides:
      parseArgs in class DiarcComponent
    • executionLoop

      protected void executionLoop()
      Description copied from class: DiarcComponent
      This is where any code that needs to be called repeatedly in a dedicated thread should live. It is not called by default and you must set shouldRunExecutionLoop to true in your constructor.
      Overrides:
      executionLoop in class DiarcComponent
    • onAgentActionUpdated

      public abstract void onAgentActionUpdated(String actor, String goal, String status)
    • onActiveGoalsUpdated

      public abstract void onActiveGoalsUpdated(List<String> agentStrings, List<String> goalStrings, List<Long> gids, List<String> goalStatuses, List<String> goalPriorityTiers)
    • onPendingGoalsUpdated

      public abstract void onPendingGoalsUpdated(List<String> agentStrings, List<String> goalStrings, List<Long> gids, List<String> goalStatuses, List<String> goalPriorityTiers)
    • onActionGenerated

      public abstract void onActionGenerated(ActionDBEntry action, boolean onStartup)
    • onBeliefNotificationUpdate

      public abstract void onBeliefNotificationUpdate(String queryTermString, Map<String,Object> bindingsStrings)
    • onDictionaryEntriesUpdated

      public abstract void onDictionaryEntriesUpdated(Set<String> keys)
    • notifyPendingGoalUpdated

      public void notifyPendingGoalUpdated(Goal g, int index, ExecutionManager.UpdateType updateType)
    • notifyActiveGoalUpdated

      public void notifyActiveGoalUpdated(Goal g, ExecutionManager.UpdateType updateType, GoalStatus status)
    • onNewActionsCallback

      public void onNewActionsCallback(List<ActionDBEntry> actions)
    • beliefNotificationCallback

      public void beliefNotificationCallback(Term query, List<Map<Variable,Symbol>> bindings)
    • actionStarted

      public void actionStarted(ActionInterpreter ai)
      Specified by:
      actionStarted in interface ActionListener
    • actionComplete

      public void actionComplete(ActionInterpreter ai)
      Specified by:
      actionComplete in interface ActionListener
    • stepStarted

      public void stepStarted(Context step)
      Specified by:
      stepStarted in interface ActionListener
    • stepComplete

      public void stepComplete(Context step)
      Specified by:
      stepComplete in interface ActionListener
    • addRelevantDisplayAction

      public void addRelevantDisplayAction(String name)
    • convertArgToReadable

      public String convertArgToReadable(String arg)