Package org.openqa.selenium.htmlunit
Class HtmlUnitWebElement
- java.lang.Object
-
- org.openqa.selenium.htmlunit.HtmlUnitWebElement
-
- All Implemented Interfaces:
org.openqa.selenium.interactions.Coordinates
,org.openqa.selenium.interactions.Locatable
,org.openqa.selenium.SearchContext
,org.openqa.selenium.TakesScreenshot
,org.openqa.selenium.WebElement
,org.openqa.selenium.WrapsDriver
public class HtmlUnitWebElement extends Object implements org.openqa.selenium.WrapsDriver, org.openqa.selenium.WebElement, org.openqa.selenium.interactions.Coordinates, org.openqa.selenium.interactions.Locatable
- Author:
- Alexei Barantsev, Ahmed Ashour, Javier Neira, Ronald Brill, Andrei Solntsev, Martin Bartoš, Scott Babcock
-
-
Constructor Summary
Constructors Constructor Description HtmlUnitWebElement(HtmlUnitDriver driver, int id, DomElement element)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected void
assertElementNotStale()
void
clear()
void
click()
boolean
equals(Object obj)
org.openqa.selenium.WebElement
findElement(org.openqa.selenium.By by)
List<org.openqa.selenium.WebElement>
findElements(org.openqa.selenium.By by)
String
getAttribute(String name)
Object
getAuxiliary()
org.openqa.selenium.interactions.Coordinates
getCoordinates()
String
getCssValue(String propertyName)
String
getDomAttribute(String name)
String
getDomProperty(String name)
protected HtmlUnitDriver
getDriver()
DomElement
getElement()
List<org.openqa.selenium.WebElement>
getElementsByTagName(String tagName)
Deprecated.int
getId()
org.openqa.selenium.Point
getLocation()
org.openqa.selenium.Rectangle
getRect()
<X> X
getScreenshotAs(org.openqa.selenium.OutputType<X> outputType)
org.openqa.selenium.Dimension
getSize()
String
getTagName()
String
getText()
org.openqa.selenium.WebDriver
getWrappedDriver()
int
hashCode()
org.openqa.selenium.Point
inViewPort()
boolean
isDisplayed()
boolean
isEnabled()
boolean
isSelected()
org.openqa.selenium.Point
onPage()
org.openqa.selenium.Point
onScreen()
void
sendKeys(CharSequence... value)
void
submit()
Map<String,Object>
toJson()
String
toString()
-
-
-
Constructor Detail
-
HtmlUnitWebElement
public HtmlUnitWebElement(HtmlUnitDriver driver, int id, DomElement element)
-
-
Method Detail
-
click
public void click()
- Specified by:
click
in interfaceorg.openqa.selenium.WebElement
-
submit
public void submit()
- Specified by:
submit
in interfaceorg.openqa.selenium.WebElement
-
clear
public void clear()
- Specified by:
clear
in interfaceorg.openqa.selenium.WebElement
-
sendKeys
public void sendKeys(CharSequence... value)
- Specified by:
sendKeys
in interfaceorg.openqa.selenium.WebElement
-
getTagName
public String getTagName()
- Specified by:
getTagName
in interfaceorg.openqa.selenium.WebElement
-
getAttribute
public String getAttribute(String name)
- Specified by:
getAttribute
in interfaceorg.openqa.selenium.WebElement
-
getDomProperty
public String getDomProperty(String name)
- Specified by:
getDomProperty
in interfaceorg.openqa.selenium.WebElement
-
getDomAttribute
public String getDomAttribute(String name)
- Specified by:
getDomAttribute
in interfaceorg.openqa.selenium.WebElement
-
isSelected
public boolean isSelected()
- Specified by:
isSelected
in interfaceorg.openqa.selenium.WebElement
-
isEnabled
public boolean isEnabled()
- Specified by:
isEnabled
in interfaceorg.openqa.selenium.WebElement
-
isDisplayed
public boolean isDisplayed()
- Specified by:
isDisplayed
in interfaceorg.openqa.selenium.WebElement
-
getLocation
public org.openqa.selenium.Point getLocation()
- Specified by:
getLocation
in interfaceorg.openqa.selenium.WebElement
-
getSize
public org.openqa.selenium.Dimension getSize()
- Specified by:
getSize
in interfaceorg.openqa.selenium.WebElement
-
getRect
public org.openqa.selenium.Rectangle getRect()
- Specified by:
getRect
in interfaceorg.openqa.selenium.WebElement
-
getText
public String getText()
- Specified by:
getText
in interfaceorg.openqa.selenium.WebElement
-
getDriver
protected HtmlUnitDriver getDriver()
-
getElement
public DomElement getElement()
-
getElementsByTagName
@Deprecated public List<org.openqa.selenium.WebElement> getElementsByTagName(String tagName)
Deprecated.
-
findElement
public org.openqa.selenium.WebElement findElement(org.openqa.selenium.By by)
- Specified by:
findElement
in interfaceorg.openqa.selenium.SearchContext
- Specified by:
findElement
in interfaceorg.openqa.selenium.WebElement
-
findElements
public List<org.openqa.selenium.WebElement> findElements(org.openqa.selenium.By by)
- Specified by:
findElements
in interfaceorg.openqa.selenium.SearchContext
- Specified by:
findElements
in interfaceorg.openqa.selenium.WebElement
-
assertElementNotStale
protected void assertElementNotStale()
-
getCssValue
public String getCssValue(String propertyName)
- Specified by:
getCssValue
in interfaceorg.openqa.selenium.WebElement
-
getWrappedDriver
public org.openqa.selenium.WebDriver getWrappedDriver()
- Specified by:
getWrappedDriver
in interfaceorg.openqa.selenium.WrapsDriver
-
getCoordinates
public org.openqa.selenium.interactions.Coordinates getCoordinates()
- Specified by:
getCoordinates
in interfaceorg.openqa.selenium.interactions.Locatable
-
onScreen
public org.openqa.selenium.Point onScreen()
- Specified by:
onScreen
in interfaceorg.openqa.selenium.interactions.Coordinates
-
inViewPort
public org.openqa.selenium.Point inViewPort()
- Specified by:
inViewPort
in interfaceorg.openqa.selenium.interactions.Coordinates
-
onPage
public org.openqa.selenium.Point onPage()
- Specified by:
onPage
in interfaceorg.openqa.selenium.interactions.Coordinates
-
getAuxiliary
public Object getAuxiliary()
- Specified by:
getAuxiliary
in interfaceorg.openqa.selenium.interactions.Coordinates
-
getScreenshotAs
public <X> X getScreenshotAs(org.openqa.selenium.OutputType<X> outputType) throws org.openqa.selenium.WebDriverException
- Specified by:
getScreenshotAs
in interfaceorg.openqa.selenium.TakesScreenshot
- Throws:
org.openqa.selenium.WebDriverException
-
getId
public int getId()
-
-