Class: Cane::SyntaxViolation
- Inherits:
-
Struct
- Object
- Struct
- Cane::SyntaxViolation
- Defined in:
- lib/cane/syntax_violation.rb
Overview
Value object used by AbcCheck for a file that cannot be parsed. This is handled by AbcCheck rather than a separate class since it is a low value violation (syntax errors should have been picked up by specs) but we still have to deal with the edge case.
Instance Attribute Summary collapse
-
#file_name ⇒ Object
Returns the value of attribute file_name.
Instance Method Summary collapse
Instance Attribute Details
#file_name ⇒ Object
Returns the value of attribute file_name
7 8 9 |
# File 'lib/cane/syntax_violation.rb', line 7 def file_name @file_name end |
Instance Method Details
#columns ⇒ Object
8 9 10 |
# File 'lib/cane/syntax_violation.rb', line 8 def columns [file_name] end |
#description ⇒ Object
12 13 14 |
# File 'lib/cane/syntax_violation.rb', line 12 def description "Files contained invalid syntax" end |
#sort_index ⇒ Object
16 17 18 |
# File 'lib/cane/syntax_violation.rb', line 16 def sort_index 0 end |