ciips.animation
Class Trajectory

java.lang.Object
  extended byciips.animation.Trajectory

public class Trajectory
extends java.lang.Object

A trajectory is a set of points which an object will follow on the screen. As an example, it can be used to define the path followed by a node as it moves down a tree looking for the insertion point It would usually be passed to the animate method from DrawingPanel.

See Also:
DrawingPanel.animate(ciips.animation.DrawingObj, java.util.Vector)

Field Summary
static int ARC_INTERPOLATION
           
static int LINEAR_INTERPOLATION
           
static int NO_INTERPOLATION
           
 
Constructor Summary
Trajectory()
           
Trajectory(Trajectory previous)
          Make a new trajectory which starts where the previous one left off
 
Method Summary
 void addPoint(DrawingObj a, java.awt.Point offset)
          Make an object move to a point offset from another one
 void addPoint(java.awt.Point x)
          Add a Point x to the trajectory
 java.awt.Point getPoint(int k)
          Get the points - used by animate
 java.util.Vector getPoints()
          Get the points - used by animate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NO_INTERPOLATION

public static final int NO_INTERPOLATION
See Also:
Constant Field Values

LINEAR_INTERPOLATION

public static final int LINEAR_INTERPOLATION
See Also:
Constant Field Values

ARC_INTERPOLATION

public static final int ARC_INTERPOLATION
See Also:
Constant Field Values
Constructor Detail

Trajectory

public Trajectory()

Trajectory

public Trajectory(Trajectory previous)
Make a new trajectory which starts where the previous one left off

Method Detail

addPoint

public void addPoint(java.awt.Point x)
Add a Point x to the trajectory


addPoint

public void addPoint(DrawingObj a,
                     java.awt.Point offset)
Make an object move to a point offset from another one


getPoint

public java.awt.Point getPoint(int k)
Get the points - used by animate


getPoints

public java.util.Vector getPoints()
Get the points - used by animate