Class ReadOnlyPrefs

java.lang.Object
VASSAL.preferences.ReadOnlyPrefs

public class ReadOnlyPrefs extends Object
A simple preferences class which permits reading stored values.
Since:
3.1.0
Author:
Joel Uckelman
  • Field Details

    • storedValues

      protected Properties storedValues
  • Constructor Details

    • ReadOnlyPrefs

      public ReadOnlyPrefs(String name)
      Parameters:
      name - the module name of the preferences to read
    • ReadOnlyPrefs

      protected ReadOnlyPrefs(File file)
  • Method Details

    • getStoredValue

      public String getStoredValue(String key)
      Return the value of a given preference.
      Parameters:
      key - the name of the preference to retrieve
      Returns:
      the value of this option in the Preferences file, or null if undefined
    • getGlobalPrefs

      public static ReadOnlyPrefs getGlobalPrefs()
      Return the module-independent global preferences.
      Returns:
      a global preferences object