public class TimeAnimationImpl extends java.lang.Object implements TimeAnimation, java.lang.Runnable
TimeAnimation.TimeAnimationRenderer
Constructor and Description |
---|
TimeAnimationImpl(TimeAnimation.TimeAnimationRenderer renderer) |
Modifier and Type | Method and Description |
---|---|
void |
addObserver(Observer obsrvr) |
void |
deleteObserver(Observer obsrvr) |
void |
deleteObservers() |
int |
getCurrentIteration() |
int |
getCurrentPosition() |
RelativeInterval |
getCurrentTime() |
double |
getFramesPerSecond() |
RelativeInterval |
getInterval() |
int |
getIterations() |
long |
getPauseTime() |
java.lang.String |
getScaleLabel(int scale) |
int |
getStatus() |
java.lang.String |
getStatusLabel(int status) |
long |
getStep() |
long |
getStep(int scale) |
int |
getStepCount() |
int |
getStepScale() |
void |
inferStepScale() |
boolean |
isPlaying()
Return is the animation is playing.
|
void |
pause()
Pauses the animation
|
void |
play()
Play the animation
|
void |
run() |
void |
setCurrentPosition(int position) |
void |
setFramesPerSecond(double fps) |
void |
setInterval(RelativeInterval interval) |
void |
setIterations(int iterations) |
void |
setPauseTime(long time) |
void |
setStep(long step) |
void |
setStep(long step,
int scale) |
void |
stop()
Stops the animation
|
public TimeAnimationImpl(TimeAnimation.TimeAnimationRenderer renderer)
public void addObserver(Observer obsrvr)
addObserver
in interface Observable
public void deleteObserver(Observer obsrvr)
deleteObserver
in interface Observable
public void deleteObservers()
deleteObservers
in interface Observable
public RelativeInterval getInterval()
getInterval
in interface TimeAnimation
public void setInterval(RelativeInterval interval)
setInterval
in interface TimeAnimation
public long getStep()
getStep
in interface TimeAnimation
public void setStep(long step)
setStep
in interface TimeAnimation
public long getStep(int scale)
getStep
in interface TimeAnimation
public int getStepScale()
getStepScale
in interface TimeAnimation
public void setStep(long step, int scale)
setStep
in interface TimeAnimation
public void setFramesPerSecond(double fps)
setFramesPerSecond
in interface TimeAnimation
public double getFramesPerSecond()
getFramesPerSecond
in interface TimeAnimation
public void setPauseTime(long time)
setPauseTime
in interface TimeAnimation
public long getPauseTime()
getPauseTime
in interface TimeAnimation
public int getIterations()
getIterations
in interface TimeAnimation
public void setIterations(int iterations)
setIterations
in interface TimeAnimation
public int getCurrentPosition()
getCurrentPosition
in interface TimeAnimation
public void setCurrentPosition(int position)
setCurrentPosition
in interface TimeAnimation
public int getCurrentIteration()
getCurrentIteration
in interface TimeAnimation
public int getStepCount()
getStepCount
in interface TimeAnimation
public RelativeInterval getCurrentTime()
getCurrentTime
in interface TimeAnimation
public int getStatus()
getStatus
in interface TimeAnimation
public boolean isPlaying()
TimeAnimation
isPlaying
in interface TimeAnimation
public void stop()
TimeAnimation
stop
in interface TimeAnimation
public void pause()
TimeAnimation
pause
in interface TimeAnimation
public void play()
TimeAnimation
play
in interface TimeAnimation
public void run()
run
in interface java.lang.Runnable
public void inferStepScale()
inferStepScale
in interface TimeAnimation
public java.lang.String getStatusLabel(int status)
getStatusLabel
in interface TimeAnimation
public java.lang.String getScaleLabel(int scale)
getScaleLabel
in interface TimeAnimation