Package lu.kbra.modelizer_next.common
Class App
java.lang.Object
lu.kbra.modelizer_next.common.App
Application-wide constants, directories, mapper setup, and metadata used by the desktop client.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidEnsures that the dirs exists exists or is up to date.static FileReturns the application directory.static FileReturns the config file.static FileReturns the styles directory.static FileReturns the update downloads directory.static voidinit()Initializes shared state required before the object is used.static voidLoads the config.static voidSaves the config.static StringBuilds the application window title from the app metadata.
-
Field Details
-
JSON
public static com.fasterxml.jackson.databind.JsonNode JSON -
NAME
-
DESCRIPTION
-
VERSION
-
DISTRIBUTOR
-
PORTABLE
public static boolean PORTABLE -
ISSUES_URL
-
WEBSITE_URL
-
ENTRY_POINT
-
AUTHOR_WEBSITE_URL
-
CONFIG
-
-
Constructor Details
-
App
public App()
-
-
Method Details
-
ensureDirsExists
public static void ensureDirsExists()Ensures that the dirs exists exists or is up to date. -
getAppDirectory
Returns the application directory.- Returns:
- the application directory
-
getConfigFile
Returns the config file.- Returns:
- the config file
-
getStylesDirectory
Returns the styles directory.- Returns:
- the styles directory
-
getUpdateDownloadsDirectory
Returns the update downloads directory.- Returns:
- the update downloads directory
-
init
public static void init() throws com.fasterxml.jackson.core.JsonProcessingExceptionInitializes shared state required before the object is used.- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the operation cannot be completed
-
loadConfig
public static void loadConfig()Loads the config. -
saveConfig
public static void saveConfig()Saves the config. -
title
Builds the application window title from the app metadata.- Parameters:
title- title text to display- Returns:
- the title result
-