Package io.jenkins.plugins.monitoring
Class MonitorPortletFactory
- java.lang.Object
-
- io.jenkins.plugins.monitoring.MonitorPortletFactory
-
- All Implemented Interfaces:
ExtensionPoint
- Direct Known Subclasses:
DemoPortlet.ExampleMonitorFactory
public abstract class MonitorPortletFactory extends Object implements ExtensionPoint
Defines the
ExtensionPoint
to register one or more new pull request monitoring portlets.The
getDisplayName()
is shown in a dropdown list as optgroup. The children of the optgroup are the registered portlets ofgetPortlets(Run)
.Since an empty dashboard is always added by default, it is possible that the method
getPortlets(Run)
will be called even though the current run may not be finished. It is therefore advisable to perform a null check on the actions of the run required by your portlet and return an empty list if necessary. (Example: code-coverage-api)- Since:
- 1.6.0
- Author:
- Simon Symhoven
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Constructor Summary
Constructors Constructor Description MonitorPortletFactory()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract String
getDisplayName()
Defines the name of the factory.abstract Collection<MonitorPortlet>
getPortlets(Run<?,?> build)
Get a collection ofMonitorPortlet
to display.
-
-
-
Method Detail
-
getPortlets
public abstract Collection<MonitorPortlet> getPortlets(Run<?,?> build)
Get a collection ofMonitorPortlet
to display.- Parameters:
build
- the referenceRun
.- Returns:
- a collection of
MonitorPortlet
.
-
getDisplayName
public abstract String getDisplayName()
Defines the name of the factory.- Returns:
- the name to display for the factory.
-
-