public class DefaultElementLocator extends Object implements ElementLocator
PageFactory
and understands the
annotations FindBy
and CacheLookup
.Constructor and Description |
---|
DefaultElementLocator(SearchContext searchContext,
Field field)
Creates a new element locator.
|
Modifier and Type | Method and Description |
---|---|
WebElement |
findElement()
Find the element.
|
List<WebElement> |
findElements()
Find the element list.
|
public DefaultElementLocator(SearchContext searchContext, Field field)
searchContext
- The context to use when finding the elementfield
- The field on the Page Object that will hold the located valuepublic WebElement findElement()
findElement
in interface ElementLocator
public List<WebElement> findElements()
findElements
in interface ElementLocator
Copyright © 2013. All rights reserved.