Package io.fluentlenium.core.components
Class AbstractComponentInstantiator
java.lang.Object
io.fluentlenium.core.components.AbstractComponentInstantiator
- All Implemented Interfaces:
ComponentInstantiator
- Direct Known Subclasses:
ComponentsManager
,DefaultComponentInstantiator
Abstract component instantiator.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<L extends List<T>,
T>
LasComponentList
(Class<L> listClass, Class<T> componentClass, Iterable<org.openqa.selenium.WebElement> elements) Create and register a new list of component from the given element iterable.<L extends List<T>,
T>
LasComponentList
(Class<L> listClass, Class<T> componentClass, List<org.openqa.selenium.WebElement> elements) Create and register a new list of component from the given element iterable.<L extends List<T>,
T>
LasComponentList
(Class<L> listClass, Class<T> componentClass, org.openqa.selenium.WebElement... elements) Create and register a new list of component from the given element iterable.<T> ComponentList<T>
asComponentList
(Class<T> componentClass, Iterable<org.openqa.selenium.WebElement> elements) Create and register a new list of component from the given element iterable.<T> ComponentList<T>
asComponentList
(Class<T> componentClass, List<org.openqa.selenium.WebElement> elements) Create and register a new list of component from the given element iterable.<T> ComponentList<T>
asComponentList
(Class<T> componentClass, org.openqa.selenium.WebElement... elements) Create and register a new list of component from the given element iterable.<T extends FluentWebElement>
FluentList<T>asFluentList
(Class<T> componentClass, Iterable<org.openqa.selenium.WebElement> elements) Create and register a new fluent list.<T extends FluentWebElement>
FluentList<T>asFluentList
(Class<T> componentClass, List<org.openqa.selenium.WebElement> elements) Create and register a new fluent list.<T extends FluentWebElement>
FluentList<T>asFluentList
(Class<T> componentClass, org.openqa.selenium.WebElement... elements) Create and register a new fluent list.asFluentList
(Iterable<org.openqa.selenium.WebElement> elements) Create and register a new fluent list from the argument collection of WebElements.asFluentList
(List<org.openqa.selenium.WebElement> elements) Create and register a new fluent list from the argument list of WebElements.asFluentList
(org.openqa.selenium.WebElement... elements) Create and register a new fluent list from the argument WebElements.<L extends List<T>,
T>
LnewComponentList
(Class<L> listClass, Class<T> componentClass) Create and register an empty list of component.<L extends List<T>,
T>
LnewComponentList
(Class<L> listClass, Class<T> componentClass, T... componentsList) Create and register a new list of component from the given component list.<T> ComponentList<T>
newComponentList
(Class<T> componentClass) Create and register an empty list of component.<T> ComponentList<T>
newComponentList
(Class<T> componentClass, List<T> componentsList) Create and register a new list of component from the given component list.<T> ComponentList<T>
newComponentList
(Class<T> componentClass, T... componentsList) Create and register a new list of component from the given component list.newFluent
(org.openqa.selenium.WebElement element) Create and register a newFluentWebElement
from the givenWebElement
.Create and register an empty fluent list.<T extends FluentWebElement>
FluentList<T>newFluentList
(Class<T> componentClass) Create and register an empty fluent list of the provided type.<T extends FluentWebElement>
FluentList<T>newFluentList
(Class<T> componentClass, List<T> elements) Create and register a new fluent list.<T extends FluentWebElement>
FluentList<T>newFluentList
(Class<T> componentClass, T... elements) Create and register a new fluent list.newFluentList
(List<FluentWebElement> elements) Create and register a new fluent list from the argument list of FluentWebElements.newFluentList
(FluentWebElement... elements) Create and register a new fluent list from the argument FluentWebElements.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.fluentlenium.core.components.ComponentInstantiator
isComponentClass, isComponentListClass, newComponent, newComponentList
-
Constructor Details
-
AbstractComponentInstantiator
public AbstractComponentInstantiator()
-
-
Method Details
-
newFluent
Description copied from interface:ComponentInstantiator
Create and register a newFluentWebElement
from the givenWebElement
.- Specified by:
newFluent
in interfaceComponentInstantiator
- Parameters:
element
- wrapped element- Returns:
- new instance of the component
-
newFluentList
Description copied from interface:ComponentInstantiator
Create and register an empty fluent list.- Specified by:
newFluentList
in interfaceComponentInstantiator
- Returns:
- new list of fluent web element
-
asFluentList
Description copied from interface:ComponentInstantiator
Create and register a new fluent list from the argument WebElements.- Specified by:
asFluentList
in interfaceComponentInstantiator
- 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 interfaceComponentInstantiator
- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
asFluentList
Description copied from interface:ComponentInstantiator
Create and register a new fluent list from the argument list of WebElements.- Specified by:
asFluentList
in interfaceComponentInstantiator
- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
newFluentList
Description copied from interface:ComponentInstantiator
Create and register a new fluent list from the argument FluentWebElements.- Specified by:
newFluentList
in interfaceComponentInstantiator
- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
newFluentList
Description copied from interface:ComponentInstantiator
Create and register a new fluent list from the argument list of FluentWebElements.- Specified by:
newFluentList
in interfaceComponentInstantiator
- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
newFluentList
Description copied from interface:ComponentInstantiator
Create and register an empty fluent list of the provided type.- Specified by:
newFluentList
in interfaceComponentInstantiator
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- list of elements- Returns:
- new list of fluent web element
-
newComponentList
Description copied from interface:ComponentInstantiator
Create and register an empty list of component.- Specified by:
newComponentList
in interfaceComponentInstantiator
- Type Parameters:
L
- type of the listT
- type of the component- Parameters:
listClass
- type of the listcomponentClass
- type of the component- Returns:
- new list of components
-
newComponentList
Description copied from interface:ComponentInstantiator
Create and register an empty list of component.- Specified by:
newComponentList
in interfaceComponentInstantiator
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentelements
- elements- Returns:
- new list of components
-
newComponentList
Description copied from interface:ComponentInstantiator
Create and register a new list of component from the given component list.- Specified by:
newComponentList
in interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentcomponentsList
- components list- Returns:
- new list of components
-
newComponentList
Description copied from interface:ComponentInstantiator
Create and register a new list of component from the given component list.- Specified by:
newComponentList
in interfaceComponentInstantiator
- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentcomponentsList
- 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 interfaceComponentInstantiator
- Type Parameters:
L
- type of the listT
- type of the component- Parameters:
listClass
- type of the listcomponentClass
- type of the componentcomponentsList
- 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 interfaceComponentInstantiator
- Type Parameters:
L
- type of the listT
- type of the component- Parameters:
listClass
- type of the listcomponentClass
- type of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
L
- type of the listT
- type of the component- Parameters:
listClass
- type of the listcomponentClass
- type of the componentelements
- 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 interfaceComponentInstantiator
- Type Parameters:
L
- type of the listT
- type of the component- Parameters:
listClass
- type of the listcomponentClass
- type of the componentelements
- elements- Returns:
- new list of components
-