Factory
This package has only one class PageinstancesFactory.java
and this class can be used to initialize our page objects by passing the class that we want to initialize.
GooglePage googlePage = PageinstancesFactory.getInstance(GooglePage.class);
We can also create page objects even by calling their constructors.
GooglePage googlePage = new GooglePage(WebDriverContext.getDriver());
Last updated
Was this helpful?