private TypeInfo GetTypeInfo(Class<?> type) throws ClassNotFoundException, DisallowedSerializeException {
if (TypeInfoMap.containsKey(type)) {
return TypeInfoMap.get(type);
}
GaeaSerializable cAnn = type.getAnnotation(GaeaSerializable.class);
if (cAnn == null) {
throw new DisallowedSerializeException();
}
int typeId = TypeHelper.GetTypeId(type);
TypeInfo typeInfo = new TypeInfo(typeId);
ArrayList<Field> fields = new ArrayList<Field>();
Class temType = type;
while (true) {
Field[] fs = temType.getDeclaredFields();
for (Field f : fs) {
fields.add(f);
}
Class superClass = temType.getSuperclass();
if (superClass == null) {
break;
}
temType = superClass;
}
Map<Integer, Field> mapFildes = new HashMap<Integer, Field>();
List<Integer> indexIds = new ArrayList<Integer>();
if (cAnn.defaultAll()) {
for (Field f : fields) {
GaeaNotMember ann = f.getAnnotation(GaeaNotMember.class);
if (ann != null) {
continue;
}