org.openide.util 6.8.22

Class LifecycleManager

  extended by org.openide.LifecycleManager

public abstract class LifecycleManager
extends Object

Manages major aspects of the NetBeans lifecycle - currently saving all objects and exiting.


Constructor Summary
protected LifecycleManager()
          Subclass constructor.
Method Summary
abstract  void exit()
          Exit NetBeans.
static LifecycleManager getDefault()
          Get the default lifecycle manager.
abstract  void saveAll()
          Save all opened objects.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


protected LifecycleManager()
Subclass constructor.

Method Detail


public static LifecycleManager getDefault()
Get the default lifecycle manager. Normally this is found in Lookup.getDefault() but if no instance is found there, a fallback instance is returned which behaves as follows:
  1. saveAll() does nothing
  2. exit() calls System.exit(int) with an exit code of 0
This is useful for unit tests and perhaps standalone library usage.

the default instance (never null)


public abstract void saveAll()
Save all opened objects.


public abstract void exit()
Exit NetBeans. This method will return only if System.exit(int) fails, or if at least one component of the system refuses to exit (because it cannot be properly shut down).

org.openide.util 6.8.22

Built on July 11 2007.  |  Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.