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.
655 656 657 |
# File 'lib/cucumber/ast/table.rb', line 655 def initialize(value, table, line) @value, @table, @line = value, table, line end |
Instance Attribute Details
#line ⇒ Object (readonly)
Returns the value of attribute line.
652 653 654 |
# File 'lib/cucumber/ast/table.rb', line 652 def line @line end |
#status ⇒ Object
Returns the value of attribute status.
653 654 655 |
# File 'lib/cucumber/ast/table.rb', line 653 def status @status end |
#table ⇒ Object (readonly)
Returns the value of attribute table.
652 653 654 |
# File 'lib/cucumber/ast/table.rb', line 652 def table @table end |
#value ⇒ Object
Returns the value of attribute value.
653 654 655 |
# File 'lib/cucumber/ast/table.rb', line 653 def value @value end |
Instance Method Details
#==(o) ⇒ Object
668 669 670 |
# File 'lib/cucumber/ast/table.rb', line 668 def ==(o) SurplusCell === o || value == o.value end |
#accept(visitor) ⇒ Object
659 660 661 662 |
# File 'lib/cucumber/ast/table.rb', line 659 def accept(visitor) return if Cucumber.wants_to_quit visitor.visit_table_cell_value(value, status) end |
#inspect! ⇒ Object
664 665 666 |
# File 'lib/cucumber/ast/table.rb', line 664 def inspect! @value = "(i) #{value.inspect}" end |
#to_sexp ⇒ Object
For testing only
673 674 675 |
# File 'lib/cucumber/ast/table.rb', line 673 def to_sexp #:nodoc: [:cell, @value] end |