Class: Cucumber::Core::Ast::ExamplesTable::Header
- Inherits:
-
Object
- Object
- Cucumber::Core::Ast::ExamplesTable::Header
- Includes:
- HasLocation
- Defined in:
- lib/cucumber/core/ast/examples_table.rb
Instance Attribute Summary collapse
-
#comments ⇒ Object
readonly
Returns the value of attribute comments.
Instance Method Summary collapse
- #build_row(row_cells, number, location, language, comments) ⇒ Object
-
#initialize(cells, location, comments) ⇒ Header
constructor
A new instance of Header.
- #inspect ⇒ Object
- #values ⇒ Object
Methods included from HasLocation
#all_locations, #attributes, #file, #file_colon_line, #line, #location, #multiline_arg, #tags
Constructor Details
#initialize(cells, location, comments) ⇒ Header
Returns a new instance of Header.
43 44 45 46 47 |
# File 'lib/cucumber/core/ast/examples_table.rb', line 43 def initialize(cells, location, comments) @cells = cells @location = location @comments = comments end |
Instance Attribute Details
#comments ⇒ Object (readonly)
Returns the value of attribute comments.
41 42 43 |
# File 'lib/cucumber/core/ast/examples_table.rb', line 41 def comments @comments end |
Instance Method Details
#build_row(row_cells, number, location, language, comments) ⇒ Object
53 54 55 |
# File 'lib/cucumber/core/ast/examples_table.rb', line 53 def build_row(row_cells, number, location, language, comments) Row.new(Hash[@cells.zip(row_cells)], number, location, language, comments) end |
#inspect ⇒ Object
57 58 59 |
# File 'lib/cucumber/core/ast/examples_table.rb', line 57 def inspect "#<#{self.class} #{values} (#{location})>" end |
#values ⇒ Object
49 50 51 |
# File 'lib/cucumber/core/ast/examples_table.rb', line 49 def values @cells end |