|
Public Member Functions |
| void | addIndex (class IndexEnvironment &environment) |
| void | addIndex (const std::string &pathname) |
| | Add a local repository.
|
| void | addServer (const std::string &hostname) |
| | Add a remote server.
|
| void | close () |
| | Close the QueryEnvironment.
|
| INT64 | documentCount (const std::string &term) |
| | Return total number of documents containing term in the collection.
|
| INT64 | documentCount () |
| | Return total number of documents in the collection.
|
| std::vector< lemur::api::DOCID_T > | documentIDsFromMetadata (const std::string &attributeName, const std::vector< std::string > &attributeValue) |
| | Return a list of document IDs where the document has a metadata key that matches attributeName, with a value matching one of the attributeValues.
|
| int | documentLength (lemur::api::DOCID_T documentID) |
| | Return the length of a document.
|
| std::vector< std::string > | documentMetadata (const std::vector< indri::api::ScoredExtentResult > &documentIDs, const std::string &attributeName) |
| | Fetch the named metadata attribute for a list of ScoredExtentResults.
|
| std::vector< std::string > | documentMetadata (const std::vector< lemur::api::DOCID_T > &documentIDs, const std::string &attributeName) |
| | Fetch the named metadata attribute for a list of document ids.
|
| std::vector< indri::api::ParsedDocument * > | documents (const std::vector< indri::api::ScoredExtentResult > &results) |
| | Fetch the parsed documents for a given list of ScoredExtentResults Caller is responsible for deleting the returned elements.
|
| std::vector< indri::api::ParsedDocument * > | documents (const std::vector< lemur::api::DOCID_T > &documentIDs) |
| | Fetch the parsed documents for a given list of document ids. Caller is responsible for deleting the returned elements.
|
| std::vector< indri::api::ParsedDocument * > | documentsFromMetadata (const std::string &attributeName, const std::vector< std::string > &attributeValues) |
| | Fetch all documents with a metadata key that matches attributeName, with a value matching one of the attributeValues.
|
| std::vector< DocumentVector * > | documentVectors (const std::vector< lemur::api::DOCID_T > &documentIDs) |
| | Fetch a document vector for a list of documents. Caller responsible for deleting the Vector.
|
| double | expressionCount (const std::string &expression, const std::string &queryType="indri") |
| | Return the total number of times this expression appears in the collection.
|
| std::vector< ScoredExtentResult > | expressionList (const std::string &expression, const std::string &queryType="indri") |
| | Return all the occurrences of this expression in the collection. Note that the returned vector may be quite large for large collections, and therefore has the very real possibility of exhausting the memory of the machine. Use this method with discretion.
|
| std::vector< std::string > | fieldList () |
| | Return the list of fields.
|
| std::vector< std::string > | pathNames (const std::vector< indri::api::ScoredExtentResult > &results) |
| | Fetch the XPath names of extents for a list of ScoredExtentResults.
|
| | QueryEnvironment () |
| void | removeIndex (const std::string &pathname) |
| | Remove a local repository.
|
| void | removeServer (const std::string &hostname) |
| | Remove a remote server.
|
| QueryAnnotation * | runAnnotatedQuery (const std::string &query, const std::vector< lemur::api::DOCID_T > &documentSet, int resultsRequested, const std::string &queryType="indri") |
| | Run an Indri query language query.
|
| QueryAnnotation * | runAnnotatedQuery (const std::string &query, int resultsRequested, const std::string &queryType="indri") |
| | Run an Indri query language query.
|
| std::vector< indri::api::ScoredExtentResult > | runQuery (const std::string &query, const std::vector< lemur::api::DOCID_T > &documentSet, int resultsRequested, const std::string &queryType="indri") |
| | Run an Indri query language query.
|
| std::vector< indri::api::ScoredExtentResult > | runQuery (const std::string &query, int resultsRequested, const std::string &queryType="indri") |
| | Run an Indri query language query.
|
| QueryResults | runQuery (QueryRequest &request) |
| | Run an Indri query language query.
|
| void | setMaxWildcardTerms (int maxTerms) |
| | set maximum number of wildcard terms to expand to.
|
| void | setMemory (UINT64 memory) |
| | Set the amount of memory to use.
|
| void | setScoringRules (const std::vector< std::string > &rules) |
| | Set the scoring rules.
|
| void | setSingleBackgroundModel (bool background) |
| | Set whether there should be one single background model or context sensitive models.
|
| void | setStopwords (const std::vector< std::string > &stopwords) |
| | Set the stopword list for query processing.
|
| INT64 | stemCount (const std::string &term) |
| | Return total number of stem occurrences.
|
| INT64 | stemFieldCount (const std::string &term, const std::string &field) |
| | Return total number of stem occurrences within a field.
|
| INT64 | termCount (const std::string &term) |
| | Return total number of term occurrences.
|
| INT64 | termCount () |
| | Return total number of terms.
|
| INT64 | termFieldCount (const std::string &term, const std::string &field) |
| | Return total number of term occurrences within a field.
|
| | ~QueryEnvironment () |
Private Member Functions |
| void | _annotateQuery (indri::infnet::InferenceNetwork::MAllResults &results, const std::vector< lemur::api::DOCID_T > &documentIDs, std::string &annotatorName, indri::lang::Node *queryRoot) |
| void | _copyStatistics (std::vector< indri::lang::RawScorerNode * > &scorerNodes, indri::infnet::InferenceNetwork::MAllResults &statisticsResults) |
| void | _mergeQueryResults (indri::infnet::InferenceNetwork::MAllResults &results, std::vector< indri::server::QueryServerResponse * > &responses) |
| void | _mergeServerQuery (indri::infnet::InferenceNetwork::MAllResults &results, std::vector< indri::lang::Node * > &roots, int resultsRequested) |
| std::vector< indri::api::ScoredExtentResult > | _runQuery (indri::infnet::InferenceNetwork::MAllResults &results, const std::string &q, int resultsRequested, const std::vector< lemur::api::DOCID_T > *documentIDs, QueryAnnotation **annotation, const std::string &queryType="indri") |
| std::vector< indri::server::QueryServerResponse * > | _runServerQuery (std::vector< indri::lang::Node * > &roots, int resultsRequested) |
| void | _scoredQuery (indri::infnet::InferenceNetwork::MAllResults &results, indri::lang::Node *queryRoot, std::string &accumulatorName, int resultsRequested, const std::vector< lemur::api::DOCID_T > *documentSet) |
| void | _sumServerQuery (indri::infnet::InferenceNetwork::MAllResults &results, std::vector< indri::lang::Node * > &roots, int resultsRequested) |
| | QueryEnvironment (QueryEnvironment &other) |
Private Attributes |
| std::vector< indri::net::NetworkMessageStream * > | _messageStreams |
| Parameters | _parameters |
| std::vector< indri::collection::Repository * > | _repositories |
std::map< std::string, std::pair<
indri::server::QueryServer *,
indri::collection::Repository * > > | _repositoryNameMap |
std::map< std::string, std::pair<
indri::server::QueryServer *,
indri::net::NetworkStream * > > | _serverNameMap |
| std::vector< indri::server::QueryServer * > | _servers |
| std::vector< indri::net::NetworkStream * > | _streams |