Package com.bumptech.glide
Class TransitionOptions<CHILD extends TransitionOptions<CHILD,TranscodeType>,TranscodeType>
java.lang.Object
com.bumptech.glide.TransitionOptions<CHILD,TranscodeType>
- Type Parameters:
CHILD- The implementation of this class to return to chain methods.TranscodeType- The type of resource that will be animated.
- All Implemented Interfaces:
Cloneable
- Direct Known Subclasses:
BitmapTransitionOptions,DrawableTransitionOptions,GenericTransitionOptions
public abstract class TransitionOptions<CHILD extends TransitionOptions<CHILD,TranscodeType>,TranscodeType>
extends Object
implements Cloneable
A base class for setting a transition to use on a resource when a load completes.
Note: Implementations must implement equals/hashcode.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal CHILDclone()final CHILDRemoves any existing animation put on the builder.booleaninthashCode()final CHILDtransition(int viewAnimationId) Sets anAnimationto run on the wrapped target when an resource load finishes.final CHILDtransition(TransitionFactory<? super TranscodeType> transitionFactory) Uses the givenTransitionFactoryto build aTransitionfor each request started with theseTransitionOptions.final CHILDtransition(ViewPropertyTransition.Animator animator) Sets an animator to run aViewPropertyAnimatoron a view that the target may be wrapping when a resource load finishes.
-
Constructor Details
-
TransitionOptions
public TransitionOptions()
-
-
Method Details
-
dontTransition
Removes any existing animation put on the builder. Will be overridden by subsequent calls that put an animation.- Returns:
- This request builder.
-
transition
Sets anAnimationto run on the wrapped target when an resource load finishes. Will only be run if the resource was loaded asynchronously (i.e. was not in the memory cache).- Parameters:
viewAnimationId- The resource id of theAnimationto use as the transition.- Returns:
- This request builder.
-
transition
Sets an animator to run aViewPropertyAnimatoron a view that the target may be wrapping when a resource load finishes. Will only be run if the load was loaded asynchronously (i.e. was not in the memory cache).- Parameters:
animator- The.Animatorto run.- Returns:
- This request builder.
-
transition
@NonNull public final CHILD transition(@NonNull TransitionFactory<? super TranscodeType> transitionFactory) Uses the givenTransitionFactoryto build aTransitionfor each request started with theseTransitionOptions.- Returns:
- This request builder.
-
clone
-
equals
-
hashCode
public int hashCode()
-