/* * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at https://mozilla.org/MPL/2.0/. */ #pragma once #include #include namespace OpenVulkano { class AppFolders { static AppFolders INSTANCE; std::filesystem::path appDataHome, appConfigHome, appState, appDataCache, appTemp; AppFolders(std::string_view appName); AppFolders(const std::filesystem::path& dir, std::optional appName); public: static void Init(std::string_view appName); static void Init(const std::filesystem::path& dir, std::optional appName); [[nodiscard]] static const std::filesystem::path& GetAppDataHomeDir(); [[nodiscard]] static const std::filesystem::path& GetAppConfigHomeDir(); [[nodiscard]] static const std::filesystem::path& GetAppStateDir(); [[nodiscard]] static const std::filesystem::path& GetAppCacheDir(); [[nodiscard]] static const std::filesystem::path& GetAppTempDir(); }; }