public class BasePlugin extends AbstractCockpitPlugin
Constructor and Description |
---|
BasePlugin() |
Modifier and Type | Method and Description |
---|---|
String |
getAssetDirectory()
Returns a uri to a plugin resources directory.
|
String |
getId()
Returns the unique id of this plugin.
|
List<String> |
getMappingFiles()
Returns a list of mapping files that define the custom queries
provided by this plugin.
|
Set<Class<?>> |
getResourceClasses()
Returns a set of JAX-RS resource classes that extend the rest API.
|
getResourceOverrides
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getResourceOverrides
public static final String ID
public Set<Class<?>> getResourceClasses()
AppPlugin
Typically, a plugin publishes its API via a subclass of AbstractPluginRootResource
.
getResourceClasses
in interface AppPlugin
getResourceClasses
in class AbstractAppPlugin
public String getId()
AppPlugin
public String getAssetDirectory()
AbstractAppPlugin
This implementation assumes that the resources are provided in the directory plugin-webapp/PLUGIN_ID
,
absolute to the root directory.
getAssetDirectory
in interface AppPlugin
getAssetDirectory
in class AbstractAppPlugin
public List<String> getMappingFiles()
CockpitPlugin
The mapping files define additional MyBatis queries that can be executed by the plugin.
Inside the plugin the queries may be executed via the QueryService
that may be obtained through
Cockpit.getQueryService(java.lang.String)
.
getMappingFiles
in interface CockpitPlugin
getMappingFiles
in class AbstractCockpitPlugin
Copyright © 2015. All rights reserved.