#include <Utils.h>
Contains possibly useful functions, that don't fit anywhere else. More...
Contains possibly useful functions, that don't fit anywhere else.
Static Public Member Functions | |
static std::wstring | widenString (const std::string &s)=delete |
Convert a string to a wstring. More... | |
static std::string | narrowString (const std::wstring &ws)=delete |
Convert a wstring to a string. More... | |
static std::string | downcaseString (const std::string &s)=delete |
Convert a string to lower case. More... | |
static std::string | upcaseString (const std::string &s)=delete |
Convert a string to upper case. More... | |
static const std::string & | getExecutablePath () |
Get the path of the executable that is currently running. More... | |
static const std::string & | getExecutableDirectory () |
Get the path to the directory of the executable that is currently running. More... | |
static const std::string & | getUserLocalDirectory () |
Get the path to the current user local config directory. More... | |
static const std::string & | getSofaUserLocalDirectory () |
Get the path to the SOFA directory into the current user local config directory. More... | |
static const std::string & | getSofaPathPrefix () |
Get the path to the "root" path of Sofa (i.e. the build directory or the installation prefix). More... | |
static const std::string | getSofaPathTo (const std::string &pathFromBuildDir) |
Construct a path based on the build dir path of Sofa. More... | |
static std::map< std::string, std::string > | readBasicIniFile (const std::string &path) |
Read a file written in a very basic ini-like format. More... | |
|
staticdelete |
Convert a string to lower case.
|
static |
Get the path to the directory of the executable that is currently running.
|
static |
Get the path of the executable that is currently running.
Note that this function uses various non-portable tricks to achieve its goal, and it might not be the most reliable thing ever written.
|
static |
Get the path to the "root" path of Sofa (i.e. the build directory or the installation prefix).
|
static |
Construct a path based on the build dir path of Sofa.
|
static |
Get the path to the SOFA directory into the current user local config directory.
|
static |
Get the path to the current user local config directory.
|
staticdelete |
Convert a wstring to a string.
|
static |
Read a file written in a very basic ini-like format.
For each line that contains a '=' character, (e.g. "key=value"), the returned map will contains a pair <"key", "value">. Other lines will be ignored.
|
staticdelete |
Convert a string to upper case.
|
staticdelete |
Convert a string to a wstring.