Class PageAwareBy

java.lang.Object
org.openqa.selenium.By
com.epam.healenium.PageAwareBy

public class PageAwareBy
extends org.openqa.selenium.By
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.openqa.selenium.By

    org.openqa.selenium.By.ByClassName, org.openqa.selenium.By.ByCssSelector, org.openqa.selenium.By.ById, org.openqa.selenium.By.ByLinkText, org.openqa.selenium.By.ByName, org.openqa.selenium.By.ByPartialLinkText, org.openqa.selenium.By.ByTagName, org.openqa.selenium.By.ByXPath
  • Constructor Summary

    Constructors 
    Constructor Description
    PageAwareBy()  
  • Method Summary

    Modifier and Type Method Description
    static PageAwareBy by​(String pageName, org.openqa.selenium.By by)
    Instantiates a page-aware locator.
    List<org.openqa.selenium.WebElement> findElements​(org.openqa.selenium.SearchContext searchContext)  
    String toString()  

    Methods inherited from class org.openqa.selenium.By

    className, cssSelector, equals, findElement, hashCode, id, linkText, name, partialLinkText, tagName, xpath

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

  • Method Details

    • by

      public static PageAwareBy by​(String pageName, org.openqa.selenium.By by)
      Instantiates a page-aware locator.
      Parameters:
      pageName - an identifier of the current UI state the element is located on
      by - the original element locator
      Returns:
      the locator that indicates that the element is a subject to healing.
    • findElements

      public List<org.openqa.selenium.WebElement> findElements​(org.openqa.selenium.SearchContext searchContext)
      Specified by:
      findElements in class org.openqa.selenium.By
    • toString

      public String toString()
      Overrides:
      toString in class org.openqa.selenium.By