Class: RubyCritic::SourceLocator
- Inherits:
-
Object
- Object
- RubyCritic::SourceLocator
- Defined in:
- lib/rubycritic/source_locator.rb
Constant Summary collapse
- RUBY_EXTENSION =
'.rb'.freeze
- RUBY_FILES =
File.join('**', "*#{RUBY_EXTENSION}")
- RUBY_SHEBANG =
'#!/usr/bin/env ruby'.freeze
Instance Method Summary collapse
-
#initialize(paths) ⇒ SourceLocator
constructor
A new instance of SourceLocator.
- #pathnames ⇒ Object
- #paths ⇒ Object
Constructor Details
#initialize(paths) ⇒ SourceLocator
Returns a new instance of SourceLocator.
12 13 14 |
# File 'lib/rubycritic/source_locator.rb', line 12 def initialize(paths) @initial_paths = Array(paths) end |
Instance Method Details
#pathnames ⇒ Object
20 21 22 |
# File 'lib/rubycritic/source_locator.rb', line 20 def pathnames @pathnames ||= end |
#paths ⇒ Object
16 17 18 |
# File 'lib/rubycritic/source_locator.rb', line 16 def paths @paths ||= pathnames.map(&:to_s) end |