类 WebLocator


  • public class WebLocator
    extends Object
    作者:
    Yun
    • 构造器概要

      构造器 
      构造器 说明
      WebLocator()  
    • 方法概要

      所有方法 静态方法 具体方法 
      修饰符和类型 方法 说明
      static org.openqa.selenium.WebElement getElement​(List<org.openqa.selenium.WebElement> elements)
      Find the first enabled and displayed in the elements
      static org.openqa.selenium.WebElement getElement​(org.openqa.selenium.WebDriver driver, org.openqa.selenium.By by)
      Find the first enabled and displayed in the elements
      static org.openqa.selenium.WebElement getElementByAttributeValue​(List<org.openqa.selenium.WebElement> elements, String attribute, String value)
      Search the target element by attribute value
      static org.openqa.selenium.WebElement getElementByAttributeValue​(org.openqa.selenium.WebDriver driver, org.openqa.selenium.By by, String attribute, String value)
      Search the target element by attribute value
      static org.openqa.selenium.WebElement getElementByAttributeValueFromAnElement​(org.openqa.selenium.WebElement e, org.openqa.selenium.By by, String attribute, String value)
      Search the target element by attribute value from an element
      static org.openqa.selenium.WebElement getElementByText​(List<org.openqa.selenium.WebElement> elements, String text)
      Search the target element by text value
      static org.openqa.selenium.WebElement getElementByText​(org.openqa.selenium.WebDriver driver, org.openqa.selenium.By by, String text)
      Search the target element by text value
      static org.openqa.selenium.WebElement getElementByTextFromAnElement​(org.openqa.selenium.WebElement e, org.openqa.selenium.By by, String text)
      Search the target element by text value from an element
    • 构造器详细资料

      • WebLocator

        public WebLocator()
    • 方法详细资料

      • getElement

        public static org.openqa.selenium.WebElement getElement​(List<org.openqa.selenium.WebElement> elements)
        Find the first enabled and displayed in the elements
      • getElement

        public static org.openqa.selenium.WebElement getElement​(org.openqa.selenium.WebDriver driver,
                                                                org.openqa.selenium.By by)
        Find the first enabled and displayed in the elements
      • getElementByAttributeValue

        public static org.openqa.selenium.WebElement getElementByAttributeValue​(List<org.openqa.selenium.WebElement> elements,
                                                                                String attribute,
                                                                                String value)
        Search the target element by attribute value
      • getElementByAttributeValue

        public static org.openqa.selenium.WebElement getElementByAttributeValue​(org.openqa.selenium.WebDriver driver,
                                                                                org.openqa.selenium.By by,
                                                                                String attribute,
                                                                                String value)
        Search the target element by attribute value
      • getElementByAttributeValueFromAnElement

        public static org.openqa.selenium.WebElement getElementByAttributeValueFromAnElement​(org.openqa.selenium.WebElement e,
                                                                                             org.openqa.selenium.By by,
                                                                                             String attribute,
                                                                                             String value)
        Search the target element by attribute value from an element
      • getElementByText

        public static org.openqa.selenium.WebElement getElementByText​(List<org.openqa.selenium.WebElement> elements,
                                                                      String text)
        Search the target element by text value
      • getElementByText

        public static org.openqa.selenium.WebElement getElementByText​(org.openqa.selenium.WebDriver driver,
                                                                      org.openqa.selenium.By by,
                                                                      String text)
        Search the target element by text value
      • getElementByTextFromAnElement

        public static org.openqa.selenium.WebElement getElementByTextFromAnElement​(org.openqa.selenium.WebElement e,
                                                                                   org.openqa.selenium.By by,
                                                                                   String text)
        Search the target element by text value from an element