net.sourceforge.pavlov.controllers
Class ChapterCoverage

java.lang.Object
  extended by net.sourceforge.sillyview.Widget
      extended by net.sourceforge.pavlov.controllers.ChapterCoverage
All Implemented Interfaces:
AnswerListener

public final class ChapterCoverage
extends Widget
implements AnswerListener

A GUI widget that shows the user information about his global history with this chapter.

Since:
1.1

Field Summary
static String NUM_ANSWERED
          Describe constant NUM_ANSWERED here.
static String NUM_ANSWERED_ONLY_WRONG
          Describe constant NUM_ANSWERED_ONLY_WRONG here.
static String NUM_ANSWERED_RIGHT
          Describe constant NUM_ANSWERED_RIGHT here.
static String NUM_NOT_ANSWERED
          Describe constant NUM_NOT_ANSWERED here.
static String NUM_QUESTIONS
          Describe constant NUM_QUESTIONS here.
static String NUM_RIGHT_ANSWERS
          Describe constant NUM_RIGHT_ANSWERS here.
static String NUM_WRONG_ANSWERS
          Describe constant NUM_WRONG_ANSWERS here.
static String PCT_ANSWERED
          Describe constant PCT_ANSWERED here.
static String PCT_RIGHT_ANSWERS
          Describe constant PCT_RIGHT_ANSWERS here.
static String PCT_WRONG_ANSWERS
          Describe constant PCT_WRONG_ANSWERS here.
 
Fields inherited from class net.sourceforge.sillyview.Widget
view
 
Constructor Summary
ChapterCoverage(WidgetView myView, ChapterData _cd)
          Creates a new TextCoverageWidget instance.
 
Method Summary
 void answerEvent(AnswerEvent e)
          User answered a question, refresh statistics and generate text.
 
Methods inherited from class net.sourceforge.sillyview.Widget
getView, setView
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NUM_ANSWERED

public static final String NUM_ANSWERED
Describe constant NUM_ANSWERED here.

See Also:
Constant Field Values

NUM_ANSWERED_ONLY_WRONG

public static final String NUM_ANSWERED_ONLY_WRONG
Describe constant NUM_ANSWERED_ONLY_WRONG here.

See Also:
Constant Field Values

NUM_ANSWERED_RIGHT

public static final String NUM_ANSWERED_RIGHT
Describe constant NUM_ANSWERED_RIGHT here.

See Also:
Constant Field Values

NUM_NOT_ANSWERED

public static final String NUM_NOT_ANSWERED
Describe constant NUM_NOT_ANSWERED here.

See Also:
Constant Field Values

NUM_QUESTIONS

public static final String NUM_QUESTIONS
Describe constant NUM_QUESTIONS here.

See Also:
Constant Field Values

NUM_RIGHT_ANSWERS

public static final String NUM_RIGHT_ANSWERS
Describe constant NUM_RIGHT_ANSWERS here.

See Also:
Constant Field Values

NUM_WRONG_ANSWERS

public static final String NUM_WRONG_ANSWERS
Describe constant NUM_WRONG_ANSWERS here.

See Also:
Constant Field Values

PCT_ANSWERED

public static final String PCT_ANSWERED
Describe constant PCT_ANSWERED here.

See Also:
Constant Field Values

PCT_RIGHT_ANSWERS

public static final String PCT_RIGHT_ANSWERS
Describe constant PCT_RIGHT_ANSWERS here.

See Also:
Constant Field Values

PCT_WRONG_ANSWERS

public static final String PCT_WRONG_ANSWERS
Describe constant PCT_WRONG_ANSWERS here.

See Also:
Constant Field Values
Constructor Detail

ChapterCoverage

public ChapterCoverage(WidgetView myView,
                       ChapterData _cd)
Creates a new TextCoverageWidget instance.

Parameters:
myView - a WidgetView value
_cd - a ChapterData value
Method Detail

answerEvent

public void answerEvent(AnswerEvent e)
User answered a question, refresh statistics and generate text.

Specified by:
answerEvent in interface AnswerListener
Parameters:
e - a AnswerEvent value