public class PluginRepository extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
PluginRepository(Configuration conf) |
| Modifier and Type | Method and Description |
|---|---|
void |
finalize() |
static PluginRepository |
get(Configuration conf) |
Class |
getCachedClass(PluginDescriptor pDescriptor,
String className) |
ExtensionPoint |
getExtensionPoint(String pXpId)
Returns a extension point indentified by a extension point id.
|
Object[] |
getOrderedPlugins(Class<?> clazz,
String xPointId,
String orderProperty)
Get ordered list of plugins.
|
PluginDescriptor |
getPluginDescriptor(String pPluginId)
Returns the descriptor of one plugin identified by a plugin id.
|
PluginDescriptor[] |
getPluginDescriptors()
Returns all registed plugin descriptors.
|
Plugin |
getPluginInstance(PluginDescriptor pDescriptor)
Returns a instance of a plugin.
|
static void |
main(String[] args)
Loads all necessary dependencies for a selected plugin, and then runs one
of the classes' main() method.
|
public PluginRepository(Configuration conf) throws RuntimeException
RuntimeExceptionObject.Object()public static PluginRepository get(Configuration conf)
public PluginDescriptor[] getPluginDescriptors()
public PluginDescriptor getPluginDescriptor(String pPluginId)
pPluginId - public ExtensionPoint getExtensionPoint(String pXpId)
pXpId - public Plugin getPluginInstance(PluginDescriptor pDescriptor) throws PluginRuntimeException
pDescriptor - PluginRuntimeExceptionpublic void finalize()
throws Throwable
public Class getCachedClass(PluginDescriptor pDescriptor, String className) throws ClassNotFoundException
ClassNotFoundExceptionpublic Object[] getOrderedPlugins(Class<?> clazz, String xPointId, String orderProperty)
clazz - interface class implemented by required pluginsxPointId - extension point id of required pluginsorderProperty - property name defining plugin orderpublic static void main(String[] args) throws Exception
args - plugin ID (needs to be activated in the configuration), and the
class name. The rest of arguments is passed to the main method of
the selected class.ExceptionCopyright © 2021 The Apache Software Foundation