-/* $Id: snippet.h,v 1.2 2005-06-07 14:53:39 adam Exp $
+/* $Id: snippet.h,v 1.4 2005-08-26 10:13:30 adam Exp $
Copyright (C) 1995-2005
Index Data ApS
02111-1307, USA.
*/
-#ifndef SNIPPET_H
-#define SNIPPET_H
+#ifndef IDZEBRA_SNIPPET_H
+#define IDZEBRA_SNIPPET_H
#include <idzebra/util.h>
struct zebra_snippet_word {
zint seqno;
- int reg_type;
int ord;
char *term;
int match;
typedef struct zebra_snippets zebra_snippets;
typedef struct zebra_snippet_word zebra_snippet_word;
+YAZ_EXPORT
zebra_snippets *zebra_snippets_create();
+
+YAZ_EXPORT
void zebra_snippets_destroy(zebra_snippets *l);
+
+YAZ_EXPORT
void zebra_snippets_append(zebra_snippets *l,
- zint seqno, int reg_type,
- int ord, const char *term);
+ zint seqno, int ord, const char *term);
+
+YAZ_EXPORT
void zebra_snippets_append_match(zebra_snippets *l,
- zint seqno, int reg_type,
- int ord, const char *term,
+ zint seqno, int ord, const char *term,
int match);
+
+YAZ_EXPORT
zebra_snippet_word *zebra_snippets_list(zebra_snippets *l);
+
+YAZ_EXPORT
void zebra_snippets_log(zebra_snippets *l, int log_level);
+
+YAZ_EXPORT
zebra_snippets *zebra_snippets_window(zebra_snippets *doc, zebra_snippets *hit,
int window_size);