@SuppressWarnings({"unchecked","rawtypes"}) protected Object readBean(Deserializer deserializer,Object bean){
  storeReference(bean);
  Class theClass=bean.getClass();
  while (hasMoreProperties()) {
    String name=readPropertyName();
    Type type=getPropertyType(bean,name);
    Object property=deserializer.deserialize(this,type);
    if (property != null) {
      try {
        if (type instanceof Class) {
          Class t=(Class)type;
          if (!t.isAssignableFrom(property.getClass())) {
            property=ConversionUtils.convert(property,t);
          }
        }
        final Field field=theClass.getField(name);
        field.set(bean,property);
      }
 catch (      Exception ex2) {
        try {
        }
 catch (        Exception ex) {
          log.error("Error mapping property: {} ({})",name,property);
        }
      }
    }
 else {
    }
    if (hasMoreProperties()) {
      skipPropertySeparator();
    }
  }
  skipEndObject();
  return bean;
}

@ SuppressWarnings ( { "unchecked" , "rawtypes" } ) protected Object readBean ( Deserializer deserializer , Object bean ) { storeReference ( bean ) ; Class theClass = bean . getClass ( ) ; while ( hasMoreProperties ( ) ) { String name = readPropertyName ( ) ; Type type = getPropertyType ( bean , name ) ; Object property = deserializer . deserialize ( this , type ) ; if ( property != null ) { try { if ( type instanceof Class ) { Class t = ( Class ) type ; if ( ! t . isAssignableFrom ( property . getClass ( ) ) ) { property = ConversionUtils . convert ( property , t ) ; } } final Field field = theClass . getField ( name ) ; field . set ( bean , property ) ; } catch ( Exception ex2 ) { try { } catch ( Exception ex ) { log . error ( "Error mapping property: {} ({})" , name , property ) ; } } } else { } if ( hasMoreProperties ( ) ) { skipPropertySeparator ( ) ; } } skipEndObject ( ) ; return bean ; }
reads the input as a bean and returns an object
