public class NanoHTTPD.Response
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
java.io.InputStream |
data
Data of the response, may be null.
|
java.util.Properties |
header
Headers for the HTTP response.
|
java.lang.String |
mimeType
MIME type of content, e.g.
|
java.lang.String |
status
HTTP status code after processing, e.g.
|
Constructor and Description |
---|
NanoHTTPD.Response()
Default constructor: response = HTTP_OK, data = mime = 'null'
|
NanoHTTPD.Response(java.lang.String status,
java.lang.String mimeType,
java.io.InputStream data)
Basic constructor.
|
NanoHTTPD.Response(java.lang.String status,
java.lang.String mimeType,
java.lang.String txt)
Convenience method that makes an InputStream out of
given text.
|
Modifier and Type | Method and Description |
---|---|
void |
addHeader(java.lang.String name,
java.lang.String value)
Adds given line to the header.
|
public java.lang.String status
public java.lang.String mimeType
public java.io.InputStream data
public java.util.Properties header
public NanoHTTPD.Response()
public NanoHTTPD.Response(java.lang.String status, java.lang.String mimeType, java.io.InputStream data)
public NanoHTTPD.Response(java.lang.String status, java.lang.String mimeType, java.lang.String txt)