}
istream& operator>>(istream& is, Response& resp)
- /*throw (HTTPResponse::Error, ios::failure, sockerr)*/ {
+ throw (HTTPResponse::Error, ios::failure, sockerr,
+ xmlpp::parse_error) {
#ifdef DEBUG
cerr << __FILE__ << "(" << __LINE__ << ")" << ": operator>>()" << endl;
#endif // DEBUG
is >> static_cast<HTTPResponse&>(resp);
if (resp.get_body().length()) {
- // TODO parseo XML del body para buscar las cosas basicas de la respuesta.
- Response::Parser parser(resp);
- try {
- parser.parse_memory(resp.get_body());
- } catch (const xmlpp::parse_error& e) {
- // TODO - ver gravedad.
-#ifdef DEBUG
- cerr << __FILE__ << "(" << __LINE__ << ")"
- << " : operator>>() error de parseo: " << e.what() << endl;
-#endif // DEBUG
- }
+ Response::Parser(resp).parse_memory(resp.get_body());
}
return is;
}