it.jnrpe.plugins
Class PluginRepository

java.lang.Object
  extended by it.jnrpe.plugins.PluginRepository
All Implemented Interfaces:
IPluginRepository

public class PluginRepository
extends Object
implements IPluginRepository

This class represent the repository of all the installed plugins.

Author:
Massimiliano Ziccardi

Constructor Summary
PluginRepository()
           
 
Method Summary
 void addPluginDefinition(PluginDefinition pluginDef)
          Adds a plugin definition to this repository.
 Collection<PluginDefinition> getAllPlugins()
          Returns all the plugin definitions managed by this repository.
 IPluginInterface getPlugin(String name)
          Returns the implementation of the plugin identified by the given name.
 void removePluginDefinition(PluginDefinition pluginDef)
          Removes a plugin definition from the repository.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PluginRepository

public PluginRepository()
Method Detail

addPluginDefinition

public final void addPluginDefinition(PluginDefinition pluginDef)
Adds a plugin definition to this repository.

Specified by:
addPluginDefinition in interface IPluginRepository
Parameters:
pluginDef - The plugin definition to be added.

removePluginDefinition

public final void removePluginDefinition(PluginDefinition pluginDef)
Removes a plugin definition from the repository.

Specified by:
removePluginDefinition in interface IPluginRepository
Parameters:
pluginDef - The plugin to be removed

getPlugin

public final IPluginInterface getPlugin(String name)
                                 throws UnknownPluginException
Returns the implementation of the plugin identified by the given name.

Specified by:
getPlugin in interface IPluginRepository
Parameters:
name - The plugin name
Returns:
the plugin identified by the given name
Throws:
UnknownPluginException - if no plugin with the given name exists.

getAllPlugins

public final Collection<PluginDefinition> getAllPlugins()
Description copied from interface: IPluginRepository
Returns all the plugin definitions managed by this repository.

Specified by:
getAllPlugins in interface IPluginRepository
Returns:
all the configured plugins


Copyright © 2014. All Rights Reserved.