Class MinMaxBounds<T extends Number>
java.lang.Object
net.minecraft.advancements.critereon.MinMaxBounds<T>
- Direct Known Subclasses:
MinMaxBounds.Doubles
,MinMaxBounds.Ints
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static interface
MinMaxBounds.BoundsFactory<T extends Number,
R extends MinMaxBounds<T>> protected static interface
MinMaxBounds.BoundsFromReaderFactory<T extends Number,
R extends MinMaxBounds<T>> static class
static class
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected static <T extends Number,
R extends MinMaxBounds<T>>
RfromJson
(com.google.gson.JsonElement p_55307_, R p_55308_, BiFunction<com.google.gson.JsonElement, String, T> p_55309_, MinMaxBounds.BoundsFactory<T, R> p_55310_) protected static <T extends Number,
R extends MinMaxBounds<T>>
RfromReader
(com.mojang.brigadier.StringReader p_55314_, MinMaxBounds.BoundsFromReaderFactory<T, R> p_55315_, Function<String, T> p_55316_, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> p_55317_, Function<T, T> p_55318_) getMax()
getMin()
private static boolean
isAllowedInputChat
(com.mojang.brigadier.StringReader p_55312_) boolean
isAny()
private static <T> T
optionallyFormat
(T p_55324_, Function<T, T> p_55325_) private static <T extends Number>
TreadNumber
(com.mojang.brigadier.StringReader p_55320_, Function<String, T> p_55321_, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> p_55322_) com.google.gson.JsonElement
-
Field Details
-
ERROR_EMPTY
public static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_EMPTY -
ERROR_SWAPPED
public static final com.mojang.brigadier.exceptions.SimpleCommandExceptionType ERROR_SWAPPED -
min
-
max
-
-
Constructor Details
-
MinMaxBounds
-
-
Method Details
-
getMin
-
getMax
-
isAny
public boolean isAny() -
serializeToJson
public com.google.gson.JsonElement serializeToJson() -
fromJson
protected static <T extends Number,R extends MinMaxBounds<T>> R fromJson(@Nullable com.google.gson.JsonElement p_55307_, R p_55308_, BiFunction<com.google.gson.JsonElement, String, T> p_55309_, MinMaxBounds.BoundsFactory<T, R> p_55310_) -
fromReader
protected static <T extends Number,R extends MinMaxBounds<T>> R fromReader(com.mojang.brigadier.StringReader p_55314_, MinMaxBounds.BoundsFromReaderFactory<T, R> p_55315_, Function<String, throws com.mojang.brigadier.exceptions.CommandSyntaxExceptionT> p_55316_, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> p_55317_, Function<T, T> p_55318_) - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
readNumber
@Nullable private static <T extends Number> T readNumber(com.mojang.brigadier.StringReader p_55320_, Function<String, T> p_55321_, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> p_55322_) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException
-
isAllowedInputChat
private static boolean isAllowedInputChat(com.mojang.brigadier.StringReader p_55312_) -
optionallyFormat
-