Class: Ibex::BisonImport::Directive
- Inherits:
-
Object
- Object
- Ibex::BisonImport::Directive
- Defined in:
- lib/ibex/bison_import.rb,
sig/ibex/bison_import.rbs
Overview
One directive occurrence and its original source position.
Instance Attribute Summary collapse
- #column ⇒ Integer readonly
- #detail ⇒ String readonly
- #line ⇒ Integer readonly
- #name ⇒ String readonly
- #status ⇒ Symbol readonly
Instance Method Summary collapse
-
#initialize(name:, status:, line:, column:, detail:) ⇒ Directive
constructor
A new instance of Directive.
- #to_h ⇒ Hash[Symbol, Object?]
Constructor Details
#initialize(name:, status:, line:, column:, detail:) ⇒ Directive
Returns a new instance of Directive.
80 81 82 83 84 85 86 87 |
# File 'lib/ibex/bison_import.rb', line 80 def initialize(name:, status:, line:, column:, detail:) @name = name.freeze @status = status @line = line @column = column @detail = detail.freeze freeze end |
Instance Attribute Details
#column ⇒ Integer (readonly)
76 77 78 |
# File 'lib/ibex/bison_import.rb', line 76 def column @column end |
#detail ⇒ String (readonly)
77 78 79 |
# File 'lib/ibex/bison_import.rb', line 77 def detail @detail end |
#line ⇒ Integer (readonly)
75 76 77 |
# File 'lib/ibex/bison_import.rb', line 75 def line @line end |
#name ⇒ String (readonly)
73 74 75 |
# File 'lib/ibex/bison_import.rb', line 73 def name @name end |
#status ⇒ Symbol (readonly)
74 75 76 |
# File 'lib/ibex/bison_import.rb', line 74 def status @status end |
Instance Method Details
#to_h ⇒ Hash[Symbol, Object?]
90 91 92 |
# File 'lib/ibex/bison_import.rb', line 90 def to_h { name: @name, status: @status, line: @line, column: @column, detail: @detail } end |