Record Class GridData.GridResource
java.lang.Object
java.lang.Record
com.refinedmods.refinedstorage.common.grid.GridData.GridResource
- Enclosing class:
GridData
public static record GridData.GridResource(ResourceAmount resourceAmount, Optional<TrackedResource> trackedResource)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionGridResource(ResourceAmount resourceAmount, Optional<TrackedResource> trackedResource) Creates an instance of aGridResourcerecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of theresourceAmountrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetrackedResourcerecord component.
-
Constructor Details
-
GridResource
Creates an instance of aGridResourcerecord class.- Parameters:
resourceAmount- the value for theresourceAmountrecord componenttrackedResource- the value for thetrackedResourcerecord component
-
-
Method Details
-
toString
-
hashCode
-
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). -
resourceAmount
Returns the value of theresourceAmountrecord component.- Returns:
- the value of the
resourceAmountrecord component
-
trackedResource
Returns the value of thetrackedResourcerecord component.- Returns:
- the value of the
trackedResourcerecord component
-