Java 类org.openqa.selenium.support.pagefactory.internal.LocatingElementListHandler 实例源码

项目:bobcat    文件:CurrentScopeListProvider.java   
@SuppressWarnings("unchecked")
private List<WebElement> retrieveListFromFactory(ElementLocatorFactory factory) {
  InvocationHandler handler = new LocatingElementListHandler(
      ((ScopedElementLocatorFactory) factory).getCurrentScope());
  return (List<WebElement>) Proxy
      .newProxyInstance(WebElement.class.getClassLoader(), new Class[] {List.class}, handler);
}