Record Class PatternLayout
java.lang.Object
java.lang.Record
com.refinedmods.refinedstorage.api.autocrafting.PatternLayout
- Record Components:
ingredients- the ingredientsoutputs- the outputsbyproducts- the byproductstype- the type
@API(status=STABLE,
since="2.0.0-milestone.4.12")
public record PatternLayout(List<Ingredient> ingredients, List<ResourceAmount> outputs, List<ResourceAmount> byproducts, PatternType type)
extends Record
Represents a pattern layout. Multiple
Patterns can share the same layout.-
Constructor Summary
ConstructorsConstructorDescriptionPatternLayout(List<Ingredient> ingredients, List<ResourceAmount> outputs, List<ResourceAmount> byproducts, PatternType type) Creates an instance of aPatternLayoutrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thebyproductsrecord component.final booleanIndicates whether some other object is "equal to" this one.static PatternLayoutexternal(List<Ingredient> ingredients, List<ResourceAmount> outputs) final inthashCode()Returns a hash code value for this object.Returns the value of theingredientsrecord component.static PatternLayoutinternal(List<Ingredient> ingredients, List<ResourceAmount> outputs, List<ResourceAmount> byproducts) outputs()Returns the value of theoutputsrecord component.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.
-
Constructor Details
-
PatternLayout
public PatternLayout(List<Ingredient> ingredients, List<ResourceAmount> outputs, List<ResourceAmount> byproducts, PatternType type) Creates an instance of aPatternLayoutrecord class.- Parameters:
ingredients- the value for theingredientsrecord componentoutputs- the value for theoutputsrecord componentbyproducts- the value for thebyproductsrecord componenttype- the value for thetyperecord component
-
-
Method Details
-
external
-
internal
public static PatternLayout internal(List<Ingredient> ingredients, List<ResourceAmount> outputs, List<ResourceAmount> byproducts) -
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). -
ingredients
Returns the value of theingredientsrecord component.- Returns:
- the value of the
ingredientsrecord component
-
outputs
Returns the value of theoutputsrecord component.- Returns:
- the value of the
outputsrecord component
-
byproducts
Returns the value of thebyproductsrecord component.- Returns:
- the value of the
byproductsrecord component
-
type
Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-