public class PluginLoader extends Object implements LifecycleListener
Constructor and Description |
---|
PluginLoader(SitePaths sitePaths,
PluginGuiceEnvironment pe,
ServerInformationImpl sii,
PluginUser.Factory puf,
com.google.inject.Provider<com.google.gerrit.server.plugins.PluginCleanerTask> pct,
org.eclipse.jgit.lib.Config cfg,
com.google.inject.Provider<String> provider,
PersistentCacheFactory cacheFactory,
com.google.gerrit.server.plugins.UniversalServerPluginProvider pluginFactory,
GerritRuntime gerritRuntime) |
Modifier and Type | Method and Description |
---|---|
void |
checkRemoteAdminEnabled() |
void |
disablePlugins(Set<String> names) |
void |
enablePlugins(Set<String> names) |
Plugin |
get(String name) |
String |
getGerritPluginName(Path srcPath) |
String |
getPluginName(Path srcPath) |
Iterable<Plugin> |
getPlugins(boolean all) |
String |
installPluginFromStream(String originalName,
InputStream in) |
boolean |
isRemoteAdminEnabled() |
com.google.common.collect.SetMultimap<String,Path> |
prunePlugins(Path pluginsDir) |
void |
reload(List<String> names) |
void |
rescan() |
void |
start()
Invoked when the server is starting.
|
void |
stop()
Invoked when the server is stopping.
|
@Inject public PluginLoader(SitePaths sitePaths, PluginGuiceEnvironment pe, ServerInformationImpl sii, PluginUser.Factory puf, com.google.inject.Provider<com.google.gerrit.server.plugins.PluginCleanerTask> pct, org.eclipse.jgit.lib.Config cfg, com.google.inject.Provider<String> provider, PersistentCacheFactory cacheFactory, com.google.gerrit.server.plugins.UniversalServerPluginProvider pluginFactory, GerritRuntime gerritRuntime)
public boolean isRemoteAdminEnabled()
public void checkRemoteAdminEnabled() throws MethodNotAllowedException
MethodNotAllowedException
public String installPluginFromStream(String originalName, InputStream in) throws IOException, PluginInstallException
IOException
PluginInstallException
public void enablePlugins(Set<String> names) throws PluginInstallException
PluginInstallException
public void start()
LifecycleListener
start
in interface LifecycleListener
public void stop()
LifecycleListener
stop
in interface LifecycleListener
public void reload(List<String> names) throws InvalidPluginException, PluginInstallException
public void rescan()
public com.google.common.collect.SetMultimap<String,Path> prunePlugins(Path pluginsDir)