Package com.google.gerrit.server.plugins
Class ServerPlugin
- java.lang.Object
-
- com.google.gerrit.server.plugins.Plugin
-
- com.google.gerrit.server.plugins.ServerPlugin
-
- Direct Known Subclasses:
TestServerPlugin
public class ServerPlugin extends Plugin
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.gerrit.server.plugins.Plugin
Plugin.ApiType, Plugin.CacheKey
-
-
Field Summary
Fields Modifier and Type Field Description protected Class<? extends com.google.inject.Module>
batchModule
protected Class<? extends com.google.inject.Module>
httpModule
protected Class<? extends com.google.inject.Module>
sshModule
protected Class<? extends com.google.inject.Module>
sysModule
-
Constructor Summary
Constructors Constructor Description ServerPlugin(String name, String pluginCanonicalWebUrl, PluginUser pluginUser, Path srcJar, org.eclipse.jgit.internal.storage.file.FileSnapshot snapshot, PluginContentScanner scanner, Path dataDir, ClassLoader classLoader, String metricsPrefix, GerritRuntime gerritRuntime)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(RegistrationHandle handle)
protected boolean
canReload()
String
getApiVersion()
PluginContentScanner
getContentScanner()
com.google.inject.Injector
getHttpInjector()
com.google.inject.Injector
getSshInjector()
com.google.inject.Injector
getSysInjector()
String
getVersion()
protected static Class<? extends com.google.inject.Module>
load(String name, ClassLoader pluginLoader)
protected void
start(PluginGuiceEnvironment env)
protected void
stop(PluginGuiceEnvironment env)
-
Methods inherited from class com.google.gerrit.server.plugins.Plugin
getApiType, getCacheKey, getCleanupHandle, getName, getSrcFile, isDisabled, setCleanupHandle, toString
-
-
-
-
Field Detail
-
sysModule
protected Class<? extends com.google.inject.Module> sysModule
-
batchModule
protected Class<? extends com.google.inject.Module> batchModule
-
sshModule
protected Class<? extends com.google.inject.Module> sshModule
-
httpModule
protected Class<? extends com.google.inject.Module> httpModule
-
-
Constructor Detail
-
ServerPlugin
public ServerPlugin(String name, String pluginCanonicalWebUrl, PluginUser pluginUser, Path srcJar, org.eclipse.jgit.internal.storage.file.FileSnapshot snapshot, PluginContentScanner scanner, Path dataDir, ClassLoader classLoader, String metricsPrefix, GerritRuntime gerritRuntime) throws InvalidPluginException
- Throws:
InvalidPluginException
-
-
Method Detail
-
load
protected static Class<? extends com.google.inject.Module> load(String name, ClassLoader pluginLoader) throws ClassNotFoundException
- Throws:
ClassNotFoundException
-
getVersion
public String getVersion()
- Specified by:
getVersion
in classPlugin
-
getApiVersion
public String getApiVersion()
- Overrides:
getApiVersion
in classPlugin
-
start
protected void start(PluginGuiceEnvironment env) throws Exception
-
stop
protected void stop(PluginGuiceEnvironment env)
-
getSysInjector
public com.google.inject.Injector getSysInjector()
- Specified by:
getSysInjector
in classPlugin
-
getSshInjector
public com.google.inject.Injector getSshInjector()
- Specified by:
getSshInjector
in classPlugin
-
getHttpInjector
public com.google.inject.Injector getHttpInjector()
- Specified by:
getHttpInjector
in classPlugin
-
add
public void add(RegistrationHandle handle)
-
getContentScanner
public PluginContentScanner getContentScanner()
- Specified by:
getContentScanner
in classPlugin
-
-