Win32 fixes
[yazpp-moved-to-github.git] / include / yaz++ / proxy.h
index dcc71f8..54f93d3 100644 (file)
@@ -2,7 +2,7 @@
  * Copyright (c) 1998-2003, Index Data.
  * See the file LICENSE for details.
  * 
- * $Id: proxy.h,v 1.4 2003-07-18 13:27:20 adam Exp $
+ * $Id: proxy.h,v 1.7 2003-09-04 20:11:03 adam Exp $
  */
 
 #include <yaz++/z-assoc.h>
 
 class Yaz_Proxy;
 
-class Yaz_RecordCache_Entry;
+struct Yaz_RecordCache_Entry;
 
 class YAZ_EXPORT Yaz_RecordCache {
  public:
     Yaz_RecordCache ();
     ~Yaz_RecordCache ();
-    void add (ODR o, Z_NamePlusRecordList *npr, int start);
+    void add (ODR o, Z_NamePlusRecordList *npr, int start, int hits);
+    
     int lookup (ODR o, Z_NamePlusRecordList **npr, int start, int num,
-               Odr_oid *syntax);
+               Odr_oid *syntax, Z_RecordComposition *comp);
     void clear();
+
+    void copy_searchRequest(Z_SearchRequest *sr);
+    void copy_presentRequest(Z_PresentRequest *pr);
  private:
     NMEM m_mem;
     Yaz_RecordCache_Entry *m_entries;
+    Z_SearchRequest *m_searchRequest;
+    Z_PresentRequest *m_presentRequest;
+    int match (Yaz_RecordCache_Entry *entry,
+              Odr_oid *syntax, int offset,
+              Z_RecordComposition *comp);
 };
 
 /// Private class
@@ -39,7 +48,7 @@ class YAZ_EXPORT Yaz_ProxyClient : public Yaz_Z_Assoc {
     void failNotify();
     void timeoutNotify();
     void connectNotify();
-    char m_cookie[32];
+    char *m_cookie;
     Yaz_ProxyClient *m_next;
     Yaz_ProxyClient **m_prev;
     int m_init_flag;