|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object flexjson.JSONContext
public class JSONContext
Constructor Summary | |
---|---|
JSONContext()
|
Method Summary | |
---|---|
static void |
cleanup()
static moethod to clean up thread when serialization is complete |
static JSONContext |
get()
static method to getTransformer the context for this thread |
LinkedList<Object> |
getObjectStack()
|
OutputHandler |
getOut()
getTransformer output handler |
Path |
getPath()
|
String |
getRootName()
|
Transformer |
getTransformer(Object object)
Retrieves a transformer for the provided object |
ChainedSet |
getVisits()
|
boolean |
isIncluded(BeanProperty prop)
|
boolean |
isIncluded(String key,
Object value)
|
protected PathExpression |
matches(List<PathExpression> expressions)
|
TypeContext |
peekTypeContext()
|
void |
popTypeContext()
|
void |
pushTypeContext(TypeContext contextEnum)
|
void |
serializationType(SerializationType serializationType)
|
void |
setOut(OutputHandler out)
Set the output handler. |
void |
setPathExpressions(List<PathExpression> pathExpressions)
|
void |
setPathTransformers(Map<Path,Transformer> pathTransformerMap)
used to pass in configured transformers from the JsonSerializer |
void |
setPrettyPrint(boolean prettyPrint)
configures the context to output JSON with new lines and indentations |
void |
setRootName(String rootName)
|
void |
setTypeTransformers(TypeTransformerMap typeTransformerMap)
used to pass in configured transformers from the JsonSerializer |
void |
setVisits(ChainedSet visits)
|
void |
transform(Object object)
Run a transformer on the provided object |
void |
write(String value)
write a simple non-quoted value to output |
void |
writeCloseArray()
|
void |
writeCloseObject()
|
void |
writeComma()
|
void |
writeIndent()
|
void |
writeName(String name)
|
TypeContext |
writeOpenArray()
|
TypeContext |
writeOpenObject()
|
void |
writeQuoted(String value)
write a quoted and escaped value to the output |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JSONContext()
Method Detail |
---|
public void serializationType(SerializationType serializationType)
public void transform(Object object)
object
- public Transformer getTransformer(Object object)
object
-
public void setTypeTransformers(TypeTransformerMap typeTransformerMap)
typeTransformerMap
- public void setPathTransformers(Map<Path,Transformer> pathTransformerMap)
pathTransformerMap
- public void setPrettyPrint(boolean prettyPrint)
prettyPrint
- public void pushTypeContext(TypeContext contextEnum)
public void popTypeContext()
public TypeContext peekTypeContext()
public void setOut(OutputHandler out)
out
- public OutputHandler getOut()
public void write(String value)
value
- public TypeContext writeOpenObject()
public void writeCloseObject()
public void writeName(String name)
public void writeComma()
public TypeContext writeOpenArray()
public void writeCloseArray()
public void writeIndent()
public void writeQuoted(String value)
value
- public static JSONContext get()
public static void cleanup()
public ChainedSet getVisits()
public void setVisits(ChainedSet visits)
public LinkedList<Object> getObjectStack()
public String getRootName()
public void setRootName(String rootName)
public Path getPath()
public void setPathExpressions(List<PathExpression> pathExpressions)
public boolean isIncluded(BeanProperty prop)
public boolean isIncluded(String key, Object value)
protected PathExpression matches(List<PathExpression> expressions)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |