Possible compatibility problems with earlier versions marked with '*'.
+* Added whereInList member to SRW Scan Term.
+
Added support for SRW scan in yaz-client.
* Changed Z_SRW_scanRequest to be able to carry both CCL and PQF.
/*
- * Copyright (c) 1995-2004, Index Data
+ * Copyright (c) 1995-2005, Index Data
* See the file LICENSE for details.
*
- * $Id: client.c,v 1.265 2005-01-08 01:20:18 adam Exp $
+ * $Id: client.c,v 1.266 2005-01-09 21:52:48 adam Exp $
*/
#include <stdio.h>
static void handle_srw_scan_term(Z_SRW_scanTerm *term)
{
if (term->displayTerm)
- printf ("%s: ", term->displayTerm);
- if (term->value)
- printf ("%s: ", term->value);
+ printf("%s:", term->displayTerm);
+ else if (term->value)
+ printf("%s:", term->value);
+ else
+ printf("No value:");
if (term->numberOfRecords)
- printf ("%d", *term->numberOfRecords);
+ printf(" %d", *term->numberOfRecords);
+ if (term->whereInList)
+ printf(" %s", term->whereInList);
+ if (term->value && term->displayTerm)
+ printf(" %s", term->value);
printf("\n");
}
/*
- * Copyright (c) 2002-2004, Index Data.
+ * Copyright (c) 2002-2005, Index Data.
* See the file LICENSE for details.
*
- * $Id: srw.h,v 1.18 2005-01-08 01:20:18 adam Exp $
+ * $Id: srw.h,v 1.19 2005-01-09 21:52:48 adam Exp $
*/
/**
* \file srw.h
char *value;
int *numberOfRecords;
char *displayTerm;
+ char *whereInList;
} Z_SRW_scanTerm;
typedef struct {
/*
- * Copyright (c) 2002-2004, Index Data.
+ * Copyright (c) 2002-2005, Index Data.
* See the file LICENSE for details.
*
- * $Id: srw.c,v 1.29 2005-01-08 01:20:19 adam Exp $
+ * $Id: srw.c,v 1.30 2005-01-09 21:52:49 adam Exp $
*/
/**
* \file srw.c
term->value = 0;
term->numberOfRecords = 0;
term->displayTerm = 0;
+ term->whereInList = 0;
for (ptr = pptr->children; ptr; ptr = ptr->next)
{
if (match_xsd_string(ptr, "value", o, &term->value))
else if (match_xsd_string(ptr, "displayTerm", o,
&term->displayTerm))
;
+ else if (match_xsd_string(ptr, "whereInList", o,
+ &term->whereInList))
+ ;
}
}
else if (o->direction == ODR_ENCODE)
add_xsd_string(ptr, "value", term->value);
add_xsd_integer(ptr, "value", term->numberOfRecords);
add_xsd_string(ptr, "displayTerm", term->displayTerm);
+ add_xsd_string(ptr, "whereInList", term->whereInList);
}
return 0;
}