Class TutorialFrame

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Window
                           |
                           +----java.awt.Frame
                                   |
                                   +----RobotlFrame
                                           |
                                           +----SupportFrame
                                                   |
                                                   +----TutorialFrame

public class TutorialFrame
extends SupportFrame
implements ElJefe
SupportFrames are used for the example programs and tutorial windows. When created, the function reads a specified index file from the server (in index file format) and creates the text boxes and buttons.

Author:
Theo Van Dinter, Peter Sagerson
See Also:
IndexEntry, SupportFrame

Variable Index

 o moduleFrame

Constructor Index

 o TutorialFrame(String, RobotlApplet, List, Hashtable, boolean)

Method Index

 o atFirstModule()
Returns true if the first item in the list is selected.
 o atLastModule()
Returns true if the last item in the list is selected.
 o cleanup()
Informs supervisor that we're closing, cleans up the window's resources and closes it.
 o killFrame(RobotlFrame)
Removes the module window.
 o nextModule()
Selects the module immediately after the current one and returns it.
 o previousModule()
Selects the module immediately before the current one and returns it.
 o retrieveCode(String)
A wrapper for RobotlApplet.retrieveCode().
 o useCode(String)
A wrapper for RobotlApplet.setCode().
 o useSelection()
Displays the selected module.

Variables

 o moduleFrame
 ModuleFrame moduleFrame

Constructors

 o TutorialFrame
 public TutorialFrame(String title,
                      RobotlApplet inApplet,
                      List inList,
                      Hashtable inTable,
                      boolean browse)
Parameters:
title - the title of the window.
inApplet - the RobotlApplet to report to.
inList - the List the display.
inTable - the table of entries associated with inList.

Methods

 o useSelection
 public void useSelection()
Displays the selected module.

Overrides:
useSelection in class SupportFrame
 o atFirstModule
 boolean atFirstModule()
Returns true if the first item in the list is selected.

 o atLastModule
 boolean atLastModule()
Returns true if the last item in the list is selected.

 o nextModule
 public IndexEntry nextModule()
Selects the module immediately after the current one and returns it. If the last one is already selected, it is returned instead.

 o previousModule
 public IndexEntry previousModule()
Selects the module immediately before the current one and returns it. If the first one is already selected, it is returned instead.

 o retrieveCode
 public String retrieveCode(String filename)
A wrapper for RobotlApplet.retrieveCode().

 o useCode
 public void useCode(String filename)
A wrapper for RobotlApplet.setCode().

 o killFrame
 public void killFrame(RobotlFrame frame)
Removes the module window.

 o cleanup
 public void cleanup()
Informs supervisor that we're closing, cleans up the window's resources and closes it.

Overrides:
cleanup in class RobotlFrame