#include <DistSearchMethod.hpp>
Public Member Functions | |
DistSearchMethod () | |
DistSearchMethod (const lemur::api::Index *index, lemur::api::RetMethodManager::RetModel defmodel=lemur::api::RetMethodManager::INQUERY) | |
~DistSearchMethod () | |
void | setReturnCount (int retCount) |
set the return documents number; | |
void | setIndex (const lemur::api::Index *index) |
use the given collection selection index | |
void | setDefaultRetMethod (lemur::api::RetMethodManager::RetModel rt) |
use the given retrieval method to do search if none is specified for an index | |
void | scoreIndexSet (const lemur::api::Query &qry, const lemur::api::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 lemur::api::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 Member Functions | |
void | indexToID (const lemur::api::Index *ind, const lemur::api::IndexedRealVector *ivec, DocScoreVector *dvec) |
convert the given IndexRealVector into a DocScoreVector. | |
Protected Member Functions | |
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 lemur::api::Index * | csindex |
lemur::api::RetMethodManager::RetModel | defrt |
const lemur::api::Query * | query |
DocScoreVector ** | allres |
int | reslen |
int | returnCount |
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
|
|
|
|
|
|
|
assuming all required parameters for index and retrieval method are on the top stack, do retrieval on this single index using the given query.
|
|
convert the given IndexRealVector into a DocScoreVector.
|
|
score every document in each index in the indexset for the given query and return results in the results vector
|
|
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. |
|
use the given retrieval method to do search if none is specified for an index
|
|
use the given collection selection index
|
|
set the return documents number;
|
|
|
|
|
|
|
|
|
|
|
|
|