Class zAPI

java.lang.Object
me.yleoft.zAPI.zAPI

public class zAPI extends Object
  • Field Details

    • customCommandNBT

      public static String customCommandNBT
    • placeholderAPIHandler

      public static PlaceholderAPIHandler placeholderAPIHandler
    • plugin

      protected static org.bukkit.plugin.java.JavaPlugin plugin
    • pluginName

      protected static String pluginName
    • coloredPluginName

      protected static String coloredPluginName
    • papi

      protected static Object papi
    • economy

      protected static Object economy
  • Constructor Details

    • zAPI

      public zAPI()
  • Method Details

    • init

      public static void init(@NotNull @NotNull org.bukkit.plugin.java.JavaPlugin plugin, @NotNull @NotNull String pluginName, @NotNull @NotNull String coloredPluginName, boolean useNBTAPI)
      Initialize zAPI
      Parameters:
      plugin - The plugin that is using zAPI
      pluginName - The custom name of the plugin
      coloredPluginName - The custom colored name of the plugin
      useNBTAPI - If the plugin should use NBTAPI
    • init

      public static void init(@NotNull @NotNull org.bukkit.plugin.java.JavaPlugin plugin, @NotNull @NotNull String pluginName, @NotNull @NotNull String coloredPluginName)
    • getPlugin

      @NotNull public static @NotNull org.bukkit.plugin.java.JavaPlugin getPlugin()
      Returns the class of the plugin that has initialized zAPI
      Returns:
      The class of the plugin using zAPI
    • getPluginName

      @NotNull public static @NotNull String getPluginName()
      Returns the custom name of the plugin that initialized zAPI
      Returns:
      The name of the plugin
    • setPluginName

      public static void setPluginName(@NotNull @NotNull String pluginName)
    • getColoredPluginName

      @NotNull public static @NotNull String getColoredPluginName()
      Returns the custom colored name of the plugin that initialized zAPI
      Returns:
      The colored name of the plugin
    • setColoredPluginName

      public static void setColoredPluginName(@NotNull @NotNull String coloredPluginName)
    • getPlaceholderExpansion

      public static me.clip.placeholderapi.expansion.PlaceholderExpansion getPlaceholderExpansion()
      Returns the PlaceholderAPI Expansion of the plugin for you
      Returns:
      The PlaceholderExpansion class of the plugin
      Throws:
      RuntimeException - if the PlaceholderAPI is not enabled
    • startMetrics

      public static void startMetrics(int pluginId)
      Start the plugin metrics on bStats
      Parameters:
      pluginId - The ID of the plugin on bStats
    • setPlaceholderAPIHandler

      public static void setPlaceholderAPIHandler(@NotNull @NotNull PlaceholderAPIHandler handler)
      Set the PlaceholderAPIHandler for the plugin
      Parameters:
      handler - The PlaceholderAPIHandler class of the plugin
    • getPlaceholderAPIHandler

      public static PlaceholderAPIHandler getPlaceholderAPIHandler()
      Returns the PlaceholderAPIHandler for the plugin
      Returns:
      The PlaceholderAPIHandler class of the plugin
    • registerPlaceholderExpansion

      public static void registerPlaceholderExpansion(@NotNull @NotNull String author, @NotNull @NotNull String version, boolean canRegister, boolean persist)
      Register the PlaceholderAPI Expansion for you
      Parameters:
      author - The author of the plugin
      version - The version of the plugin
      canRegister - If the expansion can be registered
      persist - If the expansion should persist
    • unregisterPlaceholderExpansion

      public static void unregisterPlaceholderExpansion()
      Unregisters the PlaceholderAPI Expansion