de.saar.chorus.ubench.gui
Class CommandListener

Object
  extended by CommandListener
All Implemented Interfaces:
ConnectionManager.StateChangeListener, ActionListener, ItemListener, EventListener

public class CommandListener
extends Object
implements ActionListener, ItemListener, ConnectionManager.StateChangeListener

The main ActionListener and ItemListener of Ubench's GUI. For file choosers, it provides some file filters and stores the last chosen path.

Author:
Alexander Koller, Michaela Regneri

Nested Class Summary
 class CommandListener.PDFFilter
          A FileFilter that accepts files with *.pdf-extension.
 class CommandListener.PDFView
          A FileView that shows PDF-Files.
 class CommandListener.XMLFilter
          A FileFilter that accepts files with *.xml-extension.
 
Constructor Summary
CommandListener()
          Creates a new Instance of CommandListener.
 
Method Summary
 void actionPerformed(ActionEvent e)
          Overwrites the actionPerformed method of ActionListener.
 void itemStateChanged(ItemEvent e)
          Overwrites the itemStateChanged method of ItemListener.
 void registerEventSource(Object source, String desc)
          TODO comment me!
 void stateChanged(ConnectionManager.State newState)
           
 
Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CommandListener

public CommandListener()
Creates a new Instance of CommandListener.

Method Detail

actionPerformed

public void actionPerformed(ActionEvent e)
Overwrites the actionPerformed method of ActionListener.

Specified by:
actionPerformed in interface ActionListener

itemStateChanged

public void itemStateChanged(ItemEvent e)
Overwrites the itemStateChanged method of ItemListener. This handles the events occuring when one of the preference checkboxes is (de-)selected.

Specified by:
itemStateChanged in interface ItemListener

registerEventSource

public void registerEventSource(Object source,
                                String desc)
TODO comment me!

Parameters:
source -
desc -

stateChanged

public void stateChanged(ConnectionManager.State newState)
Specified by:
stateChanged in interface ConnectionManager.StateChangeListener