Record Class FluidMixing.Rule
java.lang.Object
java.lang.Record
fr.robie.machineengine.api.resource.fluid.FluidMixing.Rule
- Enclosing class:
FluidMixing
public static record FluidMixing.Rule(@NotNull FluidMixing.Selector with, @NotNull FluidReaction reaction)
extends Record
One rule: when the fluid already there matches
with, reaction decides.-
Constructor Summary
ConstructorsConstructorDescriptionRule(@NotNull FluidMixing.Selector with, @NotNull FluidReaction reaction) Creates an instance of aRulerecord 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.@NotNull FluidReactionreaction()Returns the value of thereactionrecord component.final StringtoString()Returns a string representation of this record class.@NotNull FluidMixing.Selectorwith()Returns the value of thewithrecord component.
-
Constructor Details
-
Rule
Creates an instance of aRulerecord class.- Parameters:
with- the value for thewithrecord componentreaction- the value for thereactionrecord 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). -
with
Returns the value of thewithrecord component.- Returns:
- the value of the
withrecord component
-
reaction
Returns the value of thereactionrecord component.- Returns:
- the value of the
reactionrecord component
-