Class WebUiPlugin
- java.lang.Object
-
- com.google.gerrit.extensions.webui.WebUiPlugin
-
- Direct Known Subclasses:
JavaScriptPlugin
public abstract class WebUiPlugin extends Object
Specifies JavaScript to dynamically load into the web UI.To automatically register (instead of writing a Guice module), declare the intention with
@Listen
, extend the correct class and define a constructor to configure the correct resource:@Listen class MyJs extends JavaScriptPlugin { MyJs() { super("hello.js"); } }
- See Also:
JavaScriptPlugin
-
-
Constructor Summary
Constructors Constructor Description WebUiPlugin()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract String
getJavaScriptResourcePath()
String
getPluginName()
static JavaScriptPlugin
js(String scriptName)
String
toString()
-
-
-
Method Detail
-
js
public static final JavaScriptPlugin js(String scriptName)
-
getPluginName
public final String getPluginName()
- Returns:
- installed name of the plugin that provides this UI feature.
-
getJavaScriptResourcePath
public abstract String getJavaScriptResourcePath()
- Returns:
- path to initialization script within the plugin's JAR.
-
-