Class DrawableCombiner
- java.lang.Object
- 
- jadex.extension.envsupport.observer.graphics.drawable.AbstractVisual2D
- 
- jadex.extension.envsupport.observer.graphics.drawable.DrawableCombiner
 
 
- 
- All Implemented Interfaces:
- IPropertyObject
 
 public class DrawableCombiner extends AbstractVisual2D implements IPropertyObject This drawable combines multiple drawables into a single drawable object.
- 
- 
Field SummaryFields Modifier and Type Field Description protected java.util.MappropertiesThe properties
 - 
Constructor SummaryConstructors Constructor Description DrawableCombiner()Creates a new DrawableCombiner of size 1.0.DrawableCombiner(java.lang.Object position, java.lang.Object rotation, java.lang.Object size)Creates a new DrawableCombiner of size 1.0.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddPrimitive(Primitive p)Adds a primitive to the combiner.voidaddPrimitive(Primitive p, int layer)Adds a primitive to the combiner in a specific layer.voiddraw(java.lang.Object obj, java.lang.Integer layer, IViewport vp)Draws the objects to a viewportvoidflushRenderInfo()Flushes the render information.java.lang.ObjectgetBoundValue(java.lang.Object obj, java.lang.Object prop, IViewport viewport)Gets the bound value for a property.java.util.SetgetLayers()Returns all layers used by this DrawableCombiner.java.lang.ObjectgetProperty(java.lang.String name)Returns a property.java.util.SetgetPropertyNames()Returns all of the properties.booleanhasProperty(java.lang.String name)Tests if the given property name exists If an property isnullit existsvoidremovePrimitive(Primitive p)Removes a primitive from all layers in the combiner.voidsetProperty(java.lang.String name, java.lang.Object value)Sets a property- 
Methods inherited from class jadex.extension.envsupport.observer.graphics.drawable.AbstractVisual2DbindPosition, bindRotation, bindSize, getPosition, getRotation, getSize, setPosition, setRotation, setSize
 
- 
 
- 
- 
- 
Method Detail- 
addPrimitivepublic void addPrimitive(Primitive p) Adds a primitive to the combiner.- Parameters:
- p- the primitive
 
 - 
addPrimitivepublic void addPrimitive(Primitive p, int layer) Adds a primitive to the combiner in a specific layer.- Parameters:
- p- the primitive
- layer- the layer
- sizeDefining- true if the added object should be the size-defining one
 
 - 
removePrimitivepublic void removePrimitive(Primitive p) Removes a primitive from all layers in the combiner.- Parameters:
- p- the primitive
 
 - 
drawpublic void draw(java.lang.Object obj, java.lang.Integer layer, IViewport vp)Draws the objects to a viewport- Parameters:
- obj- object being drawn
- layer- the current layer
- vp- the viewport
 
 - 
getLayerspublic java.util.Set getLayers() Returns all layers used by this DrawableCombiner.- Returns:
- all layers used by the DrawableCombiner
 
 - 
flushRenderInfopublic void flushRenderInfo() Flushes the render information.
 - 
getBoundValuepublic java.lang.Object getBoundValue(java.lang.Object obj, java.lang.Object prop, IViewport viewport)Gets the bound value for a property.- Returns:
- The bound value.
 
 - 
getPropertypublic java.lang.Object getProperty(java.lang.String name) Returns a property.- Specified by:
- getPropertyin interface- IPropertyObject
- Parameters:
- name- name of the property
- Returns:
- the property
 
 - 
getPropertyNamespublic java.util.Set getPropertyNames() Returns all of the properties.- Specified by:
- getPropertyNamesin interface- IPropertyObject
- Returns:
- the properties
 
 - 
setPropertypublic void setProperty(java.lang.String name, java.lang.Object value)Sets a property- Specified by:
- setPropertyin interface- IPropertyObject
- Parameters:
- name- name of the property
- value- value of the property
 
 - 
hasPropertypublic boolean hasProperty(java.lang.String name) Description copied from interface:IPropertyObjectTests if the given property name exists If an property isnullit exists- Specified by:
- hasPropertyin interface- IPropertyObject
- Parameters:
- name- the name of the property to test
- Returns:
- trueif and only if the property exists
 
 
- 
 
-