JavaView® v2.12

jvx.math
Class MathTimerListener

java.lang.Object
  |
  +--jvx.math.MathListener
        |
        +--jvx.math.MathTimerListener
All Implemented Interfaces:
PsTimeListenerIf

public class MathTimerListener
extends MathListener
implements PsTimeListenerIf

Listener to receive time events of a ticker to invoke Mathematica commands. This listener invokes a Mathematica method which has been registered under the name "update".

Version:
21.02.01, 1.20 revised (kp) Adjusted to new methods in PsTimeListenerIf.
16.09.00, 1.10 revised (kp) Adjusted to renaming of interface PsDynamicIf to PsTimeListenerIf.
30.07.00, 1.00 created (kp)
Author:
Konrad Polthier
See Also:
PsTimeListenerIf

Constructor Summary
MathTimerListener()
           
 
Method Summary
 PsAnimation getAnimation()
          Get the animation object of the project which handles the projects animations.
 boolean hasAnimation()
          Check whether this project is registered as listener of an animation object.
 void setAnimation(PsAnimation anAnimation)
          Assign the animation object where this listener is registered.
 boolean setTime(PsTimeEvent time)
          Animation updates the dynamic object through this method whenever time has changed.
 
Methods inherited from class jvx.math.MathListener
getHandler, getName, setHandler, setName
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface jv.anim.PsTimeListenerIf
getName
 

Constructor Detail

MathTimerListener

public MathTimerListener()
Method Detail

setTime

public boolean setTime(PsTimeEvent time)
Animation updates the dynamic object through this method whenever time has changed.
Specified by:
setTime in interface PsTimeListenerIf
Parameters:
event - Pick event issued by the display
See Also:
jv.project.PsTimeListenerIf

getAnimation

public PsAnimation getAnimation()
Get the animation object of the project which handles the projects animations. This listener may only have a single animation object which is assigned by the animation object when this listener is registered using setAnimation(PsAnimation).
Specified by:
getAnimation in interface PsTimeListenerIf
See Also:
hasAnimation(), setAnimation(PsAnimation)

hasAnimation

public boolean hasAnimation()
Check whether this project is registered as listener of an animation object.
Specified by:
hasAnimation in interface PsTimeListenerIf
See Also:
getAnimation(), setAnimation(PsAnimation)

setAnimation

public void setAnimation(PsAnimation anAnimation)
Assign the animation object where this listener is registered. This method is invoked by the animation object during registration of this listener, and usually is not required to be called by a user. If this listener has an assigned animation object, then its animation panel may be shown to change the current time of this listener.

If this project has an animation object assigned in its constructor or init() method, then the animation panel is shown when the project's start() method is invoked during loading of the project.

Only one animation object may be assigned to this listener. Subsequent assignments will replace the previous assignment.

Specified by:
setAnimation in interface PsTimeListenerIf
See Also:
getAnimation(), hasAnimation()

JavaView® v2.12

The software JavaView® is copyright protected. All Rights Reserved.