@Component(value="tapirSingleSelect") @Scope(value="prototype") public class DefaultSeleniumSingleSelect extends AbstractSingleSeleniumElement implements SingleSelect
SingleSelect
.WebElement
in a Select
to obtain helper methods to select and deselect
options.Constructor and Description |
---|
DefaultSeleniumSingleSelect() |
Modifier and Type | Method and Description |
---|---|
List<SingleSelectOption> |
findElements(Predicate<? super SingleSelectOption> predicate)
Returns all elements which match the given predicate
|
List<SingleSelectOption> |
findElementsByLabel(String aLabel)
Returns all elements which have the given label.
|
SingleSelectOption |
findFirstElement(Predicate<? super SingleSelectOption> predicate)
Returns the first element which matches the given predicate
|
SingleSelectOption |
findFirstElementByLabel(String aLabel)
Returns the first element which has the given label
|
List<SingleSelectOption> |
getElements()
Returns all elements
|
protected List<SingleSelectOption> |
getElementsInternal(Predicate<? super SingleSelectOption> predicate,
boolean returnOnFirstMatch) |
SingleSelectOption |
getSelectedElement()
Returns the selected element.
|
boolean |
isDisplayed()
Returns true, if the element is displayed.
|
boolean |
isEnabled()
Returns true, if the element is enabled.
|
getWebElement, setWebElement
public boolean isDisplayed()
Displayable
isDisplayed
in interface Displayable
public boolean isEnabled()
Enabable
public List<SingleSelectOption> getElements()
ElementCollection
getElements
in interface ElementCollection<SingleSelectOption>
protected List<SingleSelectOption> getElementsInternal(Predicate<? super SingleSelectOption> predicate, boolean returnOnFirstMatch)
public SingleSelectOption getSelectedElement()
SingleSelectable
getSelectedElement
in interface SingleSelectable<SingleSelectOption>
public List<SingleSelectOption> findElements(Predicate<? super SingleSelectOption> predicate)
ElementCollection
findElements
in interface ElementCollection<SingleSelectOption>
predicate
- the predicate for finding the elementspublic SingleSelectOption findFirstElement(Predicate<? super SingleSelectOption> predicate)
ElementCollection
findFirstElement
in interface ElementCollection<SingleSelectOption>
predicate
- the predicate for selecting the elementpublic List<SingleSelectOption> findElementsByLabel(String aLabel)
SingleSelect
findElementsByLabel
in interface SingleSelect
aLabel
- the label for finding the elementspublic SingleSelectOption findFirstElementByLabel(String aLabel)
SingleSelect
findFirstElementByLabel
in interface SingleSelect
aLabel
- the label for selecting the elementCopyright © 2018–2020 b+m Informatik AG. All rights reserved.