Record Class SurfaceRules.SequenceRuleSource
java.lang.Object
java.lang.Record
net.minecraft.world.level.levelgen.SurfaceRules.SequenceRuleSource
- All Implemented Interfaces:
Function<SurfaceRules.Context, SurfaceRules.SurfaceRule>, SurfaceRules.RuleSource
- Enclosing class:
SurfaceRules
private static record SurfaceRules.SequenceRuleSource(List<SurfaceRules.RuleSource> sequence)
extends Record
implements SurfaceRules.RuleSource
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final KeyDispatchDataCodec<SurfaceRules.SequenceRuleSource> private final List<SurfaceRules.RuleSource> The field for thesequencerecord component. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateSequenceRuleSource(List<SurfaceRules.RuleSource> sequence) Creates an instance of aSequenceRuleSourcerecord class. -
Method Summary
Modifier and TypeMethodDescriptionapply(SurfaceRules.Context context) KeyDispatchDataCodec<? extends SurfaceRules.RuleSource> codec()final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.sequence()Returns the value of thesequencerecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
sequence
The field for thesequencerecord component. -
CODEC
-
-
Constructor Details
-
SequenceRuleSource
Creates an instance of aSequenceRuleSourcerecord class.- Parameters:
sequence- the value for thesequencerecord component
-
-
Method Details
-
codec
- Specified by:
codecin interfaceSurfaceRules.RuleSource
-
apply
- Specified by:
applyin interfaceFunction<SurfaceRules.Context, SurfaceRules.SurfaceRule>
-
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). -
sequence
Returns the value of thesequencerecord component.- Returns:
- the value of the
sequencerecord component
-