|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectlejos.robotics.Movement
public class Movement
Models a movement performed by a pilot
Nested Class Summary | |
---|---|
static class |
Movement.MovementType
The type of movement made in sufficient detail to allow errors in the movement to be modelled. |
Constructor Summary | |
---|---|
Movement(Movement.MovementType type,
float distance,
float angle,
boolean isMoving)
Create a movement object to record a movement made by a pilot |
Method Summary | |
---|---|
float |
getAngleTurned()
Get the angle turned by a rotate or an arc operation. |
float |
getArcRadius()
Get the radius of the arc |
float |
getDistanceTraveled()
Get the distance traveled. |
Movement.MovementType |
getMovementType()
Get the type of the movement performed |
boolean |
isMoving()
Test if move was in progress |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Movement(Movement.MovementType type, float distance, float angle, boolean isMoving)
type
- the movement typedistance
- the distance traveled in pilot unitsangle
- the angle turned in degreesisMoving
- true iff the movement was created while the robot was movingMethod Detail |
---|
public float getDistanceTraveled()
public float getAngleTurned()
public Movement.MovementType getMovementType()
public float getArcRadius()
public boolean isMoving()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |