1 /* $Id: test_relevance.c,v 1.1 2007-04-16 13:58:20 marc Exp $
2 Copyright (c) 2006-2007, Index Data.
4 This file is part of Pazpar2.
6 Pazpar2 is free software; you can redistribute it and/or modify it under
7 the terms of the GNU General Public License as published by the Free
8 Software Foundation; either version 2, or (at your option) any later
11 Pazpar2 is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
16 You should have received a copy of the GNU General Public License
17 along with Pazpar2; see the file LICENSE. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
27 #include <sys/socket.h>
39 #include <yaz/timing.h>
45 //#include "pazpar2.h"
46 #include "relevance.h"
55 void test_relevance(int argc, char **argv)
57 NMEM nmem = nmem_create();
58 struct conf_service service;
61 struct record_cluster *cluster = 0;
62 struct relevance *rel = 0;
65 //const char * terms[] =
66 // {"ål", "abe", "økologi", "fisk", "æble", "yoghurt"};
67 const char * terms[] =
70 struct record_metadata *metadata = 0;
73 relevance_create(nmem, terms, numrecs);
75 relevance_prepare_read(rel, &list);
77 cluster = reclist_insert(&service, &list, &record, mergekey, &total);
79 //relevance_newrec(rel, cluster);
81 //relevance_donerecord(se->relevance, cluster);
82 // relevance_countwords(se->relevance, cluster,
83 // (char *) value, md->rank);
96 int main(int argc, char **argv)
98 YAZ_CHECK_INIT(argc, argv);
102 test_relevance(argc, argv);
114 * indent-tabs-mode: nil
116 * vim: shiftwidth=4 tabstop=8 expandtab