2013-10-24 17:08:58 +02:00
|
|
|
#ifndef CONCORDIA_CONFIG_HDR
|
|
|
|
#define CONCORDIA_CONFIG_HDR
|
|
|
|
|
|
|
|
#include <string>
|
|
|
|
#include <list>
|
|
|
|
#include <libconfig.h++>
|
|
|
|
|
|
|
|
#include "concordia/concordia_exception.hpp"
|
|
|
|
|
|
|
|
using namespace std;
|
|
|
|
using namespace libconfig;
|
|
|
|
|
|
|
|
/*!
|
|
|
|
Class representing the Concordia configuration.
|
|
|
|
*/
|
|
|
|
class ConcordiaConfig {
|
|
|
|
public:
|
|
|
|
/*!
|
|
|
|
Constructor.
|
|
|
|
\param configFilePath path of the configuration file (see \ref running3 for file specification).
|
|
|
|
\throws ConcordiaException
|
|
|
|
*/
|
|
|
|
explicit ConcordiaConfig(const string & configFilePath)
|
|
|
|
throw(ConcordiaException);
|
|
|
|
|
|
|
|
/*! Destructor.
|
|
|
|
*/
|
|
|
|
virtual ~ConcordiaConfig();
|
|
|
|
|
|
|
|
/*! Getter for the puddle file path parameter.
|
|
|
|
\returns file path of the puddle tagset
|
|
|
|
*/
|
|
|
|
string & getPuddleTagsetFilePath() {
|
|
|
|
return _puddleTagsetFilePath;
|
|
|
|
}
|
|
|
|
|
2013-11-28 16:47:57 +01:00
|
|
|
string & getWordMapFilePath() {
|
|
|
|
return _wordMapFilePath;
|
|
|
|
}
|
|
|
|
|
|
|
|
string & getHashedIndexFilePath() {
|
|
|
|
return _hashedIndexFilePath;
|
|
|
|
}
|
|
|
|
|
2014-02-20 10:49:17 +01:00
|
|
|
string & getMarkersFilePath() {
|
|
|
|
return _markersFilePath;
|
|
|
|
}
|
|
|
|
|
2013-11-28 16:47:57 +01:00
|
|
|
string & getSuffixArrayFilePath() {
|
|
|
|
return _suffixArrayFilePath;
|
|
|
|
}
|
|
|
|
|
2014-04-29 14:46:04 +02:00
|
|
|
string & getHtmlTagsFilePath() {
|
|
|
|
return _htmlTagsFilePath;
|
|
|
|
}
|
|
|
|
|
|
|
|
string & getSpaceSymbolsFilePath() {
|
|
|
|
return _spaceSymbolsFilePath;
|
|
|
|
}
|
|
|
|
|
|
|
|
string & getStopWordsFilePath() {
|
|
|
|
return _stopWordsFilePath;
|
|
|
|
}
|
|
|
|
|
|
|
|
string & getNamedEntitiesFilePath() {
|
|
|
|
return _namedEntitiesFilePath;
|
|
|
|
}
|
|
|
|
|
|
|
|
string & getStopSymbolsFilePath() {
|
|
|
|
return _stopSymbolsFilePath;
|
|
|
|
}
|
|
|
|
|
2013-10-24 17:08:58 +02:00
|
|
|
private:
|
|
|
|
Config _config;
|
|
|
|
|
|
|
|
string _puddleTagsetFilePath;
|
|
|
|
|
2013-11-28 16:47:57 +01:00
|
|
|
string _wordMapFilePath;
|
|
|
|
|
|
|
|
string _hashedIndexFilePath;
|
|
|
|
|
2014-02-20 10:49:17 +01:00
|
|
|
string _markersFilePath;
|
|
|
|
|
2013-11-28 16:47:57 +01:00
|
|
|
string _suffixArrayFilePath;
|
|
|
|
|
2014-04-29 14:46:04 +02:00
|
|
|
string _htmlTagsFilePath;
|
|
|
|
|
|
|
|
string _spaceSymbolsFilePath;
|
|
|
|
|
|
|
|
string _stopWordsFilePath;
|
|
|
|
|
|
|
|
string _namedEntitiesFilePath;
|
|
|
|
|
|
|
|
string _stopSymbolsFilePath;
|
|
|
|
|
2013-10-24 17:08:58 +02:00
|
|
|
string _readConfigParameterStr(const string & name)
|
|
|
|
throw(ConcordiaException);
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|