Class: Celerity::TableElement
- Includes:
- ClickableElement, Enumerable
- Defined in:
- lib/celerity/elements/table_elements.rb
Direct Known Subclasses
Constant Summary collapse
- ATTRIBUTES =
BASE_ATTRIBUTES | CELLHALIGN_ATTRIBUTES | CELLVALIGN_ATTRIBUTES
- DEFAULT_HOW =
:id
Constants inherited from Element
Element::BASE_ATTRIBUTES, Element::CELLHALIGN_ATTRIBUTES, Element::CELLVALIGN_ATTRIBUTES, Element::HTML_401_TRANSITIONAL, Element::TAGS
Instance Attribute Summary
Attributes inherited from Element
Attributes included from Container
Instance Method Summary collapse
Methods included from ClickableElement
#click, #click_and_attach, #double_click, #download, #right_click
Methods inherited from Element
#==, #assert_exists, #attribute_string, #attribute_value, #exists?, #fire_event, #focus, #focused?, #initialize, #javascript_object, #method_missing, #methods, #object, #parent, #respond_to?, #text, #to_s, #to_xml, #visible?, #xpath
Methods included from Container
#area, #areas, #button, #buttons, #cell, #cells, #check_box, #checkboxes, #container=, #contains_text, #dd, #dds, #del, #dels, #div, #divs, #dl, #dls, #dt, #dts, #em, #ems, #file_field, #file_fields, #form, #forms, #frame, #frames, #h1, #h1s, #h2, #h2s, #h3, #h3s, #h4, #h4s, #h5, #h5s, #h6, #h6s, #hidden, #hiddens, #image, #images, #ins, #inses, #inspect, #label, #labels, #li, #link, #links, #lis, #map, #maps, #meta, #metas, #ol, #ols, #option, #p, #pre, #pres, #ps, #radio, #radios, #row, #rows, #select_list, #select_lists, #span, #spans, #strong, #strongs, #table, #tables, #tbodies, #tbody, #text_field, #text_fields, #tfoot, #tfoots, #th, #thead, #theads, #ths, #ul, #uls
Methods included from ShortInspect
Constructor Details
This class inherits a constructor from Celerity::Element
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Celerity::Element
Instance Method Details
#[](index) ⇒ Object
14 15 16 17 |
# File 'lib/celerity/elements/table_elements.rb', line 14 def [](index) assert_exists TableRow.new(self, :object, @rows[index - Celerity.index_offset]) end |
#each ⇒ Object
24 25 26 27 |
# File 'lib/celerity/elements/table_elements.rb', line 24 def each assert_exists @rows.each { |row| yield TableRow.new(self, :object, row) } end |
#length ⇒ Object
19 20 21 22 |
# File 'lib/celerity/elements/table_elements.rb', line 19 def length assert_exists @object.getRows.length end |
#locate ⇒ Object
9 10 11 12 |
# File 'lib/celerity/elements/table_elements.rb', line 9 def locate super @rows = @object.getRows if @object end |