Class AvaDisplayComponent

java.lang.Object
edu.tufts.hrilab.diarc.DiarcComponent
edu.tufts.hrilab.ava.AvaDisplayComponent

public class AvaDisplayComponent extends DiarcComponent
Class representing the display functionality on the screen of the Ava robot. More specifically the high level interaction between Ava/DIARC and the granular canvas
  • Constructor Details

    • AvaDisplayComponent

      public AvaDisplayComponent()
  • 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
    • refreshMedia

      public void refreshMedia()
    • postRegistrationInit

      protected void postRegistrationInit()
      Overrides:
      postRegistrationInit in class DiarcComponent
    • getVideosDir

      public String getVideosDir()
    • getUserImageDir

      public String getUserImageDir()
    • deleteMedia

      public void deleteMedia(String path)
    • stopIdleImageCycle

      public void stopIdleImageCycle()
    • startIdleImageCycle

      public void startIdleImageCycle()
    • hideListeningIndicator

      public void hideListeningIndicator()
    • setListeningIndicator

      public void setListeningIndicator(boolean visible)
    • registerDialogueCallback

      public void registerDialogueCallback(ai.thinkingrobots.trade.TRADEServiceInfo service)
      Registers avaDisplayDialogueCallback as the callback service for dialog events.
    • setSuggestedInput

      public void setSuggestedInput(String suggestedInput)
    • displayImageWithName

      public boolean displayImageWithName(String imageName, Symbol timeoutSymbol)
    • displayImageWithName

      public boolean displayImageWithName(String imageName, long timeout)
    • displaySlideWithName

      public void displaySlideWithName(String presentationName, String imageName, long timeout)
    • interruptDisplayImageWithName

      public void interruptDisplayImageWithName()
    • displayNextVideo

      public void displayNextVideo()
    • isVideoSaved

      public boolean isVideoSaved(String name)
    • displayVideoMatching

      public boolean displayVideoMatching(String match)
    • isMediaPlaying

      public boolean isMediaPlaying()
    • cancelVideoPlayback

      public void cancelVideoPlayback()
    • pauseVideoPlayback

      public void pauseVideoPlayback()
    • resumeVideoPlayback

      public void resumeVideoPlayback()
    • clearImage

      public void clearImage()
      Exposed TRADE service for clearing image on the DisplayCanvas.
    • clearText

      public void clearText()
      Exposed TRADE service for clearing text on the DisplayCanvas.
    • displayText

      public void displayText(String text)
      Exposed TRADE service for displaying text on the DisplayCanvas.
      Parameters:
      text - string to display
    • displayText

      public void displayText(String text, long timeout)
    • avaDisplayDialogueCallback

      public void avaDisplayDialogueCallback(Utterance utterance, boolean newAddition)
      Callback TRADE service to receive dialogue events and display them on the DisplayCanvas.
      Parameters:
      utterance - object from dialogue history
    • getVideoNames

      public List<String> getVideoNames(boolean includeFileEndings)
    • getImageNames

      public List<String> getImageNames(boolean includeFileEndings)
    • getUserIdleImageNames

      public List<String> getUserIdleImageNames()
      Returns the list of uploaded image names currently used as idle images.
    • setUserIdleImageNames

      public void setUserIdleImageNames(List<String> names)
      Sets which uploaded images are used as idle images. Only image names that exist in userImages are stored.
    • setVideoVolume

      public boolean setVideoVolume(Symbol volumeSymbol)
    • setVideoVolume

      public boolean setVideoVolume(int volume)
    • getVideoVolume

      public int getVideoVolume()
    • lowerVideoVolume

      public boolean lowerVideoVolume()
    • raiseVideoVolume

      public boolean raiseVideoVolume()
    • deletePresentationSlides

      public void deletePresentationSlides(String presentationName)
    • learnNewPresentationAction

      public boolean learnNewPresentationAction(String presentationName, List<String> slideFilenames, long duration)
    • additionalUsageInfo

      protected List<org.apache.commons.cli.Option> additionalUsageInfo()
      Description copied from class: DiarcComponent
      Override this method to define 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
      Override this method to parse command line args in the sub-class. Called directly after construction to pass runtime values that will override default values. This should parse all the options that additionalUsageInfo provides.
      Overrides:
      parseArgs in class DiarcComponent
    • shutdownComponent

      public void shutdownComponent()
      Description copied from class: DiarcComponent
      Any component that needs particular shutdown logic needs to override this method and
      Overrides:
      shutdownComponent in class DiarcComponent