Added support for static ranking. Bug #174. The staticrank is enabled
[idzebra-moved-to-github.git] / index / zinfo.h
index 0332bdb..e2b74b6 100644 (file)
@@ -1,6 +1,6 @@
-/* $Id: zinfo.h,v 1.19 2004-09-28 10:15:03 adam Exp $
-   Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002
-   Index Data Aps
+/* $Id: zinfo.h,v 1.26 2005-08-18 12:50:18 adam Exp $
+   Copyright (C) 1995-2005
+   Index Data ApS
 
 This file is part of the Zebra server.
 
@@ -28,6 +28,13 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
 #include <idzebra/api.h>
 #include "recindex.h"
 
+/* Compare string (ignore case) */
+#ifdef WIN32
+#define STRCASECMP     stricmp
+#else
+#define STRCASECMP     strcasecmp
+#endif
+
 YAZ_BEGIN_CDECL
 
 typedef struct zebraExplainInfo *ZebraExplainInfo;
@@ -43,8 +50,16 @@ void zebraExplain_close (ZebraExplainInfo zei);
 int zebraExplain_curDatabase (ZebraExplainInfo zei, const char *database);
 int zebraExplain_newDatabase (ZebraExplainInfo zei, const char *database,
                              int explain_database);
-int zebraExplain_lookupSU (ZebraExplainInfo zei, int set, int use);
-int zebraExplain_addSU (ZebraExplainInfo zei, int set, int use);
+int zebraExplain_lookup_attr_su(ZebraExplainInfo zei, int index_type,
+                               int set, int use);
+int zebraExplain_lookup_attr_su_any_index(ZebraExplainInfo zei,
+                                         int set, int use);
+int zebraExplain_add_attr_su(ZebraExplainInfo zei, int index_type,
+                            int set, int use);
+int zebraExplain_lookup_attr_str(ZebraExplainInfo zei, int index_type,
+                                const char *str);
+int zebraExplain_add_attr_str(ZebraExplainInfo zei, int index_type,
+                             const char *str);
 void zebraExplain_addSchema (ZebraExplainInfo zei, Odr_oid *oid);
 void zebraExplain_recordCountIncrement (ZebraExplainInfo zei, int adjust_num);
 void zebraExplain_recordBytesIncrement (ZebraExplainInfo zei, int adjust_num);
@@ -63,7 +78,8 @@ int zebraExplain_removeDatabase(ZebraExplainInfo zei, void *updateHandle);
 typedef struct {
     int recordSize;
     off_t recordOffset;
-    int runNumber;
+    zint runNumber;
+    zint staticrank;
 } RecordAttr;
 RecordAttr *rec_init_attr (ZebraExplainInfo zei, Record rec);