Interface QuestionRecorder<T>

Type Parameters:
T - the type of question handled by this recorder
All Superinterfaces:
Serializable

@Role public interface QuestionRecorder<T> extends Serializable
Component used to record the answers given to a specific type of questions and to replay the recorded answers later in case those questions are asked again.
Since:
7.1RC1
Version:
$Id: 8509bad61637455b39fc1b980ec6f36e1810eb90 $
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    record(T question)
    Record the answer to the given question.
    boolean
    replay(T question)
    Respond to the given question using a recorded answer, if available.
  • Method Details

    • record

      void record(T question)
      Record the answer to the given question. The answer is included in the object that represents the question.
      Parameters:
      question - the question that has been asked and its answer
    • replay

      boolean replay(T question)
      Respond to the given question using a recorded answer, if available.
      Parameters:
      question - the question that must be answered
      Returns:
      true if there is a recorded answer for the given question (which is used to answer the question), false if there is not recorded answer for the given question