122 void addValue(
const char *v) { m_value.append(v); }
128 void init() { m_value.clear(); }
147 void addValue(
const char *v) { m_valueRange.append(v); }
155 void init() { m_value = m_defValue.copy(); }
185 void init() { m_value = m_defValue.copy(); }
215 void init() { m_value = m_defValue; }
243 void init() { m_value = m_defValue; }
274 #define Config_getString(val) Config::instance()->getString(__FILE__,__LINE__,val) 275 #define Config_getInt(val) Config::instance()->getInt(__FILE__,__LINE__,val) 276 #define Config_getList(val) Config::instance()->getList(__FILE__,__LINE__,val) 277 #define Config_getEnum(val) Config::instance()->getEnum(__FILE__,__LINE__,val) 278 #define Config_getBool(val) Config::instance()->getBool(__FILE__,__LINE__,val) 301 if (m_instance==0) m_instance =
new Config;
334 QStrList &getList(
const char *fileName,
int num,
const char *name)
const;
340 QCString &getEnum(
const char *fileName,
int num,
const char *name)
const;
346 int &getInt(
const char *fileName,
int num,
const char *name)
const;
352 bool &getBool(
const char *fileName,
int num,
const char *name)
const;
359 return m_dict->find(name);
374 m_options->append(result);
385 m_options->append(result);
386 m_dict->insert(name,result);
399 m_options->append(result);
400 m_dict->insert(name,result);
411 m_options->append(result);
412 m_dict->insert(name,result);
423 int minVal,
int maxVal,
int defVal)
426 m_options->append(result);
427 m_dict->insert(name,result);
440 m_options->append(result);
441 m_dict->insert(name,result);
448 m_dict->insert(name,option);
449 m_obsolete->append(option);
456 m_dict->insert(name,option);
457 m_disabled->append(option);
468 void setHeader(
const char *header) { m_header = header; }
482 void substituteEnvironmentVars();
497 bool parseString(
const char *
fn,
const char *
str,
bool upd =
FALSE);
503 bool parse(
const char *fn,
bool upd =
FALSE);
548 m_dict =
new QDict<ConfigOption>(257);
550 m_obsolete->setAutoDelete(
TRUE);
551 m_disabled->setAutoDelete(
TRUE);
552 m_initialized =
FALSE;
564 void checkFileName(
const char *);
QList< ConfigOption > * m_disabled
static Config * m_instance
void setEncoding(const QCString &e)
void writeBoolValue(FTextStream &t, bool v)
ConfigList * addList(const char *name, const char *doc)
The QRegExp class provides pattern matching using regular expressions or wildcards.
ConfigInfo(const char *name, const char *doc)
ConfigInfo * addInfo(const char *name, const char *doc)
void setHeader(const char *header)
QCString * valueStringRef()
void writeStringValue(FTextStream &t, QCString &s)
void setWidgetType(WidgetType w)
void writeStringList(FTextStream &t, QStrList &l)
QDict< ConfigOption > * m_dict
void addValue(const char *v)
ConfigBool * addBool(const char *name, const char *doc, bool defVal)
ConfigOption(OptionType t)
Simplified and optimized version of QTextStream.
QStrListIterator iterator()
ConfigString * addString(const char *name, const char *doc)
QCString takeStartComment()
QList< ConfigOption > * m_options
QList< ConfigOption > * m_obsolete
bool check(const std::vector< std::vector< float > > &outputs)
ConfigDisabled(const char *name)
virtual void convertStrToVal()
ConfigEnum * addEnum(const char *name, const char *doc, const char *defVal)
void writeIntValue(FTextStream &t, int i)
ConfigObsolete(const char *name)
void setWidgetType(WidgetType w)
JAVACC_STRING_TYPE String
WidgetType widgetType() const
static void deleteInstance()
virtual void substEnvVars()=0
void setValueString(const QCString &v)
ConfigList(const char *name, const char *doc)
static Config * instance()
void appendUserComment(const QCString &u)
ConfigOption * addDisabled(const char *name)
ConfigInt(const char *name, const char *doc, int minVal, int maxVal, int defVal)
void addDependency(const char *dep)
ConfigString(const char *name, const char *doc)
bool fill(char c, int len=-1)
void setDefaultValue(const char *v)
QInternalListIterator< char > QStrListIterator
QCString dependsOn() const
ConfigOption * addObsolete(const char *name)
QListIterator< ConfigOption > iterator()
WidgetType widgetType() const
ConfigBool(const char *name, const char *doc, bool defVal)
void setAutoDelete(bool enable)
QCString takeUserComment()
ConfigInt * addInt(const char *name, const char *doc, int minVal, int maxVal, int defVal)
QCString & replace(uint index, uint len, const char *s)
void addValue(const char *v)
void appendStartComment(const QCString &u)
virtual void writeTemplate(FTextStream &t, bool sl, bool upd)=0
ConfigEnum(const char *name, const char *doc, const char *defVal)
void setUserComment(const QCString &u)
QCString * valueStringRef()