org.opensourcephysics.controls
Interface Animation

All Known Subinterfaces:
Simulation
All Known Implementing Classes:
AbstractAnimation, AbstractSimulation

public interface Animation

An animation performs repetitive calculations in a separate thread. Prior to starting the thread, the control should invoke initializeAnimation(). The thread is started when the control invokes startAnimation().

Version:
1.0
Author:
Joshua Gould, Wolfgang Christian

Method Summary
 void initializeAnimation()
          Initializes the animation.
 void resetAnimation()
          Resets the animation to a known initial state.
 void setControl(Control control)
          Sets the object that controls this animation.
 void startAnimation()
          Starts the animation thread.
 void stepAnimation()
          Performs a single animation step.
 void stopAnimation()
          Stops the animation thread.
 

Method Detail

setControl

void setControl(Control control)
Sets the object that controls this animation.

Parameters:
control -

startAnimation

void startAnimation()
Starts the animation thread.


stopAnimation

void stopAnimation()
Stops the animation thread.


initializeAnimation

void initializeAnimation()
Initializes the animation.


resetAnimation

void resetAnimation()
Resets the animation to a known initial state.


stepAnimation

void stepAnimation()
Performs a single animation step.