hgl 0.5.25
A compiler/interpreter suite for developing images
Static Public Member Functions | List of all members
HGL::Common::Util Class Reference

Miscellaneous utility functions. More...

#include "util.h"

Inheritance diagram for HGL::Common::Util:
[legend]

Static Public Member Functions

static std::string const * getConfigValue (const std::string &key)
 Gets a value from the configuration file. More...
 
static void logWarningCount ()
 Logs the amount of WARNINGs already issued.
 
static std::string & suffixAppender (const char *suffix, std::string &oFile)
 Appends a suffix to a filename. More...
 

Detailed Description

Miscellaneous utility functions.

Author
Heiko Schäfer heiko.nosp@m.@hgl.nosp@m..rang.nosp@m.un.d.nosp@m.e

Member Function Documentation

std::string const * Util::getConfigValue ( const std::string &  key)
static

Gets a value from the configuration file.

Parameters
keythe key to search the config value for
Returns
a pointer to the value or NULL if there is no such value for key
std::string & Util::suffixAppender ( const char *  suffix,
std::string &  oFile 
)
static

Appends a suffix to a filename.

The suffix is appended to ofile if it hasn't already that suffix. The comparision if ofile already has suffix appended is done case insensitively.

Parameters
[in]suffixthe suffix to append
[in,out]oFilethe filename to append suffix to
Returns
oFile with suffix appended
Since
0.5.18