Record Class DataComponentPredicate.FireworkExplosionPredicate
java.lang.Object
java.lang.Record
net.minestom.server.instance.block.predicate.DataComponentPredicate.FireworkExplosionPredicate
- All Implemented Interfaces:
Predicate<FireworkExplosion>
- Enclosing interface:
DataComponentPredicate
public static record DataComponentPredicate.FireworkExplosionPredicate(FireworkExplosion.Shape shape, @Nullable Boolean hasTrail, @Nullable Boolean hasTwinkle)
extends Record
implements Predicate<FireworkExplosion>
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Codec<DataComponentPredicate.FireworkExplosionPredicate> -
Constructor Summary
ConstructorsConstructorDescriptionFireworkExplosionPredicate(FireworkExplosion.Shape shape, @Nullable Boolean hasTrail, @Nullable Boolean hasTwinkle) Creates an instance of aFireworkExplosionPredicaterecord 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.hasTrail()Returns the value of thehasTrailrecord component.Returns the value of thehasTwinklerecord component.shape()Returns the value of theshaperecord component.booleantest(FireworkExplosion explosion) final StringtoString()Returns a string representation of this record class.
-
Field Details
-
CODEC
-
-
Constructor Details
-
FireworkExplosionPredicate
public FireworkExplosionPredicate(@Nullable FireworkExplosion.Shape shape, @Nullable @Nullable Boolean hasTrail, @Nullable @Nullable Boolean hasTwinkle) Creates an instance of aFireworkExplosionPredicaterecord class.- Parameters:
shape- the value for theshaperecord componenthasTrail- the value for thehasTrailrecord componenthasTwinkle- the value for thehasTwinklerecord component
-
-
Method Details
-
test
- Specified by:
testin interfacePredicate<FireworkExplosion>
-
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). -
shape
Returns the value of theshaperecord component.- Returns:
- the value of the
shaperecord component
-
hasTrail
-
hasTwinkle
-