|
Fray Engine
|
Classes | |
| class | StateManager |
| Owns a SQLite connection and a typed key/value state table. Database operations serialize on a recursive mutex; the attached FileManager is borrowed, not owned. More... | |
Functions | |
| F_err | readApplicationLocation (const std::filesystem::path &directory, std::filesystem::path &result) |
| Reads the selected application database path, if one has been recorded. | |
| F_err | writeApplicationFile (const std::filesystem::path &directory, const std::string &filename, const std::string &value, bool replaceExisting=true) |
| Atomically replaces a named application-owned file. | |
| F_err | writeApplicationLocation (const std::filesystem::path &directory, const std::filesystem::path &database) |
| Atomically records the selected application database path. | |
Variables | |
| constexpr const char * | applicationLocationFile = "Fray.application-database" |
| Name of the Engine-adjacent file identifying the selected application database. | |
|
inline |
Reads the selected application database path, if one has been recorded.
| directory | Engine directory containing the location file. |
| result | Receives an absolute path, or an empty path when no choice is saved. |
Definition at line 40 of file application_state_location.hpp.
|
inline |
Atomically replaces a named application-owned file.
| directory | Existing directory containing the file. |
| filename | Simple file name within the directory. |
| value | Complete file contents. |
| replaceExisting | Replace an existing file; otherwise leave it untouched. |
Definition at line 91 of file application_state_location.hpp.
|
inline |
Atomically records the selected application database path.
| directory | Engine directory containing the location file. |
| database | Absolute application database path. |
Definition at line 204 of file application_state_location.hpp.
|
inlineconstexpr |
Name of the Engine-adjacent file identifying the selected application database.
Definition at line 32 of file application_state_location.hpp.