Class: MetricFu::AnalyzerTables
- Inherits:
-
Object
- Object
- MetricFu::AnalyzerTables
- Defined in:
- lib/metric_fu/metrics/hotspots/analysis/analyzer_tables.rb
Instance Method Summary collapse
- #generate_records ⇒ Object
-
#initialize(analyzer_columns) ⇒ AnalyzerTables
constructor
A new instance of AnalyzerTables.
- #table ⇒ Object
- #tables_for(item) ⇒ Object
- #tool_tables ⇒ Object
Constructor Details
#initialize(analyzer_columns) ⇒ AnalyzerTables
Returns a new instance of AnalyzerTables.
7 8 9 |
# File 'lib/metric_fu/metrics/hotspots/analysis/analyzer_tables.rb', line 7 def initialize(analyzer_columns) @columns = analyzer_columns end |
Instance Method Details
#generate_records ⇒ Object
11 12 13 14 |
# File 'lib/metric_fu/metrics/hotspots/analysis/analyzer_tables.rb', line 11 def generate_records build_lookups! process_rows! end |
#table ⇒ Object
20 21 22 |
# File 'lib/metric_fu/metrics/hotspots/analysis/analyzer_tables.rb', line 20 def table @table ||= make_table(@columns) end |
#tables_for(item) ⇒ Object
24 25 26 27 28 29 30 31 32 33 |
# File 'lib/metric_fu/metrics/hotspots/analysis/analyzer_tables.rb', line 24 def tables_for(item) { class: @class_tables, method: @method_tables, file: @file_tables, tool: @tool_tables }.fetch(item) do raise ArgumentError, "Item must be :class, :method, or :file, but was #{item}" end end |
#tool_tables ⇒ Object
16 17 18 |
# File 'lib/metric_fu/metrics/hotspots/analysis/analyzer_tables.rb', line 16 def tool_tables @tool_tables ||= make_table_hash(@columns) end |