Record Class CachedParseState.CacheEntry<T>
java.lang.Object
java.lang.Record
net.minecraft.util.parsing.packrat.CachedParseState.CacheEntry<T>
- Enclosing class:
CachedParseState<S>
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final int
The field for themarkAfterParse
record component.static final CachedParseState.CacheEntry
<?> private final T
The field for thevalue
record component. -
Constructor Summary
ConstructorsConstructorDescriptionCacheEntry
(T value, int markAfterParse) Creates an instance of aCacheEntry
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.int
Returns the value of themarkAfterParse
record component.static <T> CachedParseState.CacheEntry
<T> final String
toString()
Returns a string representation of this record class.value()
Returns the value of thevalue
record component.
-
Field Details
-
value
The field for thevalue
record component. -
markAfterParse
private final int markAfterParseThe field for themarkAfterParse
record component. -
NEGATIVE
-
-
Constructor Details
-
CacheEntry
CacheEntry(@Nullable T value, int markAfterParse) Creates an instance of aCacheEntry
record class.- Parameters:
value
- the value for thevalue
record componentmarkAfterParse
- the value for themarkAfterParse
record component
-
-
Method Details
-
negativeEntry
-
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. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
value
Returns the value of thevalue
record component.- Returns:
- the value of the
value
record component
-
markAfterParse
public int markAfterParse()Returns the value of themarkAfterParse
record component.- Returns:
- the value of the
markAfterParse
record component
-