Interface GuiElementCore
-
- All Superinterfaces:
GuiElementCoreActions,WebElementRetainer
- All Known Implementing Classes:
AbstractGuiElementCore,AbstractGuiElementCoreDecorator,AbstractWebDriverCore,DelayActionsGuiElementFacade,GuiElementCoreSequenceDecorator,UiElementLogger
public interface GuiElementCore extends GuiElementCoreActions, WebElementRetainer
Provides basicUiElementfeatures and acts as adapter forWebDriverimplementations
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description java.lang.StringgetAttribute(java.lang.String attributeName)WebElement.getAttribute.java.lang.StringgetCssValue(java.lang.String cssIdentifier)WebElement.getCssValue.intgetLengthOfValueAfterSendKeys(java.lang.String textToInput)Deprecated.org.openqa.selenium.PointgetLocation()WebElement.getLocation.intgetNumberOfFoundElements()A given location strategy (Locator + WebElementFilter) can match to many elements in a Website.org.openqa.selenium.RectanglegetRect()Gets the element's rectangleorg.openqa.selenium.DimensiongetSize()WebElement.getSize.java.lang.StringgetTagName()WebElement.getTagName.java.lang.StringgetText()Calls WebElement.getText.java.util.List<java.lang.String>getTextsFromChildren()Deprecated.default org.openqa.selenium.WebElementgetWebElement()Deprecated.booleanisDisplayed()WebElement.isDisplayed.booleanisEnabled()WebElement.isEnabled.booleanisPresent()Checks if an element is found by webdriver.booleanisSelectable()Checks if the element is selectable.booleanisSelected()WebElement.isSelected.booleanisVisible(boolean fullyVisible)Checks if the element is visible in the current viewportjava.io.FiletakeScreenshot()Takes a screenshot of the GuiElement-
Methods inherited from interface eu.tsystems.mms.tic.testframework.pageobjects.internal.core.GuiElementCoreActions
clear, click, contextClick, deselect, doubleClick, highlight, hover, mouseOver, rightClick, scrollIntoView, scrollIntoView, scrollToElement, scrollToElement, scrollToTop, select, select, sendKeys, submit, swipe, type
-
Methods inherited from interface eu.tsystems.mms.tic.testframework.pageobjects.internal.WebElementRetainer
findWebElement
-
-
-
-
Method Detail
-
isPresent
boolean isPresent()
Checks if an element is found by webdriver.- Returns:
- true if found, false otherwise.
-
isEnabled
boolean isEnabled()
WebElement.isEnabled.- Returns:
- true if element is enabled.
-
isDisplayed
boolean isDisplayed()
WebElement.isDisplayed.- Returns:
- true if element is displayed.
-
isVisible
boolean isVisible(boolean fullyVisible)
Checks if the element is visible in the current viewport- Returns:
-
isSelected
boolean isSelected()
WebElement.isSelected.- Returns:
- true if element is selected.
-
getText
java.lang.String getText()
Calls WebElement.getText. Please note that this will only return a String, if the elements text is actually visible.- Returns:
- text of the element.
-
getAttribute
java.lang.String getAttribute(java.lang.String attributeName)
WebElement.getAttribute.- Parameters:
attributeName- Name of the attribute.- Returns:
- The value of the attribute.
-
getRect
org.openqa.selenium.Rectangle getRect()
Gets the element's rectangle
-
isSelectable
boolean isSelectable()
Checks if the element is selectable.- Returns:
- ture, if the element is selectable
-
getTagName
java.lang.String getTagName()
WebElement.getTagName.- Returns:
- The tag name as String.
-
getLocation
org.openqa.selenium.Point getLocation()
WebElement.getLocation.- Returns:
- The location of the webelement.
-
getSize
org.openqa.selenium.Dimension getSize()
WebElement.getSize.- Returns:
- Size of the webelement.
-
getCssValue
java.lang.String getCssValue(java.lang.String cssIdentifier)
WebElement.getCssValue.- Parameters:
cssIdentifier- .- Returns:
- Css value of the webelement.
-
getTextsFromChildren
@Deprecated java.util.List<java.lang.String> getTextsFromChildren()
Deprecated.Returns with all texts of child-elements.- Returns:
- .
-
getLengthOfValueAfterSendKeys
@Deprecated int getLengthOfValueAfterSendKeys(java.lang.String textToInput)
Deprecated.Types your text and returns the length of the attribute 'value' afterwards. Can be useful to check a maximal input length- Parameters:
textToInput- text to check- Returns:
- Length of the attribute 'value'
- See Also:
*
-
getNumberOfFoundElements
int getNumberOfFoundElements()
A given location strategy (Locator + WebElementFilter) can match to many elements in a Website. This method returns that number. This can be useful for tests, that want to ensure that a GuiElement is found n times.- Returns:
- The number, how many WebElements were identified by this GuiElement.
-
takeScreenshot
java.io.File takeScreenshot()
Takes a screenshot of the GuiElement- Returns:
- File object of the screenshot or NULL on error
-
getWebElement
@Deprecated default org.openqa.selenium.WebElement getWebElement()
Deprecated.
-
-