Public Types | Static Public Member Functions

ParserFactory Class Reference

Factory for the parsers. More...

#include <parserfactory.hpp>

List of all members.

Public Types

enum  FileType { Invalid = 0, XML = 1, ODT = 2 }
 

File types to parse.

More...
typedef QHash< FileType, int > TypeCountMap
 Map for counting each file type total files.

Static Public Member Functions

static FileType fileType (const QString &fileName)
 Returns the file type depending on the file extension.
static void initializeTypeCountMap (TypeCountMap &map)
 Initializes the map to zero for each file type.
static AbstractParsernewParser (FileType fileType, IndexingProgress &indexingProgress, DocumentList &documentList, OptionManager &optionManager, GlobalParserDatabase &globalDatabase)
 Returns the parser for the given file type.

Detailed Description

Factory for the parsers.


Member Typedef Documentation

Map for counting each file type total files.


Member Enumeration Documentation

File types to parse.

Enumerator:
Invalid 
XML 
ODT 

Member Function Documentation

ParserFactory::FileType ParserFactory::fileType ( const QString &  fileName  )  [static]

Returns the file type depending on the file extension.

void ParserFactory::initializeTypeCountMap ( ParserFactory::TypeCountMap map  )  [static]

Initializes the map to zero for each file type.

AbstractParser * ParserFactory::newParser ( ParserFactory::FileType  fileType,
IndexingProgress indexingProgress,
DocumentList documentList,
OptionManager optionManager,
GlobalParserDatabase globalDatabase 
) [static]

Returns the parser for the given file type.

Exceptions:
Exception if file type is unknown or has no parser
All Classes Functions Variables Typedefs Enumerations Enumerator