public class FirefoxDriver extends org.openqa.selenium.remote.RemoteWebDriver implements org.openqa.selenium.html5.WebStorage, HasExtensions
The best way to construct a FirefoxDriver
with various options is to make use of the
FirefoxOptions
, like so:
FirefoxOptions options = new FirefoxOptions() .setProfile(new FirefoxProfile()); WebDriver driver = new FirefoxDriver(options);
Modifier and Type | Class and Description |
---|---|
static class |
FirefoxDriver.SystemProperty |
org.openqa.selenium.remote.RemoteWebDriver.RemoteTargetLocator, org.openqa.selenium.remote.RemoteWebDriver.RemoteWebDriverOptions, org.openqa.selenium.remote.RemoteWebDriver.When
org.openqa.selenium.WebDriver.ImeHandler, org.openqa.selenium.WebDriver.Navigation, org.openqa.selenium.WebDriver.Options, org.openqa.selenium.WebDriver.TargetLocator, org.openqa.selenium.WebDriver.Timeouts, org.openqa.selenium.WebDriver.Window
Modifier and Type | Field and Description |
---|---|
protected FirefoxBinary |
binary |
static java.lang.String |
BINARY |
static java.lang.String |
MARIONETTE |
static java.lang.String |
PROFILE |
Constructor and Description |
---|
FirefoxDriver() |
FirefoxDriver(org.openqa.selenium.Capabilities desiredCapabilities)
Deprecated.
|
FirefoxDriver(FirefoxDriverService service) |
FirefoxDriver(FirefoxDriverService service,
org.openqa.selenium.Capabilities desiredCapabilities)
Deprecated.
|
FirefoxDriver(FirefoxDriverService service,
FirefoxOptions options) |
FirefoxDriver(FirefoxOptions options) |
Modifier and Type | Method and Description |
---|---|
<X> X |
getFullPageScreenshotAs(org.openqa.selenium.OutputType<X> outputType)
Capture the full page screenshot and store it in the specified location.
|
org.openqa.selenium.html5.LocalStorage |
getLocalStorage() |
org.openqa.selenium.html5.SessionStorage |
getSessionStorage() |
java.lang.String |
installExtension(java.nio.file.Path path)
Installs an extension.
|
void |
setFileDetector(org.openqa.selenium.remote.FileDetector detector) |
void |
uninstallExtension(java.lang.String extensionId)
Uninstall the extension by the given identifier.
|
builder, close, execute, execute, executeAsyncScript, executeScript, findElement, findElement, findElementByClassName, findElementByCssSelector, findElementById, findElementByLinkText, findElementByName, findElementByPartialLinkText, findElementByTagName, findElementByXPath, findElements, findElements, findElementsByClassName, findElementsByCssSelector, findElementsById, findElementsByLinkText, findElementsByName, findElementsByPartialLinkText, findElementsByTagName, findElementsByXPath, get, getCapabilities, getCommandExecutor, getCurrentUrl, getElementConverter, getErrorHandler, getExecuteMethod, getFileDetector, getKeyboard, getMouse, getPageSource, getScreenshotAs, getSessionId, getTitle, getWindowHandle, getWindowHandles, log, manage, navigate, perform, quit, resetInputState, setCommandExecutor, setElementConverter, setErrorHandler, setFoundBy, setLogLevel, setSessionId, startSession, switchTo, toString
public static final java.lang.String BINARY
public static final java.lang.String PROFILE
public static final java.lang.String MARIONETTE
protected FirefoxBinary binary
public FirefoxDriver()
@Deprecated public FirefoxDriver(org.openqa.selenium.Capabilities desiredCapabilities)
FirefoxDriver(FirefoxOptions)
.@Deprecated public FirefoxDriver(FirefoxDriverService service, org.openqa.selenium.Capabilities desiredCapabilities)
FirefoxDriver(FirefoxDriverService, FirefoxOptions)
.public FirefoxDriver(FirefoxOptions options)
public FirefoxDriver(FirefoxDriverService service)
public FirefoxDriver(FirefoxDriverService service, FirefoxOptions options)
public void setFileDetector(org.openqa.selenium.remote.FileDetector detector)
setFileDetector
in class org.openqa.selenium.remote.RemoteWebDriver
public org.openqa.selenium.html5.LocalStorage getLocalStorage()
getLocalStorage
in interface org.openqa.selenium.html5.WebStorage
public org.openqa.selenium.html5.SessionStorage getSessionStorage()
getSessionStorage
in interface org.openqa.selenium.html5.WebStorage
public java.lang.String installExtension(java.nio.file.Path path)
HasExtensions
installExtension
in interface HasExtensions
path
- absolute path to the extension file that should be installed.public void uninstallExtension(java.lang.String extensionId)
HasExtensions
uninstallExtension
in interface HasExtensions
extensionId
- The unique extension identifier returned by {HasExtensions.installExtension(Path)
}public <X> X getFullPageScreenshotAs(org.openqa.selenium.OutputType<X> outputType) throws org.openqa.selenium.WebDriverException
X
- Return type for getFullPageScreenshotAs.outputType
- target type, @see OutputTypeorg.openqa.selenium.WebDriverException
- on failure.