TGUI
0.8.9
|
Helper functionality for filesystem access. More...
#include <TGUI/Filesystem.hpp>
Classes | |
class | Path |
Object to represent paths on a filesystem. More... | |
Static Public Member Functions | |
static bool | directoryExists (const Path &path) |
Checks if a directory exists. More... | |
static bool | directoryExists (const String &path) |
Checks if a directory exists. More... | |
static bool | fileExists (const Path &path) |
Checks if a file exists. More... | |
static bool | fileExists (const String &path) |
Checks if a file exists. More... | |
static bool | createDirectory (const Path &path) |
Create a directory. More... | |
static bool | createDirectory (const String &path) |
Create a directory. More... | |
static Path | getLocalDataDirectory () |
Returns the directory to store application data. More... | |
Helper functionality for filesystem access.
When TGUI is built with c++17 support then std::filesystem is used on newer compilers. Otherwise, POSIX or Windows-specific code is used to implement the functionality.
|
static |
Create a directory.
Path | to the directory to create |
This function will fail if the parent directory doesn't exist. It won't try to recursively create the directory.
|
inlinestatic |
Create a directory.
Path | to the directory to create |
This function will fail if the parent directory doesn't exist. It won't try to recursively create the directory.
|
static |
Checks if a directory exists.
Path | to the directory to check |
|
inlinestatic |
Checks if a directory exists.
Path | to the directory to check |
|
static |
Checks if a file exists.
Path | to the file to check |
|
inlinestatic |
Checks if a file exists.
Path | to the file to check |
|
static |
Returns the directory to store application data.
On Windows, this returns the value of LOCALAPPDATA% On macOS, this returns $HOME/Library/Application Support On Linux and other platforms, this returns $HOME/.local/share