Package net.minecraft.predicate
Record Class NumberRange.Bounds<T extends Number & Comparable<T>>
java.lang.Object
java.lang.Record
net.minecraft.predicate.NumberRange.Bounds<T>
- Record Components:
min-max-
- Enclosing interface:
NumberRange<T extends Number & Comparable<T>>
public static record NumberRange.Bounds<T extends Number & Comparable<T>>(Optional<T extends Number & Comparable<T>> min, Optional<T extends Number & Comparable<T>> max)
extends Record
- Mappings:
Namespace Name named net/minecraft/predicate/NumberRange$Boundsintermediary net/minecraft/class_2096$class_11893official cx$anamed minintermediary comp_4769official anamed maxintermediary comp_4770official b
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends Number & Comparable<T>>
NumberRange.Bounds<T> any()static <T extends Number & Comparable<T>>
NumberRange.Bounds<T> atLeast(T value) static <T extends Number & Comparable<T>>
NumberRange.Bounds<T> atMost(T value) static <T extends Number & Comparable<T>>
NumberRange.Bounds<T> between(T min, T max) (package private) static <T extends Number & Comparable<T>>
com.mojang.serialization.Codec<NumberRange.Bounds<T>> createCodec(com.mojang.serialization.Codec<T> valueCodec) (package private) static <B extends ByteBuf,T extends Number & Comparable<T>>
PacketCodec<B, NumberRange.Bounds<T>> createPacketCodec(PacketCodec<B, T> valuePacketCodec) final booleanIndicates whether some other object is "equal to" this one.static <T extends Number & Comparable<T>>
NumberRange.Bounds<T> exactly(T value) getPoint()final inthashCode()Returns a hash code value for this object.booleanisAny()boolean<U extends Number & Comparable<U>>
NumberRange.Bounds<U> max()Returns the value of themaxrecord component.min()Returns the value of theminrecord component.static <T extends Number & Comparable<T>>
NumberRange.Bounds<T> parse(com.mojang.brigadier.StringReader reader, Function<String, T> parsingFunction, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> exceptionSupplier) parseNumber(com.mojang.brigadier.StringReader reader, Function<String, T> parsingFunction, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> exceptionSupplier) private static booleanshouldSkip(com.mojang.brigadier.StringReader reader) final StringtoString()Returns a string representation of this record class.com.mojang.serialization.DataResult<NumberRange.Bounds<T>> validate()
-
Field Details
-
Constructor Details
-
Bounds
-
-
Method Details
-
isAny
public boolean isAny()- Mappings:
Namespace Name Mixin selector named isAnyLnet/minecraft/predicate/NumberRange$Bounds;isAny()Zintermediary method_74108Lnet/minecraft/class_2096$class_11893;method_74108()Zofficial aLcx$a;a()Z
-
validate
- Mappings:
Namespace Name Mixin selector named validateLnet/minecraft/predicate/NumberRange$Bounds;validate()Lcom/mojang/serialization/DataResult;intermediary method_74120Lnet/minecraft/class_2096$class_11893;method_74120()Lcom/mojang/serialization/DataResult;official bLcx$a;b()Lcom/mojang/serialization/DataResult;
-
isSwapped
public boolean isSwapped()- Mappings:
Namespace Name Mixin selector named isSwappedLnet/minecraft/predicate/NumberRange$Bounds;isSwapped()Zintermediary method_74124Lnet/minecraft/class_2096$class_11893;method_74124()Zofficial cLcx$a;c()Z
-
getPoint
- Mappings:
Namespace Name Mixin selector named getPointLnet/minecraft/predicate/NumberRange$Bounds;getPoint()Ljava/util/Optional;intermediary method_74126Lnet/minecraft/class_2096$class_11893;method_74126()Ljava/util/Optional;official dLcx$a;d()Ljava/util/Optional;
-
any
- Mappings:
Namespace Name Mixin selector named anyLnet/minecraft/predicate/NumberRange$Bounds;any()Lnet/minecraft/predicate/NumberRange$Bounds;intermediary method_74127Lnet/minecraft/class_2096$class_11893;method_74127()Lnet/minecraft/class_2096$class_11893;official eLcx$a;e()Lcx$a;
-
exactly
- Mappings:
Namespace Name Mixin selector named exactlyLnet/minecraft/predicate/NumberRange$Bounds;exactly(Ljava/lang/Number;)Lnet/minecraft/predicate/NumberRange$Bounds;intermediary method_74116Lnet/minecraft/class_2096$class_11893;method_74116(Ljava/lang/Number;)Lnet/minecraft/class_2096$class_11893;official aLcx$a;a(Ljava/lang/Number;)Lcx$a;
-
between
- Mappings:
Namespace Name Mixin selector named betweenLnet/minecraft/predicate/NumberRange$Bounds;between(Ljava/lang/Number;Ljava/lang/Number;)Lnet/minecraft/predicate/NumberRange$Bounds;intermediary method_74117Lnet/minecraft/class_2096$class_11893;method_74117(Ljava/lang/Number;Ljava/lang/Number;)Lnet/minecraft/class_2096$class_11893;official aLcx$a;a(Ljava/lang/Number;Ljava/lang/Number;)Lcx$a;
-
atLeast
- Mappings:
Namespace Name Mixin selector named atLeastLnet/minecraft/predicate/NumberRange$Bounds;atLeast(Ljava/lang/Number;)Lnet/minecraft/predicate/NumberRange$Bounds;intermediary method_74123Lnet/minecraft/class_2096$class_11893;method_74123(Ljava/lang/Number;)Lnet/minecraft/class_2096$class_11893;official bLcx$a;b(Ljava/lang/Number;)Lcx$a;
-
atMost
- Mappings:
Namespace Name Mixin selector named atMostLnet/minecraft/predicate/NumberRange$Bounds;atMost(Ljava/lang/Number;)Lnet/minecraft/predicate/NumberRange$Bounds;intermediary method_74125Lnet/minecraft/class_2096$class_11893;method_74125(Ljava/lang/Number;)Lnet/minecraft/class_2096$class_11893;official cLcx$a;c(Ljava/lang/Number;)Lcx$a;
-
map
- Mappings:
Namespace Name Mixin selector named mapLnet/minecraft/predicate/NumberRange$Bounds;map(Ljava/util/function/Function;)Lnet/minecraft/predicate/NumberRange$Bounds;intermediary method_74119Lnet/minecraft/class_2096$class_11893;method_74119(Ljava/util/function/Function;)Lnet/minecraft/class_2096$class_11893;official aLcx$a;a(Ljava/util/function/Function;)Lcx$a;
-
createCodec
static <T extends Number & Comparable<T>> com.mojang.serialization.Codec<NumberRange.Bounds<T>> createCodec(com.mojang.serialization.Codec<T> valueCodec) - Mappings:
Namespace Name Mixin selector named createCodecLnet/minecraft/predicate/NumberRange$Bounds;createCodec(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;intermediary method_74113Lnet/minecraft/class_2096$class_11893;method_74113(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;official aLcx$a;a(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
-
createPacketCodec
static <B extends ByteBuf,T extends Number & Comparable<T>> PacketCodec<B,NumberRange.Bounds<T>> createPacketCodec(PacketCodec<B, T> valuePacketCodec) - Mappings:
Namespace Name Mixin selector named createPacketCodecLnet/minecraft/predicate/NumberRange$Bounds;createPacketCodec(Lnet/minecraft/network/codec/PacketCodec;)Lnet/minecraft/network/codec/PacketCodec;intermediary method_74109Lnet/minecraft/class_2096$class_11893;method_74109(Lnet/minecraft/class_9139;)Lnet/minecraft/class_9139;official aLcx$a;a(Laae;)Laae;
-
parse
public static <T extends Number & Comparable<T>> NumberRange.Bounds<T> parse(com.mojang.brigadier.StringReader reader, Function<String, T> parsingFunction, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> exceptionSupplier) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException- Mappings:
Namespace Name Mixin selector named parseLnet/minecraft/predicate/NumberRange$Bounds;parse(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;Ljava/util/function/Supplier;)Lnet/minecraft/predicate/NumberRange$Bounds;intermediary method_74111Lnet/minecraft/class_2096$class_11893;method_74111(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;Ljava/util/function/Supplier;)Lnet/minecraft/class_2096$class_11893;official aLcx$a;a(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;Ljava/util/function/Supplier;)Lcx$a;
-
parseNumber
private static <T extends Number> Optional<T> parseNumber(com.mojang.brigadier.StringReader reader, Function<String, T> parsingFunction, Supplier<com.mojang.brigadier.exceptions.DynamicCommandExceptionType> exceptionSupplier) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException- Mappings:
Namespace Name Mixin selector named parseNumberLnet/minecraft/predicate/NumberRange$Bounds;parseNumber(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;Ljava/util/function/Supplier;)Ljava/util/Optional;intermediary method_74121Lnet/minecraft/class_2096$class_11893;method_74121(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;Ljava/util/function/Supplier;)Ljava/util/Optional;official bLcx$a;b(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;Ljava/util/function/Supplier;)Ljava/util/Optional;
-
shouldSkip
private static boolean shouldSkip(com.mojang.brigadier.StringReader reader) - Mappings:
Namespace Name Mixin selector named shouldSkipLnet/minecraft/predicate/NumberRange$Bounds;shouldSkip(Lcom/mojang/brigadier/StringReader;)Zintermediary method_74110Lnet/minecraft/class_2096$class_11893;method_74110(Lcom/mojang/brigadier/StringReader;)Zofficial aLcx$a;a(Lcom/mojang/brigadier/StringReader;)Z
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
min
Returns the value of theminrecord component.- Returns:
- the value of the
minrecord component
-
max
Returns the value of themaxrecord component.- Returns:
- the value of the
maxrecord component
-