Class DumpCommand

java.lang.Object
net.neoforged.neoforge.server.command.DumpCommand

class DumpCommand extends Object
The /neoforge dump registry command for printing out the contents of a registry to a file in the game directory's dumps/registry folder.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private static final String
     
    private static final org.slf4j.Logger
     
    private static final String
     
    private static final net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<net.minecraft.core.Registry<?>>>
     
    private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    private static int
    dumpRegistry(com.mojang.brigadier.context.CommandContext<net.minecraft.commands.CommandSourceStack> ctx, boolean alphabeticalSort, boolean printNumericIds)
     
    private static List<net.minecraft.resources.ResourceLocation>
    getSortedRegistryKeys(boolean alphabeticalSort, boolean printNumericIds, net.minecraft.core.Registry<?> registry)
     
    static com.mojang.brigadier.builder.ArgumentBuilder<net.minecraft.commands.CommandSourceStack,?>
     

    Methods inherited from class java.lang.Object

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

    • LOGGER

      private static final org.slf4j.Logger LOGGER
    • ROOT_REGISTRY_KEY

      private static final net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<net.minecraft.core.Registry<?>>> ROOT_REGISTRY_KEY
    • ALPHABETICAL_SORT_PARAM

      private static final String ALPHABETICAL_SORT_PARAM
      See Also:
    • UNKNOWN_REGISTRY

      private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType UNKNOWN_REGISTRY
  • Constructor Details

    • DumpCommand

      DumpCommand()
  • Method Details

    • register

      public static com.mojang.brigadier.builder.ArgumentBuilder<net.minecraft.commands.CommandSourceStack,?> register()
    • dumpRegistry

      private static int dumpRegistry(com.mojang.brigadier.context.CommandContext<net.minecraft.commands.CommandSourceStack> ctx, boolean alphabeticalSort, boolean printNumericIds) throws com.mojang.brigadier.exceptions.CommandSyntaxException
      Throws:
      com.mojang.brigadier.exceptions.CommandSyntaxException
    • getSortedRegistryKeys

      private static List<net.minecraft.resources.ResourceLocation> getSortedRegistryKeys(boolean alphabeticalSort, boolean printNumericIds, net.minecraft.core.Registry<?> registry)