PhraseHunter::EmptyToken Class Reference

A Token without a token string nor any occurrences. More...

#include <token.h>

Inherits PhraseHunter::Token.

Inheritance diagram for PhraseHunter::EmptyToken:

Inheritance graph
[legend]
Collaboration diagram for PhraseHunter::EmptyToken:

Collaboration graph
[legend]
List of all members.

Public Member Functions

unsigned int corpusFrequency () const
 Always returns 0.
bool isEmpty () const
 Always returns true.
unsigned int numTokens () const
 Always returns 0.

Static Public Member Functions

static TokenPtr instance ()
 Return instance() anywhere you would otherwise return NULL for a TokenPtr.

Protected Member Functions

bool boolean_test () const

Private Member Functions

 EmptyToken ()

Static Private Attributes

static TokenPtr s_inst

Detailed Description

A Token without a token string nor any occurrences.

Definition at line 100 of file token.h.


Constructor & Destructor Documentation

PhraseHunter::EmptyToken::EmptyToken (  )  [inline, private]

Definition at line 102 of file token.h.


Member Function Documentation

bool PhraseHunter::EmptyToken::boolean_test (  )  const [inline, protected]

Definition at line 106 of file token.h.

static TokenPtr PhraseHunter::EmptyToken::instance (  )  [inline, static]

Return instance() anywhere you would otherwise return NULL for a TokenPtr.

Definition at line 111 of file token.h.

References s_inst.

Referenced by PhraseHunter::Phrase::getAdjacent(), PhraseHunter::CorpusToken::loadFromCorpus(), PhraseHunter::LightCorpusToken::search(), PhraseHunter::SearchEngine::searchPhrase(), and PhraseHunter::SearchEngine::searchToken().

unsigned int PhraseHunter::EmptyToken::corpusFrequency (  )  const [inline, virtual]

Always returns 0.

Implements PhraseHunter::Token.

Definition at line 115 of file token.h.

bool PhraseHunter::EmptyToken::isEmpty (  )  const [inline, virtual]

Always returns true.

Reimplemented from PhraseHunter::Token.

Definition at line 117 of file token.h.

unsigned int PhraseHunter::EmptyToken::numTokens (  )  const [inline, virtual]

Always returns 0.

Reimplemented from PhraseHunter::Token.

Definition at line 119 of file token.h.


Member Data Documentation

TokenPtr PhraseHunter::EmptyToken::s_inst [static, private]

Definition at line 103 of file token.h.

Referenced by instance().


The documentation for this class was generated from the following files:
Generated on Thu Dec 21 16:14:44 2006 for The Phrasehunter by  doxygen 1.5.1