class HttpServer extends Object
Based on Spark HttpServer, wraps a Jetty server.
| Modifier and Type | Field and Description |
|---|---|
private static String |
localIpAddress |
private int |
port |
private File |
resourceBase |
private org.eclipse.jetty.server.Server |
server |
| Constructor and Description |
|---|
HttpServer(File resourceBase) |
| Modifier and Type | Method and Description |
|---|---|
private static String |
findLocalIpAddress() |
private static <E> Iterable<E> |
iterable(Enumeration<E> enumeration) |
(package private) static String |
localIpAddress()
Get the local host's IP address in dotted-quad format (e.g.
|
private static void |
logWarning(String s) |
(package private) void |
start() |
(package private) void |
stop() |
(package private) String |
uri()
Returns the URI of this HTTP server ("http://host:port").
|
private static String localIpAddress
private final File resourceBase
private org.eclipse.jetty.server.Server server
private int port
HttpServer(File resourceBase)
void start()
void stop()
String uri()
static String localIpAddress()
private static String findLocalIpAddress() throws IOException
IOExceptionprivate static <E> Iterable<E> iterable(Enumeration<E> enumeration)
private static void logWarning(String s)
Copyright © 2012–2017 The Apache Software Foundation. All rights reserved.