|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.lang.Thread
nl.knowledgeplaza.util.thread.AnimatedTransition
public abstract class AnimatedTransition
This class adds that the progress runs inside the swing thread with an invokeAndWait.| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class java.lang.Thread |
|---|
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
| Field Summary | |
|---|---|
static java.lang.String |
SOURCECODE_VERSION
Standard variable for determining version of a class file. |
| Fields inherited from class java.lang.Thread |
|---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
| Constructor Summary | |
|---|---|
AnimatedTransition()
|
|
| Method Summary | |
|---|---|
static AnimatedTransition |
appendTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
double stepFactor,
int minimumStepDelay)
Start the animation after the previous has finished |
static AnimatedTransition |
appendTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
int minimumStepDelay)
Start the animation after the previous has finished |
protected void |
begin()
for initializing |
protected void |
done()
For cleaning up (like setting the animation variable to null) When this method is executed, it only means that the animation is finished, NOT that it has reached its end value! |
protected void |
doProcess(double v)
here the process method is called, a hookin for the swing version |
boolean |
getAnimate()
|
double |
getEndValue()
|
int |
getMinimumStepDelay()
|
double |
getStartValue()
|
double |
getStepFactor()
|
double |
getStepSize()
|
double |
getValue()
|
boolean |
isAnimating()
are we currently animating |
static AnimatedTransition |
newTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
double stepFactor,
int minimumStepDelay)
Stop the current transaction and when stopped, start a new. |
static AnimatedTransition |
newTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
int minimumStepDelay)
Stop the current transaction and when stopped, start a new. |
protected abstract void |
progress(double value)
here it happens |
void |
run()
This is the actual animation |
void |
setAnimate(boolean v)
animate |
void |
setEndValue(double v)
The step size in the progress |
void |
setMinimumStepDelay(int v)
The minimum time between each step (milliseconds) |
void |
setStartValue(double v)
The step size in the progress |
void |
setStepFactor(double v)
This allows for non linear transition: the value - endvalue is divided by step factor, if this value is larger than stepsize, this value is used |
void |
setStepSize(double v)
The step size in the progress |
protected void |
setValue(double v)
The current value of the transition |
protected void |
waitForThreadToFinish(java.lang.Thread t)
The swing version of AnimatedTransition does this without blocking the swing thread. |
| Methods inherited from class java.lang.Thread |
|---|
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String SOURCECODE_VERSION
| Constructor Detail |
|---|
public AnimatedTransition()
| Method Detail |
|---|
public void setAnimate(boolean v)
public boolean getAnimate()
public boolean isAnimating()
public void setStartValue(double v)
public double getStartValue()
public void setEndValue(double v)
public double getEndValue()
public void setStepSize(double v)
public double getStepSize()
public void setStepFactor(double v)
public double getStepFactor()
public void setMinimumStepDelay(int v)
public int getMinimumStepDelay()
protected void setValue(double v)
public double getValue()
protected void doProcess(double v)
protected void begin()
protected abstract void progress(double value)
protected void done()
public void run()
run in interface java.lang.Runnablerun in class java.lang.Thread
public static AnimatedTransition newTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
int minimumStepDelay)
previousAnimatedTransition - newAnimatedTransition - startValue - if Double.MIN_VALUE is provided, the start value will be the value of the previous animation after it has stoppedendValue - stepSize - minimumStepDelay -
public static AnimatedTransition newTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
double stepFactor,
int minimumStepDelay)
previousAnimatedTransition - newAnimatedTransition - startValue - if Double.MIN_VALUE is provided, the start value will be the value of the previous animation after it has stoppedendValue - stepSize - stepFactor - minimumStepDelay -
public static AnimatedTransition appendTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
int minimumStepDelay)
previousAnimatedTransition - newAnimatedTransition - startValue - endValue - stepSize - minimumStepDelay -
public static AnimatedTransition appendTransition(AnimatedTransition previousAnimatedTransition,
AnimatedTransition newAnimatedTransition,
double startValue,
double endValue,
double stepSize,
double stepFactor,
int minimumStepDelay)
previousAnimatedTransition - newAnimatedTransition - startValue - endValue - stepSize - minimumStepDelay -
protected void waitForThreadToFinish(java.lang.Thread t)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||