Record Class PropertiesPredicate
java.lang.Object
java.lang.Record
net.minestom.server.instance.block.predicate.PropertiesPredicate
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final BinaryTagSerializer<PropertiesPredicate> static final NetworkBuffer.Type<PropertiesPredicate> -
Constructor Summary
ConstructorsConstructorDescriptionPropertiesPredicate(@NotNull Map<String, PropertiesPredicate.ValuePredicate> properties) Creates an instance of aPropertiesPredicaterecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.static @NotNull PropertiesPredicatefinal inthashCode()Returns a hash code value for this object.@NotNull Map<String, PropertiesPredicate.ValuePredicate> Returns the value of thepropertiesrecord component.booleanfinal StringtoString()Returns a string representation of this record class.
-
Field Details
-
NETWORK_TYPE
-
NBT_TYPE
-
-
Constructor Details
-
PropertiesPredicate
public PropertiesPredicate(@NotNull @NotNull Map<String, PropertiesPredicate.ValuePredicate> properties) Creates an instance of aPropertiesPredicaterecord class.- Parameters:
properties- the value for thepropertiesrecord component
-
-
Method Details
-
exact
@NotNull public static @NotNull PropertiesPredicate exact(@NotNull @NotNull String key, @NotNull @NotNull String value) -
test
-
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). -
properties
Returns the value of thepropertiesrecord component.- Returns:
- the value of the
propertiesrecord component
-