com.alibaba.fastjson.serializer
Class FieldSerializer

java.lang.Object
  extended by com.alibaba.fastjson.serializer.FieldSerializer
All Implemented Interfaces:
Comparable<FieldSerializer>
Direct Known Subclasses:
ObjectFieldSerializer

public abstract class FieldSerializer
extends Object
implements Comparable<FieldSerializer>

Author:
wenshao

Constructor Summary
FieldSerializer(FieldInfo fieldInfo)
           
 
Method Summary
 int compareTo(FieldSerializer o)
           
 Field getField()
           
 Method getMethod()
           
 String getName()
           
 Object getPropertyValue(Object object)
           
 boolean isWriteNull()
           
 void writePrefix(JSONSerializer serializer)
           
abstract  void writeProperty(JSONSerializer serializer, Object propertyValue)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FieldSerializer

public FieldSerializer(FieldInfo fieldInfo)
Method Detail

isWriteNull

public boolean isWriteNull()

getField

public Field getField()

getName

public String getName()

getMethod

public Method getMethod()

writePrefix

public void writePrefix(JSONSerializer serializer)
                 throws IOException
Throws:
IOException

compareTo

public int compareTo(FieldSerializer o)
Specified by:
compareTo in interface Comparable<FieldSerializer>

getPropertyValue

public Object getPropertyValue(Object object)
                        throws Exception
Throws:
Exception

writeProperty

public abstract void writeProperty(JSONSerializer serializer,
                                   Object propertyValue)
                            throws Exception
Throws:
Exception


Copyright © 2012 Alibaba Group. All Rights Reserved.