X-Git-Url: http://git.indexdata.com/?p=yazpp-moved-to-github.git;a=blobdiff_plain;f=zoom%2Fzclient.cpp;fp=zoom%2Fzclient.cpp;h=7938b0d419446f97ffd22bc878564a016b0ede4d;hp=ca159a886aeb0fb2a8dae1e7ce130f823824a87e;hb=01126607d1b475f43b29548dbd98f199f8e9f57f;hpb=1c579e7c96bf635658b0b1729cbf8c0a3b223b1a diff --git a/zoom/zclient.cpp b/zoom/zclient.cpp index ca159a8..7938b0d 100644 --- a/zoom/zclient.cpp +++ b/zoom/zclient.cpp @@ -1,16 +1,16 @@ -// $Id: zclient.cpp,v 1.6 2002-12-02 15:57:58 mike Exp $ +// $Id: zclient.cpp,v 1.7 2003-07-02 10:25:13 adam Exp $ // Simple sample client #include // for atoi() -#include +#include #include "zoom.h" int main(int argc, char **argv) { if (argc != 5) { - cerr << "Usage: " << + std::cerr << "Usage: " << argv[0] << " <@prefix-search>\n"; return 1; } @@ -25,21 +25,21 @@ int main(int argc, char **argv) resultSet rs(conn, pq); size_t n = rs.size(); - cout << "found " << n << " records:\n"; + std::cout << "found " << n << " records:\n"; for (size_t i = 0; i < n; i++) { const record rec(rs, i); - cout << "=== record " << i+1 << - " (record-syntax " << (string) rec.recsyn() << ")" << + std::cout << "=== record " << i+1 << + " (record-syntax " << (std::string) rec.recsyn() << ")" << " ===\n" << rec.render(); } } catch(bib1Exception& err) { - cerr << argv[0] << ": bib1Exception " << + std::cerr << argv[0] << ": bib1Exception " << err.errmsg() << " (" << err.addinfo() << ")\n"; return 2; } catch(ZOOM::exception& err) { - cerr << argv[0] << ": exception " << + std::cerr << argv[0] << ": exception " << err.errmsg() << "\n"; return 3; }