public class BrowserListener extends Object implements CodeServerListener
Constructor and Description |
---|
BrowserListener(TreeLogger treeLogger,
DevMode.HostedModeOptions options,
BrowserChannelServer.SessionHandlerServer handler)
Listens for new connections from browsers.
|
Modifier and Type | Method and Description |
---|---|
static String |
getDevModeURLParams(String address,
int port)
Get a query parameter to be added to the URL that specifies the address of this listener.
|
int |
getSocketPort() |
URL |
makeStartupUrl(String url)
Returns the URL to use in the browser for using this codeserver.
|
void |
setIgnoreRemoteDeath(boolean ignoreRemoteDeath)
Set any created BrowserChannelServers to ignore remote deaths.
|
void |
start()
Starts the code server.
|
void |
waitUntilReady(TreeLogger logger)
Blocks until the code server ready to handle requests.
|
void |
writeCompilerOutput(StandardLinkerContext linkerStack,
ArtifactSet artifacts,
ModuleDef module,
boolean isRelink)
Writes compiler output to the right places so that the browser will see
the newly compiled GWT code.
|
public BrowserListener(TreeLogger treeLogger, DevMode.HostedModeOptions options, BrowserChannelServer.SessionHandlerServer handler)
public static String getDevModeURLParams(String address, int port)
address
- address of host to use for connectionsport
- TCP port number to use for connectionpublic int getSocketPort()
getSocketPort
in interface CodeServerListener
public URL makeStartupUrl(String url) throws UnableToCompleteException
CodeServerListener
makeStartupUrl
in interface CodeServerListener
UnableToCompleteException
public void writeCompilerOutput(StandardLinkerContext linkerStack, ArtifactSet artifacts, ModuleDef module, boolean isRelink) throws UnableToCompleteException
CodeServerListener
writeCompilerOutput
in interface CodeServerListener
UnableToCompleteException
public void setIgnoreRemoteDeath(boolean ignoreRemoteDeath)
This is most commonly wanted by JUnitShell.
setIgnoreRemoteDeath
in interface CodeServerListener
ignoreRemoteDeath
- public void start()
CodeServerListener
start
in interface CodeServerListener
public void waitUntilReady(TreeLogger logger) throws UnableToCompleteException
CodeServerListener
waitUntilReady
in interface CodeServerListener
UnableToCompleteException
- if unable to start.Copyright © 2018. All rights reserved.