public class KsonSerializer extends Object
Date: 20.12.13 Time: 12:03
Created by ruedi on 07.08.2014.
| Modifier and Type | Field and Description |
|---|---|
protected FSTConfiguration |
conf |
protected KsonTypeMapper |
mapper |
protected KsonCharOutput |
out |
protected boolean |
pretty |
protected boolean |
writeNull |
| Constructor and Description |
|---|
KsonSerializer(KsonCharOutput out,
KsonTypeMapper mapper,
FSTConfiguration conf) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
isWriteNull() |
protected void |
removeLastListSep() |
void |
setWriteNull(boolean writeNull) |
protected boolean |
shouldQuote(String string) |
protected void |
writeClazzTag(Class expectedClass,
Object o)
determines classname tagging.
|
protected void |
writeIndent(int indent) |
protected void |
writeKey(String name)
called when writing a key of an key:value inside an object or map
|
protected void |
writeListEnd() |
protected void |
writeListSep() |
protected void |
writeListStart() |
protected void |
writeln() |
void |
writeObject(Object o) |
void |
writeObject(Object o,
Class aClass) |
protected void |
writeObjectInternal(Class expectedClass,
Class expectedValueClass,
Object o,
int indent) |
void |
writeString(String string) |
protected KsonCharOutput out
protected KsonTypeMapper mapper
protected boolean pretty
protected boolean writeNull
protected FSTConfiguration conf
public KsonSerializer(KsonCharOutput out, KsonTypeMapper mapper, FSTConfiguration conf)
protected void writeObjectInternal(Class expectedClass, Class expectedValueClass, Object o, int indent) throws Exception
Exceptionprotected void writeKey(String name)
name - protected void writeClazzTag(Class expectedClass, Object o)
expectedClass - o - protected void writeListEnd()
protected void writeListStart()
protected void removeLastListSep()
protected void writeListSep()
protected void writeln()
public void writeString(String string)
protected boolean shouldQuote(String string)
protected void writeIndent(int indent)
public boolean isWriteNull()
public void setWriteNull(boolean writeNull)
Copyright © 2015. All rights reserved.