Interface Configuration

All Known Implementing Classes:
AbstractConfiguration

public interface Configuration
Represents a configuration for a holder that can be saved and loaded. Always related to a Configurable
  • Method Summary

    Modifier and Type
    Method
    Description
    Get the holder of this configuration.
    default void
    load(org.bukkit.configuration.ConfigurationSection config)
    Loads the data from the configuration section into this configuration.
    default void
    save(org.bukkit.configuration.ConfigurationSection config)
    Saves the data from this configuration into the provided configuration section.
    default void
    whenLoaded(org.bukkit.configuration.ConfigurationSection config)
    Called when a configuration has been loaded.
    default void
    whenSaved(org.bukkit.configuration.ConfigurationSection config)
    Called when a configuration has been saved.
  • Method Details

    • getConfigurable

      Configurable<?> getConfigurable()
      Get the holder of this configuration. Aka. the configurable.
      Returns:
      The configurable.
    • whenLoaded

      default void whenLoaded(org.bukkit.configuration.ConfigurationSection config)
      Called when a configuration has been loaded. Used to, for example, fill additional fields and data.
      Parameters:
      config - The configuration section.
    • whenSaved

      default void whenSaved(org.bukkit.configuration.ConfigurationSection config)
      Called when a configuration has been saved. Used to, for example, save additional fields and data.
      Parameters:
      config - The configuration section.
    • load

      default void load(org.bukkit.configuration.ConfigurationSection config)
      Loads the data from the configuration section into this configuration.
      Parameters:
      config - The configuration section.
    • save

      default void save(org.bukkit.configuration.ConfigurationSection config)
      Saves the data from this configuration into the provided configuration section.
      Parameters:
      config - The configuration section.