Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## chrriis.common
Class WebServer

    java.lang.Object
      chrriis.common.WebServer

    public class WebServer

extends Object

Author:
  Christopher Deckers

Nested Class Summary
`static class` | `WebServer.HTTPData`
`static class` | `WebServer.HTTPRequest`
`static class` | `WebServer.WebServerContent`

Constructor Summary
`WebServer()`
`WebServer(int port)`

Method Summary
`void` | `addReferenceClassLoader(ClassLoader referenceClassLoader)`
`String` | `getClassPathResourceURL(String className, String resourcePath)`
`static WebServer` | `getDefaultWebServer()`
`String` | `getDynamicContentURL(String className, String parameter)`
`String` | `getDynamicContentURL(String className, String codebase, String parameter)`
`int` | `getPort()`
`String` | `getResourcePathURL(String codeBase, String resourcePath)`
`WebServer.WebServerContent` | `getURLContent(String resourceURL)`
`String` | `getURLPrefix()`
`protected static WebServer.WebServerContent` | `getWebServerContent(WebServer.HTTPRequest httpRequest)`
`boolean` | `isRunning()`
`void` | `removeReferenceClassLoader(ClassLoader referenceClassLoader)`
`void` | `start()`
`void` | `start(boolean isDaemon)`
`void` | `stop()`
`static void` | `stopDefaultWebServer()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### WebServer

    public WebServer()

### WebServer

    public WebServer(int port)

Method Detail

### stop

    public void stop()

### isRunning

    public boolean isRunning()

### start

    public void start()
               throws IOException

  Throws:
    `IOException`

### start

    public void start(boolean isDaemon)
               throws IOException

  Throws:
    `IOException`

### getPort

    public int getPort()

### getURLPrefix

    public String getURLPrefix()

### getDynamicContentURL

    public String getDynamicContentURL(String className,
                                       String parameter)

  Returns:
    A URL that when accessed will invoke the method `static WebServerContent getWebServerContent(HTTPRequest)` of the parameter class (the method visibility does not matter).

### getDynamicContentURL

    public String getDynamicContentURL(String className,
                                       String codebase,
                                       String parameter)

  Returns:
    A URL that when accessed will invoke the method `static WebServerContent getWebServerContent(HTTPRequest)` of the parameter class (the method visibility does not matter).

### getClassPathResourceURL

    public String getClassPathResourceURL(String className,
                                          String resourcePath)

### getResourcePathURL

    public String getResourcePathURL(String codeBase,
                                     String resourcePath)

### getURLContent

    public WebServer.WebServerContent getURLContent(String resourceURL)

### addReferenceClassLoader

    public void addReferenceClassLoader(ClassLoader referenceClassLoader)

### removeReferenceClassLoader

    public void removeReferenceClassLoader(ClassLoader referenceClassLoader)

### getWebServerContent

    protected static WebServer.WebServerContent getWebServerContent(WebServer.HTTPRequest httpRequest)

### stopDefaultWebServer

    public static void stopDefaultWebServer()

### getDefaultWebServer

    public static WebServer getDefaultWebServer()

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD