Module: PageObject::Platforms::WatirWebDriver::TableRow

Defined in:
lib/page-object/platforms/watir_webdriver/table_row.rb

Instance Method Summary collapse

Instance Method Details

#[](idx) ⇒ Object

Return the PageObject::Elements::TableCell for the index provided. Index is zero based.



10
11
12
# File 'lib/page-object/platforms/watir_webdriver/table_row.rb', line 10

def [](idx)
  Object::PageObject::Elements::TableCell.new(element[idx], :platform => :watir_webdriver)
end

#columnsObject

Returns the number of columns in the table.



17
18
19
# File 'lib/page-object/platforms/watir_webdriver/table_row.rb', line 17

def columns
  element.wd.find_elements(:xpath, child_xpath).size
end