org.hyperic.hq.product
Class ProductPluginManager
java.lang.Object
org.hyperic.hq.product.PluginManager
org.hyperic.hq.product.ProductPluginManager
public class ProductPluginManager
- extends PluginManager
This class is a manager for ProductPlugin implementations and is also a
manager of plugin managers.
Methods inherited from class org.hyperic.hq.product.PluginManager |
classNotFoundMessage, createPlugin, createPlugin, createPlugin, getConfigSchema, getParent, getPlatformPlugin, getPlatformPlugin, getPlatformPlugins, getPlatformPlugins, getPlugin, getPluginInfo, getPlugins, getPlugins, getProperties, getProperty, getProperty, init, isPropertyEnabled, isPropertyEnabled, isRegistered, mergeConfigSchema, registerPlugin, registerPlugin, registerPlugin, removePlugin, setPluginInfo, updatePlugin |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PROP_PDK_DIR
public static final String PROP_PDK_DIR
- See Also:
- Constant Field Values
PLUGIN_PROPERTIES_FILE
public static final File PLUGIN_PROPERTIES_FILE
PROPERTY_PREFIX
public static final String PROPERTY_PREFIX
- See Also:
- Constant Field Values
ProductPluginManager
public ProductPluginManager()
ProductPluginManager
public ProductPluginManager(File file)
ProductPluginManager
public ProductPluginManager(Properties props)
setRegisterTypes
public void setRegisterTypes(boolean registerTypes)
- If true creates a mapping of the ProductPlugin TypeInfos, only needed on
the server side.
getRegisterTypes
public boolean getRegisterTypes()
getPropertyKey
public static String getPropertyKey(String plugin,
String key)
getName
public String getName()
- Specified by:
getName
in class PluginManager
getNameFromFile
public static String getNameFromFile(String file)
- Derive plugin name from file name-plugin.ext
getTypeInfo
public TypeInfo getTypeInfo(String platform,
String name)
- Find TypeInfo for the given platform and type name.
- Parameters:
platform
- The platform name, e.g. "Linux"name
- The type name, e.g. "Apache 2.0"
getPdkDir
public static String getPdkDir()
setPdkDir
public static void setPdkDir(String dir)
getPdkPluginsDir
public static String getPdkPluginsDir()
setPdkPluginsDir
public static void setPdkPluginsDir(String dir)
getPdkWorkDir
public static String getPdkWorkDir()
setPdkWorkDir
public static void setPdkWorkDir(String dir)
init
public void init()
throws PluginException
- Throws:
PluginException
initPluginManagers
protected void initPluginManagers(Properties props)
throws PluginException
- Throws:
PluginException
shutdown
public void shutdown()
throws PluginException
- Overrides:
shutdown
in class PluginManager
- Throws:
PluginException
getMeasurementPluginManager
public MeasurementPluginManager getMeasurementPluginManager()
getControlPluginManager
public ControlPluginManager getControlPluginManager()
getAutoinventoryPluginManager
public AutoinventoryPluginManager getAutoinventoryPluginManager()
getRtPluginManager
public RtPluginManager getRtPluginManager()
getLogTrackPluginManager
public LogTrackPluginManager getLogTrackPluginManager()
getConfigTrackPluginManager
public ConfigTrackPluginManager getConfigTrackPluginManager()
getLiveDataPluginManager
public LiveDataPluginManager getLiveDataPluginManager()
getMeasurementPlugin
public MeasurementPlugin getMeasurementPlugin(String name)
getControlPlugin
public ControlPlugin getControlPlugin(String name)
getAutoinventoryPlugin
public ServerDetector getAutoinventoryPlugin(String name)
getRtPlugin
public RtPlugin getRtPlugin(String name)
getProductPlugin
public ProductPlugin getProductPlugin(String name)
isLoadablePluginName
public boolean isLoadablePluginName(String name)
registerPluginJar
public String registerPluginJar(String jarName)
throws PluginException,
PluginExistsException
- registerPluginJar() without mapping types.
- Parameters:
jarName
- The name of the jar file on disk.
- Throws:
PluginException
PluginExistsException
- See Also:
registerPluginJar(String jarName,ClassLoader resourceLoader)
registerCustomPlugins
public int registerCustomPlugins(String startDir)
registerPlugins
public int registerPlugins(String path)
registerPluginJar
public String registerPluginJar(String jarName,
ClassLoader resourceLoader)
throws PluginException,
PluginExistsException
- Load a product plugin jar. Registers the product plugin, as defined by
the Main-Class jar manifest attribute which must be a class which
implements the ProductPlugin interface. Registers plugins supported for
each plugin type (control, measurement, responsetime) as returned by the
ProductPlugin.getPlugin method.
- Parameters:
jarName
- The name of the jar file on disk.resourceLoader
- ClassLoader used to find jar resources.
- Returns:
- The name of the product plugin as returned by
ProductPlugin.getName.
- Throws:
PluginException
PluginExistsException
- See Also:
ProductPlugin
addPluginTypes
public void addPluginTypes(TypeInfo[] types,
ProductPlugin plugin)
throws PluginExistsException
- Throws:
PluginExistsException
removePluginTypes
public void removePluginTypes(List<TypeInfo> typeInfos)
removePluginJar
public void removePluginJar(String jarName)
throws PluginException
- Throws:
PluginException
updatePluginJar
public void updatePluginJar(String jarName)
throws PluginException
- Throws:
PluginException
getPluginManager
public PluginManager getPluginManager(String type)
throws PluginException
- Throws:
PluginException
setProperty
public void setProperty(String key,
String value)
isClient
public boolean isClient()
Copyright © 2004-2010 Hyperic, Inc. support@hyperic.net, All Rights Reserved.