Class AbstractComponentInstantiator

java.lang.Object
io.fluentlenium.core.components.AbstractComponentInstantiator
All Implemented Interfaces:
ComponentInstantiator
Direct Known Subclasses:
ComponentsManager, DefaultComponentInstantiator

public abstract class AbstractComponentInstantiator extends Object implements ComponentInstantiator
Abstract component instantiator.
  • Constructor Details

    • AbstractComponentInstantiator

      public AbstractComponentInstantiator()
  • Method Details

    • newFluent

      public FluentWebElement newFluent (org.openqa.selenium.WebElement element)
      Description copied from interface: ComponentInstantiator
      Create and register a new FluentWebElement from the given WebElement.
      Specified by:
      newFluent in interface ComponentInstantiator
      Parameters:
      element - wrapped element
      Returns:
      new instance of the component
    • newFluentList

      public FluentList<FluentWebElement> newFluentList()
      Description copied from interface: ComponentInstantiator
      Create and register an empty fluent list.
      Specified by:
      newFluentList in interface ComponentInstantiator
      Returns:
      new list of fluent web element
    • asFluentList

      public FluentList<FluentWebElement> asFluentList (org.openqa.selenium.WebElement... elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list from the argument WebElements.
      Specified by:
      asFluentList in interface ComponentInstantiator
      Parameters:
      elements - list of elements
      Returns:
      new list of fluent web element
    • asFluentList

      public FluentList<FluentWebElement> asFluentList (Iterable<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list from the argument collection of WebElements.
      Specified by:
      asFluentList in interface ComponentInstantiator
      Parameters:
      elements - list of elements
      Returns:
      new list of fluent web element
    • asFluentList

      public FluentList<FluentWebElement> asFluentList (List<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list from the argument list of WebElements.
      Specified by:
      asFluentList in interface ComponentInstantiator
      Parameters:
      elements - list of elements
      Returns:
      new list of fluent web element
    • newFluentList

      public FluentList<FluentWebElement> newFluentList (FluentWebElement... elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list from the argument FluentWebElements.
      Specified by:
      newFluentList in interface ComponentInstantiator
      Parameters:
      elements - list of elements
      Returns:
      new list of fluent web element
    • newFluentList

      public FluentList<FluentWebElement> newFluentList (List<FluentWebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list from the argument list of FluentWebElements.
      Specified by:
      newFluentList in interface ComponentInstantiator
      Parameters:
      elements - list of elements
      Returns:
      new list of fluent web element
    • newFluentList

      public <T extends FluentWebElement> FluentList<T> newFluentList (Class<T> componentClass)
      Description copied from interface: ComponentInstantiator
      Create and register an empty fluent list of the provided type.
      Specified by:
      newFluentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - class of the component
      Returns:
      new list of fluent web element
    • newFluentList

      public <T extends FluentWebElement> FluentList<T> newFluentList (Class<T> componentClass, T... elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list.
      Specified by:
      newFluentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - class of the component
      elements - list of elements
      Returns:
      new list of fluent web element
    • newFluentList

      public <T extends FluentWebElement> FluentList<T> newFluentList (Class<T> componentClass, List<T> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list.
      Specified by:
      newFluentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - class of the component
      elements - list of elements
      Returns:
      new list of fluent web element
    • asFluentList

      public <T extends FluentWebElement> FluentList<T> asFluentList (Class<T> componentClass, org.openqa.selenium.WebElement... elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list.
      Specified by:
      asFluentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - class of the component
      elements - list of elements
      Returns:
      new list of fluent web element
    • asFluentList

      public <T extends FluentWebElement> FluentList<T> asFluentList (Class<T> componentClass, Iterable<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list.
      Specified by:
      asFluentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - class of the component
      elements - list of elements
      Returns:
      new list of fluent web element
    • asFluentList

      public <T extends FluentWebElement> FluentList<T> asFluentList (Class<T> componentClass, List<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new fluent list.
      Specified by:
      asFluentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - class of the component
      elements - list of elements
      Returns:
      new list of fluent web element
    • newComponentList

      public <L extends List<T>, T> L newComponentList (Class<L> listClass, Class<T> componentClass)
      Description copied from interface: ComponentInstantiator
      Create and register an empty list of component.
      Specified by:
      newComponentList in interface ComponentInstantiator
      Type Parameters:
      L - type of the list
      T - type of the component
      Parameters:
      listClass - type of the list
      componentClass - type of the component
      Returns:
      new list of components
    • newComponentList

      public <T> ComponentList<T> newComponentList (Class<T> componentClass)
      Description copied from interface: ComponentInstantiator
      Create and register an empty list of component.
      Specified by:
      newComponentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - type of the component
      Returns:
      new list of components
    • asComponentList

      public <T> ComponentList<T> asComponentList (Class<T> componentClass, org.openqa.selenium.WebElement... elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given element iterable.
      Specified by:
      asComponentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - type of the component
      elements - elements
      Returns:
      new list of components
    • asComponentList

      public <T> ComponentList<T> asComponentList (Class<T> componentClass, Iterable<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given element iterable.
      Specified by:
      asComponentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - type of the component
      elements - elements
      Returns:
      new list of components
    • asComponentList

      public <T> ComponentList<T> asComponentList (Class<T> componentClass, List<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given element iterable.
      Specified by:
      asComponentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - type of the component
      elements - elements
      Returns:
      new list of components
    • newComponentList

      public <T> ComponentList<T> newComponentList (Class<T> componentClass, T... componentsList)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given component list.
      Specified by:
      newComponentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - type of the component
      componentsList - components list
      Returns:
      new list of components
    • newComponentList

      public <T> ComponentList<T> newComponentList (Class<T> componentClass, List<T> componentsList)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given component list.
      Specified by:
      newComponentList in interface ComponentInstantiator
      Type Parameters:
      T - type of the component
      Parameters:
      componentClass - type of the component
      componentsList - components list
      Returns:
      new list of components
    • newComponentList

      public <L extends List<T>, T> L newComponentList (Class<L> listClass, Class<T> componentClass, T... componentsList)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given component list.
      Specified by:
      newComponentList in interface ComponentInstantiator
      Type Parameters:
      L - type of the list
      T - type of the component
      Parameters:
      listClass - type of the list
      componentClass - type of the component
      componentsList - components list
      Returns:
      new list of components
    • asComponentList

      public <L extends List<T>, T> L asComponentList (Class<L> listClass, Class<T> componentClass, org.openqa.selenium.WebElement... elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given element iterable.
      Specified by:
      asComponentList in interface ComponentInstantiator
      Type Parameters:
      L - type of the list
      T - type of the component
      Parameters:
      listClass - type of the list
      componentClass - type of the component
      elements - elements
      Returns:
      new list of components
    • asComponentList

      public <L extends List<T>, T> L asComponentList (Class<L> listClass, Class<T> componentClass, Iterable<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given element iterable.
      Specified by:
      asComponentList in interface ComponentInstantiator
      Type Parameters:
      L - type of the list
      T - type of the component
      Parameters:
      listClass - type of the list
      componentClass - type of the component
      elements - elements
      Returns:
      new list of components
    • asComponentList

      public <L extends List<T>, T> L asComponentList (Class<L> listClass, Class<T> componentClass, List<org.openqa.selenium.WebElement> elements)
      Description copied from interface: ComponentInstantiator
      Create and register a new list of component from the given element iterable.
      Specified by:
      asComponentList in interface ComponentInstantiator
      Type Parameters:
      L - type of the list
      T - type of the component
      Parameters:
      listClass - type of the list
      componentClass - type of the component
      elements - elements
      Returns:
      new list of components