RoboJDETM v2.0

com.ridgesoft.robotics
Class Pose

java.lang.Object
  extended by com.ridgesoft.robotics.Pose

public class Pose
extends Object

Holds x and y Cartesian coordinates and a heading to encapsulate a robot's pose in an immutable object.


Field Summary
 float heading
          The heading in radians.
 float x
          The x coordinate in whatever units the software uses to measure distance.
 float y
          The y coordinate in whatever units the software uses to measure distance.
 
Constructor Summary
Pose(float x, float y, float heading)
          Constructs an immutable Pose object.
 
Method Summary
 String toString()
          Returns a String containing the current pose in the format x, y, heading.
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait
 

Field Detail

heading

public final float heading
The heading in radians.


x

public final float x
The x coordinate in whatever units the software uses to measure distance.


y

public final float y
The y coordinate in whatever units the software uses to measure distance.

Constructor Detail

Pose

public Pose(float x,
            float y,
            float heading)
Constructs an immutable Pose object.

Parameters:
x - x coordinate in whatever units the software uses
y - y coordinate in whatever units the software uses
heading - heading in radians
Method Detail

toString

public String toString()
Returns a String containing the current pose in the format x, y, heading.

The heading is in degrees.

Overrides:
toString in class Object
Returns:
string representation of this object

RoboJDETM v2.0

Copyright (c) 2003-2009 RidgeSoft, LLC. All rights reserved.
www.ridgesoft.com