Class ConfigLoader

java.lang.Object
no.ntnu.idatt1002.demo.ConfigLoader

public class ConfigLoader extends Object
Class for loading properties from a config file.
  • Field Details

  • Constructor Details

    • ConfigLoader

      private ConfigLoader()
  • Method Details

    • getInstance

      private static ConfigLoader getInstance()
    • load

      public static Properties load(String path)
      Loads properties from the config file.
      Parameters:
      path - The path to the config file.
      Returns:
      The properties.
    • getProperties

      public static Properties getProperties()
      Returns the properties.
      Returns:
      The properties.
    • setProperty

      public static void setProperty(String key, String value)
      Sets a specified property.
      Parameters:
      key - The key of the property.
      value - The value of the property.