com.jgoodies.uif.application
Interface ExitListener

All Superinterfaces:
EventListener

public interface ExitListener
extends EventListener

Describes listeners that hook into the application shutdown process. Implementors can veto against an application shutdown, for example if there are unsaved documents. And implementors can perform operations on application shutdown, for example persist data.

Since:
1.8
Version:
$Revision: 1.5 $
Author:
Karsten Lentzsch
See Also:
Application.exit(EventObject), Application.addExitListener(ExitListener), Application.removeExitListener(ExitListener)

Method Summary
 boolean applicationExitAllowed(EventObject event)
          Checks and answers whether the application may exit or not.
 void applicationExiting()
          Invoked if the application is exiting.
 

Method Detail

applicationExitAllowed

boolean applicationExitAllowed(EventObject event)
Checks and answers whether the application may exit or not. Useful to veto against the application exit. The given event has a source which can be used to determine where to open dialogs in case you veto against a shutdown.

Parameters:
event - the event that caused the application to exit
Returns:
true if this listener does not veto against the exit, false if it vetoes

applicationExiting

void applicationExiting()
Invoked if the application is exiting.



Copyright © 2000-2008 JGoodies Karsten Lentzsch. All Rights Reserved.