Class PageFactory

java.lang.Object
net.thucydides.core.pages.PageFactory

public class PageFactory
extends java.lang.Object
  • Constructor Summary

    Constructors
    Constructor Description
    PageFactory​(org.openqa.selenium.WebDriver driver)  
  • Method Summary

    Modifier and Type Method Description
    <T extends PageObject>
    T
    createPageOfType​(java.lang.Class<T> pageObjectClass)
    Create a new Page Object of the given type.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PageFactory

      public PageFactory​(org.openqa.selenium.WebDriver driver)
  • Method Details

    • createPageOfType

      public <T extends PageObject> T createPageOfType​(java.lang.Class<T> pageObjectClass)
      Create a new Page Object of the given type. The Page Object must have a constructor
      Parameters:
      pageObjectClass -
      Throws:
      java.lang.IllegalArgumentException