aim4.vehicle
Class BasicVehicle.SteeringMovement

java.lang.Object
  extended by aim4.vehicle.BasicVehicle.NonAccelMovement
      extended by aim4.vehicle.BasicVehicle.SteeringMovement
All Implemented Interfaces:
BasicVehicle.Movement
Enclosing class:
BasicVehicle

public static class BasicVehicle.SteeringMovement
extends BasicVehicle.NonAccelMovement

The steering movement.


Field Summary
 
Fields inherited from class aim4.vehicle.BasicVehicle.NonAccelMovement
heading, position, spec, velocity
 
Constructor Summary
BasicVehicle.SteeringMovement(VehicleSpec spec, Point2D position, double heading, double velocity, double steeringAngle)
          Create a steering movement.
 
Method Summary
 double getSteeringAngle()
          Get the steering angle.
 void move(double currentTime, double timeStep)
          Move the vehicle while holding all vehicle properties constant.
 void setSteeringAngleWithBound(double steeringAngle)
          Set the steering angle with respect to the physical limit of the vehicle.
 String toString()
          
 
Methods inherited from class aim4.vehicle.BasicVehicle.NonAccelMovement
getHeading, getPosition, getVehicleSpec, getVelocity, setVelocityWithBound
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BasicVehicle.SteeringMovement

public BasicVehicle.SteeringMovement(VehicleSpec spec,
                                     Point2D position,
                                     double heading,
                                     double velocity,
                                     double steeringAngle)
Create a steering movement.

Parameters:
spec - the vehicle specification
position - the position
heading - the heading
velocity - the velocity
steeringAngle - the steering angle
Method Detail

getSteeringAngle

public double getSteeringAngle()
Get the steering angle.

Returns:
the steering angle

setSteeringAngleWithBound

public void setSteeringAngleWithBound(double steeringAngle)
Set the steering angle with respect to the physical limit of the vehicle.

Parameters:
steeringAngle - the steering angle

move

public void move(double currentTime,
                 double timeStep)
Move the vehicle while holding all vehicle properties constant.

Parameters:
timeStep - the length of time for which to move the Vehicle
currentTime - the current time

toString

public String toString()

Overrides:
toString in class BasicVehicle.NonAccelMovement


Copyright © 2011. All Rights Reserved.