Package org.eclipse.draw2d
Class Animator
java.lang.Object
org.eclipse.draw2d.Animator
- Direct Known Subclasses:
- LayoutAnimator,- RoutingAnimator
Animates some aspect of a figure. Each animator will capture some of the
 effects of validation of the figures.
 
Animators must be hooked to figure in special ways. Refer to each implementation for the specific requirements. Animators are generally stateless, which allows them to be shared and prevents them from leaking memory.
- Since:
- 3.2
- 
Method SummaryModifier and TypeMethodDescriptionvoidCaptures the final state of the given figure.protected abstract ObjectgetCurrentState(IFigure figure) Returns an object encapsulating the current state of the figure.voidSets up the animator for the given figure to be animated.protected booleanPlays back the animation for the given figure and returnstrueif successful.voidplaybackStarting(IFigure figure) Sent as playback is starting for a given figure.protected voidrecordFinalState(IFigure figure) Records the final state information for a figure.protected voidrecordInitialState(IFigure figure) Records initial state information for the given figure.voidReverts any temporary changes made to the figure during animation.
- 
Method Details- 
captureCaptures the final state of the given figure. This method is called once after the update manager has completed validation of all invalid figures.- Parameters:
- figure- the container
- Since:
- 3.2
 
- 
getCurrentStateReturns an object encapsulating the current state of the figure. This method is called to capture both the initial and final states.- Parameters:
- figure- the figure
- Returns:
- the current state
- Since:
- 3.2
 
- 
playbackPlays back the animation for the given figure and returnstrueif successful. This method does nothing by default and returnfalse.- Parameters:
- figure- the figure being animated
- Returns:
- trueif playback was successful
- Since:
- 3.2
 
- 
playbackStartingSent as playback is starting for a given figure.- Parameters:
- figure- the figure
- Since:
- 3.2
 
- 
recordFinalStateRecords the final state information for a figure.- Parameters:
- figure- the figure
- Since:
- 3.2
 
- 
recordInitialStateRecords initial state information for the given figure.- Parameters:
- figure- the container.
- Since:
- 3.2
 
- 
initSets up the animator for the given figure to be animated. This method is called exactly once time prior to any layouts happening. The animator can capture the figure's current state, and set any animation-time settings for the figure. Changes made to the figure should be reverted intearDown(IFigure).- Parameters:
- figure- the animated figure
- Since:
- 3.2
 
- 
tearDownReverts any temporary changes made to the figure during animation. This method is called exactly once after all animation has been completed. Subclasses should extend this method to revert any changes.- Parameters:
- figure- the animated figure
- Since:
- 3.2
- See Also:
 
 
-