Class AbstractVisual2D
- java.lang.Object
-
- jadex.extension.envsupport.observer.graphics.drawable.AbstractVisual2D
-
- Direct Known Subclasses:
DrawableCombiner
,Primitive
public class AbstractVisual2D extends java.lang.Object
Base class for visual elements.
-
-
Constructor Summary
Constructors Constructor Description AbstractVisual2D()
Initializes the members with default values.AbstractVisual2D(java.lang.Object position, java.lang.Object rotation, java.lang.Object size)
Initializes the members with default values.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
bindPosition(java.lang.String propId)
Binds the position of the visual to an object property.void
bindRotation(java.lang.String propId)
Binds the z-rotation of the visual to an object property.void
bindSize(java.lang.String propId)
Binds the size of the visual to an object property.java.lang.Object
getPosition()
Get the position.java.lang.Object
getRotation()
Get the rotation.java.lang.Object
getSize()
Get the size.void
setPosition(IVector2 pos)
Sets the position of the visual to a fixed position.void
setRotation(IVector3 rotation)
Sets the rotation of the visual to a fixed rotation.void
setSize(IVector2 size)
Sets the size (scale) of the visual to a fixed size.
-
-
-
Method Detail
-
setPosition
public void setPosition(IVector2 pos)
Sets the position of the visual to a fixed position.- Parameters:
pos
- fixed position
-
setRotation
public void setRotation(IVector3 rotation)
Sets the rotation of the visual to a fixed rotation.- Parameters:
rotation
- the fixed rotation
-
setSize
public void setSize(IVector2 size)
Sets the size (scale) of the visual to a fixed size.- Parameters:
size
- fixed size
-
bindPosition
public void bindPosition(java.lang.String propId)
Binds the position of the visual to an object property.- Parameters:
propId
- the property ID
-
bindRotation
public void bindRotation(java.lang.String propId)
Binds the z-rotation of the visual to an object property. (alias for bindZRotation)- Parameters:
propId
- the property ID
-
bindSize
public void bindSize(java.lang.String propId)
Binds the size of the visual to an object property.- Parameters:
propId
- the property ID
-
getSize
public java.lang.Object getSize()
Get the size.- Returns:
- the size.
-
getRotation
public java.lang.Object getRotation()
Get the rotation.- Returns:
- the rotation.
-
getPosition
public java.lang.Object getPosition()
Get the position.- Returns:
- the position.
-
-