Package net.minecraft.util.dynamic
Record Class Range<T extends Comparable<T>>
java.lang.Object
java.lang.Record
net.minecraft.util.dynamic.Range<T>
- Record Components:
minInclusive
-maxInclusive
-
public record Range<T extends Comparable<T>>(T extends Comparable<T> minInclusive, T extends Comparable<T> maxInclusive)
extends Record
- Mappings:
Namespace Name named net/minecraft/util/dynamic/Range
intermediary net/minecraft/class_6497
official azw
named minInclusive
intermediary comp_1
official b
named maxInclusive
intermediary comp_2
official c
-
Field Summary
Modifier and TypeFieldDescriptionprivate final T
The field for themaxInclusive
record component.private final T
The field for theminInclusive
record component. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
static <T extends Comparable<T>>
com.mojang.serialization.Codec<Range<T>> createCodec
(com.mojang.serialization.Codec<T> elementCodec) static <T extends Comparable<T>>
com.mojang.serialization.Codec<Range<T>> createRangedCodec
(com.mojang.serialization.Codec<T> codec, T minInclusive, T maxInclusive) final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.Returns the value of themaxInclusive
record component.Returns the value of theminInclusive
record component.toString()
Returns a string representation of this record class.static <T extends Comparable<T>>
com.mojang.serialization.DataResult<Range<T>> validate
(T minInclusive, T maxInclusive)
-
Field Details
-
minInclusive
The field for theminInclusive
record component. -
maxInclusive
The field for themaxInclusive
record component. -
CODEC
- Mappings:
Namespace Name Mixin selector named CODEC
Lnet/minecraft/util/dynamic/Range;CODEC:Lcom/mojang/serialization/Codec;
intermediary field_34390
Lnet/minecraft/class_6497;field_34390:Lcom/mojang/serialization/Codec;
official a
Lazw;a:Lcom/mojang/serialization/Codec;
-
-
Constructor Details
-
Range
Creates an instance of aRange
record class.- Parameters:
minInclusive
- the value for theminInclusive
record componentmaxInclusive
- the value for themaxInclusive
record component
-
Range
- Mappings:
Namespace Name Mixin selector named <init>
Lnet/minecraft/util/dynamic/Range;<init>(Ljava/lang/Comparable;)V
intermediary <init>
Lnet/minecraft/class_6497;<init>(Ljava/lang/Comparable;)V
official <init>
Lazw;<init>(Ljava/lang/Comparable;)V
-
-
Method Details
-
createCodec
public static <T extends Comparable<T>> com.mojang.serialization.Codec<Range<T>> createCodec(com.mojang.serialization.Codec<T> elementCodec) - Mappings:
Namespace Name Mixin selector named createCodec
Lnet/minecraft/util/dynamic/Range;createCodec(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
intermediary method_37953
Lnet/minecraft/class_6497;method_37953(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
official a
Lazw;a(Lcom/mojang/serialization/Codec;)Lcom/mojang/serialization/Codec;
-
createRangedCodec
public static <T extends Comparable<T>> com.mojang.serialization.Codec<Range<T>> createRangedCodec(com.mojang.serialization.Codec<T> codec, T minInclusive, T maxInclusive) - Mappings:
Namespace Name Mixin selector named createRangedCodec
Lnet/minecraft/util/dynamic/Range;createRangedCodec(Lcom/mojang/serialization/Codec;Ljava/lang/Comparable;Ljava/lang/Comparable;)Lcom/mojang/serialization/Codec;
intermediary method_37954
Lnet/minecraft/class_6497;method_37954(Lcom/mojang/serialization/Codec;Ljava/lang/Comparable;Ljava/lang/Comparable;)Lcom/mojang/serialization/Codec;
official a
Lazw;a(Lcom/mojang/serialization/Codec;Ljava/lang/Comparable;Ljava/lang/Comparable;)Lcom/mojang/serialization/Codec;
-
validate
public static <T extends Comparable<T>> com.mojang.serialization.DataResult<Range<T>> validate(T minInclusive, T maxInclusive) - Mappings:
Namespace Name Mixin selector named validate
Lnet/minecraft/util/dynamic/Range;validate(Ljava/lang/Comparable;Ljava/lang/Comparable;)Lcom/mojang/serialization/DataResult;
intermediary method_37956
Lnet/minecraft/class_6497;method_37956(Ljava/lang/Comparable;Ljava/lang/Comparable;)Lcom/mojang/serialization/DataResult;
official a
Lazw;a(Ljava/lang/Comparable;Ljava/lang/Comparable;)Lcom/mojang/serialization/DataResult;
-
contains
- Mappings:
Namespace Name Mixin selector named contains
Lnet/minecraft/util/dynamic/Range;contains(Ljava/lang/Comparable;)Z
intermediary method_37955
Lnet/minecraft/class_6497;method_37955(Ljava/lang/Comparable;)Z
official a
Lazw;a(Ljava/lang/Comparable;)Z
-
contains
- Mappings:
Namespace Name Mixin selector named contains
Lnet/minecraft/util/dynamic/Range;contains(Lnet/minecraft/util/dynamic/Range;)Z
intermediary method_37952
Lnet/minecraft/class_6497;method_37952(Lnet/minecraft/class_6497;)Z
official a
Lazw;a(Lazw;)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)
. -
minInclusive
Returns the value of theminInclusive
record component.- Returns:
- the value of the
minInclusive
record component
-
maxInclusive
Returns the value of themaxInclusive
record component.- Returns:
- the value of the
maxInclusive
record component
-