gshute.ioutil
Class CircularListTester

java.lang.Object
  |
  +--gshute.ioutil.Tester
        |
        +--gshute.ioutil.CircularListTester

public class CircularListTester
extends Tester

This class provides a main() method for testing the CircularList class.


Field Summary
protected  java.util.Hashtable lists
          lists is a table of lists for this CircularListTester.
 
Fields inherited from class gshute.ioutil.Tester
commandStream, commandTable, prompt
 
Constructor Summary
CircularListTester()
           
 
Method Summary
 void addCommands()
          addCommands() adds testing commands to the command table.
static void main(java.lang.String[] args)
          If this program is executed with no command line argument then it executes commands entered from the terminal.
protected  CircularList readList(LineScanner ls)
          readList(ls) reads the next argument of ls and returns the list that it names, provided the name is registered in lists.
 
Methods inherited from class gshute.ioutil.Tester
doCommands, openStream, startInteractive
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

lists

protected java.util.Hashtable lists
lists is a table of lists for this CircularListTester.
Constructor Detail

CircularListTester

public CircularListTester()
Method Detail

addCommands

public void addCommands()
addCommands() adds testing commands to the command table.
Overrides:
addCommands in class Tester

readList

protected CircularList readList(LineScanner ls)
readList(ls) reads the next argument of ls and returns the list that it names, provided the name is registered in lists. Otherwise, an error message is added to ls and null is returned.

main

public static void main(java.lang.String[] args)
                 throws java.io.FileNotFoundException,
                        java.io.IOException
If this program is executed with no command line argument then it executes commands entered from the terminal. If this program is executed with a single command-line argument then that argument is interpreted as a file name. The program attempts to open the named file and execute the commands in it. If the open fails, or if there is more than one command-line argument, then the program terminates with an error message.