Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

lemur::parse::StringQuery Class Reference

#include <StringQuery.hpp>

Inheritance diagram for lemur::parse::StringQuery:

lemur::api::TermQuery lemur::api::TextHandler lemur::api::Query List of all members.

Public Member Functions

 StringQuery ()
 StringQuery (const char *query, const char *qid=NULL)
 StringQuery (const string &query, const string &qid="")
 ~StringQuery ()
void startTermIteration () const
 TermQuery methods.

bool hasMore () const
const lemur::api::TermnextTerm () const
void addTerm (const string &token)
void addTerm (const char *token)
void parse (const string &token)
char * handleWord (char *word)
 TextHandler methods.

char * handleSymbol (char *sym)
 Handle a word, possibly transforming it.

Protected Attributes

vector< string > tokens
int iter
lemur::api::Term tt

Detailed Description

A query class for handling string queries. Tokenizes at spaces. Also a TextHandler to begin a chain (call empty constructor, add other TH, then call parse) Can be used at the end of a chain also after other TH. i.e. look at RetMethodManager::runTextQuery

Constructor & Destructor Documentation

lemur::parse::StringQuery::StringQuery  ) 

lemur::parse::StringQuery::StringQuery const char *  query,
const char *  qid = NULL

lemur::parse::StringQuery::StringQuery const string &  query,
const string &  qid = ""

lemur::parse::StringQuery::~StringQuery  ) 

Member Function Documentation

void lemur::parse::StringQuery::addTerm const char *  token  ) 

void lemur::parse::StringQuery::addTerm const string &  token  ) 

char * lemur::parse::StringQuery::handleSymbol char *  sym  )  [virtual]

Handle a word, possibly transforming it.

Reimplemented from lemur::api::TextHandler.

char * lemur::parse::StringQuery::handleWord char *  word  )  [virtual]

TextHandler methods.

Reimplemented from lemur::api::TextHandler.

bool lemur::parse::StringQuery::hasMore  )  const [inline, virtual]

Implements lemur::api::TermQuery.

const lemur::api::Term * lemur::parse::StringQuery::nextTerm  )  const [virtual]

Implements lemur::api::TermQuery.

void lemur::parse::StringQuery::parse const string &  token  ) 

void lemur::parse::StringQuery::startTermIteration  )  const [inline, virtual]

TermQuery methods.

Implements lemur::api::TermQuery.

Member Data Documentation

int lemur::parse::StringQuery::iter [mutable, protected]

vector<string> lemur::parse::StringQuery::tokens [protected]

lemur::api::Term lemur::parse::StringQuery::tt [mutable, protected]

The documentation for this class was generated from the following files:
Generated on Tue Jun 15 11:03:06 2010 for Lemur by doxygen 1.3.4