-/* $Id: gduutil.cpp,v 1.22 2007-05-22 13:03:32 adam Exp $
- Copyright (c) 2005-2007, Index Data.
-
-This file is part of Metaproxy.
+/* This file is part of Metaproxy.
+ Copyright (C) 2005-2010 Index Data
Metaproxy is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
for more details.
You should have received a copy of the GNU General Public License
-along with Metaproxy; see the file LICENSE. If not, write to the
-Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA.
- */
+along with this program; if not, write to the Free Software
+Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+*/
#include "gduutil.hpp"
-#include "util.hpp"
+#include <metaproxy/util.hpp>
#include <yaz/wrbuf.h>
#include <yaz/oid_db.h>
os << "-";
}
-static void dump_opt_int(std::ostream& os, const int *i)
+static void dump_opt_int(std::ostream& os, const Odr_int *i)
{
os << " ";
if (i)
{
Z_PresentResponse *pr
= zapdu.u.presentResponse;
- if ((pr->presentStatus) && !*(pr->presentStatus))
+ if (pr->presentStatus &&
+ *pr->presentStatus != Z_PresentStatus_failure)
{
- os << "OK";
+ switch (*pr->presentStatus)
+ {
+ case Z_PresentStatus_success:
+ os << "OK"; break;
+ case Z_PresentStatus_partial_1:
+ os << "Partial-1"; break;
+ case Z_PresentStatus_partial_2:
+ os << "Partial-2"; break;
+ case Z_PresentStatus_partial_3:
+ os << "Partial-3"; break;
+ case Z_PresentStatus_partial_4:
+ os << "Partial-4"; break;
+ default:
+ os << "Unknown"; break;
+ }
//<< pr->referenceId << " "
if (pr->numberOfRecordsReturned)
os << " " << *(pr->numberOfRecordsReturned);
/*
* Local variables:
* c-basic-offset: 4
+ * c-file-style: "Stroustrup"
* indent-tabs-mode: nil
- * c-file-style: "stroustrup"
* End:
* vim: shiftwidth=4 tabstop=8 expandtab
*/
+