[operations] [attributes] [fields] [template] [definition]
[implementation] [documentation]
To use the search tool you need to use a browser which supports JAVA (c)

[next] [prev] [superclass] [next peer] [prev peer] [subclass] [index] [hierarchy]

LessonTool

inherits from ChooseableTool

Object <- ChooseableTool <- LessonTool



Operations

Get list of all operations

AbortLesson
AbortLessonWithAnnouncement
AbortLessonWithConfirm
AbortSuspendedLesson
NextStep
PrepareLesson
ShouldForceBorders
TouchAsTouchTool
TouchTarget


Attributes

Get list of all attributes

CurrentStepNum
Lesson
LessonWindow
Suspended


Fields

Field Type
ChooseableTool: image: Image
LessonTool: lesson: LessonStepList
horzWindow: LessonWindow
vertWindow: LessonWindow
bigWindow: LessonWindow
bootWindow: LessonWindow
currentWindow: LessonWindow
currentStep: LessonStep
currentStepNum: Unsigned
suspended: Boolean


Instance template

instance LessonTool tag;
          image: nilObject;
         lesson: nilObject;
     horzWindow: nilObject;
     vertWindow: nilObject;
      bigWindow: nilObject;
     bootWindow: nilObject;
  currentWindow: nilObject;
    currentStep: nilObject;
 currentStepNum: 0;
      suspended: false;
end instance;

Class definition

Define Class LessonTool;
    inherits from ChooseableTool;

    field lesson:           LessonStepList, getter, setter; 
        //  the associated list of steps
    field horzWindow:       LessonWindow;                   
        //  the horizontal lesson window
    field vertWindow:       LessonWindow;                   
        //  the vertical lesson window
    field bigWindow:        LessonWindow;                   
        //  the large stepInfo window
    field bootWindow:       LessonWindow;                   
        //  the screen-covering window used at boot
    field currentWindow:    LessonWindow;                   
        //  the window used by current step
    field currentStep:      LessonStep;                     
        //  the step currently executing
    field currentStepNum:   Unsigned, getter, setter;       
        //  which step is onscreen now
    field suspended:        Boolean, getter;

    operation PrepareLesson(stepList: Object);              
        //  begins a lesson
    operation NextStep(), safe, common;                     
        //  advances to the next step in the lesson
    operation AbortLesson(), safe, common;                  
        //  hide the lesson window and reset touch tool
    operation AbortLessonWithAnnouncement(announcement: Announcement);  
        // tell the user why lesson was aborted
    operation AbortLessonWithConfirm(), safe, common;       
        //  show confirm dialog for aborting the lesson
    operation AbortSuspendedLesson();                       
        //  if a lesson is suspended, abort it and tell the user
    overrides ShouldForceBorders;                           
        //  returns false
    operation TouchAsTouchTool(touchInput: TouchInput);     
        //  redispatches touch after setting touch tool
    overrides TouchTarget;                                  
        //  checks step conditions to handle various situations
    
    attribute CurrentStepNum:   Unsigned, safe;             
        //  current step's position in lesson
    attribute Lesson:           LessonStepList;             
        //  public interface for list of steps
    attribute LessonWindow:     LessonWindow, readOnly;     
        //  public interface for current lesson window
    attribute Suspended:        Boolean, safe;              
        //  is lesson currently suspended?
end class;