Interface FileConfigObjectProvider

All Superinterfaces:
ConfigObjectProvider
All Known Implementing Classes:
DefaultFileConfigObjectProvider, NoOpFileConfigObjectProvider

public interface FileConfigObjectProvider extends ConfigObjectProvider
Used to persist config objects to/from disk.
  • Method Details

    • initialize

      void initialize(Path dataPath)
      Initializes the provider with a data path to persist config objects to.
      Parameters:
      dataPath - The data path to persist config objects to.
    • registerChangeCallback

      void registerChangeCallback(String name, Consumer<String> callback)
      Registers a callback for when the configuration has changed.
      Parameters:
      name - Name of the configuration object you're interested in.
      callback - Callback function that takes the name as its only parameter.
    • unregisterChangeCallback

      void unregisterChangeCallback(String name)
      Unregisters a callback previously registered.
      Parameters:
      name - Name of the configuration object you're interested in.