Class ThirdPartyCommands

java.lang.Object
dev.kitteh.factions.command.ThirdPartyCommands

@AvailableSince("4.0.0") @NullMarked public final class ThirdPartyCommands extends Object
For the registry of /f and /fa commands from other plugins.
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    register(org.bukkit.plugin.Plugin providingPlugin, String command, TriConsumer<org.incendo.cloud.CommandManager<Sender>,org.incendo.cloud.Command.Builder<Sender>,org.incendo.cloud.minecraft.extras.MinecraftHelp<Sender>> consumer)
    Registers a command for the main faction command, to be called during load.
    static void
    registerAdmin(org.bukkit.plugin.Plugin providingPlugin, String command, TriConsumer<org.incendo.cloud.CommandManager<Sender>,org.incendo.cloud.Command.Builder<Sender>,org.incendo.cloud.minecraft.extras.MinecraftHelp<Sender>> consumer)
    Registers a command for the faction admin command, to be called during load.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • register

      public static void register(org.bukkit.plugin.Plugin providingPlugin, String command, TriConsumer<org.incendo.cloud.CommandManager<Sender>,org.incendo.cloud.Command.Builder<Sender>,org.incendo.cloud.minecraft.extras.MinecraftHelp<Sender>> consumer)
      Registers a command for the main faction command, to be called during load.
      Parameters:
      providingPlugin - your plugin, for tracking in exceptions
      command - command name, for tracking in exceptions
      consumer - a consumer of the command manager and the builder for the faction command, to build from. The consumer will be called during FactionsUUID's onEnable
      Throws:
      IllegalArgumentException - for not using your plugin
      IllegalStateException - if attempting after registration has closed
    • registerAdmin

      public static void registerAdmin(org.bukkit.plugin.Plugin providingPlugin, String command, TriConsumer<org.incendo.cloud.CommandManager<Sender>,org.incendo.cloud.Command.Builder<Sender>,org.incendo.cloud.minecraft.extras.MinecraftHelp<Sender>> consumer)
      Registers a command for the faction admin command, to be called during load.
      Parameters:
      providingPlugin - your plugin, for tracking in exceptions
      command - command name, for tracking in exceptions
      consumer - a consumer of the command manager and the builder for the faction admin command, to build from. The consumer will be called during FactionsUUID's onEnable
      Throws:
      IllegalArgumentException - for not using your plugin
      IllegalStateException - if attempting after registration has closed