KDevelop API Documentation

BackgroundParser Class Reference

#include <backgroundparser.h>

Inheritance diagram for BackgroundParser:

QThread QThread QThread QThread List of all members.

Public Member Functions

 BackgroundParser (ProblemReporter *reporter, const QString &source, const QString &filename)
virtual ~BackgroundParser ()
virtual void run ()
 BackgroundParser (CppSupportPart *, QWaitCondition *consumed)
virtual ~BackgroundParser ()
QMutexmutex ()
void lock ()
void unlock ()
QWaitConditioncanParse ()
QWaitConditionisEmpty ()
bool filesInQueue ()
void addFile (const QString &fileName, bool readFromDisk=false)
void removeFile (const QString &fileName)
void removeAllFiles ()
TranslationUnitASTtranslationUnit (const QString &fileName)
QValueList< Problemproblems (const QString &fileName)
void updateParserConfiguration ()
void close ()
virtual void run ()
 BackgroundParser (JavaSupportPart *, QWaitCondition *consumed)
virtual ~BackgroundParser ()
QMutexmutex ()
void lock ()
void unlock ()
QWaitConditioncanParse ()
QWaitConditionisEmpty ()
bool filesInQueue ()
void addFile (const QString &fileName, bool readFromDisk=false)
void removeFile (const QString &fileName)
void removeAllFiles ()
RefJavaAST translationUnit (const QString &fileName)
QValueList< Problemproblems (const QString &fileName)
void close ()
virtual void run ()
 BackgroundParser (ProblemReporter *reporter, const QString &source, const QString &filename)
virtual ~BackgroundParser ()
virtual void run ()

Protected Member Functions

UnitfindUnit (const QString &fileName)
UnitparseFile (const QString &fileName, bool readFromDisk, bool lock=false)
UnitfindUnit (const QString &fileName)
UnitparseFile (const QString &fileName, bool readFromDisk)

Private Attributes

ProblemReporterm_reporter
QString m_source
QString m_fileName
KDevDriverm_driver
QString m_currentFile
QWaitCondition m_canParse
QWaitCondition m_isEmpty
QWaitConditionm_consumed
QMutex m_mutex
SynchronizedFileListm_fileList
CppSupportPartm_cppSupport
bool m_close
QMap< QString, Unit * > m_unitDict
KDevDriverm_driver
QWaitConditionm_consumed
SynchronizedFileListm_fileList
JavaSupportPartm_javaSupport
QMap< QString, Unit * > m_unitDict
ProblemReporterm_reporter

Constructor & Destructor Documentation

BackgroundParser::BackgroundParser ProblemReporter reporter,
const QString source,
const QString filename
 

Definition at line 28 of file backgroundparser.cpp.

References BackgroundParser(), and length().

Referenced by BackgroundParser().

BackgroundParser::~BackgroundParser  )  [virtual]
 

Definition at line 37 of file backgroundparser.cpp.

BackgroundParser::BackgroundParser CppSupportPart ,
QWaitCondition consumed
 

Definition at line 183 of file backgroundparser.cpp.

References BackgroundParser(), m_cppSupport, m_driver, m_fileList, Driver::parseFile(), and Driver::setSourceProvider().

virtual BackgroundParser::~BackgroundParser  )  [virtual]
 

BackgroundParser::BackgroundParser JavaSupportPart ,
QWaitCondition consumed
 

Definition at line 182 of file backgroundparser.cpp.

References BackgroundParser(), m_driver, m_fileList, m_javaSupport, and Driver::setSourceProvider().

virtual BackgroundParser::~BackgroundParser  )  [virtual]
 

BackgroundParser::BackgroundParser ProblemReporter reporter,
const QString source,
const QString filename
 

virtual BackgroundParser::~BackgroundParser  )  [virtual]
 


Member Function Documentation

void BackgroundParser::addFile const QString fileName,
bool  readFromDisk = false
 

void BackgroundParser::addFile const QString fileName,
bool  readFromDisk = false
 

Definition at line 208 of file backgroundparser.cpp.

References addFile(), SynchronizedFileList::contains(), deepCopy(), m_canParse, m_fileList, and SynchronizedFileList::push_back().

Referenced by AddMethodDialog::accept(), AddAttributeDialog::accept(), addFile(), JavaSupportPart::partRemoved(), and CppSupportPart::partRemoved().

QWaitCondition& BackgroundParser::canParse  )  [inline]
 

Definition at line 53 of file backgroundparser.h.

References m_canParse.

QWaitCondition& BackgroundParser::canParse  )  [inline]
 

Definition at line 53 of file backgroundparser.h.

References m_canParse.

void BackgroundParser::close  ) 
 

void BackgroundParser::close  ) 
 

Definition at line 326 of file backgroundparser.cpp.

References m_canParse, m_close, and m_mutex.

Referenced by CppSupportPart::~CppSupportPart(), and JavaSupportPart::~JavaSupportPart().

bool BackgroundParser::filesInQueue  ) 
 

bool BackgroundParser::filesInQueue  ) 
 

Definition at line 333 of file backgroundparser.cpp.

References SynchronizedFileList::count(), m_currentFile, m_fileList, and m_mutex.

Unit* BackgroundParser::findUnit const QString fileName  )  [protected]
 

Unit * BackgroundParser::findUnit const QString fileName  )  [protected]
 

Definition at line 298 of file backgroundparser.cpp.

References findUnit(), and m_unitDict.

Referenced by findUnit(), problems(), removeFile(), and translationUnit().

QWaitCondition& BackgroundParser::isEmpty  )  [inline]
 

Definition at line 54 of file backgroundparser.h.

References m_isEmpty.

QWaitCondition& BackgroundParser::isEmpty  )  [inline]
 

Definition at line 54 of file backgroundparser.h.

References m_isEmpty.

void BackgroundParser::lock  )  [inline]
 

Definition at line 50 of file backgroundparser.h.

References m_mutex.

void BackgroundParser::lock  )  [inline]
 

Definition at line 50 of file backgroundparser.h.

References m_mutex.

Referenced by JavaSupportPart::customEvent(), CppSupportPart::recomputeCodeModel(), CppSupportPart::slotMakeMember(), and CppSupportPart::slotNeedTextHint().

QMutex& BackgroundParser::mutex  )  [inline]
 

Definition at line 49 of file backgroundparser.h.

References m_mutex.

QMutex& BackgroundParser::mutex  )  [inline]
 

Definition at line 49 of file backgroundparser.h.

References m_mutex.

Unit * BackgroundParser::parseFile const QString fileName,
bool  readFromDisk
[protected]
 

Definition at line 250 of file backgroundparser.cpp.

References SynchronizedFileList::contains(), endl(), Unit::fileName, SynchronizedFileList::isEmpty(), kdDebug(), m_currentFile, m_driver, m_fileList, m_isEmpty, m_javaSupport, m_unitDict, Driver::parseFile(), parseFile(), Driver::problems(), Unit::problems, RefJavaAST, Driver::remove(), Driver::sourceProvider(), Driver::takeTranslationUnit(), Unit::translationUnit, and translationUnit().

Unit * BackgroundParser::parseFile const QString fileName,
bool  readFromDisk,
bool  lock = false
[protected]
 

Definition at line 256 of file backgroundparser.cpp.

References Unit::fileName, SynchronizedFileList::isEmpty(), m_cppSupport, m_currentFile, m_driver, m_fileList, m_isEmpty, m_mutex, m_unitDict, TranslationUnitAST::Node, Driver::parseFile(), parseFile(), Driver::problems(), Unit::problems, Driver::remove(), Driver::removeAllMacrosInFile(), Driver::sourceProvider(), Driver::takeTranslationUnit(), Unit::translationUnit, and translationUnit().

Referenced by parseFile(), problems(), and translationUnit().

QValueList<Problem> BackgroundParser::problems const QString fileName  ) 
 

QValueList< Problem > BackgroundParser::problems const QString fileName  ) 
 

Definition at line 315 of file backgroundparser.cpp.

References findUnit(), m_fileList, parseFile(), Unit::problems, problems(), and SynchronizedFileList::remove().

Referenced by problems().

void BackgroundParser::removeAllFiles  ) 
 

void BackgroundParser::removeAllFiles  ) 
 

Definition at line 222 of file backgroundparser.cpp.

References SynchronizedFileList::clear(), endl(), kdDebug(), m_driver, m_fileList, m_isEmpty, m_mutex, m_unitDict, and Driver::reset().

Referenced by JavaSupportPart::projectClosed().

void BackgroundParser::removeFile const QString fileName  ) 
 

void BackgroundParser::removeFile const QString fileName  ) 
 

Definition at line 241 of file backgroundparser.cpp.

References findUnit(), SynchronizedFileList::isEmpty(), m_driver, m_fileList, m_isEmpty, m_mutex, m_unitDict, Driver::remove(), and removeFile().

Referenced by JavaSupportPart::partRemoved(), CppSupportPart::partRemoved(), JavaSupportPart::removedFilesFromProject(), CppSupportPart::removedFilesFromProject(), and removeFile().

virtual void BackgroundParser::run  )  [virtual]
 

virtual void BackgroundParser::run  )  [virtual]
 

virtual void BackgroundParser::run  )  [virtual]
 

void BackgroundParser::run  )  [virtual]
 

Definition at line 41 of file backgroundparser.cpp.

References AdaParser::compilation_unit(), endl(), AdaParser::initializeASTFactory(), kdDebug(), m_fileName, m_reporter, m_source, ProblemReporter::reportError(), AdaParser::resetErrors(), AdaLexer::resetErrors(), AdaParser::setProblemReporter(), and AdaLexer::setProblemReporter().

RefJavaAST BackgroundParser::translationUnit const QString fileName  ) 
 

RefJavaAST BackgroundParser::translationUnit const QString fileName  ) 
 

Definition at line 304 of file backgroundparser.cpp.

References findUnit(), m_fileList, parseFile(), SynchronizedFileList::remove(), Unit::translationUnit, and translationUnit().

Referenced by JavaSupportPart::customEvent(), parseFile(), CppSupportPart::recomputeCodeModel(), CppSupportPart::slotMakeMember(), CppSupportPart::slotNeedTextHint(), and translationUnit().

void BackgroundParser::unlock  )  [inline]
 

Definition at line 51 of file backgroundparser.h.

References m_mutex.

void BackgroundParser::unlock  )  [inline]
 

Definition at line 51 of file backgroundparser.h.

References m_mutex.

Referenced by JavaSupportPart::customEvent(), CppSupportPart::recomputeCodeModel(), CppSupportPart::slotMakeMember(), and CppSupportPart::slotNeedTextHint().

void BackgroundParser::updateParserConfiguration  ) 
 

Definition at line 340 of file backgroundparser.cpp.

References m_cppSupport, m_driver, m_mutex, Driver::parseFile(), Driver::removeAllMacrosInFile(), and CppSupportPart::specialHeaderName().

Referenced by CppSupportPart::updateParserConfiguration().


Member Data Documentation

QWaitCondition BackgroundParser::m_canParse [private]
 

Definition at line 76 of file backgroundparser.h.

Referenced by addFile(), canParse(), and close().

bool BackgroundParser::m_close [private]
 

Definition at line 82 of file backgroundparser.h.

Referenced by close().

QWaitCondition* BackgroundParser::m_consumed [private]
 

Definition at line 78 of file backgroundparser.h.

QWaitCondition* BackgroundParser::m_consumed [private]
 

Definition at line 79 of file backgroundparser.h.

CppSupportPart* BackgroundParser::m_cppSupport [private]
 

Definition at line 82 of file backgroundparser.h.

Referenced by BackgroundParser(), parseFile(), and updateParserConfiguration().

QString BackgroundParser::m_currentFile [private]
 

Definition at line 75 of file backgroundparser.h.

Referenced by filesInQueue(), and parseFile().

class KDevDriver* BackgroundParser::m_driver [private]
 

Definition at line 74 of file backgroundparser.h.

class KDevDriver* BackgroundParser::m_driver [private]
 

Definition at line 75 of file backgroundparser.h.

Referenced by BackgroundParser(), parseFile(), removeAllFiles(), removeFile(), and updateParserConfiguration().

SynchronizedFileList* BackgroundParser::m_fileList [private]
 

Definition at line 80 of file backgroundparser.h.

SynchronizedFileList* BackgroundParser::m_fileList [private]
 

Definition at line 81 of file backgroundparser.h.

Referenced by addFile(), BackgroundParser(), filesInQueue(), parseFile(), problems(), removeAllFiles(), removeFile(), and translationUnit().

QString BackgroundParser::m_fileName [private]
 

Definition at line 32 of file backgroundparser.h.

Referenced by run().

QWaitCondition BackgroundParser::m_isEmpty [private]
 

Definition at line 77 of file backgroundparser.h.

Referenced by isEmpty(), parseFile(), removeAllFiles(), and removeFile().

JavaSupportPart* BackgroundParser::m_javaSupport [private]
 

Definition at line 81 of file backgroundparser.h.

Referenced by BackgroundParser(), and parseFile().

QMutex BackgroundParser::m_mutex [private]
 

Definition at line 79 of file backgroundparser.h.

Referenced by close(), filesInQueue(), lock(), mutex(), parseFile(), removeAllFiles(), removeFile(), unlock(), and updateParserConfiguration().

ProblemReporter* BackgroundParser::m_reporter [private]
 

Definition at line 30 of file backgroundparser.h.

ProblemReporter* BackgroundParser::m_reporter [private]
 

Definition at line 32 of file backgroundparser.h.

Referenced by run().

QString BackgroundParser::m_source [private]
 

Definition at line 31 of file backgroundparser.h.

Referenced by run().

QMap<QString, Unit*> BackgroundParser::m_unitDict [private]
 

Definition at line 83 of file backgroundparser.h.

QMap<QString, Unit*> BackgroundParser::m_unitDict [private]
 

Definition at line 84 of file backgroundparser.h.

Referenced by findUnit(), parseFile(), removeAllFiles(), and removeFile().


The documentation for this class was generated from the following files:
KDE Logo
This file is part of the documentation for KDevelop Version 3.0.4.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Wed Oct 6 17:39:20 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003