ddc
Public Member Functions | Public Attributes | List of all members
CQueryResult Struct Reference

CQueryResult: query results, possibly aggregated by "break". More...

#include <QueryResult.h>

Inheritance diagram for CQueryResult:
Inheritance graph
[legend]

Public Member Functions

void ClearQueryResults ()
 clears CQueryResult fields More...
 
template<typename HitIndexLessThanT >
void SortResultsByIndex (HitIndexLessThanT &HitIndexLess)
 
template<typename HitLessThanT >
void SortResultsByHit (HitLessThanT &HitLess)
 
template<typename HitIndexLessThanT >
void SortResultsByIndexP (HitIndexLessThanT HitIndexLess)
 
template<typename HitLessThanT >
void SortResultsByHitP (HitLessThanT HitLess)
 

Public Attributes

vector< CHitm_Hits
 found hits (not more than m_pConcordance->m_MaxCachedHitsCount). More...
 
vector< CTokenNom_HighlightOccurs
 words that should be highlighted in hits; m_HighlightOccurs is the concatenation of CQueryNode::m_Occurrences for all subcorpora More...
 
vector< BYTEm_HighlightIds
 highlighting match-ids for m_HighlightOccurs More...
 
size_t m_AllHitsCount
 the number of all found hits (if m_AllHitsCount < m_pConcordance->m_MaxCachedHitsCount, then m_Hits.size() == m_AllHitsCount) More...
 
size_t m_RelevantDocumentCount
 the number of documents, where at least one hit is found More...
 
bool m_bSortByString: 1
 whether to sort by string-value More...
 
bool m_bPrune: 1
 whether primary sort is a prune-sort More...
 
HitSortOrderEnum m_SortOrder: 4
 hit sort order More...
 
vector< BYTEm_DebugInfo
 ? More...
 

Detailed Description

CQueryResult: query results, possibly aggregated by "break".

Class CQueryResult contains all information about the first m_pConcordance->m_MaxCachedHitsCount hits for the input query. Other hits (beyond m_pConcordance->m_MaxCachedHitsCount) are not stored but they can be retrieved on user's demand.

Member Function Documentation

◆ ClearQueryResults()

void CQueryResult::ClearQueryResults ( )

clears CQueryResult fields

References ClearVector(), hsoNone, m_AllHitsCount, m_bSortByString, m_DebugInfo, m_HighlightIds, m_HighlightOccurs, m_Hits, m_RelevantDocumentCount, and m_SortOrder.

Referenced by CConcSession::ClearQueryResults().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SortResultsByIndex()

template<typename HitIndexLessThanT >
void CQueryResult::SortResultsByIndex ( HitIndexLessThanT &  HitIndexLess)
inline

sort all hits by generic index-comparison function (comparison predicate reference)

See also
CQueryResultIndex<HitIndexLessThanT>::SortByIndex()
CQueryResultIndex<HitIndexLessThanT>::Apply()

References CQueryResultIndex::Apply(), and CQueryResultIndex::SortByIndex().

Referenced by SortResultsByIndexP().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SortResultsByHit()

template<typename HitLessThanT >
void CQueryResult::SortResultsByHit ( HitLessThanT &  HitLess)
inline

sort hits by generic hit-comparison function (comparison predicate reference)

See also
CQueryResultIndex<HitIndexLessThanT>::SortByHit()
CQueryResultIndex<HitIndexLessThanT>::Apply()

References CQueryResultIndex::Apply(), and CQueryResultIndex::SortByHit().

Referenced by SortResultsByHitP().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SortResultsByIndexP()

template<typename HitIndexLessThanT >
void CQueryResult::SortResultsByIndexP ( HitIndexLessThanT  HitIndexLess)
inline

sort all hits by generic index-comparison function (comparison predicate value)

See also
CQueryResultIndex<HitIndexLessThanT>::SortByIndex()
CQueryResultIndex<HitIndexLessThanT>::Apply()

References SortResultsByIndex().

Here is the call graph for this function:

◆ SortResultsByHitP()

template<typename HitLessThanT >
void CQueryResult::SortResultsByHitP ( HitLessThanT  HitLess)
inline

sort hits by generic hit-comparison function (comparsion predicate value)

See also
CQueryResultIndex<HitIndexLessThanT>::SortByHit()
CQueryResultIndex<HitIndexLessThanT>::Apply()

References SortResultsByHit().

Referenced by CQCount::CountLocal().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ m_Hits

vector<CHit> CQueryResult::m_Hits

◆ m_HighlightOccurs

vector<CTokenNo> CQueryResult::m_HighlightOccurs

◆ m_HighlightIds

vector<BYTE> CQueryResult::m_HighlightIds

◆ m_AllHitsCount

size_t CQueryResult::m_AllHitsCount

the number of all found hits (if m_AllHitsCount < m_pConcordance->m_MaxCachedHitsCount, then m_Hits.size() == m_AllHitsCount)

Referenced by CConcSessionContext::CacheGet(), CConcSessionContext::CacheSet(), ClearQueryResults(), CQCount::ConvertCountsToHits(), CQCount::CountLocal(), CDDCLeafServer::handle__get_first_hits(), and CDDCLeafServer::handle__run_query().

◆ m_RelevantDocumentCount

size_t CQueryResult::m_RelevantDocumentCount

◆ m_bSortByString

bool CQueryResult::m_bSortByString

◆ m_bPrune

bool CQueryResult::m_bPrune

whether primary sort is a prune-sort

◆ m_SortOrder

HitSortOrderEnum CQueryResult::m_SortOrder

◆ m_DebugInfo

vector<BYTE> CQueryResult::m_DebugInfo
mutable

The documentation for this struct was generated from the following files: