com.alibaba.fastjson.util
Class FieldInfo

java.lang.Object
  extended by com.alibaba.fastjson.util.FieldInfo
All Implemented Interfaces:
Comparable<FieldInfo>

public class FieldInfo
extends Object
implements Comparable<FieldInfo>


Constructor Summary
FieldInfo(String name, Class<?> declaringClass, Class<?> fieldClass, Type fieldType, Method method, Field field)
           
FieldInfo(String name, Method method, Field field)
           
 
Method Summary
 int compareTo(FieldInfo o)
           
 Object get(Object javaObject)
           
<T extends Annotation>
T
getAnnotation(Class<T> annotationClass)
           
 Class<?> getDeclaringClass()
           
 Field getField()
           
 Class<?> getFieldClass()
           
 Type getFieldType()
           
 Method getMethod()
           
 String getName()
           
 void set(Object javaObject, Object value)
           
 void setAccessible(boolean flag)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FieldInfo

public FieldInfo(String name,
                 Class<?> declaringClass,
                 Class<?> fieldClass,
                 Type fieldType,
                 Method method,
                 Field field)

FieldInfo

public FieldInfo(String name,
                 Method method,
                 Field field)
Method Detail

toString

public String toString()
Overrides:
toString in class Object

getDeclaringClass

public Class<?> getDeclaringClass()

getFieldClass

public Class<?> getFieldClass()

getFieldType

public Type getFieldType()

getName

public String getName()

getMethod

public Method getMethod()

getField

public Field getField()

compareTo

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

getAnnotation

public <T extends Annotation> T getAnnotation(Class<T> annotationClass)

get

public Object get(Object javaObject)
           throws IllegalAccessException,
                  InvocationTargetException
Throws:
IllegalAccessException
InvocationTargetException

set

public void set(Object javaObject,
                Object value)
         throws IllegalAccessException,
                InvocationTargetException
Throws:
IllegalAccessException
InvocationTargetException

setAccessible

public void setAccessible(boolean flag)
                   throws SecurityException
Throws:
SecurityException


Copyright © 2012 Alibaba Group. All Rights Reserved.