X-Git-Url: http://git.indexdata.com/?p=yaz-moved-to-github.git;a=blobdiff_plain;f=include%2Fyaz%2Fsrw.h;h=b8bfae2474680df6df1331ea89a554d9881450f4;hp=981097a76cf6b58807f820c8d0df5b10de2a6c20;hb=45bf7a223153a11dcc07b1f1cb988f02af3a23f1;hpb=96e65728eefb6d7efef6e2f74a3b0d64f92b3c23 diff --git a/include/yaz/srw.h b/include/yaz/srw.h index 981097a..b8bfae2 100644 --- a/include/yaz/srw.h +++ b/include/yaz/srw.h @@ -1,5 +1,5 @@ /* This file is part of the YAZ toolkit. - * Copyright (C) 1995-2010 Index Data. + * Copyright (C) 1995-2011 Index Data. * All rights reserved. * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: @@ -37,6 +37,7 @@ #include #include #include +#include "facet.h" YAZ_BEGIN_CDECL @@ -92,6 +93,7 @@ typedef struct { char *database; char *stylesheet; Odr_int *resultSetTTL; + Z_FacetList *facetList; } Z_SRW_searchRetrieveRequest; typedef struct { @@ -107,6 +109,7 @@ typedef struct { Odr_int *nextRecordPosition; Z_SRW_extra_record **extra_records; /* of size num_records */ + Z_FacetList *facetList; } Z_SRW_searchRetrieveResponse; typedef struct { @@ -309,8 +312,17 @@ YAZ_EXPORT int yaz_sru_post_encode(Z_HTTP_Request *hreq, Z_SRW_PDU *srw_pdu, ODR encode, const char *charset); YAZ_EXPORT int yaz_sru_soap_encode(Z_HTTP_Request *hreq, Z_SRW_PDU *srw_pdu, ODR odr, const char *charset); -YAZ_EXPORT int yaz_solr_encode(Z_HTTP_Request *hreq, Z_SRW_PDU *srw_pdu, - ODR encode, const char *charset); + +/** \brief encode SOLR request (HTTP) + \param hreq HTTP request to be modified (with encoded request) + \param srw_pdu SRW request + \param encode ODR for result + \param charset character set for request (may be NULL) + \retval -1 fail + \retval 0 OK +*/ +YAZ_EXPORT int yaz_solr_encode_request(Z_HTTP_Request *hreq, Z_SRW_PDU *srw_pdu, + ODR encode, const char *charset); YAZ_EXPORT char *yaz_negotiate_sru_version(char *input_ver);