|
JHotDraw 7.0.9 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jhotdraw.beans.AbstractBean
org.jhotdraw.app.AbstractApplication
public abstract class AbstractApplication
AbstractApplication.
Field Summary | |
---|---|
protected ResourceBundleUtil |
labels
|
Fields inherited from class org.jhotdraw.beans.AbstractBean |
---|
propertySupport |
Constructor Summary | |
---|---|
AbstractApplication()
Creates a new instance. |
Method Summary | |
---|---|
void |
add(Project p)
Adds a project to this application. |
void |
addRecentFile(java.io.File file)
Appends a file to the list of recent files. |
protected Project |
basicCreateProject()
|
void |
clearRecentFiles()
Clears the list of recent files. |
void |
configure(java.lang.String[] args)
Configures the application using the provided arguments array. |
java.awt.Container |
createContainer()
|
Project |
createProject()
Creates a new project for this application. |
void |
dispose(Project p)
This is a convenience method for removing a project and disposing it. |
java.lang.String |
getCopyright()
Returns the copyright of the application. |
ApplicationModel |
getModel()
Returns the application model. |
java.lang.String |
getName()
Returns the name of the application. |
java.lang.String |
getVersion()
Returns the version of the application. |
void |
init()
Initializes the application. |
protected void |
initLabels()
|
protected abstract void |
initProjectActions(Project p)
|
boolean |
isEnabled()
Returns the enabled state of the application. |
void |
launch(java.lang.String[] args)
Launches the application from the main method. |
java.util.Collection<Project> |
projects()
Returns a read only collection view of the projects of this application. |
java.util.List<java.io.File> |
recentFiles()
Returns the recently opened files. |
void |
remove(Project p)
Removes a project from this application and removes it from the users view. |
void |
setEnabled(boolean newValue)
Sets the enabled state of the application. |
void |
setModel(ApplicationModel newValue)
Sets the application model. |
void |
start()
Starts the application. |
void |
stop()
Stops the application without saving any unsaved projects. |
Methods inherited from class org.jhotdraw.beans.AbstractBean |
---|
addPropertyChangeListener, addPropertyChangeListener, clone, firePropertyChange, firePropertyChange, firePropertyChange, removePropertyChangeListener, removePropertyChangeListener |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.jhotdraw.app.Application |
---|
addPropertyChangeListener, getComponent, getCurrentProject, hide, isSharingToolsAmongProjects, removePropertyChangeListener, show |
Field Detail |
---|
protected ResourceBundleUtil labels
Constructor Detail |
---|
public AbstractApplication()
Method Detail |
---|
public void init()
Application
configure()
should have been invoked before the application
is inited. Alternatively an application can be configured using setter
methods.
init
in interface Application
public void start()
Application
init()
must have been invoked before the application is started.
start
in interface Application
public final Project createProject()
Application
createProject
in interface Application
public void setModel(ApplicationModel newValue)
Application
setModel
in interface Application
public ApplicationModel getModel()
Application
getModel
in interface Application
protected Project basicCreateProject()
public java.lang.String getName()
Application
getName
in interface Application
public java.lang.String getVersion()
Application
getVersion
in interface Application
public java.lang.String getCopyright()
Application
getCopyright
in interface Application
protected abstract void initProjectActions(Project p)
public void stop()
Application
init()
must have been invoked before the application is stopped.
stop
in interface Application
public void remove(Project p)
Application
remove
in interface Application
public void add(Project p)
Application
add
in interface Application
public void dispose(Project p)
Application
dispose
in interface Application
public java.util.Collection<Project> projects()
Application
projects
in interface Application
public boolean isEnabled()
Application
isEnabled
in interface Application
public void setEnabled(boolean newValue)
Application
setEnabled
in interface Application
public java.awt.Container createContainer()
public void launch(java.lang.String[] args)
Application
launch
in interface Application
protected void initLabels()
public void configure(java.lang.String[] args)
Application
configure
in interface Application
public java.util.List<java.io.File> recentFiles()
Application
recentFiles
in interface Application
public void clearRecentFiles()
Application
clearRecentFiles
in interface Application
public void addRecentFile(java.io.File file)
Application
addRecentFile
in interface Application
|
Copyright 1996-2007 (c) JHotDraw.org. Some rights reserved. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |