Class SettingsMatcher


  • public class SettingsMatcher
    extends Object
    This class provides a utility function that transforms strings to replace embedded settings with the current values of the setting.
    • Constructor Detail

      • SettingsMatcher

        public SettingsMatcher()
    • Method Detail

      • replaceSettings

        public static String replaceSettings​(String input)
        Replace all settings variables with their values. This function takes the input string and looks for all settings that are embedded in the string and replaces those settings with the value of that setting. E.g., given a string "The survey is $survey and the scale is $scale." the method will look for the settings survey and scale and in the global Settings and replace these substrings with their current values. E.g., the previous might return with "The survey is Digitized Sky Survey and the scale is 0.00133." If a setting has multiple values, only the first is used. If no value is found for the setting, then the text is left unchanged.
      • main

        public static void main​(String[] args)