public abstract class Entity
extends java.lang.Object
Engine
engine(s). The interface allows getting information about the entity type, which
is useful for checking ability of an engine to process a given entity.Constructor and Description |
---|
Entity(EntityType type)
Constructs an entity with a given type.
|
Modifier and Type | Method and Description |
---|---|
void |
add(Entity entity)
Adds a given entity to this one.
|
boolean |
equals(java.lang.Object obj) |
EntityType |
getEntityType()
Returns the type of the entity (a unique identifier).
|
int |
hashCode() |
java.lang.String |
toString() |
public Entity(EntityType type)
type
- the entity type.public final EntityType getEntityType()
EntityType
the type of the entity.public void add(Entity entity)
entity
- the entity to be added.public java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object