Class Transitions
- java.lang.Object
-
- org.pepstock.charba.client.configuration.Transitions
-
- All Implemented Interfaces:
IsDefaultTransitions
,IsTransitions
public class Transitions extends Object implements IsTransitions
It animates charts out of the box.
A number of options are provided to configure how the animation looks and how long it takes.
This configuration item is configuring the common animation properties for a specific update mode (transition).- Author:
- Andrea "Stock" Stocchero
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AnimationTransition
create(TransitionMode transition)
Creates an animation transition instance and stores in the animation options.AnimationTransition
get(TransitionMode transition)
Returns an animation transition instance if stored in the animation options.boolean
has(TransitionMode transition)
Returnstrue
if an animation transition instance is stored in the animation options.void
remove(TransitionMode transition)
Removes an animation transition previously added.void
set(TransitionMode transition, AnimationTransition animationTransition)
Sets an animation transition instance to store in the animation options.
-
-
-
Method Detail
-
has
public boolean has(TransitionMode transition)
Returnstrue
if an animation transition instance is stored in the animation options.- Specified by:
has
in interfaceIsDefaultTransitions
- Parameters:
transition
- transition instance used to check in the animation options- Returns:
true
if an animation transition instance is stored in the animation options
-
get
public AnimationTransition get(TransitionMode transition)
Returns an animation transition instance if stored in the animation options.- Specified by:
get
in interfaceIsDefaultTransitions
- Specified by:
get
in interfaceIsTransitions
- Parameters:
transition
- transition instance used to get for animation options- Returns:
- an animation transition instance or
null
if does not exists
-
set
public void set(TransitionMode transition, AnimationTransition animationTransition)
Sets an animation transition instance to store in the animation options.- Specified by:
set
in interfaceIsTransitions
- Parameters:
transition
- transition instance used to get for animation optionsanimationTransition
- an animation transition instance to set
-
create
public AnimationTransition create(TransitionMode transition)
Creates an animation transition instance and stores in the animation options.- Specified by:
create
in interfaceIsTransitions
- Parameters:
transition
- transition key used to create the animation transitions- Returns:
- a transition animation options
-
remove
public void remove(TransitionMode transition)
Removes an animation transition previously added.- Specified by:
remove
in interfaceIsTransitions
- Parameters:
transition
- transition instance used to remove from animation options
-
-