public interface ISelect
| 限定符和类型 | 方法和说明 |
|---|---|
void |
deselectAll()
Clear all selected entries.
|
void |
deselectByIndex(int index)
Deselect the option at the given index.
|
void |
deselectByValue(String value)
Deselect all options that have a value matching the argument.
|
void |
deselectByVisibleText(String text)
Deselect all options that display text matching the argument.
|
List<WebElement> |
getAllSelectedOptions() |
WebElement |
getFirstSelectedOption() |
List<WebElement> |
getOptions() |
boolean |
isMultiple() |
void |
selectByIndex(int index)
Select the option at the given index.
|
void |
selectByValue(String value)
Select all options that have a value matching the argument.
|
void |
selectByVisibleText(String text)
Select all options that display text matching the argument.
|
boolean isMultiple()
List<WebElement> getOptions()
List<WebElement> getAllSelectedOptions()
WebElement getFirstSelectedOption()
void selectByVisibleText(String text)
text - The visible text to match againstvoid selectByIndex(int index)
index - The option at this index will be selectedvoid selectByValue(String value)
value - The value to match againstvoid deselectAll()
void deselectByValue(String value)
value - The value to match againstvoid deselectByIndex(int index)
index - The option at this index will be deselectedvoid deselectByVisibleText(String text)
text - The visible text to match against