Class Extension


  • public class Extension
    extends java.lang.Object
    Since:
    CAC v. 0.9945
    Author:
    Clientastisch
    • Constructor Detail

      • Extension

        public Extension()
    • Method Detail

      • registerListener

        public static void registerListener​(Addon addon,
                                            EventListener listener)
        Parameters:
        addon - Main-class of the extension
        listener - Anticheat event listener
      • registerListener

        public static void registerListener​(Addon addon,
                                            org.bukkit.event.Listener listener)
        Parameters:
        addon - Main-class of the extension
        listener - Bukkit event listener
      • unregisterListener

        public static void unregisterListener​(Addon addon,
                                              EventListener listener)
        Parameters:
        addon - Main-class of the extension
        listener - Anticheat event listener
      • unregisterListener

        public static void unregisterListener​(Addon addon,
                                              org.bukkit.event.Listener listener)
        Parameters:
        addon - Main-class of the extension
        listener - Bukkit event listener
      • registerCommand

        public static void registerCommand​(Addon addon,
                                           Command command)
        Parameters:
        addon - Main-class of the extension
        command - Command listener
      • unregisterCommand

        public static void unregisterCommand​(Addon addon,
                                             Command command)
        Parameters:
        addon - Main-class of the extension
        command - Command listener
      • registerDialect

        public static void registerDialect​(Addon addon,
                                           PunishDialect dialect)
        Parameters:
        addon - Main-class of the extension
        dialect - Database dialect
      • unregisterDialect

        public static void unregisterDialect​(Addon addon,
                                             PunishDialect dialect)
        Parameters:
        addon - Main-class of the extension
        dialect - Database dialect
      • registerDialect

        public static void registerDialect​(Addon addon,
                                           ViolationDialect dialect)
        Parameters:
        addon - Main-class of the extension
        dialect - Database dialect
      • unregisterDialect

        public static void unregisterDialect​(Addon addon,
                                             ViolationDialect dialect)
        Parameters:
        addon - Main-class of the extension
        dialect - Database dialect
      • getAddons

        public java.util.List<AddonInfo> getAddons()
        Get a list of all loaded addons
        Returns:
        List of loaded addons
      • isLoaded

        public boolean isLoaded​(java.lang.String addon)
        Check if a addon is loaded
        Parameters:
        addon - Name of the addon
        Returns:
        whether the addon is loaded