@@ -0,0 +1,1574 @@
+package com.gmail.zahusek.configurations;%0A%0Aimport java.io.File;%0Aimport java.io.IOException;%0Aimport java.util.Map;%0A%0Aimport org.bukkit.configuration.InvalidConfigurationException;%0Aimport org.bukkit.configuration.file.YamlConfiguration;%0A%0Aimport com.google.common.collect.Maps;%0A%0Apublic class QConfig extends YamlConfiguration %7B%0A%0A%09private String id;%0A%09private File file;%0A%09private Map%3CString, Object%3E variables;%0A%0A%09public QConfig(String id, File file) %7B%0A%09%09super();%0A%09%09this.id = id.trim();%0A%09%09this.file = file;%0A%09%09this.variables = Maps.newHashMap();%0A%09%7D%0A%0A%09public String getId() %7B%0A%09%09return id;%0A%09%7D%0A%0A%09public File getFile() %7B%0A%09%09return file;%0A%09%7D%0A%0A%09public Map%3CString, Object%3E getVariables() %7B%0A%09%09return variables;%0A%09%7D%0A%0A%09public void loadVariables() %7B%0A%09%09for(String key : getKeys(true)) variables.put(key, get(key));%0A%09%7D%0A%0A%09public void saveVariables() %7B%0A%09%09for(String key : variables.keySet()) set(key, variables.get(key));%0A%09%7D%0A%09public void save() %7B%0A%09%09try %7B%0A%09%09%09save(file);%0A%09%09%7D catch (IOException e) %7B%0A%09%09%09System.out.println(%22== An error when saving a file %22 + id + %22 ==%22);%0A%09%09%09e.printStackTrace();%0A%09%09%7D%0A%09%7D%0A%0A%09public void load() %7B%0A%09%09try %7B%0A%09%09%09load(file);%0A%09%09%7D catch (IOException %7C InvalidConfigurationException e) %7B%0A%09%09%09System.out.println(%22== An error when loading a file %22 + id + %22 ==%22);%0A%09%09%09e.printStackTrace();%0A%09%09%7D%0A%09%09loadVariables();%0A%09%7D%0A%0A%09public boolean equals(QConfig c) %7B%0A%09%09return c.getId().equals(this.id);%0A%09%7D%0A%0A%09@SuppressWarnings(%22unchecked%22)%0A%09public %3CT%3E T getVariable(String path) %7B%0A%09%09return (T) variables.get(path);%0A%09%7D%0A%09public void setVariable(String path, Object obj) %7B%0A%09%09variables.put(path, obj);%0A%09%7D%0A%7D%0A

Create QConfig.java