KVIrc  4.9.2
DeveloperAPIs
Classes | Signals | Public Member Functions | Private Slots | Private Member Functions | Private Attributes | List of all members
HelpIndex Class Reference

#include <HelpIndex.h>

+ Inheritance diagram for HelpIndex:

Classes

struct  Entry
 
struct  PosEntry
 

Signals

void indexingEnd ()
 
void indexingProgress (int)
 
void indexingStart (int)
 

Public Member Functions

const QStringList & documentList ()
 
QString getDocumentTitle (const QString &)
 
 HelpIndex (const QString &dp, const QString &hp)
 
 HelpIndex (const QStringList &dl, const QString &hp)
 
void makeIndex ()
 
QStringList query (const QStringList &, const QStringList &, const QStringList &)
 
void readDict ()
 
void setDictionaryFile (const QString &)
 
void setDocList (const QStringList &)
 
void setDocListFile (const QString &)
 
const QStringList & titlesList ()
 
void writeDict ()
 

Private Slots

void filterNext ()
 
void setLastWinClosed ()
 

Private Member Functions

void buildMiniDict (const QString &)
 
QString getCharsetForDocument (QFile *)
 
QStringList getWildcardTerms (const QString &)
 
void insertInDict (const QString &, int)
 
void parseDocument (const QString &, int)
 
void readDocumentList ()
 
bool searchForPattern (const QStringList &, const QStringList &, const QString &)
 
void setupDocumentList ()
 
QVector< DocumentsetupDummyTerm (const QStringList &)
 
QStringList split (const QString &)
 
void writeDocumentList ()
 

Private Attributes

bool alreadyHaveDocList
 
QHash< QString, Entry * > dict
 
QString dictFile
 
QStringList docList
 
QString docListFile
 
QString docPath
 
QHash< QString, QString > documentTitleCache
 
bool lastWindowClosed
 
int m_iCurItem
 
QTimer * m_pTimer
 
QHash< QString, PosEntry * > miniDict
 
QStringList titleList
 
uint wordNum
 

Constructor & Destructor Documentation

HelpIndex::HelpIndex ( const QString &  dp,
const QString &  hp 
)
HelpIndex::HelpIndex ( const QStringList &  dl,
const QString &  hp 
)

Member Function Documentation

void HelpIndex::buildMiniDict ( const QString &  str)
private

References miniDict, and wordNum.

Referenced by searchForPattern().

const QStringList& HelpIndex::documentList ( )
inline
void HelpIndex::filterNext ( )
privateslot
QString HelpIndex::getCharsetForDocument ( QFile *  file)
private

References r, and s.

Referenced by parseDocument().

QString HelpIndex::getDocumentTitle ( const QString &  fullFileName)

References documentTitleCache, and s.

Referenced by setupDocumentList(), and HelpWindow::startSearch().

QStringList HelpIndex::getWildcardTerms ( const QString &  term)
private

References dict, and split().

Referenced by query().

void HelpIndex::indexingEnd ( )
signal

Referenced by filterNext().

void HelpIndex::indexingProgress ( int  )
signal

Referenced by filterNext().

void HelpIndex::indexingStart ( int  )
signal

Referenced by makeIndex().

void HelpIndex::insertInDict ( const QString &  str,
int  docNum 
)
private

References dict, HelpIndex::Entry::documents, and e.

Referenced by parseDocument().

void HelpIndex::makeIndex ( )
void HelpIndex::parseDocument ( const QString &  filename,
int  docNum 
)
private

References c, getCharsetForDocument(), i, insertInDict(), j, and s.

Referenced by filterNext().

QStringList HelpIndex::query ( const QStringList &  terms,
const QStringList &  termSeq,
const QStringList &  seqWords 
)
void HelpIndex::readDict ( )
void HelpIndex::readDocumentList ( )
private

References docList, docListFile, f, s, and titleList.

Referenced by readDict().

bool HelpIndex::searchForPattern ( const QStringList &  patterns,
const QStringList &  words,
const QString &  fileName 
)
private

References a, buildMiniDict(), c, i, j, miniDict, s, and wordNum.

Referenced by query().

void HelpIndex::setDictionaryFile ( const QString &  f)

References dictFile, and f.

Referenced by help_module_init().

void HelpIndex::setDocList ( const QStringList &  lst)

References docList.

void HelpIndex::setDocListFile ( const QString &  f)

References docListFile, and f.

Referenced by help_module_init().

void HelpIndex::setLastWinClosed ( )
privateslot

References lastWindowClosed.

Referenced by HelpIndex().

void HelpIndex::setupDocumentList ( )
private

References d, docList, docPath, getDocumentTitle(), and titleList.

Referenced by makeIndex().

QVector< Document > HelpIndex::setupDummyTerm ( const QStringList &  terms)
private

References dict, Term::documents, HelpIndex::Entry::documents, e, and t().

Referenced by query().

QStringList HelpIndex::split ( const QString &  str)
private

References i, j, and l.

Referenced by getWildcardTerms().

const QStringList& HelpIndex::titlesList ( )
inline
void HelpIndex::writeDict ( )
void HelpIndex::writeDocumentList ( )
private

References docList, docListFile, f, s, and titleList.

Referenced by writeDict().

Member Data Documentation

bool HelpIndex::alreadyHaveDocList
private

Referenced by HelpIndex(), and makeIndex().

QHash<QString, Entry *> HelpIndex::dict
private
QString HelpIndex::dictFile
private
QStringList HelpIndex::docList
private
QString HelpIndex::docListFile
private
QString HelpIndex::docPath
private

Referenced by setupDocumentList().

QHash<QString, QString> HelpIndex::documentTitleCache
private

Referenced by getDocumentTitle().

bool HelpIndex::lastWindowClosed
private
int HelpIndex::m_iCurItem
private

Referenced by filterNext(), and makeIndex().

QTimer* HelpIndex::m_pTimer
private

Referenced by filterNext(), HelpIndex(), and makeIndex().

QHash<QString, PosEntry *> HelpIndex::miniDict
private

Referenced by buildMiniDict(), and searchForPattern().

QStringList HelpIndex::titleList
private
uint HelpIndex::wordNum
private

Referenced by buildMiniDict(), and searchForPattern().


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