Examples of addDefaults()


Examples of org.bukkit.configuration.file.FileConfiguration.addDefaults()

  for (String sectionName : this.getKeys(false)) {
   if (section != null && !sectionName.equals(section))
    continue;
   if (this.isConfigurationSection(sectionName)) {
    FileConfiguration sectionConfig = new YamlConfiguration();
    sectionConfig.addDefaults(this.getConfigurationSection(sectionName).getValues(true));
    sectionConfig.options().copyDefaults(true);
    sectionConfig.save(new File(directory, sectionName + ".yml"));
   }
  }
}
View Full Code Here

Examples of org.bukkit.configuration.file.YamlConfiguration.addDefaults()

  for (String sectionName : this.getKeys(false)) {
   if (section != null && !sectionName.equals(section))
    continue;
   if (this.isConfigurationSection(sectionName)) {
    FileConfiguration sectionConfig = new YamlConfiguration();
    sectionConfig.addDefaults(this.getConfigurationSection(sectionName).getValues(true));
    sectionConfig.options().copyDefaults(true);
    sectionConfig.save(new File(directory, sectionName + ".yml"));
   }
  }
}
View Full Code Here

Examples of org.freeplane.core.resources.ResourceController.addDefaults()

  public void registerInstalledAddOn(final AddOnProperties addOn) {
    installedAddOns.add(addOn);
    final ResourceController resourceController = ResourceController.getResourceController();
    if (addOn.getDefaultProperties() != null)
      resourceController.addDefaults(addOn.getDefaultProperties());
    if (addOn.getPreferencesXml() != null) {
      final ModeController modeController = Controller.getCurrentModeController();
      if (modeController instanceof MModeController) {
        ((MModeController)modeController).getOptionPanelBuilder().load(new StringReader(addOn.getPreferencesXml()));
      }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.