SRJRCFrames
v0.1.296

de.schwarzrot.net.http.server
Interface HTTPServer<C extends ServiceConfig>


public interface HTTPServer<C extends ServiceConfig>

describes the public interface for the HTTP protocol server. The HTTP server is used as a backend for i.e. JSON requests, to enable a remote user interface especially for windows systems..

Author:
Reinhard Mantey

Method Summary
 String generateReply(HttpStatusCode status, String message)
          assembles a very basic reply.
 C getConfig()
          accessor to service configuration
 File getDocumentRoot()
          the document root is used as a base for file access.
 String serverID()
          assembles a response string to identify the server.
 

Method Detail

generateReply

String generateReply(HttpStatusCode status,
                     String message)
assembles a very basic reply. This is used mainly for error messages and/or help messages.

Parameters:
status - - the http status code
message - - the body content
Returns:
- the assembled HTTP message ready to be sent to the client

getConfig

C getConfig()
accessor to service configuration

Returns:
configuration instance

getDocumentRoot

File getDocumentRoot()
the document root is used as a base for file access. Each path will be validated before accessing the file to avoid misusage.

Returns:
- the defined document root

serverID

String serverID()
assembles a response string to identify the server.

Returns:
- the servers id

SRJRCFrames
v0.1.296

hosted at
Find SRJRCFrames at SourceForge.net. Fast, secure and free:
           Open Source Software download
Submit a bug or request a feature

SRJRCFrames is published according to the GNU General Public License
Copyright 2005-2012 Reinhard Mantey - some rights reserved.