public class SeleniumDriverResourceHandler extends ResourceHandler
SeleniumServer
SeleniumServer
,
Serialized FormConstructor and Description |
---|
SeleniumDriverResourceHandler(SeleniumServer remoteControl,
DriverSessions webdriverSessions) |
Modifier and Type | Method and Description |
---|---|
protected String |
commandResultsLogMessage(String cmd,
String sessionId,
String results) |
protected File |
createTempFile(String name) |
void |
deregisterBrowserSession(BrowserSessionFactory.BrowserSessionInfo sessionInfo)
De-registers the given browser session from among the active sessions.
|
String |
doCommand(String cmd,
Vector<String> values,
String sessionId,
HttpResponse res) |
protected void |
download(URL url,
File outputFile) |
BrowserLauncherFactory |
getBrowserLauncherFactory() |
protected String |
getNewBrowserSession(String browserString,
String startURL,
String extensionJs,
Capabilities browserConfigurations) |
protected FrameGroupCommandQueueSet |
getQueueSet(String sessionId) |
protected static String |
getSpeedForSession(String sessionId) |
void |
handle(String pathInContext,
String pathParams,
HttpRequest req,
HttpResponse res)
Handle a request.
|
void |
registerBrowserSession(BrowserSessionFactory.BrowserSessionInfo sessionInfo)
Registers the given browser session among the active sessions to handle.
|
void |
setBrowserLauncherFactory(BrowserLauncherFactory browserLauncherFactory)
Deprecated.
|
protected static void |
setSpeedForSession(String sessionId,
int speed) |
void |
stopAllBrowsers()
Kills all running browsers
|
getAllowedMethods, getAllowedString, getMinGzipLength, getRedirectWelcome, getResource, handleGet, isAcceptRanges, isDirAllowed, isMethodAllowed, sendData, setAcceptRanges, setAllowedMethods, setDirAllowed, setMinGzipLength, setRedirectWelcome, start, stop, writeHeaders
getHttpContext, getName, handleTrace, initialize, isStarted, setName, toString
public SeleniumDriverResourceHandler(SeleniumServer remoteControl, DriverSessions webdriverSessions)
public void handle(String pathInContext, String pathParams, HttpRequest req, HttpResponse res) throws HttpException, IOException
HttpHandler
handle
in interface HttpHandler
handle
in class ResourceHandler
pathInContext
- The context pathpathParams
- Path parameters such as encoded Session IDreq
- The HttpRequest requestres
- The HttpResponse responseHttpException
IOException
protected FrameGroupCommandQueueSet getQueueSet(String sessionId)
public String doCommand(String cmd, Vector<String> values, String sessionId, HttpResponse res)
protected String commandResultsLogMessage(String cmd, String sessionId, String results)
protected static void setSpeedForSession(String sessionId, int speed)
protected String getNewBrowserSession(String browserString, String startURL, String extensionJs, Capabilities browserConfigurations) throws RemoteCommandException
RemoteCommandException
public void registerBrowserSession(BrowserSessionFactory.BrowserSessionInfo sessionInfo)
sessionInfo
- the externally created browser session to register.public void deregisterBrowserSession(BrowserSessionFactory.BrowserSessionInfo sessionInfo)
sessionInfo
- the session to deregister.public void stopAllBrowsers()
public BrowserLauncherFactory getBrowserLauncherFactory()
@Deprecated public void setBrowserLauncherFactory(BrowserLauncherFactory browserLauncherFactory)
browserLauncherFactory
- To use when creating new browser sessions.Copyright © 2013. All Rights Reserved.