-/* $Id: zebraapi.c,v 1.173 2005-06-02 11:59:53 adam Exp $
+/* $Id: zebraapi.c,v 1.175 2005-06-09 10:39:53 adam Exp $
Copyright (C) 1995-2005
Index Data ApS
zh->num_basenames = 0;
zh->basenames = 0;
+ zh->approx_limit = 1000000000;
zh->trans_no = 0;
zh->trans_w_no = 0;
return ZEBRA_OK;
}
+ZEBRA_RES zebra_set_approx_limit(ZebraHandle zh, zint approx_limit)
+{
+ zh->approx_limit = approx_limit;
+ return ZEBRA_OK;
+}
+
ZEBRA_RES zebra_search_RPN(ZebraHandle zh, ODR o, Z_RPNQuery *query,
const char *setname, zint *hits)
{
{
char *buf;
int len;
+ zebra_snippets *hit_snippet = zebra_snippets_create();
- zebra_get_hit_vector(zh, setname, poset[i].sysno);
+ zebra_snippets_hit_vector(zh, setname, poset[i].sysno,
+ hit_snippet);
recs[i].errCode =
zebra_record_fetch(zh, poset[i].sysno, poset[i].score,
+ hit_snippet,
stream, input_format, comp,
&recs[i].format, &buf, &len,
&recs[i].base, &recs[i].errString);
+
recs[i].len = len;
if (len > 0)
{
recs[i].buf = buf;
recs[i].score = poset[i].score;
recs[i].sysno = poset[i].sysno;
+ zebra_snippets_destroy(hit_snippet);
}
else
{