Class: Fasterer::Analyzer
- Inherits:
-
Object
- Object
- Fasterer::Analyzer
- Defined in:
- lib/fasterer/analyzer.rb
Instance Attribute Summary collapse
-
#file_path ⇒ Object
(also: #path)
readonly
Returns the value of attribute file_path.
Instance Method Summary collapse
- #errors ⇒ Object
-
#initialize(file_path) ⇒ Analyzer
constructor
A new instance of Analyzer.
- #scan ⇒ Object
Constructor Details
#initialize(file_path) ⇒ Analyzer
Returns a new instance of Analyzer.
15 16 17 18 |
# File 'lib/fasterer/analyzer.rb', line 15 def initialize(file_path) @file_path = file_path.to_s @file_content = File.read(file_path) end |
Instance Attribute Details
#file_path ⇒ Object (readonly) Also known as: path
Returns the value of attribute file_path.
12 13 14 |
# File 'lib/fasterer/analyzer.rb', line 12 def file_path @file_path end |
Instance Method Details
#errors ⇒ Object
25 26 27 |
# File 'lib/fasterer/analyzer.rb', line 25 def errors @errors ||= Fasterer::OffenseCollector.new end |