com.tensegrity.application.swing
Class DefaultSwingGraphApplication

java.lang.Object
  extended bycom.tensegrity.application.DefaultGraphApplication
      extended bycom.tensegrity.application.swing.DefaultSwingGraphApplication
All Implemented Interfaces:
Application, GraphApplication
Direct Known Subclasses:
CompatibleSwingGraphApplication

public abstract class DefaultSwingGraphApplication
extends DefaultGraphApplication

DefaultSwingGraphApplication is an abstract default implementation of a GraphApplication for applications using the Swing/AWT window toolkit.

It is a subclass of DefaultGraphApplication to make use of common functionality.

Author:
BurkhardWick

Field Summary
 
Fields inherited from class com.tensegrity.application.DefaultGraphApplication
applicationFrames
 
Constructor Summary
DefaultSwingGraphApplication(Applet applet)
          Constructor
 
Method Summary
 CommandRegistry getCommandRegistry()
          Overridden to return a specific SwingCommandRegistry.
 KeyStrokeProvider getKeyStrokeProvider()
          Overridden to return a specific SwingKeyStrokeProvider.
 UIManager getUIManager()
          Overridden to return a specific AWT UIManager.
protected  void initGraphicsEnvironment()
          Implementations of this method should initialize the graphics environment. e.g. instances of TextOperations and ImageOperations should be registered here.
 boolean launch()
          Launches the application.
 void showError(java.lang.String errormessage)
          Asks the application to show an error message-box with the given text.
 
Methods inherited from class com.tensegrity.application.DefaultGraphApplication
createApplicationFrames, getApplet, getApplicationFrame, getApplicationFrames, getDefaultLayoutController, getDragContext, getLocale, getPreferenceHelp, getPreferences, getRuleRegistry, getUIManagerResources, initLocale, savePreferences, setPreferenceHelp, setPreferences, setRuleRegistry, shutDown
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.tensegrity.application.Application
getDefaultPreferencesFileName, getDefaultPreferencesLoadClass, getPreferencesFileName, getTitle
 

Constructor Detail

DefaultSwingGraphApplication

public DefaultSwingGraphApplication(Applet applet)
Constructor

Parameters:
applet - The applet context this application is running in or null if it is standalone
Method Detail

initGraphicsEnvironment

protected void initGraphicsEnvironment()
Description copied from class: DefaultGraphApplication
Implementations of this method should initialize the graphics environment. e.g. instances of TextOperations and ImageOperations should be registered here.

Specified by:
initGraphicsEnvironment in class DefaultGraphApplication

getKeyStrokeProvider

public KeyStrokeProvider getKeyStrokeProvider()
Overridden to return a specific SwingKeyStrokeProvider.

Returns:
the KeyStrokeProvider instance of this Application.
See Also:
Application.getKeyStrokeProvider()

showError

public void showError(java.lang.String errormessage)
Description copied from interface: Application
Asks the application to show an error message-box with the given text.

Specified by:
showError in interface Application
Overrides:
showError in class DefaultGraphApplication

getUIManager

public UIManager getUIManager()
Overridden to return a specific AWT UIManager.

Returns:
a reference to the currently used UIManager.
See Also:
Application.getUIManager()

getCommandRegistry

public CommandRegistry getCommandRegistry()
Overridden to return a specific SwingCommandRegistry.

Specified by:
getCommandRegistry in interface Application
Overrides:
getCommandRegistry in class DefaultGraphApplication
See Also:
Application.getCommandRegistry()

launch

public boolean launch()
Description copied from interface: Application
Launches the application. If an applet is present, the application is launched as an applet.

Returns:
true if the launch was successful


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.