Class: Cucumber::Ast::Table::Cell
Overview
:nodoc:
Direct Known Subclasses
Instance Attribute Summary collapse
-
#line ⇒ Object
readonly
Returns the value of attribute line.
-
#status ⇒ Object
Returns the value of attribute status.
-
#table ⇒ Object
readonly
Returns the value of attribute table.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
- #==(o) ⇒ Object
- #accept(visitor) ⇒ Object
-
#initialize(value, table, line) ⇒ Cell
constructor
A new instance of Cell.
- #inspect! ⇒ Object
-
#to_sexp ⇒ Object
For testing only.
Constructor Details
#initialize(value, table, line) ⇒ Cell
Returns a new instance of Cell.
617 618 619 |
# File 'lib/cucumber/ast/table.rb', line 617 def initialize(value, table, line) @value, @table, @line = value, table, line end |
Instance Attribute Details
#line ⇒ Object (readonly)
Returns the value of attribute line.
614 615 616 |
# File 'lib/cucumber/ast/table.rb', line 614 def line @line end |
#status ⇒ Object
Returns the value of attribute status.
615 616 617 |
# File 'lib/cucumber/ast/table.rb', line 615 def status @status end |
#table ⇒ Object (readonly)
Returns the value of attribute table.
614 615 616 |
# File 'lib/cucumber/ast/table.rb', line 614 def table @table end |
#value ⇒ Object
Returns the value of attribute value.
615 616 617 |
# File 'lib/cucumber/ast/table.rb', line 615 def value @value end |
Instance Method Details
#==(o) ⇒ Object
630 631 632 |
# File 'lib/cucumber/ast/table.rb', line 630 def ==(o) SurplusCell === o || value == o.value end |
#accept(visitor) ⇒ Object
621 622 623 624 |
# File 'lib/cucumber/ast/table.rb', line 621 def accept(visitor) return if Cucumber.wants_to_quit visitor.visit_table_cell_value(value, status) end |
#inspect! ⇒ Object
626 627 628 |
# File 'lib/cucumber/ast/table.rb', line 626 def inspect! @value = "(i) #{value.inspect}" end |
#to_sexp ⇒ Object
For testing only
635 636 637 |
# File 'lib/cucumber/ast/table.rb', line 635 def to_sexp #:nodoc: [:cell, @value] end |