Class PlayerCommandSendEvent


  • public class PlayerCommandSendEvent
    extends PlayerEvent
    This event is called when the list of available server commands is sent to the player.
    Commands may be removed from display using this event, but implementations are not required to securely remove all traces of the command. If secure removal of commands is required, then the command should be assigned a permission which is not granted to the player.
    • Constructor Detail

      • PlayerCommandSendEvent

        public PlayerCommandSendEvent​(@NotNull
                                      Player player,
                                      @NotNull
                                      Collection<String> commands)
    • Method Detail

      • getCommands

        @NotNull
        public Collection<String> getCommands()
        Returns a mutable collection of all top level commands to be sent.
        It is not legal to add entries to this collection, only remove them. Behaviour of adding entries is undefined.
        Returns:
        collection of all commands
      • getHandlerList

        @NotNull
        public static HandlerList getHandlerList()