Class ArgumentTypeRegistry

java.lang.Object
net.fabricmc.fabric.api.command.v2.ArgumentTypeRegistry

public final class ArgumentTypeRegistry extends Object
  • Method Details

    • registerArgumentType

      public static <A extends com.mojang.brigadier.arguments.ArgumentType<?>, T extends ArgumentSerializer.ArgumentTypeProperties<A>> void registerArgumentType(Identifier id, Class<? extends A> clazz, ArgumentSerializer<A,T> serializer)
      Register a new argument type.
      Type Parameters:
      A - the argument type
      T - the argument type properties
      Parameters:
      id - the identifier of the argument type
      clazz - the class of the argument type
      serializer - the serializer for the argument type