Record Class RuleBasedStateProvider.Rule
java.lang.Object
java.lang.Record
dev.wyck.worldgen.stateproviders.RuleBasedStateProvider.Rule
- Record Components:
ifTrue- The block predicate of this rule.then- The block to use when the predicate is passed.
- Enclosing interface:
RuleBasedStateProvider
@AsOf("3.0.0")
public static record RuleBasedStateProvider.Rule(BlockPredicate ifTrue, BlockStateProvider then)
extends Record
A rule.
- Since:
- 3.0.0
-
Constructor Summary
ConstructorsConstructorDescriptionRule(BlockPredicate ifTrue, BlockStateProvider then) 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.ifTrue()Returns the value of theifTruerecord component.then()Returns the value of thethenrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
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). -
ifTrue
-
then
-