class AutomationObject::State::ElementArray

Element array composite for managing state

Public Instance Methods

utilize() click to toggle source

@return [Array<AutomationObject::State::ElementProxy>] Selenium proxy

# File lib/automation_object/state/element_array.rb, line 15
def utilize
  return cache if cache

  elements = driver.find_elements(*blue_prints.selector_params)

  @active = true
  self.cache = elements.map do |element|
    ElementProxy.new(self, element)
  end
end