add some methods to Poco::Path for make it easy to follow XDG Base Directory Specification

This commit is contained in:
Björn Schramke
2014-10-09 09:46:21 +02:00
parent ef34c21e91
commit ce56190f9f
6 changed files with 178 additions and 0 deletions

View File

@@ -291,9 +291,37 @@ public:
static std::string home();
/// Returns the user's home directory.
static std::string configHome();
/// Returns the user's config directory.
///
/// On Unix systems, this is the '~/.config/'. On Windows systems,
/// this is '%APPDATA%'.
static std::string dataHome();
/// Returns the user's data directory.
///
/// On Unix systems, this is the '~/.local/share/'. On Windows systems,
/// this is '%APPDATA%'.
static std::string tempHome();
/// Returns the user's temp directory.
///
/// On Unix systems, this is the '~/.local/temp/'.
static std::string cacheHome();
/// Returns the user's cache directory.
///
/// On Unix systems, this is the '~/.cache/'. On Windows systems,
/// this is '%APPDATA%'.
static std::string temp();
/// Returns the temporary directory.
static std::string config();
/// Returns the systemwide config directory.
///
/// On Unix systems, this is the '/etc/'.
static std::string null();
/// Returns the name of the null device.