Class: Guideline::PathFinder

Inherits:
Object
  • Object
show all
Defined in:
lib/guideline/path_finder.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(pattern) ⇒ PathFinder

Returns a new instance of PathFinder.



9
10
11
# File 'lib/guideline/path_finder.rb', line 9

def initialize(pattern)
  @pattern = pattern
end

Class Method Details

.find(pattern) ⇒ Object



5
6
7
# File 'lib/guideline/path_finder.rb', line 5

def self.find(pattern)
  new(pattern).paths
end

Instance Method Details

#pathsObject



13
14
15
# File 'lib/guideline/path_finder.rb', line 13

def paths
  Pathname.glob(recognized_pattern)
end