Class GeyserEntityDataType<T>
java.lang.Object
org.geysermc.geyser.api.entity.data.GeyserEntityDataType<T>
- Type Parameters:
T- the value type associated with this entity data type
- Direct Known Subclasses:
GeyserListEntityDataType
@Experimental
public abstract sealed class GeyserEntityDataType<T>
extends Object
permits GeyserListEntityDataType<T> (not exhaustive)
Represents a type of entity data that can be sent for an entity.
Entity data types define the values stored for a particular piece of metadata,
such as a Byte, Integer, Float; and the name associated with the types.
Unlike properties of custom items or blocks, it is possible to update entity metadata at runtime,
which can be done using GeyserEntity.update(GeyserEntityDataType, Object).
Only the built-in types in GeyserEntityDataTypes are supported. Attempting to use a type
not provided by Geyser will throw an IllegalArgumentException at runtime.
- Since:
- 2.11.0
-
Method Summary
Modifier and TypeMethodDescriptionfinal booleanfinal inthashCode()final IdentifierGets the identifier associated with this entity data type.toString()Gets the Java class representing the value type associated with this data type.
-
Method Details
-
identifier
Gets the identifier associated with this entity data type.- Returns:
- the identifier for this type
- Since:
- 2.11.0
-
typeClass
Gets the Java class representing the value type associated with this data type.- Returns:
- the class of the value used by this entity data type
- Since:
- 2.11.0
-
equals
-
hashCode
public final int hashCode() -
toString
-