#include <ConcHolder.h>
FormatTypeEnum defines the format of output hits:
Class CConcHolder is created for querying a corpus. It contains all user options for the query process like m_ResultLimit (the maximal number of hits, which should be output) or m_QueryResultStr(the string representation of the query result).
FormatTypeEnum defines the format of output hits:
CConcHolder::CConcHolder | ( | ) |
References m_pBreaks, m_pIndexator, m_pQueryEvaluator, m_QueryEndTime, m_ResultFormat, m_ResultLimit, and TheEndOfTheWorld.
CConcHolder::~CConcHolder | ( | ) |
References m_pQueryEvaluator.
void CConcHolder::AddFileReference | ( | const long | FileNo | ) | [private] |
add a reference to FileNo according to m_ResultFormat
References DDC_ResultHTML, DDC_ResultTable, DDC_ResultText, CConcIndexator::GetHtmlReference(), CConcIndexator::GetShortFilename(), m_pIndexator, m_QueryResultStr, and m_ResultFormat.
Referenced by GenerateOneHitString().
add bibliographical information about Hit to m_QueryResultStr
References Date, DDC_ResultHTML, DDC_ResultTable, DDC_ResultText, Format(), CConcXml::GetFullBibliographyOfHit(), CConcIndexator::GetShortFilename(), CConcXml::GetVisibleFreeHeaderBiblAttributes(), CConcIndexator::IsDwdsCorpusInterface(), CConcIndexator::IsGutenbergInterface(), CConcIndexator::m_Bibl, CConcIndexator::m_CorpusFiles, CBibliography::m_DateStr, CHit::m_FileNo, CBibliography::m_OrigBibl, m_pIndexator, m_QueryResultStr, m_ResultFormat, CBibliography::m_ScanBibl, and UnknownPageNumber.
Referenced by GenerateOneHitString().
bool CConcHolder::ShowBibliographyForTable | ( | DWORD | PageNumber, | |
const CHit & | Hit, | |||
const vector< COutputToken > & | Tokens | |||
) | [private] |
add bibliographical information about Hit to m_QueryResultStr under TableFormat
References ConvertASCIIToHtmlSymbols(), Format(), CConcXml::GetFreeHeaderBiblAttributesWithNames(), CConcXml::GetFullBibliographyOfHit(), globalTableItemsDelim, CConcIndexator::m_Bibl, CConcIndexator::m_CorpusFiles, CBibliography::m_DateStr, CHit::m_FileNo, CBibliography::m_OrigBibl, m_pIndexator, m_QueryResultStr, CBibliography::m_ScanBibl, and UnknownPageNumber.
Referenced by GenerateOneHitString().
bool CConcHolder::GenerateOneHitString | ( | DWORD | PageNumber, | |
const CHit & | Hit, | |||
const vector< COutputToken > & | Tokens | |||
) | [private] |
add hit string built by Hit to to m_QueryResultStr
References AddFileReference(), BuildHtmlHitStrWithHighlighting(), DDC_ResultDocIds, DDC_ResultHTML, DDC_ResultJson, DDC_ResultTable, DDC_ResultText, ErrorMessage(), Format(), GenerateOneHitStringJson(), GetContext(), HasRankOrderOperator(), CQueryParser::m_bDebugRank, CQueryParser::m_bEnableBibliographyForThisQuery, CHit::m_BreakNo, CQueryParser::m_ContextSentencesCount, CQueryResult::m_DebugInfo, CHit::m_DebugRankNo, CHit::m_FileNo, CConcIndexator::m_HtmlHighlighting, CHit::m_OrderId, m_pIndexator, m_pQueryEvaluator, m_QueryResultStr, m_ResultFormat, CConcIndexator::m_TextHighlighting, CConcIndexator::m_TokenDelimiter, CConcIndexator::OutputBibliographyOfHits(), ShowBibliographyForTable(), and ShowBibliographyForTextOrHtml().
Referenced by GenerateHitStrings().
bool CConcHolder::GenerateOneHitStringJson | ( | DWORD | PageNumber, | |
const CHit & | Hit, | |||
const vector< COutputToken > & | Tokens | |||
) | [private] |
json: add hit string built by Hit to to m_QueryResultStr
References BuildJsonContextString(), ErrorMessage(), Format(), GetContextJson(), CConcXml::GetFreeHeaderBiblAttributesJson(), CConcXml::GetFullBibliographyOfHit(), HasRankOrderOperator(), jsonStr(), CQueryParser::m_bDebugRank, CConcIndexator::m_Bibl, CHit::m_BreakNo, CQueryParser::m_ContextSentencesCount, CConcIndexator::m_CorpusFiles, CBibliography::m_DateStr, CQueryResult::m_DebugInfo, CHit::m_DebugRankNo, CHit::m_FileNo, CStringIndexator::m_Indices, CConcIndexator::m_IndicesToShow, CHit::m_OrderId, CBibliography::m_OrigBibl, m_pIndexator, m_pQueryEvaluator, m_QueryResultStr, CBibliography::m_ScanBibl, CConcIndexator::m_Utf8, CConcIndexator::OutputBibliographyOfHits(), and UnknownPageNumber.
Referenced by GenerateOneHitString().
bool CConcHolder::GetContext | ( | int | StartBreakNo, | |
int | EndBreakNo, | |||
const DWORD | CurrFileNo, | |||
const bool | bConvertASCIIToHtmlSymbols, | |||
string & | Result | |||
) | const [private] |
add hit strings [StartBreakNo, EndBreakNo) without highlighting to m_QueryResultStr
References BuildHtmlHitStrWithHighlighting(), DDC_ResultTable, ErrorMessage(), Format(), GetBreaks(), CHitBorders::GetFileBreaks(), CHitBorders::GetFileStartTokenNo(), GetTokensFromStorageByBreak(), CQueryParser::m_HitTypeStr, CConcIndexator::m_IndicesToShow, m_pIndexator, m_pQueryEvaluator, m_ResultFormat, CConcIndexator::m_TokenDelimiter, and PredefinedFileBreakName.
Referenced by GenerateOneHitString().
bool CConcHolder::GetContextJson | ( | int | StartBreakNo, | |
int | EndBreakNo, | |||
const DWORD | CurrFileNo, | |||
string & | js | |||
) | const [private] |
append json hit strings [StartBreakNo, EndBreakNo) without highlighting to js
References BuildJsonContextString(), ErrorMessage(), Format(), GetBreaks(), CHitBorders::GetFileBreaks(), CHitBorders::GetFileStartTokenNo(), GetTokensFromStorageByBreak(), CQueryParser::m_HitTypeStr, CConcIndexator::m_IndicesToShow, m_pIndexator, m_pQueryEvaluator, and PredefinedFileBreakName.
Referenced by GenerateOneHitStringJson().
DDCErrorEnum CConcHolder::GetAllHits | ( | string | Query, | |
size_t | Limit | |||
) | [private] |
run query to the corpus, initializes slots from CQueryResult
References bdDontUseBigrams, CQueryResult::ClearQueryResults(), CQueryParser::DeleteTree(), CQueryParser::Evaluate(), GetBigramsToOrder(), CStringIndexator::GetSearchPeriodsCount(), InitFileReferences(), InitLessByBigrams(), InitOrderIDForHits(), CQueryResult::m_AllHitsCount, CDDCFilterWithBounds::m_bRegExp, CConcIndexator::m_bShowNumberOfRelevantDocuments, CConcIndexatorInvoker::m_bStoppedByUser, CConcIndexator::m_CorpusFiles, m_CurrentSearchPeriodNo, CQueryParser::m_Filters, CHit::m_HighlightOccurrenceEnd, CQueryResult::m_HighlightOccurs, CQueryResult::m_Hits, CQueryNode::m_Hits, CDDCFilterWithBounds::m_LevelEnd, CDDCFilterWithBounds::m_LevelStart, CConcIndexator::m_MaskedFiles, CQueryNode::m_Occurrences, m_pIndexator, m_pQueryEvaluator, CQueryParser::m_pQueryTree, m_QueryEndTime, CQueryResult::m_RelevantDocumentCount, CDDCFilterWithBounds::m_SatisfiedValues, m_ShortOccurCaches, my_lower_bound(), and TheEndOfTheWorld.
Referenced by GetHits().
bool CConcHolder::TryToGetFromCache | ( | string | Query, | |
DWORD & | EndHitNo | |||
) | [private] |
checks if Query si already in the cache, and if true, it returns its hit results from the cache
References CQueryResult::ClearQueryResults(), CQueryResult::m_AllHitsCount, CQueryResult::m_DebugInfo, CQueryResult::m_HighlightOccurs, CQueryResult::m_Hits, m_QueryCache, CQueryResult::m_RelevantDocumentCount, m_ResultLimit, and MaxCachedHitsCount.
Referenced by GetHits().
void CConcHolder::SaveToCache | ( | string & | Query, | |
vector< size_t >::const_iterator | start, | |||
vector< size_t >::const_iterator | end | |||
) | [private] |
stores Query to the cache
References CQueryResult::m_AllHitsCount, CQueryResult::m_DebugInfo, CQueryResult::m_HighlightOccurs, CQueryResult::m_Hits, m_Queries, m_QueryCache, CQueryResult::m_RelevantDocumentCount, MaxCachedHitsCount, and MaxQueryCacheSize.
Referenced by GetHits().
void CConcHolder::SetHitType | ( | ) | [private] |
sets hit type, initializing m_pBreaks
References CHitBorders::GetBreaksByName(), CQueryParser::m_HitTypeStr, m_pBreaks, m_pIndexator, m_pQueryEvaluator, CQueryParser::m_TextAreaNo, PredefinedTextAreaBreakName, and UnknownTextAreaNo.
Referenced by GetHits(), and GetOccurrences().
bool CConcHolder::GetFileSnippets | ( | const int | HitNo, | |
vector< COutputToken > & | Tokens | |||
) | const [private] |
creates snippets, concatenating contexts of found words
References concord_daemon_log(), Format(), GetBreaks(), CStringIndexator::GetTokenIndex(), CStringIndexSet::GetTokensFromStorage(), CQueryResult::m_HighlightOccurs, CQueryResult::m_Hits, CConcIndexator::m_LeftKwicContextSize, CConcIndexator::m_NumberOfKwicLinesInSnippets, m_pIndexator, and CConcIndexator::m_RightKwicContextSize.
Referenced by GenerateHitStrings().
bool CConcHolder::SaveOccurrences | ( | const vector< size_t > & | ChunkLengths, | |
int | ContextSize, | |||
const vector< CTokenNo > & | Occurrences, | |||
const vector< CHit > & | Hits, | |||
SaveTriggerType | SaveTrigger, | |||
DWORD | LParam | |||
) | [private] |
saves current found hits using SaveTrigger, this funciton is only called from GetOccurrences
References concord_daemon_log(), Format(), GetBreaks(), CStringIndexator::GetTokenIndex(), CStringIndexSet::GetTokensFromStorage(), CStringIndexator::m_Indices, m_pIndexator, and SaveTrigger().
Referenced by GetOccurrences().
bool CConcHolder::GetTokensFromStorageByBreak | ( | size_t | IndexNo, | |
size_t | BreakNo, | |||
vector< COutputToken > & | Tokens | |||
) | const [private] |
initializes Tokens with words of hit BreakNo
References concord_daemon_log(), Format(), GetBreaks(), CStringIndexSet::GetTokensFromStorage(), CStringIndexator::m_Indices, and m_pIndexator.
Referenced by GenerateHitStrings(), GetContext(), and GetContextJson().
void CConcHolder::InitFileReferences | ( | vector< CHit > & | Hits | ) | const [private] |
initializes CHit::m_FileNo for each hit of Hits
References GetBreaks(), CHitBorders::GetFileBreaks(), CHit::m_BreakNo, CHit::m_FileNo, CHit::m_OrderId, and m_pIndexator.
Referenced by GetAllHits().
void CConcHolder::InitOrderIDForHits | ( | const CDDCFilterWithBounds & | Filter | ) | const [private] |
initializes CHit::m_OrderId for each in m_pQueryEvaluator->m_pQueryTree->m_Hits
References GreaterByDate, GreaterByFreeBiblField, GreaterByRank, GreaterBySize, HitSortsCount, CConcXml::InitGreaterByBiblIntegerField(), CConcXml::InitGreaterByDate(), InitGreaterByRank(), InitGreaterBySize(), CConcXml::InitLessByBiblIntegerField(), InitLessByBigrams(), CConcXml::InitLessByDate(), InitLessByRank(), InitLessBySize(), LessByDate, LessByFreeBiblField, LessByLeftContext, LessByRank, LessByRightContext, LessBySize, CConcIndexator::m_Bibl, CDDCFilterWithBounds::m_FilterType, CDDCFilterWithBounds::m_FreeBiblAttribName, CQueryNode::m_Hits, m_pIndexator, m_pQueryEvaluator, CQueryParser::m_pQueryTree, and NoSort.
Referenced by GetAllHits().
void CConcHolder::InitLessByRank | ( | ) | const [private] |
References Format(), GetBreaks(), CHitBorders::GetCorpusEndTokenNo(), GetHitRankLen(), CQueryNode::GetNodeFrequenceByNodeIndex(), CQueryParser::GetNodeIndicesCount(), CConcXml::InitLessByBiblIntegerField(), CConcXml::IsRegisteredBiblField(), log(), CQueryParser::m_bDebugRank, CConcIndexator::m_Bibl, CHit::m_BreakNo, CQueryResult::m_DebugInfo, CHit::m_DebugRankNo, CQueryNode::m_Hits, CHitRank::m_IDFs, CConcIndexator::m_NearRank, CQueryNode::m_OccurrenceNodeIndices, CQueryNode::m_Occurrences, CHit::m_OrderId, CHitRank::m_PassageEnd, CHitRank::m_PassageStart, m_pIndexator, CConcIndexator::m_PositionRank, m_pQueryEvaluator, CQueryParser::m_pQueryTree, CHitRank::m_QueryNodeFreqs, and CConcIndexator::m_TfIdfRank.
Referenced by InitGreaterByRank(), and InitOrderIDForHits().
void CConcHolder::InitGreaterByRank | ( | ) | const [private] |
References InitLessByRank(), CQueryNode::m_Hits, m_pQueryEvaluator, and CQueryParser::m_pQueryTree.
Referenced by InitOrderIDForHits().
void CConcHolder::InitLessBySize | ( | ) | const [private] |
References GetBreaks(), CHit::m_BreakNo, CQueryNode::m_Hits, CHit::m_OrderId, m_pQueryEvaluator, and CQueryParser::m_pQueryTree.
Referenced by InitOrderIDForHits().
void CConcHolder::InitGreaterBySize | ( | ) | const [private] |
References GetBreaks(), CHit::m_BreakNo, CQueryNode::m_Hits, CHit::m_OrderId, m_pQueryEvaluator, and CQueryParser::m_pQueryTree.
Referenced by InitOrderIDForHits().
void CConcHolder::InitLessByBigrams | ( | ) | const [private] |
References GetBreaks(), CQueryNode::m_Hits, CQueryNode::m_OccurrenceTokenIdxs, CHit::m_OrderId, m_pQueryEvaluator, and CQueryParser::m_pQueryTree.
Referenced by GetAllHits(), and InitOrderIDForHits().
const vector< CTokenNo > & CConcHolder::GetBreaks | ( | ) | const |
GetBreaks returns the vector of current breaks (by m_pBreaks).
References m_pBreaks.
Referenced by CQueryNode::ConvertOccurrencesToHits(), CQueryNode::ConvertOccurrencesToHitsForPatterns(), GenerateHitStrings(), GetContext(), GetContextJson(), GetFileSnippets(), GetTokensFromStorageByBreak(), InitFileReferences(), InitGreaterBySize(), InitLessByBigrams(), InitLessByRank(), InitLessBySize(), and SaveOccurrences().
FormatTypeEnum CConcHolder::GetResultFormat | ( | ) | const [inline] |
return the current format of hit
References m_ResultFormat.
string CConcHolder::GetResultFormatStr | ( | ) | const |
return string representation of m_ResultFormat
References DDC_ResultDocIds, DDC_ResultHTML, DDC_ResultJson, DDC_ResultTable, and m_ResultFormat.
Referenced by CDDCCorpusListenHost::ProcessSocketString(), and SimpleQuery().
void CConcHolder::SetResultFormat | ( | string | ResultTypeStr | ) |
set the current format of hit
References GetResultFormatByString(), and m_ResultFormat.
Referenced by CDDCCorpusListenHost::ProcessSocketString().
DDCErrorEnum CConcHolder::GetOccurrences | ( | string | Query, | |
int | ContextSize, | |||
SaveTriggerType | SaveTrigger, | |||
DWORD | LParam | |||
) |
Finds all occurrences of Query(only occurrences , not hits!), if Query is an atomic query (CQueryNode::m_bAtomic), For each found occurrence it calls SaveTrigger, which normally should save all occurrences to a file. This function is called in application ConcordPattern.
References concord_daemon_log(), CQueryNode::ConvertOccurrencesToHitsForPatterns(), CQueryParser::DeleteTree(), ErrorMessage(), CQueryNode::EvaluateWithoutHits(), CStringIndexator::GetSearchPeriodsCount(), CQueryNode::m_bAtomic, CConcIndexatorInvoker::m_bStdout, CQueryNode::m_ChunkLengths, m_CurrentSearchPeriodNo, CExpc::m_ErrorCode, CQueryNode::m_Hits, CQueryNode::m_Occurrences, m_pIndexator, m_pQueryEvaluator, CQueryParser::m_pQueryTree, CExpc::m_strCause, CQueryParser::ParseQuery(), SaveOccurrences(), and SetHitType().
DDCErrorEnum CConcHolder::SimpleQuery | ( | string | Query, | |
DWORD & | EndHitNo, | |||
DWORD & | HitsCount | |||
) |
SimpleQuery finds hits by the given query. EndHitNo is used as an input/output parameter.
Let H0...Hn be all hits which match the Query. Then EndHitNo must be 0<= EndHitNo<=n. Let S be min (n, EndHitNo+m_ResultLimit-1). The function saves hits [EndHitNo, EndHitNo+1,... EndHitNo+s] to result strings. After this it makes EndHitNo equal to s+1. The function returns errUnknown, if there is no parse error in the given query.
References concord_daemon_log(), DDC_ResultHTML, DecorateQueryResults(), ErrorMessage(), errUnknown, Format(), GenerateHitStrings(), GetHits(), GetResultFormatStr(), CQueryResult::m_AllHitsCount, CConcIndexator::m_bShowNumberOfRelevantDocuments, CExpc::m_ErrorCode, m_pIndexator, m_QueryResultStr, CQueryResult::m_RelevantDocumentCount, m_ResultFormat, and CExpc::m_strCause.
DDCErrorEnum CConcHolder::GetHits | ( | string | Query, | |
DWORD & | EndHitNo | |||
) |
GetHits makes the same as SimpleQuery does, but without GenerateHitStrings.
References CQueryResult::ClearQueryResults(), concord_daemon_log(), ErrorMessage(), errUnknown, GetAllHits(), CExpc::m_ErrorCode, CQueryResult::m_HighlightOccurs, CQueryResult::m_Hits, m_pQueryEvaluator, m_ResultLimit, CExpc::m_strCause, MaxCachedHitsCount, CQueryParser::ParseQuery(), SaveToCache(), SetHitType(), and TryToGetFromCache().
Referenced by CDDCCorpusListenHost::ProcessSocketString(), and SimpleQuery().
DDCErrorEnum CConcHolder::GenerateHitStrings | ( | const int | StartHitNo | ) |
initializes m_QueryResultStr using current m_Hits and m_HighlightOccurs
References CHitBorders::ConvertHitsToPageBreaks(), DDC_ResultHTML, DDC_ResultJson, ErrorMessage(), errReadSourceFile, Format(), GenerateOneHitString(), GetBreaks(), GetFileSnippets(), CHitBorders::GetPageNumber(), GetTokensFromStorageByBreak(), m_AdditionalHitDelimeter, CQueryResult::m_HighlightOccurs, CQueryResult::m_Hits, CQueryParser::m_HitTypeStr, CConcIndexator::m_IndicesToShow, CConcIndexator::m_InterpDelimiter, m_pIndexator, m_pQueryEvaluator, m_QueryResultStr, m_ResultFormat, m_ResultLimit, and PredefinedFileBreakName.
Referenced by CDDCCorpusListenHost::ProcessSocketString(), and SimpleQuery().
string CConcHolder::GetHitIds | ( | ) | const |
stores order ids (CHit::m_OrderId) of current m_Hits to a string
References bdDontUseBigrams, Format(), GetBigramsToOrder(), CStringIndexSet::GetIndexItemStr(), CStringIndexator::GetTokenIndex(), CQueryResult::m_Hits, CIndexSetForQueryingStage::m_Index, and m_pIndexator.
Referenced by CDDCCorpusListenHost::ProcessSocketString().
bool CConcHolder::HitsShouldBeSorted | ( | ) | const |
return true, if the resulting hits should be ordered somehow
References CQueryParser::m_Filters, and m_pQueryEvaluator.
Referenced by CDDCCorpusListenHost::ProcessSocketString().
void CConcHolder::SetTimeOut | ( | int | TimeOut | ) |
sets timeout for query processing
References m_QueryEndTime, and TheEndOfTheWorld.
Referenced by CDDCCorpusListenHost::ProcessSocketString().
void CConcHolder::ClearQueryCache | ( | ) |
clears the query cache
References m_Queries, and m_QueryCache.
Referenced by CConcordance::LoadProject().
int CConcHolder::GetTextArea | ( | ) | const |
return the text area to be be searched
References m_pQueryEvaluator, and CQueryParser::m_TextAreaNo.
Referenced by CQueryNode::ConvertOccurrencesToHits(), and CQueryNode::ConvertOccurrencesToHitsForPatterns().
CConcHolder::FormatTypeEnum CConcHolder::GetResultFormatByString | ( | const string & | ResultTypeStr | ) | [static] |
converts a string to a FormatTypeEnum
References EngMakeUpper().
Referenced by DecorateQueryResults(), CDDCServerListenHost::ProcessSocketString(), CDDCServerListenHost::RunDistributed(), and SetResultFormat().
void CConcHolder::DecorateQueryResults | ( | const string & | ResultTypeStr, | |
string & | QueryResultString | |||
) | [static] |
adds header and footer to QueryResultStr according to format ResultTypeStr
References DDC_ResultHTML, and GetResultFormatByString().
Referenced by CDDCServerListenHost::RunDistributed(), and SimpleQuery().
bool CConcHolder::HasRankOrderOperator | ( | ) | const |
return true, if the input query contains less_by_rank or greater_by_rank moo: sick, bad, ugly, and wrong!
References LessByRank, CQueryParser::m_Filters, CDDCFilterWithBounds::m_FilterType, and m_pQueryEvaluator.
Referenced by GenerateOneHitString(), GenerateOneHitStringJson(), and CQueryNode::SetHolder().
int CConcHolder::GetBreakStarterLength | ( | ) | const |
return the length of break prefix, where DDC should search (within[sentence, 10])
BigramDirectionEnum CConcHolder::GetBigramsToOrder | ( | ) | const |
true, if left or right operator
References CQueryParser::m_BigramsUse, and m_pQueryEvaluator.
Referenced by CQueryTokenNode::EvaluateWithoutHits(), GetAllHits(), GetHitIds(), and CQueryNode::SetHolder().
string CConcHolder::BuildJsonContextString | ( | const vector< COutputToken > & | Tokens, | |
bool | doHighlight = true | |||
) | const |
moo: build a json context string by parsing delimited token data
References CConcIndexator::GetTokenFields(), jsonStr(), CStringIndexator::m_Indices, CConcIndexator::m_IndicesToShow, m_pIndexator, CStringIndexSet::m_ShortName, and CConcIndexator::m_Utf8.
Referenced by GenerateOneHitStringJson(), and GetContextJson().
map<string, CQueryResult> CConcHolder::m_QueryCache [private] |
hit results for the last MaxQueryCacheSize queries
Referenced by ClearQueryCache(), SaveToCache(), and TryToGetFromCache().
deque<string> CConcHolder::m_Queries [private] |
a deque for last MaxQueryCacheSize queries; m_Queries.last() is the last given query
Referenced by ClearQueryCache(), and SaveToCache().
CQueryParser* CConcHolder::m_pQueryEvaluator [private] |
current query parse tree, which is created to evaluate the inpur query
Referenced by CConcHolder(), GenerateHitStrings(), GenerateOneHitString(), GenerateOneHitStringJson(), GetAllHits(), GetBigramsToOrder(), GetContext(), GetContextJson(), GetHits(), GetOccurrences(), GetTextArea(), HasRankOrderOperator(), HitsShouldBeSorted(), InitGreaterByRank(), InitGreaterBySize(), InitLessByBigrams(), InitLessByRank(), InitLessBySize(), InitOrderIDForHits(), SetHitType(), and ~CConcHolder().
time_t CConcHolder::m_QueryEndTime [private] |
how much time a query can be processed, by default unlimited (-1)
Referenced by CConcHolder(), GetAllHits(), and SetTimeOut().
const vector<CTokenNo>* CConcHolder::m_pBreaks [private] |
a pointer to the current hits collection
Referenced by CConcHolder(), GetBreaks(), and SetHitType().
FormatTypeEnum CConcHolder::m_ResultFormat [private] |
the format of query result
Referenced by AddFileReference(), CConcHolder(), GenerateHitStrings(), GenerateOneHitString(), GetContext(), GetResultFormat(), GetResultFormatStr(), SetResultFormat(), ShowBibliographyForTextOrHtml(), and SimpleQuery().
a cache for short occurrence lists which is used during iterating through corpus periods and evaluating of the same query
Referenced by CQueryTokenNode::EvaluateWithoutHits(), and GetAllHits().
the result of the query (its format depends upon m_ResultFormat)
Referenced by AddFileReference(), GenerateHitStrings(), GenerateOneHitString(), GenerateOneHitStringJson(), CDDCCorpusListenHost::ProcessSocketString(), ShowBibliographyForTable(), ShowBibliographyForTextOrHtml(), and SimpleQuery().
m_pIndexator is the main (and the only) pointer to corpus indices and break collections. During the querying this pointer is used as a constant. Class CConcHolder itself is called so because it "holds" this pointer.
Referenced by AddFileReference(), BuildJsonContextString(), CQueryTokenNode::BuildRegExp(), CConcHolder(), CConcordance::CConcordance(), CQueryNode::ConvertOccurrencesToHits(), CQueryNode::ConvertOccurrencesToHitsForPatterns(), CQueryTokenNode::CreateChunkPattern(), CQueryTokenNode::CreateFileList(), CQueryTokenNode::CreateMorphAnnotationPattern(), CQueryTokenNode::CreateNodeByIndexName(), CQueryTokenNode::CreateThesPattern(), CQueryTokenNode::CreateTokenPattern(), CQueryTokenNode::EvaluateWithoutHits(), GenerateHitStrings(), GenerateOneHitString(), GenerateOneHitStringJson(), GetAllHits(), GetContext(), GetContextJson(), GetFileSnippets(), GetHitIds(), GetOccurrences(), GetTokensFromStorageByBreak(), InitFileReferences(), InitLessByRank(), InitOrderIDForHits(), CDDCCorpusListenHost::LoadHolder(), CConcordance::LoadProject(), CQueryParser::ParseQuery(), CQueryParser::ParseQueryOperators(), SaveOccurrences(), CConcordance::SaveProject(), SetHitType(), ShowBibliographyForTable(), ShowBibliographyForTextOrHtml(), SimpleQuery(), and CConcordance::~CConcordance().
size_t CConcHolder::m_ResultLimit |
the maximal number of hits, which should be output to m_HtmlResult and to m_PlainResult.
Referenced by CConcHolder(), GenerateHitStrings(), GetHits(), CDDCCorpusListenHost::ProcessSocketString(), and TryToGetFromCache().
The index of the current subcorpora, which is now being processed.
Referenced by CQueryTokenNode::EvaluateWithoutHits(), GetAllHits(), and GetOccurrences().
a delimeter which should be used between hits in m_QueryResultStr in the distributed model
Referenced by GenerateHitStrings(), and CDDCCorpusListenHost::LoadHolder().