Interface Config


public interface Config

Simple interface for raw application configuration values grouped in to sections, a la ini files, but abstracted a little.

  • Field Details

    • EMPTY

      static final Config EMPTY

      A config object that contains nothing and came from nowhere. Useful for testing and other situations where you don't need a complete config object but need something that won't implode when used.

  • Method Details

    • empty

      static Config empty(URI rootLocation)
      Parameters:
      rootLocation - the root location for the empty config
      Returns:
      an empty Config with the given root location
    • getRootLocation

      URI getRootLocation()
    • getSection

      Optional<ConfigSection> getSection(String name)

      Look up a particular section by name, returning empty if none exists

    • getAll

      List<ConfigSection> getAll()
      Returns:
      a list of all the configuration sections