Classes | Public Member Functions | Private Attributes

CShortOccurCache Class Reference

#include <ConcCommon.h>

List of all members.

Classes

Public Member Functions

Private Attributes


Detailed Description

CShortOccurCache is a structure which holds all found occurrences indexed by an index item No, if the number of occurrences for this index item is not greater than OccurBufferSize. This structure can take an advantage only if there are many corpus periods, otherwise it can even slow the program. But if there are many corpus periods, then having initialized this cache for the first period, the program can read from now on occurrences directly from the memory. CShortOccurCache is used only for one query at a time, so it is cleared in the very beginning of CConcHolder::GetAllHits.


Member Function Documentation

void CShortOccurCache::Clear (  ) 
size_t CShortOccurCache::AddNewIndexItemNoToCache ( const CTokenNo pStart,
const CTokenNo pEnd 
)

References m_IndexItemNo2Occurrences, and m_OccurrencesBody.

Referenced by CIndexSetForQueryingStage::AddOccurs().

Here is the caller graph for this function:

const CTokenNo * CShortOccurCache::GetOccurrencesFromCache ( const int  CacheId,
DWORD Length 
) const
bool CShortOccurCache::CouldContainMore (  )  const

References m_OccurrencesBody, and MaxShortOccurCacheSize.

Referenced by CIndexSetForQueryingStage::AddOccurs().

Here is the caller graph for this function:


Member Data Documentation

this map contains a relation from index item No to the address of its occurrences

Referenced by AddNewIndexItemNoToCache(), Clear(), and GetOccurrencesFromCache().

this vector contains all occurrences for this cache

Referenced by AddNewIndexItemNoToCache(), Clear(), CouldContainMore(), and GetOccurrencesFromCache().


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