Package io.fluentlenium.core.components
Interface ComponentInstantiator
- All Known Subinterfaces:
FluentControl
,FluentPageControl
,IFluentAdapter
- All Known Implementing Classes:
AbstractComponentInstantiator
,BaseFluentHook
,BaseHook
,ComponentsManager
,ContainerFluentControl
,DefaultComponentInstantiator
,DefaultFluentContainer
,FluentAdapter
,FluentControlImpl
,FluentCucumberTest
,FluentDriver
,FluentPage
,FluentStandalone
,FluentStandaloneRunnable
,FluentTest
,FluentTest
,FluentTestNg
,FluentTestNgSpringTest
,FluentTestRunnerAdapter
,FluentWebElement
,IsolatedTest
,WaitHook
public interface ComponentInstantiator
Factory building new components.
-
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.boolean
isComponentClass
(Class<?> componentClass) Check if this class is a component class.boolean
isComponentListClass
(Class<? extends List<?>> componentListClass) Check if this class is a component list class.<T> T
newComponent
(Class<T> componentClass, org.openqa.selenium.WebElement element) Create and register a new component of the provided type from the givenWebElement
.<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, List<T> componentsList) Create and register a new list of component from the given component list.<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.
-
Method Details
-
newFluent
Create and register a newFluentWebElement
from the givenWebElement
.- Parameters:
element
- wrapped element- Returns:
- new instance of the component
-
newComponent
Create and register a new component of the provided type from the givenWebElement
.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentelement
- wrapped element- Returns:
- new instance of the component
-
newFluentList
FluentList<FluentWebElement> newFluentList()Create and register an empty fluent list.- Returns:
- new list of fluent web element
-
newFluentList
Create and register a new fluent list from the argument FluentWebElements.- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
newFluentList
Create and register a new fluent list from the argument list of FluentWebElements.- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
asFluentList
Create and register a new fluent list from the argument WebElements.- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
asFluentList
Create and register a new fluent list from the argument collection of WebElements.- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
asFluentList
Create and register a new fluent list from the argument list of WebElements.- Parameters:
elements
- list of elements- Returns:
- new list of fluent web element
-
newFluentList
Create and register an empty fluent list of the provided type.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the component- Returns:
- new list of fluent web element
-
newFluentList
Create and register a new fluent list.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- list of elements- Returns:
- new list of fluent web element
-
newFluentList
<T extends FluentWebElement> FluentList<T> newFluentList(Class<T> componentClass, List<T> elements) Create and register a new fluent list.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- list of elements- Returns:
- new list of fluent web element
-
asFluentList
<T extends FluentWebElement> FluentList<T> asFluentList(Class<T> componentClass, org.openqa.selenium.WebElement... elements) Create and register a new fluent list.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- list of elements- Returns:
- new list of fluent web element
-
asFluentList
<T extends FluentWebElement> FluentList<T> asFluentList(Class<T> componentClass, Iterable<org.openqa.selenium.WebElement> elements) Create and register a new fluent list.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- list of elements- Returns:
- new list of fluent web element
-
asFluentList
<T extends FluentWebElement> FluentList<T> asFluentList(Class<T> componentClass, List<org.openqa.selenium.WebElement> elements) Create and register a new fluent list.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- class of the componentelements
- list of elements- Returns:
- new list of fluent web element
-
newComponentList
Create and register an empty list of component.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the component- Returns:
- new list of components
-
asComponentList
<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.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentelements
- elements- Returns:
- new list of components
-
asComponentList
<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.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentelements
- elements- Returns:
- new list of components
-
asComponentList
<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.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentelements
- elements- Returns:
- new list of components
-
newComponentList
Create and register a new list of component from the given component list.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentcomponentsList
- components list- Returns:
- new list of components
-
newComponentList
Create and register a new list of component from the given component list.- Type Parameters:
T
- type of the component- Parameters:
componentClass
- type of the componentcomponentsList
- components list- Returns:
- new list of components
-
newComponentList
Create and register an empty list of component.- 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
-
asComponentList
<L extends List<T>,T> L asComponentList(Class<L> listClass, Class<T> componentClass, org.openqa.selenium.WebElement... elements) Create and register a new list of component from the given element iterable.- 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
<L extends List<T>,T> L asComponentList(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.- 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
<L extends List<T>,T> L asComponentList(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.- 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
-
newComponentList
<L extends List<T>,T> L newComponentList(Class<L> listClass, Class<T> componentClass, T... componentsList) Create and register a new list of component from the given component list.- 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
-
newComponentList
<L extends List<T>,T> L newComponentList(Class<L> listClass, Class<T> componentClass, List<T> componentsList) Create and register a new list of component from the given component list.- 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
-
isComponentClass
Check if this class is a component class.- Parameters:
componentClass
- class to check- Returns:
- true if this class is a component class, false otherwise
-
isComponentListClass
Check if this class is a component list class.- Parameters:
componentListClass
- class to check- Returns:
- true if this class is a component list class, false otherwise
-