Android APIs
public interface

Animatable2

implements Animatable
android.graphics.drawable.Animatable2
Known Indirect Subclasses

Class Overview

Abstract class that drawables supporting animations and callbacks should extend.

Summary

Nested Classes
class Animatable2.AnimationCallback  
Public Methods
abstract void clearAnimationCallbacks()
Removes all existing animation callbacks.
abstract void registerAnimationCallback(Animatable2.AnimationCallback callback)
Adds a callback to listen to the animation events.
abstract boolean unregisterAnimationCallback(Animatable2.AnimationCallback callback)
Removes the specified animation callback.
[Expand]
Inherited Methods
From interface android.graphics.drawable.Animatable

Public Methods

public abstract void clearAnimationCallbacks ()

Added in API level 23

Removes all existing animation callbacks.

public abstract void registerAnimationCallback (Animatable2.AnimationCallback callback)

Added in API level 23

Adds a callback to listen to the animation events.

Parameters
callback Callback to add.

public abstract boolean unregisterAnimationCallback (Animatable2.AnimationCallback callback)

Added in API level 23

Removes the specified animation callback.

Parameters
callback Callback to remove.
Returns
  • false if callback didn't exist in the call back list, or true if callback has been removed successfully.