Lucene++ - a full-featured, c++ search engine
API Documentation


Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Data Fields | Protected Member Functions | Protected Attributes
Lucene::TermsHashPerField Class Reference

#include <TermsHashPerField.h>

+ Inheritance diagram for Lucene::TermsHashPerField:

Public Member Functions

 TermsHashPerField (const DocInverterPerFieldPtr &docInverterPerField, const TermsHashPerThreadPtr &perThread, const TermsHashPerThreadPtr &nextPerThread, const FieldInfoPtr &fieldInfo)
 
virtual ~TermsHashPerField ()
 
virtual String getClassName ()
 
boost::shared_ptr< TermsHashPerFieldshared_from_this ()
 
virtual void initialize ()
 Called directly after instantiation to create objects that depend on this object being fully constructed.
 
void shrinkHash (int32_t targetSize)
 
void reset ()
 
virtual void abort ()
 Called on hitting an aborting exception.
 
void initReader (const ByteSliceReaderPtr &reader, const RawPostingListPtr &p, int32_t stream)
 
Collection< RawPostingListPtrsortPostings ()
 Collapse the hash table and sort in-place.
 
virtual void start (const FieldablePtr &field)
 Called before a field instance is being processed.
 
virtual bool start (Collection< FieldablePtr > fields, int32_t count)
 Called once per field, and is given all Fieldable occurrences for this field in the document.
 
void add (int32_t textStart)
 
virtual void add ()
 Primary entry point (for first TermsHash)
 
void writeByte (int32_t stream, int8_t b)
 
void writeBytes (int32_t stream, const uint8_t *b, int32_t offset, int32_t length)
 
void writeVInt (int32_t stream, int32_t i)
 
virtual void finish ()
 Called once per field per document, after all Fieldable occurrences are inverted.
 
void rehashPostings (int32_t newSize)
 Called when postings hash is too small (> 50% occupied) or too large (< 20% occupied).
 
- Public Member Functions inherited from Lucene::InvertedDocConsumerPerField
virtual ~InvertedDocConsumerPerField ()
 
boost::shared_ptr< InvertedDocConsumerPerFieldshared_from_this ()
 
- Public Member Functions inherited from Lucene::LuceneObject
virtual ~LuceneObject ()
 
virtual LuceneObjectPtr clone (const LuceneObjectPtr &other=LuceneObjectPtr())
 Return clone of this object.
 
virtual int32_t hashCode ()
 Return hash code for this object.
 
virtual bool equals (const LuceneObjectPtr &other)
 Return whether two objects are equal.
 
virtual int32_t compareTo (const LuceneObjectPtr &other)
 Compare two objects.
 
virtual String toString ()
 Returns a string representation of the object.
 
- Public Member Functions inherited from Lucene::LuceneSync
virtual ~LuceneSync ()
 
virtual SynchronizePtr getSync ()
 Return this object synchronize lock.
 
virtual LuceneSignalPtr getSignal ()
 Return this object signal.
 
virtual void lock (int32_t timeout=0)
 Lock this object using an optional timeout.
 
virtual void unlock ()
 Unlock this object.
 
virtual bool holdsLock ()
 Returns true if this object is currently locked by current thread.
 
virtual void wait (int32_t timeout=0)
 Wait for signal using an optional timeout.
 
virtual void notifyAll ()
 Notify all threads waiting for signal.
 

Static Public Member Functions

static String _getClassName ()
 
- Static Public Member Functions inherited from Lucene::InvertedDocConsumerPerField
static String _getClassName ()
 

Data Fields

TermsHashConsumerPerFieldPtr consumer
 
TermsHashPerFieldPtr nextPerField
 
DocInverterPerFieldWeakPtr _docInverterPerField
 
TermsHashPerThreadPtr nextPerThread
 
TermsHashPerThreadWeakPtr _perThread
 
DocStatePtr docState
 
FieldInvertStatePtr fieldState
 
TermAttributePtr termAtt
 
CharBlockPoolPtr charPool
 
IntBlockPoolPtr intPool
 
ByteBlockPoolPtr bytePool
 
int32_t streamCount
 
int32_t numPostingInt
 
FieldInfoPtr fieldInfo
 
bool postingsCompacted
 
int32_t numPostings
 
IntArray intUptos
 
int32_t intUptoStart
 

Protected Member Functions

void compactPostings ()
 
bool postingEquals (const wchar_t *tokenText, int32_t tokenTextLen)
 Test whether the text for current RawPostingList p equals current tokenText.
 
- Protected Member Functions inherited from Lucene::LuceneObject
 LuceneObject ()
 

Protected Attributes

int32_t postingsHashSize
 
int32_t postingsHashHalfSize
 
int32_t postingsHashMask
 
Collection< RawPostingListPtrpostingsHash
 
RawPostingListPtr p
 
bool doCall
 
bool doNextCall
 
- Protected Attributes inherited from Lucene::LuceneSync
SynchronizePtr objectLock
 
LuceneSignalPtr objectSignal
 

Constructor & Destructor Documentation

◆ TermsHashPerField()

Lucene::TermsHashPerField::TermsHashPerField ( const DocInverterPerFieldPtr docInverterPerField,
const TermsHashPerThreadPtr perThread,
const TermsHashPerThreadPtr nextPerThread,
const FieldInfoPtr fieldInfo 
)

◆ ~TermsHashPerField()

virtual Lucene::TermsHashPerField::~TermsHashPerField ( )
virtual

Member Function Documentation

◆ _getClassName()

static String Lucene::TermsHashPerField::_getClassName ( )
inlinestatic

◆ abort()

virtual void Lucene::TermsHashPerField::abort ( )
virtual

Called on hitting an aborting exception.

Implements Lucene::InvertedDocConsumerPerField.

◆ add() [1/2]

virtual void Lucene::TermsHashPerField::add ( )
virtual

Primary entry point (for first TermsHash)

Implements Lucene::InvertedDocConsumerPerField.

◆ add() [2/2]

void Lucene::TermsHashPerField::add ( int32_t  textStart)

◆ compactPostings()

void Lucene::TermsHashPerField::compactPostings ( )
protected

◆ finish()

virtual void Lucene::TermsHashPerField::finish ( )
virtual

Called once per field per document, after all Fieldable occurrences are inverted.

Implements Lucene::InvertedDocConsumerPerField.

◆ getClassName()

virtual String Lucene::TermsHashPerField::getClassName ( )
inlinevirtual

◆ initialize()

virtual void Lucene::TermsHashPerField::initialize ( )
virtual

Called directly after instantiation to create objects that depend on this object being fully constructed.

Reimplemented from Lucene::LuceneObject.

◆ initReader()

void Lucene::TermsHashPerField::initReader ( const ByteSliceReaderPtr reader,
const RawPostingListPtr p,
int32_t  stream 
)

◆ postingEquals()

bool Lucene::TermsHashPerField::postingEquals ( const wchar_t *  tokenText,
int32_t  tokenTextLen 
)
protected

Test whether the text for current RawPostingList p equals current tokenText.

◆ rehashPostings()

void Lucene::TermsHashPerField::rehashPostings ( int32_t  newSize)

Called when postings hash is too small (> 50% occupied) or too large (< 20% occupied).

◆ reset()

void Lucene::TermsHashPerField::reset ( )

◆ shared_from_this()

boost::shared_ptr< TermsHashPerField > Lucene::TermsHashPerField::shared_from_this ( )
inline

◆ shrinkHash()

void Lucene::TermsHashPerField::shrinkHash ( int32_t  targetSize)

◆ sortPostings()

Collection< RawPostingListPtr > Lucene::TermsHashPerField::sortPostings ( )

Collapse the hash table and sort in-place.

◆ start() [1/2]

virtual bool Lucene::TermsHashPerField::start ( Collection< FieldablePtr fields,
int32_t  count 
)
virtual

Called once per field, and is given all Fieldable occurrences for this field in the document.

Implements Lucene::InvertedDocConsumerPerField.

◆ start() [2/2]

virtual void Lucene::TermsHashPerField::start ( const FieldablePtr field)
virtual

Called before a field instance is being processed.

Implements Lucene::InvertedDocConsumerPerField.

◆ writeByte()

void Lucene::TermsHashPerField::writeByte ( int32_t  stream,
int8_t  b 
)

◆ writeBytes()

void Lucene::TermsHashPerField::writeBytes ( int32_t  stream,
const uint8_t *  b,
int32_t  offset,
int32_t  length 
)

◆ writeVInt()

void Lucene::TermsHashPerField::writeVInt ( int32_t  stream,
int32_t  i 
)

Field Documentation

◆ _docInverterPerField

DocInverterPerFieldWeakPtr Lucene::TermsHashPerField::_docInverterPerField

◆ _perThread

TermsHashPerThreadWeakPtr Lucene::TermsHashPerField::_perThread

◆ bytePool

ByteBlockPoolPtr Lucene::TermsHashPerField::bytePool

◆ charPool

CharBlockPoolPtr Lucene::TermsHashPerField::charPool

◆ consumer

TermsHashConsumerPerFieldPtr Lucene::TermsHashPerField::consumer

◆ doCall

bool Lucene::TermsHashPerField::doCall
protected

◆ docState

DocStatePtr Lucene::TermsHashPerField::docState

◆ doNextCall

bool Lucene::TermsHashPerField::doNextCall
protected

◆ fieldInfo

FieldInfoPtr Lucene::TermsHashPerField::fieldInfo

◆ fieldState

FieldInvertStatePtr Lucene::TermsHashPerField::fieldState

◆ intPool

IntBlockPoolPtr Lucene::TermsHashPerField::intPool

◆ intUptos

IntArray Lucene::TermsHashPerField::intUptos

◆ intUptoStart

int32_t Lucene::TermsHashPerField::intUptoStart

◆ nextPerField

TermsHashPerFieldPtr Lucene::TermsHashPerField::nextPerField

◆ nextPerThread

TermsHashPerThreadPtr Lucene::TermsHashPerField::nextPerThread

◆ numPostingInt

int32_t Lucene::TermsHashPerField::numPostingInt

◆ numPostings

int32_t Lucene::TermsHashPerField::numPostings

◆ p

RawPostingListPtr Lucene::TermsHashPerField::p
protected

◆ postingsCompacted

bool Lucene::TermsHashPerField::postingsCompacted

◆ postingsHash

Collection<RawPostingListPtr> Lucene::TermsHashPerField::postingsHash
protected

◆ postingsHashHalfSize

int32_t Lucene::TermsHashPerField::postingsHashHalfSize
protected

◆ postingsHashMask

int32_t Lucene::TermsHashPerField::postingsHashMask
protected

◆ postingsHashSize

int32_t Lucene::TermsHashPerField::postingsHashSize
protected

◆ streamCount

int32_t Lucene::TermsHashPerField::streamCount

◆ termAtt

TermAttributePtr Lucene::TermsHashPerField::termAtt

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

clucene.sourceforge.net