Saving Parameters/Settings

Translations of this page:

Occasionally, settings have to be saved directly to the client so that they can be accessed at a later point in time or after a new launch of the application.

Usernames are a good example. After successful login, the username is saved at the client and is then used to populate the input field at the next launch of the application.

To handle the parameters or settings, the following methods are provided by the launcher:

public void setRegistryKey(String pKey, String pValue);
public String getRegistryKey(String pKey);

The saved values are dependent on the application in use and cannot be read by other applications.

Since the launcher is responsible for saving the data, the application does not need to consider technology dependencies.

We would usually have to differentiate between a launch of the application in a web browser, as web start (signed, not signed, html), or on the desktop to decide how data is saved. The web browser administers client data as cookies, and a desktop application either uses configuration files or the registry, depending on the operating system.

The application, and especially the developer, do not need to take these differences into consideration.

This website uses cookies for visitor traffic analysis. By using the website, you agree with storing the cookies on your computer.More information