- java.lang.Object
-
- org.redkale.convert.ObjectEncoder<W,T>
-
- 类型参数:
W
- Writer输出的子类T
- 序列化的数据类型
- 所有已实现的接口:
Encodeable<W,T>
- 直接已知子类:
JsonDynEncoder
,ProtobufObjectEncoder
public class ObjectEncoder<W extends Writer,T> extends Object implements Encodeable<W,T>
自定义对象的序列化操作类详情见: https://redkale.org
- 作者:
- zhangjx
-
-
构造器概要
构造器 限定符 构造器 说明 protected
ObjectEncoder(Type type)
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 protected void
afterInitEnMember(ConvertFactory factory)
protected void
checkInited()
void
convertTo(W out, T value)
序列化操作EnMember[]
getMembers()
Type
getType()
泛型映射接口Class
getTypeClass()
void
init(ConvertFactory factory)
protected void
initFieldMember(EnMember[] enMembers)
protected void
initForEachEnMember(ConvertFactory factory, EnMember member)
protected void
setIndex(EnMember member, int index)
protected void
setPosition(EnMember member, int position)
protected void
setTag(EnMember member, int tag)
protected void
setTagSize(EnMember member, int tagSize)
String
toString()
-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
从接口继承的方法 org.redkale.convert.Encodeable
specifyable
-
-
-
-
字段详细资料
-
type
protected final Type type
-
typeClass
protected final Class typeClass
-
members
protected EnMember[] members
-
factory
@Nullable protected ConvertFactory factory
-
inited
protected volatile boolean inited
-
-
构造器详细资料
-
ObjectEncoder
protected ObjectEncoder(Type type)
-
-
方法详细资料
-
init
public void init(ConvertFactory factory)
-
initFieldMember
protected void initFieldMember(EnMember[] enMembers)
-
checkInited
protected void checkInited()
-
convertTo
public void convertTo(W out, T value)
从接口复制的说明:Encodeable
序列化操作- 指定者:
convertTo
在接口中Encodeable<W extends Writer,T>
- 参数:
out
- Writervalue
- 对象
-
initForEachEnMember
protected void initForEachEnMember(ConvertFactory factory, EnMember member)
-
afterInitEnMember
protected void afterInitEnMember(ConvertFactory factory)
-
setTag
protected void setTag(EnMember member, int tag)
-
setTagSize
protected void setTagSize(EnMember member, int tagSize)
-
setIndex
protected void setIndex(EnMember member, int index)
-
setPosition
protected void setPosition(EnMember member, int position)
-
getType
public Type getType()
从接口复制的说明:Encodeable
泛型映射接口- 指定者:
getType
在接口中Encodeable<W extends Writer,T>
- 返回:
- 返回序列化对象类的数据类型
-
getTypeClass
public Class getTypeClass()
-
getMembers
public EnMember[] getMembers()
-
-