org.openqa.selenium.server.browserlaunchers
Class AbstractBrowserLauncher

java.lang.Object
  extended by org.openqa.selenium.server.browserlaunchers.AbstractBrowserLauncher
All Implemented Interfaces:
BrowserLauncher
Direct Known Subclasses:
DestroyableRuntimeExecutingBrowserLauncher, FirefoxChromeLauncher, FirefoxCustomProfileLauncher, GoogleChromeLauncher, InternetExplorerCustomProxyLauncher, KonquerorLauncher, OperaCustomProfileLauncher, SafariCustomProfileLauncher

public abstract class AbstractBrowserLauncher
extends java.lang.Object
implements BrowserLauncher

Runs the specified command path to start the browser, and kills the process to quit.

Version:
$Revision: 189 $
Author:
Paul Hammant

Field Summary
protected  java.lang.String sessionId
           
 
Constructor Summary
AbstractBrowserLauncher(java.lang.String sessionId, RemoteControlConfiguration configuration)
           
 
Method Summary
 RemoteControlConfiguration getConfiguration()
           
 int getPort()
           
protected abstract  void launch(java.lang.String url)
           
protected  void launch(java.lang.String url, BrowserConfigurationOptions browserConfigurationOptions)
          This is a default method and browser launchers should override this launch method to support per-test browserConfigurations If the browser configuration options object has no options, however, this method redirects to the launch(url) method.
 void launchHTMLSuite(java.lang.String suiteUrl, java.lang.String browserURL, boolean multiWindow, java.lang.String defaultLogLevel)
          Start the browser in Selenese mode, auto-running the specified HTML suite
 void launchRemoteSession(java.lang.String browserURL, boolean multiWindow)
          Start the browser and navigate directly to the specified URL
 void launchRemoteSession(java.lang.String browserURL, boolean multiWindow, BrowserConfigurationOptions browserConfigurationOptions)
          Start the browser and navigate directly to the specified URL using the supplied browser configurations
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.openqa.selenium.server.browserlaunchers.BrowserLauncher
close, getProcess
 

Field Detail

sessionId

protected java.lang.String sessionId
Constructor Detail

AbstractBrowserLauncher

public AbstractBrowserLauncher(java.lang.String sessionId,
                               RemoteControlConfiguration configuration)
Method Detail

launchHTMLSuite

public void launchHTMLSuite(java.lang.String suiteUrl,
                            java.lang.String browserURL,
                            boolean multiWindow,
                            java.lang.String defaultLogLevel)
Description copied from interface: BrowserLauncher
Start the browser in Selenese mode, auto-running the specified HTML suite

Specified by:
launchHTMLSuite in interface BrowserLauncher
Parameters:
suiteUrl - the url within which to initiate the session (if needed)
browserURL - the url of the HTML suite to launch
multiWindow - TODO
defaultLogLevel - TODO

launchRemoteSession

public void launchRemoteSession(java.lang.String browserURL,
                                boolean multiWindow,
                                BrowserConfigurationOptions browserConfigurationOptions)
Description copied from interface: BrowserLauncher
Start the browser and navigate directly to the specified URL using the supplied browser configurations

Specified by:
launchRemoteSession in interface BrowserLauncher
multiWindow - a flag to specify multiWindow mode
browserConfigurationOptions - Test level browser configuration object

launchRemoteSession

public void launchRemoteSession(java.lang.String browserURL,
                                boolean multiWindow)
Description copied from interface: BrowserLauncher
Start the browser and navigate directly to the specified URL

Specified by:
launchRemoteSession in interface BrowserLauncher
multiWindow - TODO

launch

protected abstract void launch(java.lang.String url)

launch

protected void launch(java.lang.String url,
                      BrowserConfigurationOptions browserConfigurationOptions)
This is a default method and browser launchers should override this launch method to support per-test browserConfigurations If the browser configuration options object has no options, however, this method redirects to the launch(url) method.

Parameters:
url - The base url for starting selenium
browserConfigurationOptions - The browser configuration object

getConfiguration

public RemoteControlConfiguration getConfiguration()

getPort

public int getPort()


Copyright © 2009. All Rights Reserved.