Class: FileScanners::Ruby

Inherits:
Object
  • Object
show all
Defined in:
lib/file_scanners/ruby.rb

Overview

FileScanners are in charge of finding files to be analyzed. This one in particular finds Ruby files.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ Ruby

Returns a new instance of Ruby.



9
10
11
# File 'lib/file_scanners/ruby.rb', line 9

def initialize(path)
  @path = path
end

Instance Attribute Details

#pathObject (readonly)

Returns the value of attribute path.



8
9
10
# File 'lib/file_scanners/ruby.rb', line 8

def path
  @path
end

Instance Method Details

#scanObject



13
14
15
16
17
# File 'lib/file_scanners/ruby.rb', line 13

def scan
  files.reject do |file|
    ignore? file
  end
end