|
JHotDraw 7.3.1 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface ApplicationModel
ApplicationModel provides meta-data for an Application,
actions and factory methods for creating Views and toolbars.
Framework
The interfaces and classes listed below together with the Action
classes in the org.jhotddraw.app.action package define the contracts of a
framework for document oriented applications:
Contract: Application, ApplicationModel, View.
| Method Summary | |
|---|---|
java.util.List<javax.swing.JMenu> |
createMenus(Application a,
View v)
Creates menus. |
java.util.List<javax.swing.JToolBar> |
createToolBars(Application a,
View v)
Creates tool bars. |
View |
createView()
Creates a new view for the application. |
javax.swing.Action |
getAction(java.lang.String id)
Returns the action with the specified id. |
java.lang.String |
getCopyright()
Returns the copyright of the application. |
java.lang.String |
getName()
Returns the name of the application. |
java.lang.String |
getVersion()
Returns the version of the application. |
void |
initApplication(Application a)
Inits the application model. |
void |
initView(Application a,
View v)
Inits the supplied view for the application. |
void |
putAction(java.lang.String id,
javax.swing.Action action)
Puts an action with the specified id. |
| Method Detail |
|---|
java.lang.String getName()
java.lang.String getVersion()
java.lang.String getCopyright()
View createView()
void initView(Application a,
View v)
void initApplication(Application a)
Typically, the application model creates a number of
AbstractApplicationAction
objects, which can later be retrieved using getAction, and
which are linked to menu items and toolbars created by the
application model.
void putAction(java.lang.String id,
javax.swing.Action action)
javax.swing.Action getAction(java.lang.String id)
java.util.List<javax.swing.JToolBar> createToolBars(Application a,
View v)
Depending on the document interface of the application, this method may be invoked only once for the application, or for each opened view.
a - Application.v - The view for which the toolbars need to be created, or null
if the toolbars are shared by multiple views.
java.util.List<javax.swing.JMenu> createMenus(Application a,
View v)
Depending on the document interface of the application, this method may be invoked only once for the application, or for each opened view.
a - Application.v - The view for which the toolbars need to be created, or null
if the menus are shared by multiple views.
|
Copyright 1996-2009 (c) by the authors and contributors of the JHotDraw project. Some rights reserved. |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||