Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

DistSearchMethod Class Reference

#include <DistSearchMethod.hpp>

List of all members.

Public Methods

 DistSearchMethod ()
 DistSearchMethod (const Index *index, RetMethodManager::RetModel defmodel=RetMethodManager::INQUERY)
 ~DistSearchMethod ()
void setReturnCount (int retCount)
 set the return documents number;

void setIndex (const Index *index)
 use the given collection selection index

void setDefaultRetMethod (RetMethodManager::RetModel rt)
 use the given retrieval method to do search if none is specified for an index

void scoreIndexSet (const Query &qry, const IndexedRealVector &indexset, DocScoreVector **results)
 score every document in each index in the indexset for the given query and return results in the results vector

void scoreIndexSet (const Query &qry, const vector< string > &indexset, DocScoreVector **results)
 score every document in each index in the indexset for the given query and return results in the results vector


Static Public Methods

void indexToID (const Index *ind, const IndexedRealVector *ivec, DocScoreVector *dvec)
 convert the given IndexRealVector into a DocScoreVector.


Protected Methods

void doSingleRetr ()
 assuming all required parameters for index and retrieval method are on the top stack, do retrieval on this single index using the given query.


Protected Attributes

const Indexcsindex
RetMethodManager::RetModel defrt
const Queryquery
DocScoreVector ** allres
int reslen
int returnCount


Detailed Description

This class supports searching multiple indexes and getting a list of results for each of those indexes. Each index is expected to have a parameter file that tells where its located and which retrieval method to use, similar to parameter files used for TextRetrievalMethods. If no particular RetrievalMethod is specified, a default one will be used (originally set to Okapi


Constructor & Destructor Documentation

DistSearchMethod::DistSearchMethod   [inline]
 

DistSearchMethod::DistSearchMethod const Index   index,
RetMethodManager::RetModel    defmodel = RetMethodManager::INQUERY
[inline]
 

DistSearchMethod::~DistSearchMethod   [inline]
 


Member Function Documentation

void DistSearchMethod::doSingleRetr   [protected]
 

assuming all required parameters for index and retrieval method are on the top stack, do retrieval on this single index using the given query.

void DistSearchMethod::indexToID const Index   ind,
const IndexedRealVector   ivec,
DocScoreVector   dvec
[static]
 

convert the given IndexRealVector into a DocScoreVector.

void DistSearchMethod::scoreIndexSet const Query   qry,
const vector< string > &    indexset,
DocScoreVector **    results
 

score every document in each index in the indexset for the given query and return results in the results vector

void DistSearchMethod::scoreIndexSet const Query   qry,
const IndexedRealVector   indexset,
DocScoreVector **    results
 

score every document in each index in the indexset for the given query and return results in the results vector

although the scores in indexset probably won't be used, take an IndexedRealVector here because that's what's returned by the RetrievalMethod so would make writing code easier. the indexes in indexset should correspond to indexes in the collection selection index.

void DistSearchMethod::setDefaultRetMethod RetMethodManager::RetModel    rt [inline]
 

use the given retrieval method to do search if none is specified for an index

void DistSearchMethod::setIndex const Index   index [inline]
 

use the given collection selection index

void DistSearchMethod::setReturnCount int    retCount [inline]
 

set the return documents number;


Member Data Documentation

DocScoreVector** DistSearchMethod::allres [protected]
 

const Index* DistSearchMethod::csindex [protected]
 

RetMethodManager::RetModel DistSearchMethod::defrt [protected]
 

const Query* DistSearchMethod::query [protected]
 

int DistSearchMethod::reslen [protected]
 

int DistSearchMethod::returnCount [protected]
 


The documentation for this class was generated from the following files:
Generated on Wed Nov 3 12:59:30 2004 for Lemur Toolkit by doxygen1.2.18