Class: Rubycritic::SmellsAggregator
- Inherits:
-
Object
- Object
- Rubycritic::SmellsAggregator
- Defined in:
- lib/rubycritic/smells_aggregator.rb
Instance Method Summary collapse
-
#initialize(smell_adapters) ⇒ SmellsAggregator
constructor
A new instance of SmellsAggregator.
- #smells ⇒ Object
- #smelly_pathnames ⇒ Object
Constructor Details
#initialize(smell_adapters) ⇒ SmellsAggregator
Returns a new instance of SmellsAggregator.
4 5 6 |
# File 'lib/rubycritic/smells_aggregator.rb', line 4 def initialize(smell_adapters) @smell_adapters = smell_adapters end |
Instance Method Details
#smells ⇒ Object
8 9 10 |
# File 'lib/rubycritic/smells_aggregator.rb', line 8 def smells @smells ||= @smell_adapters.map(&:smells).flatten.sort end |
#smelly_pathnames ⇒ Object
12 13 14 |
# File 'lib/rubycritic/smells_aggregator.rb', line 12 def smelly_pathnames @smelly_pathnames ||= pathnames_to_files_with_smells end |