/**
 * This file is part of XtraAPI, licensed under the MIT License (MIT).
 *
 * Copyright (c) 2016 - 2016 XtraStudio <https://github.com/XtraStudio>
 * Copyright (c) Contributors
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 * SOFTWARE.
 */

package com.xtra.api.config.base;

import com.xtra.api.config.Config;
import com.xtra.api.util.config.ConfigExecutor;
import com.xtra.api.util.config.ConfigStore;

import ninja.leaping.configurate.commented.CommentedConfigurationNode;
import ninja.leaping.configurate.loader.ConfigurationLoader;

/**
 * A base class for a config implementation. This handles much of the logic of
 * creating a configuration file for you.
 */
public abstract class ConfigBase implements Config {

    // NOTE: this is overridden by the implementation
    private static ConfigExecutor BASE = null;
    private ConfigStore store = null;

    public void init() {
        BASE.init(this);
    }

    public void load() {
        BASE.load(store);
    }

    public void save() {
        BASE.save(store);
    }

    public ConfigurationLoader<CommentedConfigurationNode> loader() {
        return BASE.loader(store);
    }

    public CommentedConfigurationNode rootNode() {
        return BASE.rootNode(store);
    }
}

@@ -1413,24 +1413,79 @@
 nfigStore;%0A%0A
+import ninja.leaping.configurate.ConfigurationOptions;%0A
 import ninja
@@ -1928,16 +1928,489 @@
  null;%0A%0A
+    /**%0A     * A %7B@link ConfigBase%7D specific method, this allows you to modify any%0A     * %7B@link ConfigurationOptions%7D before the configuration loader is built.%0A     * %0A     * %3Cp%3ENote that implementation of this method is completely optional. It%0A     * will default to %7B@link ConfigurationOptions#defaults()%7D.%3C/p%3E%0A     * %0A     * @return The configuration options%0A     */%0A    public ConfigurationOptions setOptions() %7B%0A        return ConfigurationOptions.defaults();%0A    %7D%0A%0A
     publ

Add ConfigBase#setOptions potential override.