Class: MetricFu::RoodiGrapher
- Inherits:
-
Grapher
- Object
- Grapher
- MetricFu::RoodiGrapher
show all
- Defined in:
- lib/metric_fu/metrics/roodi/grapher.rb
Instance Attribute Summary collapse
Attributes inherited from Grapher
#output_directory
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Grapher
#date, get_grapher, #graph!, graphers
Constructor Details
Returns a new instance of RoodiGrapher.
10
11
12
13
14
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 10
def initialize
super
@roodi_count = []
@labels = {}
end
|
Instance Attribute Details
#labels ⇒ Object
Returns the value of attribute labels.
4
5
6
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 4
def labels
@labels
end
|
#roodi_count ⇒ Object
Returns the value of attribute roodi_count.
4
5
6
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 4
def roodi_count
@roodi_count
end
|
Class Method Details
.metric ⇒ Object
6
7
8
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 6
def self.metric
:roodi
end
|
Instance Method Details
#data ⇒ Object
27
28
29
30
31
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 27
def data
[
["roodi", @roodi_count.join(",")]
]
end
|
#get_metrics(metrics, date) ⇒ Object
16
17
18
19
20
21
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 16
def get_metrics(metrics, date)
if metrics && metrics[:roodi]
@roodi_count.push(metrics[:roodi][:problems].size)
@labels.update(@labels.size => date)
end
end
|
#output_filename ⇒ Object
33
34
35
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 33
def output_filename
"roodi.js"
end
|
#title ⇒ Object
23
24
25
|
# File 'lib/metric_fu/metrics/roodi/grapher.rb', line 23
def title
"Roodi: design problems"
end
|