Record Class TaskSnapshot.PatternSnapshot
java.lang.Object
java.lang.Record
com.refinedmods.refinedstorage.api.autocrafting.task.TaskSnapshot.PatternSnapshot
- Enclosing class:
TaskSnapshot
public static record TaskSnapshot.PatternSnapshot(boolean root, Pattern pattern, Map<Integer,Map<ResourceKey,Long>> ingredients, @Nullable TaskSnapshot.InternalPatternSnapshot internalPattern, @Nullable TaskSnapshot.ExternalPatternSnapshot externalPattern)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionPatternSnapshot(boolean root, Pattern pattern, Map<Integer, Map<ResourceKey, Long>> ingredients, TaskSnapshot.InternalPatternSnapshot internalPattern, TaskSnapshot.ExternalPatternSnapshot externalPattern) Creates an instance of aPatternSnapshotrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the value of theexternalPatternrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of theingredientsrecord component.Returns the value of theinternalPatternrecord component.pattern()Returns the value of thepatternrecord component.booleanroot()Returns the value of therootrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
PatternSnapshot
public PatternSnapshot(boolean root, Pattern pattern, Map<Integer, Map<ResourceKey, Long>> ingredients, @Nullable TaskSnapshot.InternalPatternSnapshot internalPattern, @Nullable TaskSnapshot.ExternalPatternSnapshot externalPattern) Creates an instance of aPatternSnapshotrecord class.- Parameters:
root- the value for therootrecord componentpattern- the value for thepatternrecord componentingredients- the value for theingredientsrecord componentinternalPattern- the value for theinternalPatternrecord componentexternalPattern- the value for theexternalPatternrecord component
-
-
Method Details
-
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 '=='. -
root
public boolean root()Returns the value of therootrecord component.- Returns:
- the value of the
rootrecord component
-
pattern
Returns the value of thepatternrecord component.- Returns:
- the value of the
patternrecord component
-
ingredients
Returns the value of theingredientsrecord component.- Returns:
- the value of the
ingredientsrecord component
-
internalPattern
Returns the value of theinternalPatternrecord component.- Returns:
- the value of the
internalPatternrecord component
-
externalPattern
Returns the value of theexternalPatternrecord component.- Returns:
- the value of the
externalPatternrecord component
-