jcreek.cke.command
Class ExitAction

java.lang.Object
  extended byjavax.swing.AbstractAction
      extended byjcreek.cke.command.CreekAction
          extended byjcreek.cke.command.SaveModelAction
              extended byjcreek.cke.command.CloseModelAction
                  extended byjcreek.cke.command.ExitAction
All Implemented Interfaces:
javax.swing.Action, java.awt.event.ActionListener, java.lang.Cloneable, java.util.EventListener, java.beans.PropertyChangeListener, java.io.Serializable

public class ExitAction
extends CloseModelAction

Implements the exit program action. This ensures that all opened documents are saved before exiting the Java VM.

Version:
Author:
See Also:
Serialized Form

Field Summary
 
Fields inherited from class jcreek.cke.command.SaveModelAction
sd
 
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
 
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
ExitAction()
          Creates a new ExitAction object with the default action command string of "exit".
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent event)
          Performs the exit action.
 void propertyChange(java.beans.PropertyChangeEvent e)
           
 
Methods inherited from class jcreek.cke.command.CloseModelAction
closeDocuments, finish
 
Methods inherited from class jcreek.cke.command.SaveModelAction
askToSave, centerComponent, noCurrentKM, saveFile
 
Methods inherited from class jcreek.cke.command.CreekAction
getDocument, getModel, getString, getView, getWindow, noCurrentDocument
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExitAction

public ExitAction()
Creates a new ExitAction object with the default action command string of "exit".

Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent event)
Performs the exit action. This saves all the open documents and then closes the main window associated with the invoker of this event.

Specified by:
actionPerformed in interface java.awt.event.ActionListener
Overrides:
actionPerformed in class CloseModelAction
Parameters:
event - action event

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent e)
Specified by:
propertyChange in interface java.beans.PropertyChangeListener
Overrides:
propertyChange in class SaveModelAction


Created at IDI, NTNU by the Artificial Intelligence and Learning group