|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openpermis.editor.policy.plugin.AbstractPlugin
public abstract class AbstractPlugin
Abstract base class for plugins.
Constructor Summary | |
---|---|
AbstractPlugin(ApplicationContext context)
Creates an abstract plugin that operates on an action and resource map derived from the implementation class of this plugin. |
Method Summary | |
---|---|
void |
customizeMenu(MenuBarFactory.Customizer customizer)
Prompts the plugin to provide its menu customization. |
void |
customizeToolBar(ToolBarFactory.Customizer customizer)
Prompts the plugin to provide its tool bar customization. |
protected Action |
getAction(String name)
Convenience method to retrieve an action by name. |
protected ActionMap |
getActionMap()
Returns the application action map of this plugin class and instance. |
protected ApplicationContext |
getApplicationContext()
Returns the context of the application that owns this plugin. |
protected Container |
getMainContentPane()
Returns the content pane of the main frame. |
protected JFrame |
getMainFrame()
Returns the main frame of the application context. |
protected org.jdesktop.application.ResourceMap |
getResourceMap()
Returns the context resource map of this view plugin. |
protected String |
getTranslation(String key)
Returns the translation for the specified key. |
protected String |
getTranslation(String key,
Object... args)
Returns the translation for the specified key. |
protected void |
showError(String title,
String message)
Shows a modal error dialog. |
protected void |
showWarning(String title,
String message)
Shows a modal warning dialog. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AbstractPlugin(ApplicationContext context)
context
- the application context used to lookup the action and resource map.Method Detail |
---|
protected String getTranslation(String key)
key
- the key to translate.
protected String getTranslation(String key, Object... args)
key
- the key to translate.args
- additional arguments.
protected ApplicationContext getApplicationContext()
protected JFrame getMainFrame()
protected Container getMainContentPane()
protected void showError(String title, String message)
title
- the (already translated) title of the dialog.message
- the (already translated) message of the dialog.protected void showWarning(String title, String message)
title
- the (already translated) title of the dialog.message
- the (already translated) message of the dialog.protected org.jdesktop.application.ResourceMap getResourceMap()
protected ActionMap getActionMap()
protected Action getAction(String name)
Bascially corresponds to getActionMap().get(name).
Note: If the action does not exist an error message including stack trace is logged and an action that does nothing is returned.
name
- the name of the action to retrieve.
public void customizeMenu(MenuBarFactory.Customizer customizer)
Plugin
customizeMenu
in interface Plugin
customizer
- the customizer to use.public void customizeToolBar(ToolBarFactory.Customizer customizer)
Plugin
customizeToolBar
in interface Plugin
customizer
- the customizer to use.
|
![]() |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
OpenPermis Role Based Access Control 0.9.0 (Build 16)
2009/08/13 07:17:21
Copyright (c) 2002-2007 Ergon Informatik AG