com.lightdev.app
Class DefaultApplication


java.lang.Object

  extended by com.lightdev.app.Application

      extended by com.lightdev.app.MenuApplication

          extended by com.lightdev.app.DefaultApplication

Direct Known Subclasses:
MDIApplication

public class DefaultApplication
extends MenuApplication

Default application class

This class can be used as an example for how to make use of the Light Development Application Package. It extends the abstract base class MenuApplication which in turn extends Application and initializes some basic elements such as a resource bundle or an action to exit the application.

Version:
2, February 12, 2004
Author:
Ulrich Hilger, Light Development, http://www.lightdev.com, info@lightdev.com, published under the terms and conditions of the GNU General Public License, for details see file in the distribution package of this software as well as any licensing notes inside this documentation

Field Summary
static String ACTION_ABOUT_APP
          name of the action that shows information about this application
static String ACTION_EXIT_APP
          name of the action that exits this application
static String ACTION_SHOW_HELP_CONTENTS
          name of the action that shows help for this application
 
Fields inherited from class com.lightdev.app.MenuApplication
menuSeparatorKey, RB_KEY_APP_MENUBAR
 
Fields inherited from class com.lightdev.app.Application
actionSuffix, APP_HELP_NAME, imageSuffix, JAVA_HELP_EXT, labelSuffix, logger, RB_KEY_ABOUT_APP_DIALOG_TITLE, RB_KEY_LOG_APP_CAN_NOT_EXIT, RB_KEY_LOG_APP_STARTED, RB_KEY_LOG_APP_TERMINATED, RESOURCE_NOT_FOUND, resources, selectedIconSuffix, toolTipSuffix, URL_SEPARATOR
 
Constructor Summary
DefaultApplication()
          constructor
DefaultApplication(Level level, String logDir)
           
DefaultApplication(Level level, String logDir, boolean showUi)
           
DefaultApplication(OutputStream logStream, Level level, String logDir, boolean showUi)
           
 
Method Summary
static MainFrame findMainFrame()
          find the application's main frame
protected  void initActions()
          initialize this application's action table
protected  void initMainFrame(boolean showUi)
          initialize this application's main frame
static void main(String[] args)
          main method
 
Methods inherited from class com.lightdev.app.MenuApplication
createMenu, createMenubar, createMenubar, createMenuItem, createToolBar, getMenuItem
 
Methods inherited from class com.lightdev.app.Application
about, addAction, canExit, exitApplication, getAction, getAppName, getBundle, getHelpBroker, getIconForCommand, getIconForName, getResource, getResourceString, log, logStackTrace, setLogging, setLogLevel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ACTION_EXIT_APP


public static final String ACTION_EXIT_APP
name of the action that exits this application

See Also:
Constant Field Values

ACTION_ABOUT_APP


public static final String ACTION_ABOUT_APP
name of the action that shows information about this application

See Also:
Constant Field Values

ACTION_SHOW_HELP_CONTENTS


public static final String ACTION_SHOW_HELP_CONTENTS
name of the action that shows help for this application

See Also:
Constant Field Values
Constructor Detail

DefaultApplication


public DefaultApplication()
constructor


DefaultApplication


public DefaultApplication(Level level,

                          String logDir)

DefaultApplication


public DefaultApplication(Level level,

                          String logDir,

                          boolean showUi)

DefaultApplication


public DefaultApplication(OutputStream logStream,

                          Level level,

                          String logDir,

                          boolean showUi)
Method Detail

initActions


protected void initActions()
initialize this application's action table

Overrides:
initActions in class Application

initMainFrame


protected void initMainFrame(boolean showUi)
initialize this application's main frame


findMainFrame


public static MainFrame findMainFrame()
find the application's main frame

Returns:
MainFrame the main frame of this application or null, if none was found

main


public static void main(String[] args)
main method

Parameters:
args - String[] command line arguments

Copyright (c) 2004, 2005 Ulrich Hilger