Class IssuesChartPortlet
- java.lang.Object
-
- hudson.plugins.view.dashboard.DashboardPortlet
-
- io.jenkins.plugins.analysis.core.portlets.IssuesChartPortlet
-
- All Implemented Interfaces:
ExtensionPoint
,Describable<hudson.plugins.view.dashboard.DashboardPortlet>
,ModelObject
public class IssuesChartPortlet extends hudson.plugins.view.dashboard.DashboardPortlet
A dashboard view portlet that renders a two-dimensional table of issues per type and job.- Author:
- Ullrich Hafner
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
IssuesChartPortlet.IssuesChartPortletDescriptor
Extension point registration.-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Constructor Summary
Constructors Constructor Description IssuesChartPortlet(String name)
Creates a new instance ofIssuesChartPortlet
.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description String
getBuildTrendModel()
Returns the UI model for an ECharts line chart that shows the issues stacked by severity.int
getHeight()
boolean
getHideCleanJobs()
boolean
getSelectTools()
List<ToolSelection>
getTools()
String
getTrend()
Deprecated.replaced bygetBuildTrendModel()
which is called from JS fileint
register(List<Job<?,?>> visibleJobs)
Registers the specified jobs in this portlet.void
setHeight(int height)
Sets the height of the chart (in number of pixels).void
setHideCleanJobs(boolean hideCleanJobs)
Determines if all jobs that have no issues from the selected static analysis tools should be hidden.void
setSelectTools(boolean selectTools)
Determines whether all available tools should be selected or if the selection should be done individually.void
setTools(List<ToolSelection> tools)
Returns the tools that should be taken into account when summing up the totals of a job.
-
-
-
Constructor Detail
-
IssuesChartPortlet
@DataBoundConstructor public IssuesChartPortlet(String name)
Creates a new instance ofIssuesChartPortlet
.- Parameters:
name
- the name of the portlet
-
-
Method Detail
-
getHideCleanJobs
public boolean getHideCleanJobs()
-
setHideCleanJobs
@DataBoundSetter public void setHideCleanJobs(boolean hideCleanJobs)
Determines if all jobs that have no issues from the selected static analysis tools should be hidden.- Parameters:
hideCleanJobs
- iftrue
then all jobs with no issues will be hidden,false
otherwise
-
getSelectTools
public boolean getSelectTools()
-
setSelectTools
@DataBoundSetter public void setSelectTools(boolean selectTools)
Determines whether all available tools should be selected or if the selection should be done individually.- Parameters:
selectTools
- iftrue
the selection of tools can be done manually by selecting the corresponding ID, otherwise all available tools in a job are automatically selected
-
getTools
public List<ToolSelection> getTools()
-
setTools
@DataBoundSetter public void setTools(List<ToolSelection> tools)
Returns the tools that should be taken into account when summing up the totals of a job.- Parameters:
tools
- the tools to select- See Also:
setSelectTools(boolean)
-
getHeight
public int getHeight()
-
setHeight
@DataBoundSetter public void setHeight(int height)
Sets the height of the chart (in number of pixels).- Parameters:
height
- height of the chart
-
getBuildTrendModel
@JavaScriptMethod public String getBuildTrendModel()
Returns the UI model for an ECharts line chart that shows the issues stacked by severity.- Returns:
- the UI model as JSON
-
getTrend
@JavaScriptMethod @Deprecated public String getTrend()
Deprecated.replaced bygetBuildTrendModel()
which is called from JS fileReturns the UI model for an ECharts line chart that shows the issues stacked by severity.- Returns:
- the UI model as JSON
-
register
public int register(List<Job<?,?>> visibleJobs)
Registers the specified jobs in this portlet. These jobs will be used to render the trend chart. Note that rendering of the trend chart is done using an Ajax call later on.- Parameters:
visibleJobs
- the jobs to render- Returns:
- the number of jobs
-
-