|
Cytoscape 2.8.0 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cytoscape.plugin.PluginManager
public class PluginManager
Field Summary | |
---|---|
protected PluginTracker |
pluginTracker
|
Method Summary | |
---|---|
void |
clearErrorList()
Clears the loading error list. |
void |
delete()
Takes all objects on the "to-delete" list and deletes them. |
void |
delete(DownloadableInfo Obj)
Marks the given object for deletion the next time Cytoscape is restarted. |
DownloadableInfo |
download(DownloadableInfo Obj)
Downloads given object to the temporary directory. |
DownloadableInfo |
download(DownloadableInfo Obj,
TaskMonitor taskMonitor)
Downloads given object to the temporary directory. |
List<DownloadableInfo> |
findUpdates(DownloadableInfo Info)
Get list of plugins that would update the given plugin. |
static URLClassLoader |
getClassLoader()
|
List<DownloadableInfo> |
getDownloadables(PluginStatus Status)
Get a list of downloadable objects by status. |
List<Throwable> |
getLoadingErrors()
/** Returns list of loading exceptions. |
File |
getPluginManageDirectory()
|
static PluginManager |
getPluginManager()
Get the PluginManager object. |
protected static PluginManager |
getPluginManager(PluginTracker Tracker)
This should ONLY be used by tests!! |
static List<URL> |
getPluginURLs()
|
static List<String> |
getResourcePlugins()
|
List<DownloadableInfo> |
inquire(String Url)
Calls the given url, expects document describing plugins available for download |
void |
install()
Sets all plugins on the "install" list to "current" |
void |
install(DownloadableInfo obj)
Change the given downloadable object from "install" to "current" status |
void |
loadPlugin(DownloadableInfo i)
|
void |
loadPlugin(PluginInfo p)
Load a single plugin based on the PluginInfo object given |
void |
loadPlugins(List<String> p)
Parses the plugin input strings and transforms them into the appropriate URLs or resource names. |
protected static boolean |
recursiveDeleteFiles(File file)
|
protected void |
register(CytoscapePlugin Plugin,
JarFile Jar)
Registers a currently installed plugin with tracking object. |
protected boolean |
removeWebstartInstalls()
Deletes everything under the webstart install directory. |
protected void |
resetManager()
This is used in testing to isolate each test case. |
static void |
setPluginManageDirectory(String loc)
|
void |
update(DownloadableInfo Current,
DownloadableInfo New)
Finds the given version of the new object, sets the old object for deletion and downloads new object to temporary directory |
void |
update(DownloadableInfo currentObj,
DownloadableInfo newObj,
TaskMonitor taskMonitor)
Finds the given version of the new object, sets the old object for deletion and downloads new object to temporary directory |
static boolean |
usingWebstartManager()
Returns true/false based on the System property. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected PluginTracker pluginTracker
Method Detail |
---|
public List<Throwable> getLoadingErrors()
public void clearErrorList()
public static URLClassLoader getClassLoader()
public static List<String> getResourcePlugins()
public static List<URL> getPluginURLs()
public static boolean usingWebstartManager()
protected boolean removeWebstartInstalls()
public static PluginManager getPluginManager()
public static void setPluginManageDirectory(String loc)
loc
- Location of plugin download/install directory. If this method
is not called the default is .cytoscape/[cytoscape
version]/pluginspublic File getPluginManageDirectory()
protected static PluginManager getPluginManager(PluginTracker Tracker)
Tracker
-
protected void resetManager()
public List<DownloadableInfo> getDownloadables(PluginStatus Status)
Status
-
public List<DownloadableInfo> inquire(String Url) throws IOException, org.jdom.JDOMException
Url
-
IOException
org.jdom.JDOMException
protected void register(CytoscapePlugin Plugin, JarFile Jar)
Plugin
- JarFileName
- public void install()
public void install(DownloadableInfo obj)
obj
- public void delete(DownloadableInfo Obj) throws WebstartException
Obj
-
WebstartException
public void delete() throws ManagerException
ManagerException
- If all files fail to delete
WebstartException
- If this method is called from a webstart instanceprotected static boolean recursiveDeleteFiles(File file)
public List<DownloadableInfo> findUpdates(DownloadableInfo Info) throws IOException, org.jdom.JDOMException
Info
-
ManagerException
IOException
org.jdom.JDOMException
public void update(DownloadableInfo Current, DownloadableInfo New) throws IOException, ManagerException, WebstartException
Current
- DownloadableInfo object currently installedNew
- DownloadableInfo object to install
IOException
- Fails to download the file.
ManagerException
- If the objects don't match or the new one is not a newer
version.
WebstartException
public void update(DownloadableInfo currentObj, DownloadableInfo newObj, TaskMonitor taskMonitor) throws IOException, ManagerException, WebstartException
Current
- PluginInfo object currently installedNew
- PluginInfo object to installtaskMonitor
- TaskMonitor for downloads
IOException
- Fails to download the file.
ManagerException
- If the plugins don't match or the new one is not a newer
version.
WebstartException
public DownloadableInfo download(DownloadableInfo Obj) throws IOException, ManagerException
Obj
- PluginInfo object to be downloaded
IOException
ManagerException
public DownloadableInfo download(DownloadableInfo Obj, TaskMonitor taskMonitor) throws IOException, ManagerException
Obj
- PluginInfo object to be downloadedtaskMonitor
- TaskMonitortempDirectory
- Download to a different temporary directory. Default is
.cytoscape/plugins/[cytoscape version number]
IOException
ManagerException
public void loadPlugin(DownloadableInfo i) throws MalformedURLException, IOException, ClassNotFoundException, PluginException
MalformedURLException
IOException
ClassNotFoundException
PluginException
public void loadPlugin(PluginInfo p) throws ManagerException
PluginInfo
- The plugin to load
ManagerException
public void loadPlugins(List<String> p)
|
Cytoscape 2.8.0 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |