public abstract class ServerPlugin
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
ServerPlugin.PluginResponseType
Enuemeration of plugin response types
OPEN - Response forces browser to open a new page ( e.g. model ). |
static class |
ServerPlugin.PluginScope |
static class |
ServerPlugin.ProcessEditorServerPluginType
Enumeration of plugin types
SIMPLE - Plugin is represented by a simple button. |
Modifier and Type | Field and Description |
---|---|
protected ServerPlugin.PluginScope |
scope |
protected static java.util.Set<java.lang.Class<? extends ProcessModel>> |
SUPPORT_ALL |
protected java.util.Set<java.lang.Class<? extends ProcessModel>> |
supportedModels |
protected java.util.Set<java.lang.Class<? extends ProcessObject>> |
supportedObjects |
protected ServerPlugin.ProcessEditorServerPluginType |
type |
Constructor and Description |
---|
ServerPlugin() |
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
getItemIconPath() |
protected java.lang.String |
getItemIconUri(RequestFacade req) |
protected abstract java.lang.String |
getItemText() |
JSONObject |
getMenuItemConfig(RequestFacade req)
Get JSON-String that configures the menu item of this plugin.
|
ServerPlugin.PluginScope |
getPluginScope() |
ServerPlugin.ProcessEditorServerPluginType |
getPluginType()
Get this plugin's type
|
abstract void |
processRequest(java.lang.String requestUri,
RequestFacade req,
ResponseFacade resp,
LoginableUser u)
Process the incoming request to this plugin.
|
boolean |
showInToolbar()
Return true, to display this plugin as simple icon in toolbar
|
boolean |
supportsModel(java.lang.Class<? extends ProcessModel> modelClass) |
boolean |
supportsObject(java.lang.Class<? extends ProcessObject> objectClass) |
protected static final java.util.Set<java.lang.Class<? extends ProcessModel>> SUPPORT_ALL
protected java.util.Set<java.lang.Class<? extends ProcessModel>> supportedModels
protected java.util.Set<java.lang.Class<? extends ProcessObject>> supportedObjects
protected ServerPlugin.ProcessEditorServerPluginType type
protected ServerPlugin.PluginScope scope
public abstract void processRequest(java.lang.String requestUri, RequestFacade req, ResponseFacade resp, LoginableUser u) throws java.io.IOException
requestUri
- the requested urit
- the http exchange objectu
- the user that performs this requestjava.io.IOException
public ServerPlugin.ProcessEditorServerPluginType getPluginType()
public ServerPlugin.PluginScope getPluginScope()
public boolean showInToolbar()
protected java.lang.String getItemIconUri(RequestFacade req)
protected java.lang.String getItemIconPath()
protected abstract java.lang.String getItemText()
public boolean supportsModel(java.lang.Class<? extends ProcessModel> modelClass)
public boolean supportsObject(java.lang.Class<? extends ProcessObject> objectClass)
public JSONObject getMenuItemConfig(RequestFacade req) throws JSONException
JSONException