X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=include%2Fyaz%2Fsrw.h;h=a6d60ada36562794068ad5432dfc95800774eb1c;hb=4c176312acdc3444c9afc820f76a393e64668e52;hp=1b61e2aeb7e3505f6c24c1081a31692b2ba16443;hpb=c82bbc07fb53f78aab88bb4121629daeef42ed2a;p=yaz-moved-to-github.git diff --git a/include/yaz/srw.h b/include/yaz/srw.h index 1b61e2a..a6d60ad 100644 --- a/include/yaz/srw.h +++ b/include/yaz/srw.h @@ -1,8 +1,12 @@ /* - * Copyright (c) 2002-2003, Index Data. + * Copyright (C) 1995-2005, Index Data ApS * See the file LICENSE for details. * - * $Id: srw.h,v 1.11 2004-01-05 09:34:42 adam Exp $ + * $Id: srw.h,v 1.20 2005-01-15 19:47:10 adam Exp $ + */ +/** + * \file srw.h + * \brief Header for SRW/SRU */ #ifndef YAZ_SRW_H @@ -24,8 +28,9 @@ typedef struct { } Z_SRW_record; typedef struct { - int *code; + char *uri; char *details; + char *message; } Z_SRW_diagnostic; typedef struct { @@ -75,6 +80,7 @@ typedef struct { typedef struct { char *recordPacking; char *database; + char *stylesheet; } Z_SRW_explainRequest; typedef struct { @@ -84,7 +90,12 @@ typedef struct { } Z_SRW_explainResponse; typedef struct { - char *scanClause; + int query_type; + union { + char *cql; + char *xcql; + char *pqf; + } scanClause; int *responsePosition; int *maximumTerms; char *stylesheet; @@ -95,6 +106,7 @@ typedef struct { char *value; int *numberOfRecords; char *displayTerm; + char *whereInList; } Z_SRW_scanTerm; typedef struct { @@ -141,7 +153,16 @@ YAZ_EXPORT void yaz_uri_val_int(const char *path, const char *name, YAZ_EXPORT int yaz_srw_decode(Z_HTTP_Request *hreq, Z_SRW_PDU **srw_pdu, Z_SOAP **soap_package, ODR decode, char **charset); YAZ_EXPORT int yaz_sru_decode(Z_HTTP_Request *hreq, Z_SRW_PDU **srw_pdu, - Z_SOAP **soap_package, ODR decode, char **charset); + Z_SOAP **soap_package, ODR decode, + char **charset, + Z_SRW_diagnostic **, int *num_diagnostic); + +YAZ_EXPORT void yaz_add_srw_diagnostic(ODR o, Z_SRW_diagnostic **d, + int *num, int code, + const char *addinfo); + +YAZ_EXPORT void yaz_mk_std_diagnostic(ODR o, Z_SRW_diagnostic *d, + int code, const char *details); YAZ_END_CDECL #endif