RemoteWebDriver ClassWebDriver
Provides a way to use the driver through
Inheritance Hierarchy

SystemObject
  OpenQA.Selenium.RemoteRemoteWebDriver
    More...

Namespace: OpenQA.Selenium.Remote
Assembly: WebDriver (in WebDriver.dll) Version: 3.1.0
Syntax

public class RemoteWebDriver : IWebDriver, 
	IDisposable, ISearchContext, IJavaScriptExecutor, IFindsById, IFindsByClassName, 
	IFindsByLinkText, IFindsByName, IFindsByTagName, IFindsByXPath, IFindsByPartialLinkText, 
	IFindsByCssSelector, ITakesScreenshot, IHasInputDevices, IHasCapabilities, IHasWebStorage, 
	IHasLocationContext, IHasApplicationCache, IAllowsFileDetection, IHasSessionId

The RemoteWebDriver type exposes the following members.

Constructors

  NameDescription
Public methodRemoteWebDriver(ICapabilities)
Initializes a new instance of the RemoteWebDriver class. This constructor defaults proxy to http://127.0.0.1:4444/wd/hub
Public methodRemoteWebDriver(Uri, ICapabilities)
Initializes a new instance of the RemoteWebDriver class
Public methodRemoteWebDriver(ICommandExecutor, ICapabilities)
Initializes a new instance of the RemoteWebDriver class
Public methodRemoteWebDriver(Uri, ICapabilities, TimeSpan)
Initializes a new instance of the RemoteWebDriver class using the specified remote address, desired capabilities, and command timeout.
Top
Properties

  NameDescription
Public propertyApplicationCache
Gets an IApplicationCache object for managing application cache.
Public propertyCapabilities
Gets the capabilities that the RemoteWebDriver instance is currently using
Protected propertyCommandExecutor
Gets the ICommandExecutor which executes commands for this driver.
Public propertyCurrentWindowHandle
Gets the current window handle, which is an opaque handle to this window that uniquely identifies it within this driver instance.
Public propertyFileDetector
Gets or sets the IFileDetector responsible for detecting sequences of keystrokes representing file paths and names.
Public propertyHasApplicationCache
Gets a value indicating whether manipulating the application cache is supported for this driver.
Public propertyHasLocationContext
Gets a value indicating whether manipulating geolocation is supported for this driver.
Public propertyHasWebStorage
Gets a value indicating whether web storage is supported for this driver.
Public propertyKeyboard
Gets an IKeyboard object for sending keystrokes to the browser.
Public propertyLocationContext
Gets an ILocationContext object for managing browser location.
Public propertyMouse
Gets an IMouse object for sending mouse commands to the browser.
Public propertyPageSource
Gets the source of the page last loaded by the browser.
Public propertySessionId
Gets the SessionId for the current session of this driver.
Public propertyTitle
Gets the title of the current browser window.
Public propertyUrl
Gets or sets the URL the browser is currently displaying.
Public propertyWebStorage
Gets an IWebStorage object for managing web storage.
Public propertyWindowHandles
Gets the window handles of open browser windows.
Top
Methods

  NameDescription
Public methodClose
Closes the Browser
Protected methodCreateElement
Creates a RemoteWebElement with the specified ID.
Public methodDispose
Dispose the RemoteWebDriver Instance
Protected methodDispose(Boolean)
Stops the client from running
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Protected methodExecute
Executes a command with this driver .
Public methodExecuteAsyncScript
Executes JavaScript asynchronously in the context of the currently selected frame or window.
Public methodExecuteScript
Executes JavaScript in the context of the currently selected frame or window
Protected methodExecuteScriptCommand
Executes JavaScript in the context of the currently selected frame or window using a specific command.
Protected methodFinalize
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.)
Public methodCode exampleFindElement(By)
Finds the first element in the page that matches the By object
Protected methodFindElement(String, String)
Finds an element matching the given mechanism and value.
Public methodCode exampleFindElementByClassName
Finds the first element in the page that matches the CSS Class supplied
Public methodFindElementByCssSelector
Finds the first element matching the specified CSS selector.
Public methodCode exampleFindElementById
Finds the first element in the page that matches the ID supplied
Public methodCode exampleFindElementByLinkText
Finds the first of elements that match the link text supplied
Public methodCode exampleFindElementByName
Finds the first of elements that match the name supplied
Public methodCode exampleFindElementByPartialLinkText
Finds the first of elements that match the part of the link text supplied
Public methodCode exampleFindElementByTagName
Finds the first of elements that match the DOM Tag supplied
Public methodCode exampleFindElementByXPath
Finds the first of elements that match the XPath supplied
Public methodCode exampleFindElements(By)
Finds the elements on the page by using the By object and returns a ReadOnlyCollection of the Elements on the page
Protected methodFindElements(String, String)
Finds all elements matching the given mechanism and value.
Public methodCode exampleFindElementsByClassName
Finds a list of elements that match the class name supplied
Public methodFindElementsByCssSelector
Finds all elements matching the specified CSS selector.
Public methodCode exampleFindElementsById
Finds the first element in the page that matches the ID supplied
Public methodCode exampleFindElementsByLinkText
Finds a list of elements that match the link text supplied
Public methodCode exampleFindElementsByName
Finds a list of elements that match the name supplied
Public methodCode exampleFindElementsByPartialLinkText
Finds a list of elements that match the class name supplied
Public methodCode exampleFindElementsByTagName
Finds a list of elements that match the DOM Tag supplied
Public methodCode exampleFindElementsByXPath
Finds a list of elements that match the XPath supplied
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetScreenshot
Gets a Screenshot object representing the image of the page on the screen.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodCode exampleManage
Method For getting an object to set the Speed
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodCode exampleNavigate
Method to allow you to Navigate with WebDriver
Public methodQuit
Close the Browser and Dispose of WebDriver
Protected methodStartClient
Starts the command executor, enabling communication with the browser.
Protected methodStartSession
Starts a session with the driver
Protected methodStopClient
Stops the command executor, ending further communication with the browser.
Public methodCode exampleSwitchTo
Method to give you access to switch frames and windows
Public methodToString
Returns a String that represents the current Object.
(Inherited from Object.)
Top
Fields

  NameDescription
Protected fieldStatic memberDefaultCommandTimeout
The default command timeout for HTTP requests in a RemoteWebDriver instance.
Top
Extension Methods

  NameDescription
Public Extension MethodExecuteJavaScript(String, Object)Overloaded.
Executes JavaScript in the context of the currently selected frame or window
(Defined by WebDriverExtensions.)
Public Extension MethodExecuteJavaScriptT(String, Object)Overloaded.
Executes JavaScript in the context of the currently selected frame or window
(Defined by WebDriverExtensions.)
Public Extension MethodTakeScreenshot
Gets a Screenshot object representing the image of the page on the screen.
(Defined by WebDriverExtensions.)
Top
Examples

[TestFixture]
public class Testing
{
    private IWebDriver driver;
    <para></para>
    [SetUp]
    public void SetUp()
    {
        driver = new RemoteWebDriver(new Uri("http://127.0.0.1:4444/wd/hub"),DesiredCapabilities.InternetExplorer());
    }
    <para></para>
    [Test]
    public void TestGoogle()
    {
        driver.Navigate().GoToUrl("http://www.google.co.uk");
        /*
        *   Rest of the test
        */
    }
    <para></para>
    [TearDown]
    public void TearDown()
    {
        driver.Quit();
    }
}
See Also

Reference

Inheritance Hierarchy

SystemObject
  OpenQA.Selenium.RemoteRemoteWebDriver
    OpenQA.Selenium.ChromeChromeDriver
    OpenQA.Selenium.EdgeEdgeDriver
    OpenQA.Selenium.FirefoxFirefoxDriver
    OpenQA.Selenium.IEInternetExplorerDriver
    OpenQA.Selenium.OperaOperaDriver
    OpenQA.Selenium.PhantomJSPhantomJSDriver
    OpenQA.Selenium.SafariSafariDriver