The Plugin Provider is the entry point for ElvenideCore. It handles the initialization of the library and allows you to easily retrieve your plugin instance from anywhere in your codebase.
Initialization
To use ElvenideCore, you must set your plugin instance in your onEnable method.
@Override
public void onEnable() {
Core.plugin.set(this);
}
Retrieval
You can retrieve your plugin instance or its data folder using the following methods:
JavaPlugin myPlugin = Core.plugin.get();
File dataFolder = Core.plugin.folder();