Sha256: 1d18543360eda11754c67d4c056713312a14af1c75b7de0279141b020d90b65f

Contents?: true

Size: 594 Bytes

Versions: 3

Compression:

Stored size: 594 Bytes

Contents

module PageObject
  module Platforms
    module WatirWebDriver

      module Table

        #
        # Return the PageObject::Elements::TableRow for the index provided.  Index
        # is zero based.
        #
        # @return [PageObject::Elements::TableRow]
        #
        def [](idx)
          Object::PageObject::Elements::TableRow.new(element[idx], :platform => :watir_webdriver)
        end

        #
        # Returns the number of rows in the table.
        #
        def rows
          element.wd.find_elements(:xpath, child_xpath).size
        end

      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
page-object-0.6.6 lib/page-object/platforms/watir_webdriver/table.rb
page-object-0.6.5 lib/page-object/platforms/watir_webdriver/table.rb
page-object-0.6.4 lib/page-object/platforms/watir_webdriver/table.rb