Package net.minecraft.client
Record Class OptionInstance.IntRange
java.lang.Object
java.lang.Record
net.minecraft.client.OptionInstance.IntRange
- All Implemented Interfaces:
- OptionInstance.IntRangeBase,- OptionInstance.SliderableValueSet<Integer>,- OptionInstance.ValueSet<Integer>
- Enclosing class:
- OptionInstance<T>
public static record OptionInstance.IntRange(int minInclusive, int maxInclusive)
extends Record
implements OptionInstance.IntRangeBase
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final intThe field for themaxInclusiverecord component.private final intThe field for theminInclusiverecord component.
- 
Constructor SummaryConstructorsConstructorDescriptionIntRange(int minInclusive, int maxInclusive) Creates an instance of aIntRangerecord class.
- 
Method SummaryModifier and TypeMethodDescriptioncom.mojang.serialization.Codec<Integer>codec()final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the value of themaxInclusiverecord component.intReturns the value of theminInclusiverecord component.final StringtoString()Returns a string representation of this record class.validateValue(Integer p_231645_) Methods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.client.OptionInstance.IntRangeBasefromSliderValue, toSliderValue, xmapMethods inherited from interface net.minecraft.client.OptionInstance.SliderableValueSetcreateButton
- 
Field Details- 
minInclusiveprivate final int minInclusiveThe field for theminInclusiverecord component.
- 
maxInclusiveprivate final int maxInclusiveThe field for themaxInclusiverecord component.
 
- 
- 
Constructor Details- 
IntRangepublic IntRange(int minInclusive, int maxInclusive) Creates an instance of aIntRangerecord class.- Parameters:
- minInclusive- the value for the- minInclusiverecord component
- maxInclusive- the value for the- maxInclusiverecord component
 
 
- 
- 
Method Details- 
validateValue- Specified by:
- validateValuein interface- OptionInstance.ValueSet<Integer>
 
- 
codec- Specified by:
- codecin interface- OptionInstance.ValueSet<Integer>
 
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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 with '=='.
- 
minInclusivepublic int minInclusive()Returns the value of theminInclusiverecord component.- Specified by:
- minInclusivein interface- OptionInstance.IntRangeBase
- Returns:
- the value of the minInclusiverecord component
 
- 
maxInclusivepublic int maxInclusive()Returns the value of themaxInclusiverecord component.- Specified by:
- maxInclusivein interface- OptionInstance.IntRangeBase
- Returns:
- the value of the maxInclusiverecord component
 
 
-