Record Class ResourceContainerInsertStrategy.InsertResult
java.lang.Object
java.lang.Record
com.refinedmods.refinedstorage.common.api.support.resource.ResourceContainerInsertStrategy.InsertResult
- Enclosing interface:
ResourceContainerInsertStrategy
public static record ResourceContainerInsertStrategy.InsertResult(net.minecraft.world.item.ItemStack container, long inserted)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionInsertResult(net.minecraft.world.item.ItemStack container, long inserted) Creates an instance of aInsertResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.world.item.ItemStackReturns the value of thecontainerrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.longinserted()Returns the value of theinsertedrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
InsertResult
public InsertResult(net.minecraft.world.item.ItemStack container, long inserted) Creates an instance of aInsertResultrecord class.- Parameters:
container- the value for thecontainerrecord componentinserted- the value for theinsertedrecord 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 '=='. -
container
public net.minecraft.world.item.ItemStack container()Returns the value of thecontainerrecord component.- Returns:
- the value of the
containerrecord component
-
inserted
public long inserted()Returns the value of theinsertedrecord component.- Returns:
- the value of the
insertedrecord component
-