Record Class ContaminantInfoCategory.ContaminantInfoRecipe<STACK>
java.lang.Object
java.lang.Record
com.petrolpark.compat.jei.category.ContaminantInfoCategory.ContaminantInfoRecipe<STACK>
- Enclosing class:
ContaminantInfoCategory<STACK>
public static record ContaminantInfoCategory.ContaminantInfoRecipe<STACK>(Optional<Pair<STACK,IContamination<?,STACK>>> stack, net.minecraft.core.Holder<Contaminant> contaminant)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionContaminantInfoRecipe(Optional<Pair<STACK, IContamination<?, STACK>>> stack, net.minecraft.core.Holder<Contaminant> contaminant) Creates an instance of aContaminantInfoReciperecord class. -
Method Summary
Modifier and TypeMethodDescriptionnet.minecraft.core.Holder<Contaminant> Returns the value of thecontaminantrecord component.final booleanIndicates whether some other object is "equal to" this one.static ContaminantInfoCategory.ContaminantInfoRecipe<net.minecraft.world.item.ItemStack> forItemStacks(net.minecraft.core.Holder<Contaminant> contaminant) final inthashCode()Returns a hash code value for this object.Optional<Pair<STACK, IContamination<?, STACK>>> stack()Returns the value of thestackrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ContaminantInfoRecipe
public ContaminantInfoRecipe(Optional<Pair<STACK, IContamination<?, STACK>>> stack, net.minecraft.core.Holder<Contaminant> contaminant) Creates an instance of aContaminantInfoReciperecord class.- Parameters:
stack- the value for thestackrecord componentcontaminant- the value for thecontaminantrecord component
-
-
Method Details
-
forItemStacks
public static ContaminantInfoCategory.ContaminantInfoRecipe<net.minecraft.world.item.ItemStack> forItemStacks(net.minecraft.core.Holder<Contaminant> contaminant) -
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. All components in this record class are compared withObjects::equals(Object,Object). -
stack
Returns the value of thestackrecord component.- Returns:
- the value of the
stackrecord component
-
contaminant
Returns the value of thecontaminantrecord component.- Returns:
- the value of the
contaminantrecord component
-