# Guide
# Install
# Maven
# JitPick
# Libraries
# Usage
# Load plugin
Define a PluginInitializer
interface.
public interface PluginInitializer {
default void onInitializer() {};
}
Then load this plugin.
public static void main(String[] args) throws Exception {
BullPlugin bullPlugin = new BullPlugin(new File("plugins"));
ArrayList<PluginInitializer> plugins = new ArrayList<PluginInitializer>();
for (Object c : bullPlugin.getPlugins()) {
plugins.add((PluginInitializer) c);
}
for (PluginInitializer p : plugins) {
p.onInitializer();
}
}
# Make plugin
Create a new class.
Add the annotation @Plugin
.
@Plugin
public class Example implements PluginInitializer {
@Override
public void onInitializer() {
System.out.println("Already loaded!");
}
}