当前位置: 首页>>代码示例>>Java>>正文


Java RemoteLocationContext类代码示例

本文整理汇总了Java中org.openqa.selenium.remote.html5.RemoteLocationContext的典型用法代码示例。如果您正苦于以下问题:Java RemoteLocationContext类的具体用法?Java RemoteLocationContext怎么用?Java RemoteLocationContext使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


RemoteLocationContext类属于org.openqa.selenium.remote.html5包,在下文中一共展示了RemoteLocationContext类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: AppiumDriver

import org.openqa.selenium.remote.html5.RemoteLocationContext; //导入依赖的package包/类
/**
 * @param executor is an instance of {@link org.openqa.selenium.remote.HttpCommandExecutor}
 *                 or class that extends it. Default commands or another vendor-specific
 *                 commands may be specified there.
 * @param capabilities take a look
 *                     at {@link org.openqa.selenium.Capabilities}
 * @param converterClazz is an instance of a class that extends
 * {@link org.openqa.selenium.remote.internal.JsonToWebElementConverter}. It converts
 *                       JSON response to an instance of
 *                       {@link org.openqa.selenium.WebElement}
 */
protected AppiumDriver(HttpCommandExecutor executor, Capabilities capabilities,
    Class<? extends JsonToWebElementConverter> converterClazz) {
    super(executor, capabilities);
    this.executeMethod = new AppiumExecutionMethod(this);
    locationContext = new RemoteLocationContext(executeMethod);
    super.setErrorHandler(errorHandler);
    this.remoteAddress = executor.getAddressOfRemoteServer();
    try {
        Constructor<? extends JsonToWebElementConverter> constructor =
                converterClazz.getConstructor(RemoteWebDriver.class);
        this.setElementConverter(constructor.newInstance(this));
    } catch (NoSuchMethodException | IllegalAccessException | InstantiationException
            | InvocationTargetException e) {
        throw new RuntimeException(e);
    }
}
 
开发者ID:JoeUtt,项目名称:menggeqa,代码行数:28,代码来源:AppiumDriver.java

示例2: MyChromeDriver

import org.openqa.selenium.remote.html5.RemoteLocationContext; //导入依赖的package包/类
public MyChromeDriver(ChromeDriverService service, Capabilities capabilities) {
	super(new MyChromeDriverCommandExecutor(service), capabilities);
	this.locationContext = new RemoteLocationContext(this.getExecuteMethod());
	this.webStorage = new RemoteWebStorage(this.getExecuteMethod());
	this.touchScreen = new RemoteTouchScreen(this.getExecuteMethod());
	this.networkConnection = new RemoteNetworkConnection(this.getExecuteMethod());
}
 
开发者ID:fjalvingh,项目名称:domui,代码行数:8,代码来源:MyChromeDriver.java

示例3: getLocationContext

import org.openqa.selenium.remote.html5.RemoteLocationContext; //导入依赖的package包/类
static LocationContext getLocationContext(WebDriver driver) {
  return convert(driver, LocationContext.class, CapabilityType.SUPPORTS_LOCATION_CONTEXT,
      RemoteLocationContext.class);
}
 
开发者ID:alexkogon,项目名称:grid-refactor-remote-server,代码行数:5,代码来源:Utils.java


注:本文中的org.openqa.selenium.remote.html5.RemoteLocationContext类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。