Class WebElementUtil


  • public class WebElementUtil
    extends Object
    Author:
    Madhav Krishna
    • Method Detail

      • isElementDisabledButNotReadonly

        public static boolean isElementDisabledButNotReadonly​(SmartAppDriver appDriver,
                                                              DOMObject domObject)
      • isElementVisible

        public static boolean isElementVisible​(SmartAppDriver appDriver,
                                               org.openqa.selenium.WebElement webElem)
      • getElementText

        public static String getElementText​(SmartAppDriver appDriver,
                                            org.openqa.selenium.WebElement webElem)
      • getInputTextValue

        public static String getInputTextValue​(SmartAppDriver appDriver,
                                               DOMObject domObject,
                                               int maxIterationsToLocateElements)
      • getInputTextValue

        public static String getInputTextValue​(SmartAppDriver appDriver,
                                               org.openqa.selenium.WebElement webElem)
      • getCssValue

        public static String getCssValue​(SmartAppDriver appDriver,
                                         org.openqa.selenium.WebElement webElem,
                                         String pseudoElem,
                                         String cssPropertyName)
        Used to get the CSS property value when pseudoElement is specified like in CSS example below: .sampleCSS::after { background-color: #ffffff; } here "sampleCSS" is a CSS class name and ":after" is a pseudoElement.
        Parameters:
        appDriver -
        webElem -
        pseudoElem -
        cssPropertyName -
        Returns:
        the CSS property value for the pseudo element.