Package net.minecraft.command.impl.data
Class DataCommand
- java.lang.Object
-
- net.minecraft.command.impl.data.DataCommand
-
public class DataCommand extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceDataCommand.IDataProvider(package private) static interfaceDataCommand.IModificationSourceArgumentBuilder(package private) static interfaceDataCommand.IModificationType
-
Field Summary
Fields Modifier and Type Field Description static java.util.List<java.util.function.Function<java.lang.String,DataCommand.IDataProvider>>ALL_PROVIDERSprivate static com.mojang.brigadier.exceptions.DynamicCommandExceptionTypeERROR_EXPECTED_LISTprivate static com.mojang.brigadier.exceptions.DynamicCommandExceptionTypeERROR_EXPECTED_OBJECTprivate static com.mojang.brigadier.exceptions.DynamicCommandExceptionTypeERROR_GET_NON_EXISTENTprivate static com.mojang.brigadier.exceptions.DynamicCommandExceptionTypeERROR_GET_NOT_NUMBERprivate static com.mojang.brigadier.exceptions.DynamicCommandExceptionTypeERROR_INVALID_INDEXprivate static com.mojang.brigadier.exceptions.SimpleCommandExceptionTypeERROR_MERGE_UNCHANGEDprivate static com.mojang.brigadier.exceptions.SimpleCommandExceptionTypeERROR_MULTIPLE_TAGSstatic java.util.List<DataCommand.IDataProvider>SOURCE_PROVIDERSstatic java.util.List<DataCommand.IDataProvider>TARGET_PROVIDERS
-
Constructor Summary
Constructors Constructor Description DataCommand()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static com.mojang.brigadier.builder.ArgumentBuilder<CommandSource,?>decorateModification(java.util.function.BiConsumer<com.mojang.brigadier.builder.ArgumentBuilder<CommandSource,?>,DataCommand.IModificationSourceArgumentBuilder> p_218935_0_)private static intgetData(CommandSource p_198947_0_, IDataAccessor p_198947_1_)private static intgetData(CommandSource p_201228_0_, IDataAccessor p_201228_1_, NBTPathArgument.NBTPath p_201228_2_)private static intgetNumeric(CommandSource p_198938_0_, IDataAccessor p_198938_1_, NBTPathArgument.NBTPath p_198938_2_, double p_198938_3_)private static INBTgetSingleTag(NBTPathArgument.NBTPath p_218928_0_, IDataAccessor p_218928_1_)private static intinsertAtIndex(int p_218944_0_, CompoundNBT p_218944_1_, NBTPathArgument.NBTPath p_218944_2_, java.util.List<INBT> p_218944_3_)private static intmanipulateData(com.mojang.brigadier.context.CommandContext<CommandSource> p_218933_0_, DataCommand.IDataProvider p_218933_1_, DataCommand.IModificationType p_218933_2_, java.util.List<INBT> p_218933_3_)private static intmergeData(CommandSource p_198946_0_, IDataAccessor p_198946_1_, CompoundNBT p_198946_2_)static voidregister(com.mojang.brigadier.CommandDispatcher<CommandSource> p_198937_0_)private static intremoveData(CommandSource p_198942_0_, IDataAccessor p_198942_1_, NBTPathArgument.NBTPath p_198942_2_)
-
-
-
Field Detail
-
ERROR_MERGE_UNCHANGED
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_MERGE_UNCHANGED
-
ERROR_GET_NOT_NUMBER
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_GET_NOT_NUMBER
-
ERROR_GET_NON_EXISTENT
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_GET_NON_EXISTENT
-
ERROR_MULTIPLE_TAGS
private static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_MULTIPLE_TAGS
-
ERROR_EXPECTED_LIST
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_EXPECTED_LIST
-
ERROR_EXPECTED_OBJECT
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_EXPECTED_OBJECT
-
ERROR_INVALID_INDEX
private static final com.mojang.brigadier.exceptions.DynamicCommandExceptionType ERROR_INVALID_INDEX
-
ALL_PROVIDERS
public static final java.util.List<java.util.function.Function<java.lang.String,DataCommand.IDataProvider>> ALL_PROVIDERS
-
TARGET_PROVIDERS
public static final java.util.List<DataCommand.IDataProvider> TARGET_PROVIDERS
-
SOURCE_PROVIDERS
public static final java.util.List<DataCommand.IDataProvider> SOURCE_PROVIDERS
-
-
Method Detail
-
register
public static void register(com.mojang.brigadier.CommandDispatcher<CommandSource> p_198937_0_)
-
insertAtIndex
private static int insertAtIndex(int p_218944_0_, CompoundNBT p_218944_1_, NBTPathArgument.NBTPath p_218944_2_, java.util.List<INBT> p_218944_3_) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
decorateModification
private static com.mojang.brigadier.builder.ArgumentBuilder<CommandSource,?> decorateModification(java.util.function.BiConsumer<com.mojang.brigadier.builder.ArgumentBuilder<CommandSource,?>,DataCommand.IModificationSourceArgumentBuilder> p_218935_0_)
-
manipulateData
private static int manipulateData(com.mojang.brigadier.context.CommandContext<CommandSource> p_218933_0_, DataCommand.IDataProvider p_218933_1_, DataCommand.IModificationType p_218933_2_, java.util.List<INBT> p_218933_3_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
removeData
private static int removeData(CommandSource p_198942_0_, IDataAccessor p_198942_1_, NBTPathArgument.NBTPath p_198942_2_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getSingleTag
private static INBT getSingleTag(NBTPathArgument.NBTPath p_218928_0_, IDataAccessor p_218928_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getData
private static int getData(CommandSource p_201228_0_, IDataAccessor p_201228_1_, NBTPathArgument.NBTPath p_201228_2_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getNumeric
private static int getNumeric(CommandSource p_198938_0_, IDataAccessor p_198938_1_, NBTPathArgument.NBTPath p_198938_2_, double p_198938_3_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
getData
private static int getData(CommandSource p_198947_0_, IDataAccessor p_198947_1_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
mergeData
private static int mergeData(CommandSource p_198946_0_, IDataAccessor p_198946_1_, CompoundNBT p_198946_2_) throws com.mojang.brigadier.exceptions.CommandSyntaxException
- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
-