Package net.minecraft.predicate
Record Class NumberRange.IntRange
java.lang.Object
java.lang.Record
net.minecraft.predicate.NumberRange.IntRange
- Record Components:
getMin-getMax-minSquared-maxSquared-
- All Implemented Interfaces:
NumberRange<Integer>
- Enclosing interface:
NumberRange<T extends Number>
public static record NumberRange.IntRange(Optional<Integer> getMin, Optional<Integer> getMax, Optional<Long> minSquared, Optional<Long> maxSquared)
extends Record
implements NumberRange<Integer>
- Mappings:
Namespace Name official cj$dintermediary net/minecraft/class_2096$class_2100named net/minecraft/predicate/NumberRange$IntRangeofficial eintermediary comp_1805named getMinofficial fintermediary comp_1806named getMaxofficial gintermediary comp_1809named minSquaredofficial hintermediary comp_1810named maxSquared
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.predicate.NumberRange
NumberRange.CommandFactory<T extends Number,R extends NumberRange<T>>, NumberRange.Factory<T extends Number, R extends NumberRange<T>>, NumberRange.FloatRange, NumberRange.IntRange -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final NumberRange.IntRangestatic final com.mojang.serialization.Codec<NumberRange.IntRange>The field for thegetMaxrecord component.The field for thegetMinrecord component.The field for themaxSquaredrecord component.The field for theminSquaredrecord component.Fields inherited from interface net.minecraft.predicate.NumberRange
EXCEPTION_EMPTY, EXCEPTION_SWAPPED -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic NumberRange.IntRangeatLeast(int value) static NumberRange.IntRangeatMost(int value) static NumberRange.IntRangebetween(int min, int max) final booleanIndicates whether some other object is "equal to" this one.static NumberRange.IntRangeexactly(int value) static NumberRange.IntRangefromJson(@Nullable JsonElement element) static NumberRange.IntRangefromStringReader(com.mojang.brigadier.StringReader reader, Function<Integer, Integer> converter) getMax()getMin()final inthashCode()Returns a hash code value for this object.Returns the value of themaxSquaredrecord component.Returns the value of theminSquaredrecord component.static NumberRange.IntRangeparse(com.mojang.brigadier.StringReader reader) private static NumberRange.IntRangeparse(com.mojang.brigadier.StringReader reader, Optional<Integer> optional, Optional<Integer> optional2) booleantest(int value) booleantestSqrt(long value) final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.predicate.NumberRange
isDummy, method_53194
-
Field Details
-
getMin
The field for thegetMinrecord component. -
getMax
The field for thegetMaxrecord component. -
minSquared
The field for theminSquaredrecord component. -
maxSquared
The field for themaxSquaredrecord component. -
ANY
- Mappings:
Namespace Name Mixin selector official cLcj$d;c:Lcj$d;intermediary field_9708Lnet/minecraft/class_2096$class_2100;field_9708:Lnet/minecraft/class_2096$class_2100;named ANYLnet/minecraft/predicate/NumberRange$IntRange;ANY:Lnet/minecraft/predicate/NumberRange$IntRange;
-
field_45763
- Mappings:
Namespace Name Mixin selector official dLcj$d;d:Lcom/mojang/serialization/Codec;intermediary field_45763Lnet/minecraft/class_2096$class_2100;field_45763:Lcom/mojang/serialization/Codec;named field_45763Lnet/minecraft/predicate/NumberRange$IntRange;field_45763:Lcom/mojang/serialization/Codec;
-
-
Constructor Details
-
IntRange
-
IntRange
-
-
Method Details
-
parse
private static NumberRange.IntRange parse(com.mojang.brigadier.StringReader reader, Optional<Integer> optional, Optional<Integer> optional2) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException- Mappings:
Namespace Name Mixin selector official aLcj$d;a(Lcom/mojang/brigadier/StringReader;Ljava/util/Optional;Ljava/util/Optional;)Lcj$d;intermediary method_9055Lnet/minecraft/class_2096$class_2100;method_9055(Lcom/mojang/brigadier/StringReader;Ljava/util/Optional;Ljava/util/Optional;)Lnet/minecraft/class_2096$class_2100;named parseLnet/minecraft/predicate/NumberRange$IntRange;parse(Lcom/mojang/brigadier/StringReader;Ljava/util/Optional;Ljava/util/Optional;)Lnet/minecraft/predicate/NumberRange$IntRange;
-
squared
- Mappings:
Namespace Name Mixin selector official aLcj$d;a(Ljava/util/Optional;)Ljava/util/Optional;intermediary method_9059Lnet/minecraft/class_2096$class_2100;method_9059(Ljava/util/Optional;)Ljava/util/Optional;named squaredLnet/minecraft/predicate/NumberRange$IntRange;squared(Ljava/util/Optional;)Ljava/util/Optional;
-
exactly
- Mappings:
Namespace Name Mixin selector official aLcj$d;a(I)Lcj$d;intermediary method_9058Lnet/minecraft/class_2096$class_2100;method_9058(I)Lnet/minecraft/class_2096$class_2100;named exactlyLnet/minecraft/predicate/NumberRange$IntRange;exactly(I)Lnet/minecraft/predicate/NumberRange$IntRange;
-
between
- Mappings:
Namespace Name Mixin selector official aLcj$d;a(II)Lcj$d;intermediary method_35287Lnet/minecraft/class_2096$class_2100;method_35287(II)Lnet/minecraft/class_2096$class_2100;named betweenLnet/minecraft/predicate/NumberRange$IntRange;between(II)Lnet/minecraft/predicate/NumberRange$IntRange;
-
atLeast
- Mappings:
Namespace Name Mixin selector official bLcj$d;b(I)Lcj$d;intermediary method_9053Lnet/minecraft/class_2096$class_2100;method_9053(I)Lnet/minecraft/class_2096$class_2100;named atLeastLnet/minecraft/predicate/NumberRange$IntRange;atLeast(I)Lnet/minecraft/predicate/NumberRange$IntRange;
-
atMost
- Mappings:
Namespace Name Mixin selector official cLcj$d;c(I)Lcj$d;intermediary method_35289Lnet/minecraft/class_2096$class_2100;method_35289(I)Lnet/minecraft/class_2096$class_2100;named atMostLnet/minecraft/predicate/NumberRange$IntRange;atMost(I)Lnet/minecraft/predicate/NumberRange$IntRange;
-
test
public boolean test(int value) - Mappings:
Namespace Name Mixin selector official dLcj$d;d(I)Zintermediary method_9054Lnet/minecraft/class_2096$class_2100;method_9054(I)Znamed testLnet/minecraft/predicate/NumberRange$IntRange;test(I)Z
-
testSqrt
public boolean testSqrt(long value) - Mappings:
Namespace Name Mixin selector official aLcj$d;a(J)Zintermediary method_35288Lnet/minecraft/class_2096$class_2100;method_35288(J)Znamed testSqrtLnet/minecraft/predicate/NumberRange$IntRange;testSqrt(J)Z
-
fromJson
- Mappings:
Namespace Name Mixin selector official aLcj$d;a(Lcom/google/gson/JsonElement;)Lcj$d;intermediary method_9056Lnet/minecraft/class_2096$class_2100;method_9056(Lcom/google/gson/JsonElement;)Lnet/minecraft/class_2096$class_2100;named fromJsonLnet/minecraft/predicate/NumberRange$IntRange;fromJson(Lcom/google/gson/JsonElement;)Lnet/minecraft/predicate/NumberRange$IntRange;
-
method_53199
- Mappings:
Namespace Name Mixin selector official eLcj$d;e()Lcom/google/gson/JsonElement;intermediary method_53199Lnet/minecraft/class_2096$class_2100;method_53199()Lcom/google/gson/JsonElement;named method_53199Lnet/minecraft/predicate/NumberRange$IntRange;method_53199()Lcom/google/gson/JsonElement;
-
parse
public static NumberRange.IntRange parse(com.mojang.brigadier.StringReader reader) throws com.mojang.brigadier.exceptions.CommandSyntaxException - Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException- Mappings:
Namespace Name Mixin selector official aLcj$d;a(Lcom/mojang/brigadier/StringReader;)Lcj$d;intermediary method_9060Lnet/minecraft/class_2096$class_2100;method_9060(Lcom/mojang/brigadier/StringReader;)Lnet/minecraft/class_2096$class_2100;named parseLnet/minecraft/predicate/NumberRange$IntRange;parse(Lcom/mojang/brigadier/StringReader;)Lnet/minecraft/predicate/NumberRange$IntRange;
-
fromStringReader
public static NumberRange.IntRange fromStringReader(com.mojang.brigadier.StringReader reader, Function<Integer, Integer> converter) throws com.mojang.brigadier.exceptions.CommandSyntaxException- Throws:
com.mojang.brigadier.exceptions.CommandSyntaxException- Mappings:
Namespace Name Mixin selector official aLcj$d;a(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;)Lcj$d;intermediary method_9057Lnet/minecraft/class_2096$class_2100;method_9057(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;)Lnet/minecraft/class_2096$class_2100;named fromStringReaderLnet/minecraft/predicate/NumberRange$IntRange;fromStringReader(Lcom/mojang/brigadier/StringReader;Ljava/util/function/Function;)Lnet/minecraft/predicate/NumberRange$IntRange;
-
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). -
getMin
- Specified by:
getMinin interfaceNumberRange<Integer>- Mappings:
Namespace Name Mixin selector official aLcj;a()Ljava/util/Optional;intermediary comp_1805Lnet/minecraft/class_2096;comp_1805()Ljava/util/Optional;named getMinLnet/minecraft/predicate/NumberRange;getMin()Ljava/util/Optional;
-
getMax
- Specified by:
getMaxin interfaceNumberRange<Integer>- Mappings:
Namespace Name Mixin selector official bLcj;b()Ljava/util/Optional;intermediary comp_1806Lnet/minecraft/class_2096;comp_1806()Ljava/util/Optional;named getMaxLnet/minecraft/predicate/NumberRange;getMax()Ljava/util/Optional;
-
minSquared
Returns the value of theminSquaredrecord component.- Returns:
- the value of the
minSquaredrecord component
-
maxSquared
Returns the value of themaxSquaredrecord component.- Returns:
- the value of the
maxSquaredrecord component
-