public interface IMesh extends IManagedUpdateable, IManagedUpdateableListener
Modifier and Type | Method and Description |
---|---|
void |
addEntity(IController newEntity)
Add a new entity to the part.
|
void |
addEntityToCategory(IController newEntity,
IMeshCategory category)
Adds a new child entity under the given category.
|
void |
copy(IMesh otherObject)
Deep copies the contents of another AbstractMeshComponent into this one.
|
java.util.ArrayList<IController> |
getAllEntities()
Returns a list of all related entities.
|
IController |
getController()
Getter method for the controller.
|
java.util.Map<IMeshCategory,java.util.ArrayList<IController>> |
getEntities()
Get the entities map in the form of an array of map entries.
|
java.util.ArrayList<IController> |
getEntitiesFromCategory(IMeshCategory category)
Return all of the part's children entities of a given category.
|
<T extends IController> |
getEntitiesFromCategory(IMeshCategory category,
java.lang.Class<T> returnType)
Return all of the part's children entities of a given category cast to a
list of the specified return type.
|
java.util.Set<IMeshCategory> |
getEntityCategories()
Get the set of all categories in the mesh's entities map.
|
java.util.Map<IMeshProperty,java.lang.String> |
getProperties()
Get the properties map in the form of an array of map entries.
|
java.lang.String |
getProperty(IMeshProperty property)
Return the value of the given property
|
java.util.Map<IMeshProperty,java.lang.String> |
getPropertyMap()
Get the entire properties map for the mesh.
|
double[] |
getRotation()
Get the part's rotation in the x, y, and z directions
|
double[] |
getScale()
Get the part's scale in the x, y, and z directions.
|
double |
getSize()
Get the part's size.
|
double[] |
getSkew()
Get the part's skew in the x, y, and z directions
|
Transformation |
getTransformation()
Getter function for the part's transformation.
|
double[] |
getTranslation()
Get the part's translation in the x, y, and z directions
|
MeshType |
getType()
Getter method for type.
|
void |
removeEntity(IController entity)
Removes the given entity from the part's children
|
void |
setController(IController controller)
Setter method for the controller.
|
void |
setEntities(java.util.Map<IMeshCategory,java.util.ArrayList<IController>> entities)
Set the mesh's map of entities to be equal to the provided map.
|
void |
setProperties(java.util.Map<IMeshProperty,java.lang.String> properties)
Set the mesh's properties according to the given map.
|
void |
setProperty(IMeshProperty property,
java.lang.String value)
Set the given property, creating it in the map if it is not already
present.
|
void |
setTransformation(Transformation newTransformation)
Setter function for the part's transformation.
|
void |
setType(MeshType type)
Setter method for the mesh's type
|
register, unregister
getSubscriptions, update
MeshType getType()
void setType(MeshType type)
java.util.ArrayList<IController> getAllEntities()
java.util.ArrayList<IController> getEntitiesFromCategory(IMeshCategory category)
category
- The category of entities to return<T extends IController> java.util.ArrayList<T> getEntitiesFromCategory(IMeshCategory category, java.lang.Class<T> returnType)
category
- The category of entities to returnreturnType
- The class to which members of the category belong.java.lang.String getProperty(IMeshProperty property)
void setProperty(IMeshProperty property, java.lang.String value)
java.util.Map<IMeshProperty,java.lang.String> getPropertyMap()
void addEntity(IController newEntity)
void removeEntity(IController entity)
void addEntityToCategory(IController newEntity, IMeshCategory category)
newEntity
- The new child entity to be addedcategory
- The new entity's categoryvoid copy(IMesh otherObject)
otherObject
- The object which will be copied into this.IController getController()
Transformation getTransformation()
void setController(IController controller)
controller
- The IController which manages this componentjava.util.Set<IMeshCategory> getEntityCategories()
java.util.Map<IMeshCategory,java.util.ArrayList<IController>> getEntities()
java.util.Map<IMeshProperty,java.lang.String> getProperties()
void setEntities(java.util.Map<IMeshCategory,java.util.ArrayList<IController>> entities)
entities
- void setProperties(java.util.Map<IMeshProperty,java.lang.String> properties)
properties
- The new map of properties for the mesh.void setTransformation(Transformation newTransformation)
newTransformation
- The transformation to apply to this part.double[] getRotation()
double[] getScale()
double getSize()
double[] getSkew()
double[] getTranslation()