Class YmlConfiguration

java.lang.Object
org.bukkit.configuration.MemorySection
org.bukkit.configuration.MemoryConfiguration
org.bukkit.configuration.file.FileConfiguration
org.bukkit.configuration.file.YamlConfiguration
dk.lockfuglsang.minecraft.yml.YmlConfiguration
All Implemented Interfaces:
org.bukkit.configuration.Configuration, org.bukkit.configuration.ConfigurationSection

public class YmlConfiguration extends org.bukkit.configuration.file.YamlConfiguration
A YamlConfiguration that supports comments Note: This includes a VERY SIMPLISTIC Yaml-parser, which sole purpose is to detect and store comments.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addComment​(String path, String comment)
     
    void
    addComments​(Map<String,​String> comments)
     
     
     
     
    void
    loadFromString​(String contents)
     
     

    Methods inherited from class org.bukkit.configuration.file.YamlConfiguration

    loadConfiguration, loadConfiguration, options

    Methods inherited from class org.bukkit.configuration.file.FileConfiguration

    load, load, load, save, save

    Methods inherited from class org.bukkit.configuration.MemoryConfiguration

    addDefault, addDefaults, addDefaults, getDefaults, getParent, setDefaults

    Methods inherited from class org.bukkit.configuration.MemorySection

    contains, contains, createPath, createPath, createSection, createSection, get, get, getBoolean, getBoolean, getBooleanList, getByteList, getCharacterList, getColor, getColor, getConfigurationSection, getCurrentPath, getDefaultSection, getDouble, getDouble, getDoubleList, getFloatList, getInt, getInt, getIntegerList, getItemStack, getItemStack, getKeys, getList, getList, getLocation, getLocation, getLong, getLong, getLongList, getMapList, getName, getObject, getObject, getOfflinePlayer, getOfflinePlayer, getRoot, getSerializable, getSerializable, getShortList, getString, getString, getValues, getVector, getVector, isBoolean, isColor, isConfigurationSection, isDouble, isInt, isItemStack, isList, isLocation, isLong, isOfflinePlayer, isSet, isString, isVector, set, toString

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.bukkit.configuration.ConfigurationSection

    contains, contains, createSection, createSection, get, get, getBoolean, getBoolean, getBooleanList, getByteList, getCharacterList, getColor, getColor, getConfigurationSection, getCurrentPath, getDefaultSection, getDouble, getDouble, getDoubleList, getFloatList, getInt, getInt, getIntegerList, getItemStack, getItemStack, getKeys, getList, getList, getLocation, getLocation, getLong, getLong, getLongList, getMapList, getName, getObject, getObject, getOfflinePlayer, getOfflinePlayer, getRoot, getSerializable, getSerializable, getShortList, getString, getString, getValues, getVector, getVector, isBoolean, isColor, isConfigurationSection, isDouble, isInt, isItemStack, isList, isLocation, isLong, isOfflinePlayer, isSet, isString, isVector, set
  • Constructor Details

    • YmlConfiguration

      public YmlConfiguration()
  • Method Details

    • getComment

      public String getComment(String key)
    • getComments

      public Map<String,​String> getComments()
    • addComment

      public void addComment(String path, String comment)
    • addComments

      public void addComments(Map<String,​String> comments)
    • loadFromString

      public void loadFromString(String contents) throws org.bukkit.configuration.InvalidConfigurationException
      Overrides:
      loadFromString in class org.bukkit.configuration.file.YamlConfiguration
      Throws:
      org.bukkit.configuration.InvalidConfigurationException
    • getStringList

      public List<String> getStringList(String path)
      Specified by:
      getStringList in interface org.bukkit.configuration.ConfigurationSection
      Overrides:
      getStringList in class org.bukkit.configuration.MemorySection
    • saveToString

      public String saveToString()
      Overrides:
      saveToString in class org.bukkit.configuration.file.YamlConfiguration