|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.unifreiburg.twodeedoo.scene.test.StubPhasedPuppet
public class StubPhasedPuppet
IPhasedPuppet
impl with simple fields behind the setters.
Field Summary |
---|
Fields inherited from interface de.unifreiburg.twodeedoo.scene.IPuppet |
---|
NULL_OBJECT |
Constructor Summary | |
---|---|
StubPhasedPuppet(int numberOfPhases)
|
Method Summary | |
---|---|
int |
getCurrentPhase()
|
int |
getNumberOfPhases()
How many phases? |
int |
getX()
X coordinate |
int |
getY()
Y coordinate |
void |
moveAbs(int x,
int y)
Move the reference point to new coordinates. |
void |
paint(java.awt.Graphics g)
Paint something on my coordinates on the given graphics context. |
void |
removeFromScene()
Not implemented. |
void |
setContainingScene(IScene scene)
Not implemented. |
void |
setPhase(int phase)
Which phase to draw from now on |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StubPhasedPuppet(int numberOfPhases)
Method Detail |
---|
public void setPhase(int phase)
IPhasedPuppet
setPhase
in interface IPhasedPuppet
phase
- must be at least 0 and less than IPhasedPuppet.getNumberOfPhases()
public int getX()
IPuppet
getX
in interface IPuppet
public int getY()
IPuppet
getY
in interface IPuppet
public void moveAbs(int x, int y)
IPuppet
moveAbs
in interface IPuppet
x
- x coordinate in the scene of my reference pointy
- y coordinate in the scene of my reference point.public void paint(java.awt.Graphics g)
IPainter
paint
in interface IPainter
g
- some graphics context.public int getCurrentPhase()
public int getNumberOfPhases()
IPhasedPuppet
getNumberOfPhases
in interface IPhasedPuppet
public void removeFromScene()
removeFromScene
in interface IPuppet
IPuppet.removeFromScene()
public void setContainingScene(IScene scene)
setContainingScene
in interface IPuppet
scene
- the new scene. Could be a non-displaying scene.IPuppet.setContainingScene(de.unifreiburg.twodeedoo.scene.IScene)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |