public class WebFragmentImpl extends Object implements WebFragment
WebElement
and delegates all method calls to the underlying
WebElement
.Modifier and Type | Field and Description |
---|---|
protected org.openqa.selenium.WebDriver |
driver |
protected org.openqa.selenium.WebElement |
element |
Constructor and Description |
---|
WebFragmentImpl(org.openqa.selenium.WebDriver driver,
org.openqa.selenium.WebElement element) |
Modifier and Type | Method and Description |
---|---|
void |
checkTextToBeNotPresent(String text) |
void |
checkTextToBePresent(String text) |
void |
clear() |
void |
click() |
boolean |
containsText(String text) |
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) |
String |
getCssValue(String propertyName) |
org.openqa.selenium.WebElement |
getElement() |
String |
getId() |
org.openqa.selenium.Point |
getLocation() |
org.openqa.selenium.Dimension |
getSize() |
String |
getTagName() |
String |
getText() |
<T extends WebFragment> |
getWebFragment(org.openqa.selenium.By by,
Class<T> webFragmentClass) |
<T extends WebFragment> |
getWebFragment(org.openqa.selenium.WebElement element,
Class<T> webFragmentClass) |
boolean |
isDisplayed() |
boolean |
isEnabled() |
boolean |
isSelected() |
void |
sendKeys(CharSequence... keysToSend) |
void |
setElement(org.openqa.selenium.WebElement element) |
void |
submit() |
void |
waitForTextToBePresent(String text) |
protected final org.openqa.selenium.WebDriver driver
protected org.openqa.selenium.WebElement element
public WebFragmentImpl(org.openqa.selenium.WebDriver driver, org.openqa.selenium.WebElement element)
public String getId()
getId
in interface WebFragment
public org.openqa.selenium.WebElement getElement()
getElement
in interface WebFragment
public void setElement(org.openqa.selenium.WebElement element)
setElement
in interface WebFragment
public void click()
click
in interface WebFragment
public void submit()
submit
in interface WebFragment
public void sendKeys(CharSequence... keysToSend)
sendKeys
in interface WebFragment
public void clear()
clear
in interface WebFragment
public String getTagName()
getTagName
in interface WebFragment
public String getAttribute(String name)
getAttribute
in interface WebFragment
public boolean isSelected()
isSelected
in interface WebFragment
public boolean isEnabled()
isEnabled
in interface WebFragment
public String getText()
getText
in interface WebFragment
public List<org.openqa.selenium.WebElement> findElements(org.openqa.selenium.By by)
findElements
in interface WebFragment
public org.openqa.selenium.WebElement findElement(org.openqa.selenium.By by)
findElement
in interface WebFragment
public boolean isDisplayed()
isDisplayed
in interface WebFragment
public org.openqa.selenium.Point getLocation()
getLocation
in interface WebFragment
public org.openqa.selenium.Dimension getSize()
getSize
in interface WebFragment
public String getCssValue(String propertyName)
getCssValue
in interface WebFragment
public <T extends WebFragment> T getWebFragment(org.openqa.selenium.By by, Class<T> webFragmentClass)
getWebFragment
in interface WebFragment
public <T extends WebFragment> T getWebFragment(org.openqa.selenium.WebElement element, Class<T> webFragmentClass)
getWebFragment
in interface WebFragment
public boolean containsText(String text)
containsText
in interface WebFragment
public void waitForTextToBePresent(String text)
waitForTextToBePresent
in interface WebFragment
public void checkTextToBePresent(String text)
checkTextToBePresent
in interface WebFragment
public void checkTextToBeNotPresent(String text)
checkTextToBeNotPresent
in interface WebFragment
Copyright © 2017 Nuxeo. All rights reserved.