Boeing Simulation 3.1 API Specification

objects
Class MovingObject

java.lang.Object
  |
  +--objects.WhatWhere
        |
        +--objects.MovingObject
All Implemented Interfaces:
Extensible, Locatable, Movable, Serializable

public class MovingObject
extends WhatWhere
implements Movable

This class is intended to be the the basis for moving physical objects in the world. It provides methods for update the location of the object. The Mover class uses the Movable provided and updates its location via setLoc calls.

Version:
$Revision: 1.5 $
Author:
Dave Jurgens
See Also:
Serialized Form

Field Summary
protected  objects.Mover mover
           
private static long serialVersionUID
           
 
Fields inherited from class objects.WhatWhere
dim, loc
 
Constructor Summary
MovingObject(double xcoord, double ycoord, double width, double height)
           
MovingObject(double xcoord, double ycoord, double width, double height, objects.Mover mover)
           
MovingObject(objects.Location loc, objects.Dimension dim)
           
MovingObject(objects.Location loc, objects.Dimension dim, objects.Mover mover)
           
 
Method Summary
 double getMovementRate()
           
 boolean isMoving()
           
 void setLoc(double xcoord, double ycoord)
          Sets the location of this object to the coordinate arguments.
 void setLoc(objects.Location loc)
          Sets the location of this object to loc.
 void startMoving(objects.Mover mover)
           
 void stopMoving()
           
 
Methods inherited from class objects.WhatWhere
bound, getCenter, getDimensions, getDistance, getHeight, getLoc, getWidth, isEastOf, isNorthOf, isSouthOf, isWestOf, overlaps
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface objects.Locatable
getDistance, getLoc, isEastOf, isNorthOf, isSouthOf, isWestOf
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

mover

protected objects.Mover mover
Constructor Detail

MovingObject

public MovingObject(objects.Location loc,
                    objects.Dimension dim,
                    objects.Mover mover)

MovingObject

public MovingObject(objects.Location loc,
                    objects.Dimension dim)

MovingObject

public MovingObject(double xcoord,
                    double ycoord,
                    double width,
                    double height,
                    objects.Mover mover)

MovingObject

public MovingObject(double xcoord,
                    double ycoord,
                    double width,
                    double height)
Method Detail

setLoc

public void setLoc(objects.Location loc)
Description copied from interface: Movable
Sets the location of this object to loc.

Specified by:
setLoc in interface Movable

setLoc

public void setLoc(double xcoord,
                   double ycoord)
Description copied from interface: Movable
Sets the location of this object to the coordinate arguments.

Specified by:
setLoc in interface Movable

startMoving

public void startMoving(objects.Mover mover)

stopMoving

public void stopMoving()

isMoving

public boolean isMoving()

getMovementRate

public double getMovementRate()

Boeing Simulation 3.1 API Specification

To submit a bug or feature email the author of that class. Funding for this research was provided by Boeing and DARPA.