简体   繁体   English

Selenium WebDriver-什么是“ Selenium客户端和WebDriver语言绑定”

[英]Selenium WebDriver - What is “Selenium Client & WebDriver Language Bindings”

In the selenium download page, I see a section "Selenium Client & WebDriver Language Bindings" 在selenium下载页面中,我看到了“ Selenium Client和WebDriver语言绑定”部分。

1) What is a Language Binding? 1)什么是语言绑定? and

2) What is a Client Driver? 2)什么是客户端驱动程序? (I am not from from a technical background) (我不是来自技术背景)

Can someone please explain the following taken from selenium download page :( http://docs.seleniumhq.org/download/ ) 有人可以解释一下从硒下载页面获取的以下内容:( http://docs.seleniumhq.org/download/

* *

In order to create scripts that interact with the Selenium Server (Selenium RC, Selenium Remote Webdriver) or create local Selenium WebDriver script you need to make use of language-specific client drivers. 为了创建与Selenium服务器交互的脚本(Selenium RC,Selenium远程Webdriver)或创建本地Selenium WebDriver脚本,您需要使用特定于语言的客户端驱动程序。 These languages include both 1.x and 2.x style clients. 这些语言包括1.x和2.x样式的客户端。 While language bindings for other languages exist, these are the core ones that are supported by the main project hosted on google code. 虽然存在其他语言的语言绑定,但这些是Google代码上托管的主项目支持的核心绑定。

    * *

Some of that documentation is old. 该文档有些过时了。 It comes from the old Selenium 1.x versions. 它来自旧的Selenium 1.x版本。 Selenium WebDriver is much different now, with 2.x versions (the latest being 2.31). Selenium WebDriver现在与2.x版本(最新版本为2.31)大不相同。 Selenium 2.x versions have bindings hidden from your view. Selenium 2.x版本在您的视图中隐藏了绑定。 You define capabilities and start a new RemoteWebDriver and the Hub+Node handles the binding under the covers. 定义功能并启动新的RemoteWebDriver,然后Hub + Node会在幕后处理绑定。

Now, to interact similar to RC you need: 现在,要类似于RC进行交互,您需要:

  1.  To start a Grid Hub on port 4444
  2.  Start 1 Node Hub on port 5555 on either your local machine or a remote machine.  It has configuration that tells it how to connect to the Hub.
  3.  In your script, start a new client using:

 URL hubURL = new URL("127.0.0.1:4444"); // always use IP address
 DesiredCapabilities capability = DesiredCapabilities.internetExplorer();
 RemoteWebDriver driver = new RemoteWebDriver(new URL(hubURL), capability);

I have an example project you can try here . 我有一个示例项目,您可以在这里尝试

2) What is a Client Driver? 2)什么是客户端驱动程序?

Selenium uses many client drivers java,python.... so to work with each programming language there is a different driver.This is nothing but a JAR in my understanding. Selenium使用许多客户端驱动程序java,python ....,因此要使用每种编程语言,都有一个不同的驱动程序。在我的理解中,这不过是一个JAR。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使用Java绑定并行化Selenium Webdriver实例? - How to parallelize instances of selenium webdriver with java bindings? 使用 Selenium WebDriver Java 绑定清除浏览器 Cookie - Clear browser Cookies with Selenium WebDriver Java bindings Selenium WebDriver - 在 linux 上更改浏览器的语言 - Selenium WebDriver - changing browser's language on linux 如何使用Selenium WebDriver配置网页语言 - How to configure webpage language using selenium webdriver 如何在selenium webdriver中关闭语言选项框架 - How to close language option frame in selenium webdriver 如何在客户端计算机上运行Selenium Webdriver? - How to run selenium webdriver on client machine? Webdriver异常-Selenium Webdriver Java - Webdriver Exception - Selenium Webdriver Java “Selenium-server-standalone.jar”和“Selenium Client & WebDriver”之间有什么区别? - What are the differences between 'Selenium-server-standalone.jar' and 'Selenium Client & WebDriver'? Java-Selenium Webdriver-Ruby绑定-缺少的特性和功能 - Java - Selenium Webdriver - Ruby bindings - Missing features and functions 使用Webdriver 2和Selenium Java Client Client驱动程序进行Selenium Eclipse配置 - Selenium eclipse Configuration with Webdriver 2 and Selenium Java Client Driver
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM