public class JsonRenderImpl extends Object implements JsonRender
Constructor and Description |
---|
JsonRenderImpl() |
JsonRenderImpl(Writer writer,
JsonFormat format) |
Modifier and Type | Method and Description |
---|---|
protected void |
appendNull() |
protected void |
appendPair(boolean needPairEnd,
String name,
Object value) |
protected String |
doDateFormat(Date date,
DateFormat df) |
protected void |
doIntent() |
JsonFormat |
getFormat() |
Writer |
getWriter() |
void |
render(Object obj) |
void |
setFormat(JsonFormat format) |
void |
setWriter(Writer writer) |
protected String |
value2string(JsonEntityField jef,
Object value) |
public JsonRenderImpl()
public JsonRenderImpl(Writer writer, JsonFormat format)
public JsonFormat getFormat()
public void setFormat(JsonFormat format)
setFormat
in interface JsonRender
public Writer getWriter()
public void setWriter(Writer writer)
setWriter
in interface JsonRender
public void render(Object obj) throws IOException
render
in interface JsonRender
IOException
protected void appendPair(boolean needPairEnd, String name, Object value) throws IOException
IOException
protected String value2string(JsonEntityField jef, Object value)
protected void doIntent() throws IOException
IOException
protected void appendNull() throws IOException
IOException
protected String doDateFormat(Date date, DateFormat df)
Copyright © 2017. All rights reserved.