BioLegato 0.5.6

org.biolegato.core.plugins
Class PluginLoader

java.lang.Object
  extended by org.biolegato.core.plugins.PluginLoader

public class PluginLoader
extends java.lang.Object

This class is used to handle plugins.

Author:
Graham Alvare, Brian Fristensky

Constructor Summary
PluginLoader()
           
 
Method Summary
static PluginWrapper getPlugin(java.lang.String string)
          Retrieves a plugin by name.
static java.util.Map<java.lang.String,PluginWrapper> getPluginHash()
          Returns a list with all of the plugins loaded by BioLegato.
static java.util.Collection<PluginWrapper> getPlugins(java.lang.Class<?> type)
          Returns a list with all of the plugins loaded by BioLegato that are instances of the class type indicated.
static void loadPlugins(java.lang.String directory)
          Loads an the plugins into BioLegato.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PluginLoader

public PluginLoader()
Method Detail

getPluginHash

public static java.util.Map<java.lang.String,PluginWrapper> getPluginHash()
Returns a list with all of the plugins loaded by BioLegato.

Returns:
a list containing all of the plugins loaded

getPlugins

public static java.util.Collection<PluginWrapper> getPlugins(java.lang.Class<?> type)
Returns a list with all of the plugins loaded by BioLegato that are instances of the class type indicated.

Parameters:
type - the plugin type to find
Returns:
a list containing all of the plugins loaded

getPlugin

public static PluginWrapper getPlugin(java.lang.String string)
Retrieves a plugin by name. This can be used for plugins dependant on other plugins

Parameters:
string - the plugin to retrieve
Returns:
the plugin requested (null on failure)

loadPlugins

public static void loadPlugins(java.lang.String directory)
Loads an the plugins into BioLegato.

Parameters:
directory - the directory to load the plugins from

BioLegato 0.5.6

Copyright © 2008-2009 University of Manitoba.