at.tuwien.ifs.somtoolbox.apps.viewer.controls.psomserver.httphandler
Class PocketSOMConfigProvider
java.lang.Object
at.tuwien.ifs.somtoolbox.apps.viewer.controls.psomserver.httphandler.PocketSOMConfigProvider
- All Implemented Interfaces:
- com.sun.net.httpserver.HttpHandler
public class PocketSOMConfigProvider
- extends java.lang.Object
- implements com.sun.net.httpserver.HttpHandler
The ConfigurationProvider provides sends all PocketSOM-Files via http: (psom, jpeg and list)
- Author:
- Jakob Frank
Method Summary |
private void |
addServerHeaders(com.sun.net.httpserver.HttpExchange t)
|
private java.lang.String |
getClient(com.sun.net.httpserver.HttpExchange t)
|
private java.lang.String |
getPreferredCharSet(com.sun.net.httpserver.HttpExchange t,
java.lang.StringBuilder response)
|
void |
handle(com.sun.net.httpserver.HttpExchange t)
|
private void |
printRequest(com.sun.net.httpserver.HttpExchange t)
|
private void |
sendMapping(com.sun.net.httpserver.HttpExchange t)
|
private void |
sendPsomFile(com.sun.net.httpserver.HttpExchange t)
|
private void |
sendVisualisation(com.sun.net.httpserver.HttpExchange t)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PSOM
protected static final java.lang.String PSOM
- See Also:
- Constant Field Values
IMG
protected static final java.lang.String IMG
- See Also:
- Constant Field Values
MAPPING
protected static final java.lang.String MAPPING
- See Also:
- Constant Field Values
NL
private static final java.lang.String NL
- See Also:
- Constant Field Values
DEBUG
private static final boolean DEBUG
- See Also:
- Constant Field Values
LOG_SEP
private static final java.lang.String LOG_SEP
- See Also:
- Constant Field Values
log
private final java.util.logging.Logger log
connectorEndpointPort
private final int connectorEndpointPort
musicContext
private final java.lang.String musicContext
state
private final CommonSOMViewerStateData state
PocketSOMConfigProvider
public PocketSOMConfigProvider(CommonSOMViewerStateData state,
int port,
java.lang.String mapContentContext)
handle
public void handle(com.sun.net.httpserver.HttpExchange t)
throws java.io.IOException
- Specified by:
handle
in interface com.sun.net.httpserver.HttpHandler
- Throws:
java.io.IOException
sendMapping
private void sendMapping(com.sun.net.httpserver.HttpExchange t)
throws java.io.IOException
- Throws:
java.io.IOException
sendVisualisation
private void sendVisualisation(com.sun.net.httpserver.HttpExchange t)
throws java.io.IOException
- Throws:
java.io.IOException
getClient
private java.lang.String getClient(com.sun.net.httpserver.HttpExchange t)
sendPsomFile
private void sendPsomFile(com.sun.net.httpserver.HttpExchange t)
throws java.io.IOException
- Throws:
java.io.IOException
getPreferredCharSet
private java.lang.String getPreferredCharSet(com.sun.net.httpserver.HttpExchange t,
java.lang.StringBuilder response)
addServerHeaders
private void addServerHeaders(com.sun.net.httpserver.HttpExchange t)
printRequest
private void printRequest(com.sun.net.httpserver.HttpExchange t)
throws java.io.IOException
- Throws:
java.io.IOException