source: main/tags/2.80/indexers/mg/src/text/query_term_list.h@ 24541

Last change on this file since 24541 was 3745, checked in by mdewsnip, 21 years ago

Addition of MG package for search and retrieval

  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 2.1 KB
Line 
1/**************************************************************************
2 *
3 * term_lists.h -- description
4 * Copyright (C) 1994 Authors
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19 *
20 * $Id: query_term_list.h 3745 2003-02-20 21:20:24Z mdewsnip $
21 *
22 **************************************************************************/
23
24/*
25 $Log$
26 Revision 1.1 2003/02/20 21:18:24 mdewsnip
27 Addition of MG package for search and retrieval
28
29 Revision 1.1 1999/08/10 21:18:21 sjboddie
30 renamed mg-1.3d directory mg
31
32 Revision 1.1 1998/11/17 09:35:37 rjmcnab
33 *** empty log message ***
34
35 * Revision 1.1 1994/10/20 03:57:08 tes
36 * I have rewritten the boolean query optimiser and abstracted out the
37 * components of the boolean query.
38 *
39 */
40
41#ifndef QUERY_TERM_LIST_H
42#define QUERY_TERM_LIST_H
43
44#include "sysfuncs.h"
45
46typedef struct QueryTermEntry
47 {
48 int Count; /* The number of times the word occurs in the query */
49 u_char *Term; /* The query term */
50 int stem_method; /* The steming method to apply to the term : -1 is default */
51 }
52QueryTermEntry;
53
54typedef struct QueryTermList
55 {
56 int list_size;
57 int num;
58 QueryTermEntry QTE[1];
59 }
60QueryTermList;
61
62/* --- prototypes --- */
63void ConvertQueryTermsToString (QueryTermList * query_term_list, char *str);
64int AddQueryTerm (QueryTermList ** query_term_list, u_char * Term, int Count, int stem_method);
65void ResetQueryTermList (QueryTermList ** tl);
66void FreeQueryTermList (QueryTermList ** the_qtl);
67QueryTermList *MakeQueryTermList (int n);
68
69
70#endif
Note: See TracBrowser for help on using the repository browser.