public Object readReply(Class expectedClass) throws Exception {
  if (startReply()) {
    Object value=readObject(expectedClass);
    completeReply();
    return value;
  }
 else {
    Hashtable fault=readFault();
    Object detail=fault.get("detail");
    if (detail instanceof Exception)     throw (Exception)detail;
 else {
      String code=(String)fault.get("code");
      String message=(String)fault.get("message");
      throw new BurlapServiceException(message,code,detail);
    }
  }
}

public Object readReply ( Class expectedClass ) throws Exception { if ( startReply ( ) ) { Object value = readObject ( expectedClass ) ; completeReply ( ) ; return value ; } else { Hashtable fault = readFault ( ) ; Object detail = fault . get ( "detail" ) ; if ( detail instanceof Exception ) throw ( Exception ) detail ; else { String code = ( String ) fault . get ( "code" ) ; String message = ( String ) fault . get ( "message" ) ; throw new BurlapServiceException ( message , code , detail ) ; } } }
reads a reply as an object . if the reply has a fault , throws the exception .
