Package net.ssterling.bukkitversion
Class BukkitVersionPlugin
java.lang.Object
org.bukkit.plugin.PluginBase
org.bukkit.plugin.java.JavaPlugin
net.ssterling.bukkitversion.BukkitVersionPlugin
- All Implemented Interfaces:
CommandExecutor
,TabCompleter
,TabExecutor
,Plugin
The
BukkitVersionPlugin
class initialises a
JavaPlugin
to expose the BukkitVersion API
to other plugins running on a Bukkit server.
This is a common alternative to including an API directly in a project
in typical fashion.
For Maven users: change the dependency scope for BukkitVersion in your
plugin’s pom.xml
:
<scope>provided</scope>
Also, add the following to your plugin’s plugin.yml
:
depend: [BukkitVersion]
You can now use the BukkitVersion API without including the entire package
within your plugin JAR; however, you must instruct users of your plugin
to download the BukkitVersion jar from SpigotMC.- Since:
- 0.2.0
- Author:
- Seth Price
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final int
bStats plugin ID (for metrics).private static org.bstats.bukkit.Metrics
Metrics object for bStats.private static final String
Spigot project ID (for update checker). -
Constructor Summary
-
Method Summary
Methods inherited from class org.bukkit.plugin.java.JavaPlugin
getClassLoader, getCommand, getConfig, getDataFolder, getDefaultBiomeProvider, getDefaultWorldGenerator, getDescription, getFile, getLogger, getPlugin, getPluginLoader, getProvidingPlugin, getResource, getServer, getTextResource, isEnabled, isNaggable, onCommand, onDisable, onLoad, onTabComplete, reloadConfig, saveConfig, saveDefaultConfig, saveResource, setEnabled, setNaggable, toString
Methods inherited from class org.bukkit.plugin.PluginBase
equals, getName, hashCode
-
Field Details
-
BSTATS_ID
private static final int BSTATS_IDbStats plugin ID (for metrics).- See Also:
-
PROJECT_ID
Spigot project ID (for update checker).- See Also:
-
metrics
private static org.bstats.bukkit.Metrics metricsMetrics object for bStats.
-
-
Constructor Details
-
BukkitVersionPlugin
public BukkitVersionPlugin()
-
-
Method Details
-
onEnable
public void onEnable()Loads bStats metrics. No, really, that’s it.- Specified by:
onEnable
in interfacePlugin
- Overrides:
onEnable
in classJavaPlugin
-