All Packages Class Hierarchy This Package Previous Next Index WEKA's home
Class weka.gui.SimpleCLI
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----java.awt.Window
|
+----java.awt.Frame
|
+----weka.gui.SimpleCLI
- public class SimpleCLI
- extends Frame
- implements ActionListener
Creates a very simple command line for invoking the main method of
classes. System.out and System.err are redirected to an output area.
Features a simple command history -- use up and down arrows to move
through previous commmands. This gui uses only AWT (i.e. no Swing).
- Version:
- $Revision: 1.2 $
- Author:
- Len Trigg (trigg@cs.waikato.ac.nz)
-
SimpleCLI()
- Constructor
-
actionPerformed(ActionEvent)
- Only gets called when return is pressed in the input area, which
starts the command running.
-
doHistory(KeyEvent)
- Changes the currently displayed command line when certain keys
are pressed.
-
main(String[])
- Method to start up the simple cli
-
runCommand(String)
- Executes a simple cli command.
SimpleCLI
public SimpleCLI() throws Exception
- Constructor
- Throws: Exception
- if an error occurs
runCommand
public void runCommand(String commands) throws Exception
- Executes a simple cli command.
- Parameters:
- commands - the command string
- Throws: Exception
- if an error occurs
doHistory
public void doHistory(KeyEvent e)
- Changes the currently displayed command line when certain keys
are pressed. The up arrow moves back through history entries
and the down arrow moves forward through history entries.
- Parameters:
- e - a value of type 'KeyEvent'
actionPerformed
public void actionPerformed(ActionEvent e)
- Only gets called when return is pressed in the input area, which
starts the command running.
- Parameters:
- e - a value of type 'ActionEvent'
main
public static void main(String args[])
- Method to start up the simple cli
- Parameters:
- args - array of command line arguments. Not used.
All Packages Class Hierarchy This Package Previous Next Index WEKA's home