public class ERXJSONRestWriter extends ERXRestWriter
Name | Description |
---|---|
| Boolean property to enable pretty-printing of JSON response. Defaults to false. |
| Integer property to set the pretty print indentation space count. Defaults to 2 . |
contentEncoding, ContentTypeHeaderKey, TheDefaultResponseEncoding
Constructor and Description |
---|
ERXJSONRestWriter() |
Modifier and Type | Method and Description |
---|---|
void |
appendToResponse(ERXRestRequestNode node,
IERXRestResponse response,
ERXRestFormat.Delegate delegate,
ERXRestContext context)
Called at the end of a request to produce the output to the user.
|
protected net.sf.json.JsonConfig |
configWithContext(ERXRestContext context) |
String |
contentType()
The corresponding HTTP header content type for this REST response.
|
protected ERXRestRequestNode |
processNode(ERXRestRequestNode node) |
appendHeadersToResponse, contentEncoding, contentTypeHeaderValue, defaultEncoding, setContentEncoding, setDefaultEncoding
protected net.sf.json.JsonConfig configWithContext(ERXRestContext context)
protected ERXRestRequestNode processNode(ERXRestRequestNode node)
public void appendToResponse(ERXRestRequestNode node, IERXRestResponse response, ERXRestFormat.Delegate delegate, ERXRestContext context)
IERXRestWriter
node
- the node to renderresponse
- the response to write intodelegate
- the REST delegatecontext
- the REST contextpublic String contentType()
ERXRestWriter
contentType
in class ERXRestWriter
Copyright © 2002 – 2024 Project Wonder.