com.atlassian.plugin.loaders
Class BundledPluginLoader

java.lang.Object
  extended by com.atlassian.plugin.loaders.ScanningPluginLoader
      extended by com.atlassian.plugin.loaders.DirectoryPluginLoader
          extended by com.atlassian.plugin.loaders.BundledPluginLoader
All Implemented Interfaces:
DynamicPluginLoader, PluginLoader

public class BundledPluginLoader
extends DirectoryPluginLoader

Plugin loader that unzips plugins from a zip file into a local directory, and ensures that directory only contains plugins from that zip file. It also treats all plugins loaded from the directory as bundled plugins, meaning they can can be upgraded, but not deleted.


Field Summary
 
Fields inherited from class com.atlassian.plugin.loaders.ScanningPluginLoader
pluginArtifactFactory, pluginFactories, plugins, scanner
 
Constructor Summary
BundledPluginLoader(java.net.URL zipUrl, java.io.File pluginPath, java.util.List<PluginFactory> pluginFactories, PluginEventManager eventManager)
           
 
Method Summary
protected  Plugin deployPluginFromUnit(DeploymentUnit deploymentUnit, ModuleDescriptorFactory moduleDescriptorFactory)
          Just like the ScanningPluginLoader.deployPluginFromUnit(DeploymentUnit,ModuleDescriptorFactory) method but changes the plugin to not be deletable
 
Methods inherited from class com.atlassian.plugin.loaders.ScanningPluginLoader
addFoundPlugins, canLoad, loadAllPlugins, onShutdown, removePlugin, shutDown, supportsAddition, supportsRemoval
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BundledPluginLoader

public BundledPluginLoader(java.net.URL zipUrl,
                           java.io.File pluginPath,
                           java.util.List<PluginFactory> pluginFactories,
                           PluginEventManager eventManager)
Method Detail

deployPluginFromUnit

protected Plugin deployPluginFromUnit(DeploymentUnit deploymentUnit,
                                      ModuleDescriptorFactory moduleDescriptorFactory)
                               throws PluginParseException
Just like the ScanningPluginLoader.deployPluginFromUnit(DeploymentUnit,ModuleDescriptorFactory) method but changes the plugin to not be deletable

Overrides:
deployPluginFromUnit in class ScanningPluginLoader
Parameters:
deploymentUnit - The plugin to deploy
moduleDescriptorFactory - The descriptor factory
Returns:
The created plugin
Throws:
PluginParseException - If there is a problem parsing the configuration


Copyright © 2008 Atlassian Pty Ltd. All Rights Reserved.