![]() |
SudokuFX
|
Centralized registry of application-specific paths, both internal (classpath) and system-level. More...
Collaboration diagram for fr.softsf.sudokufx.common.enums.AppPaths:Public Member Functions | |
| AppPaths (final String path) | |
| final String | getPath () |
Public Attributes | |
| CONFIG_LOGBACK_INVALID_PATH_FOR_TESTS =("/invalid/path") | |
| CONFIG_LOGBACK_PATH =("/fr/softsf/sudokufx/config/logback.xml") | |
| DATA_FOLDER =("data-sudokufx") | |
| DATABASE_MIGRATION_PATH =("/fr/softsf/sudokufx/flyway/scripts/hsqldb/migration") | |
| DATABASE_NAME =("sudokufxdb") | |
| I18N_PATH =("fr/softsf/sudokufx/i18n/resource") | |
| LINUX_BASE_PATH =(resolveXdgDataHome()) | |
| LINUX_SUDO_FX_BASE_PATH =(LINUX_BASE_PATH.getPath() + "/Soft64.fr/SudokuFX/") | |
| LINUX_SUPPOSED_DATA_FOLDER_FOR_SUDO_FX | |
| LINUX_SUPPOSED_LOGS_FOLDER_FOR_SUDO_FX | |
| LOGO_SUDO_PNG_PATH =("/fr/softsf/sudokufx/images/stage-icon.png") | |
| LOGS_FILE_NAME_PATH =("/SudokuFX.log") | |
| LOGS_FOLDER =("logs-sudokufx") | |
| MACOS_BASE_PATH =("/Library/Application Support/Soft64.fr/SudokuFX/") | |
| MACOS_SUDO_FX_BASE_PATH =(USER_HOME.getPath() + MACOS_BASE_PATH.getPath()) | |
| MACOS_SUPPOSED_DATA_FOLDER_FOR_SUDO_FX | |
| MACOS_SUPPOSED_LOGS_FOLDER_FOR_SUDO_FX | |
| RESOURCES_CSS_ALERT_PATH =("/fr/softsf/sudokufx/style/alert.css") | |
| RESOURCES_CSS_PATH =("/fr/softsf/sudokufx/style/style.css") | |
| RESOURCES_FXML_PATH =("/fr/softsf/sudokufx/fxml/") | |
| USER_HOME =(resolveUserHome()) | |
| WINDOWS_BASE_PATH =("/AppData/Local/Soft64.fr/SudokuFX/") | |
| WINDOWS_SUDO_FX_BASE_PATH =(USER_HOME.getPath() + WINDOWS_BASE_PATH.getPath()) | |
| WINDOWS_SUPPOSED_DATA_FOLDER_FOR_SUDO_FX | |
| WINDOWS_SUPPOSED_LOGS_FOLDER_FOR_SUDO_FX | |
Static Private Member Functions | |
| static String | resolveUserHome () |
| Returns the user's home directory with forward slashes, for consistent path concatenation. | |
| static String | resolveXdgDataHome () |
| Resolves the user-specific data directory according to the XDG Base Directory Specification. | |
Private Attributes | |
| final String | path |
Centralized registry of application-specific paths, both internal (classpath) and system-level.
All paths are expressed as POSIX-style strings for consistency across platforms. System paths are dynamically resolved at runtime, including XDG-compliant locations on Linux.
| fr.softsf.sudokufx.common.enums.AppPaths.AppPaths | ( | final String | path | ) |
| final String fr.softsf.sudokufx.common.enums.AppPaths.getPath | ( | ) |
|
staticprivate |
Returns the user's home directory with forward slashes, for consistent path concatenation.
|
staticprivate |
Resolves the user-specific data directory according to the XDG Base Directory Specification.
If the environment variable XDG_DATA_HOME is defined and non-empty, its value is used as the base directory for application data. Otherwise, the fallback is returned, ensuring compatibility with Linux systems that follow the XDG standard.
$HOME/.local/share
Backslashes are replaced with forward slashes to ensure consistent path formatting across operating systems, especially for string-based path composition.
String representing the resolved data directory path in POSIX format
Here is the call graph for this function:| fr.softsf.sudokufx.common.enums.AppPaths.CONFIG_LOGBACK_INVALID_PATH_FOR_TESTS =("/invalid/path") |
| fr.softsf.sudokufx.common.enums.AppPaths.CONFIG_LOGBACK_PATH =("/fr/softsf/sudokufx/config/logback.xml") |
| fr.softsf.sudokufx.common.enums.AppPaths.DATA_FOLDER =("data-sudokufx") |
| fr.softsf.sudokufx.common.enums.AppPaths.DATABASE_MIGRATION_PATH =("/fr/softsf/sudokufx/flyway/scripts/hsqldb/migration") |
| fr.softsf.sudokufx.common.enums.AppPaths.DATABASE_NAME =("sudokufxdb") |
| fr.softsf.sudokufx.common.enums.AppPaths.I18N_PATH =("fr/softsf/sudokufx/i18n/resource") |
| fr.softsf.sudokufx.common.enums.AppPaths.LINUX_BASE_PATH =(resolveXdgDataHome()) |
| fr.softsf.sudokufx.common.enums.AppPaths.LINUX_SUDO_FX_BASE_PATH =(LINUX_BASE_PATH.getPath() + "/Soft64.fr/SudokuFX/") |
| fr.softsf.sudokufx.common.enums.AppPaths.LINUX_SUPPOSED_DATA_FOLDER_FOR_SUDO_FX |
| fr.softsf.sudokufx.common.enums.AppPaths.LINUX_SUPPOSED_LOGS_FOLDER_FOR_SUDO_FX |
| fr.softsf.sudokufx.common.enums.AppPaths.LOGO_SUDO_PNG_PATH =("/fr/softsf/sudokufx/images/stage-icon.png") |
| fr.softsf.sudokufx.common.enums.AppPaths.LOGS_FILE_NAME_PATH =("/SudokuFX.log") |
| fr.softsf.sudokufx.common.enums.AppPaths.LOGS_FOLDER =("logs-sudokufx") |
| fr.softsf.sudokufx.common.enums.AppPaths.MACOS_BASE_PATH =("/Library/Application Support/Soft64.fr/SudokuFX/") |
| fr.softsf.sudokufx.common.enums.AppPaths.MACOS_SUDO_FX_BASE_PATH =(USER_HOME.getPath() + MACOS_BASE_PATH.getPath()) |
| fr.softsf.sudokufx.common.enums.AppPaths.MACOS_SUPPOSED_DATA_FOLDER_FOR_SUDO_FX |
| fr.softsf.sudokufx.common.enums.AppPaths.MACOS_SUPPOSED_LOGS_FOLDER_FOR_SUDO_FX |
|
private |
| fr.softsf.sudokufx.common.enums.AppPaths.RESOURCES_CSS_ALERT_PATH =("/fr/softsf/sudokufx/style/alert.css") |
| fr.softsf.sudokufx.common.enums.AppPaths.RESOURCES_CSS_PATH =("/fr/softsf/sudokufx/style/style.css") |
| fr.softsf.sudokufx.common.enums.AppPaths.RESOURCES_FXML_PATH =("/fr/softsf/sudokufx/fxml/") |
| fr.softsf.sudokufx.common.enums.AppPaths.USER_HOME =(resolveUserHome()) |
| fr.softsf.sudokufx.common.enums.AppPaths.WINDOWS_BASE_PATH =("/AppData/Local/Soft64.fr/SudokuFX/") |
| fr.softsf.sudokufx.common.enums.AppPaths.WINDOWS_SUDO_FX_BASE_PATH =(USER_HOME.getPath() + WINDOWS_BASE_PATH.getPath()) |
| fr.softsf.sudokufx.common.enums.AppPaths.WINDOWS_SUPPOSED_DATA_FOLDER_FOR_SUDO_FX |
| fr.softsf.sudokufx.common.enums.AppPaths.WINDOWS_SUPPOSED_LOGS_FOLDER_FOR_SUDO_FX |