Thus add new metric - 'projects'.
files=measure('files')
packages=measure('packages')
functions=measure('functions')
+ projects=measure('projects')
if measure('lines') || ncloc
files=measure('files')
statements=measure('statements')
<% if files && measure('classes') %>
<p><%= format_measure(files, :suffix => message('widget.size.files.suffix'), :url => url_for_drilldown(files)) -%> <%= dashboard_configuration.selected_period? ? format_variation(files) : trend_icon(files) -%></p>
<% end %>
+ <% if projects %>
+ <p><%= format_measure(projects, :suffix => message('widget.size.projects.suffix'), :url => url_for_drilldown(projects)) -%> <%= dashboard_configuration.selected_period? ? format_variation(projects) : trend_icon(projects) -%></p>
+ <% end %>
</div>
</td>
<td width="10"> </td>
widget.size.methods.suffix=\ methods
widget.size.accessors.suffix=\ accessors
widget.size.paragraphs.suffix=\ paragraphs
+widget.size.projects.suffix=\ projects
widget.timeline.name=Timeline
widget.timeline.description=Displays up to 3 metrics on a history chart.
.setFormula(new SumChildValuesFormula(false))
.create();
+ /**
+ * @since 2.15
+ */
+ public static final String PROJECTS_KEY = "projects";
+
+ /**
+ * @since 2.15
+ */
+ public static final Metric PROJECTS = new Metric.Builder(PROJECTS_KEY, "Projects", Metric.ValueType.INT)
+ .setDescription("Number of projects")
+ .setDirection(Metric.DIRECTION_WORST)
+ .setQualitative(false)
+ .setDomain(DOMAIN_SIZE)
+ .create();
//--------------------------------------------------------------------------------------------------------------------
//