Module: Bodhi::CountMetrics
- Included in:
- Metric
- Defined in:
- lib/bodhi/definitions/count.rb
Instance Method Summary collapse
Instance Method Details
#count(*args) ⇒ Object
3 4 5 6 7 8 9 10 11 |
# File 'lib/bodhi/definitions/count.rb', line 3 def count (*args) = args. [:model_name] = args[0] if args[0].is_a? Symbol count_type = args[1] || [:count_type] || :total [:block] = get_block(count_type) [:name] ||= "#{[:model_name]}_count_#{count_type}" define() end |