Class BanIpCommand

java.lang.Object
net.minecraft.server.dedicated.command.BanIpCommand

public class BanIpCommand
extends Object
  • Field Details

    • PATTERN

      public static final Pattern PATTERN
    • INVALID_IP_EXCEPTION

      private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType INVALID_IP_EXCEPTION
    • ALREADY_BANNED_EXCEPTION

      private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ALREADY_BANNED_EXCEPTION
  • Constructor Details

    • BanIpCommand

      public BanIpCommand()
  • Method Details

    • register

      public static void register​(com.mojang.brigadier.CommandDispatcher<ServerCommandSource> dispatcher)
    • checkIp

      private static int checkIp​(ServerCommandSource source, String target, @Nullable Text reason) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • banIp

      private static int banIp​(ServerCommandSource source, String targetIp, @Nullable Text reason) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException