@Generated(value="org.realityforge.webtack")
@JsType(isNative=true,
namespace="<global>",
name="Animation")
public class Animation
extends EventTarget
| Modifier and Type | Field and Description |
|---|---|
java.lang.Double |
currentTime
The Animation.currentTime property of the Web Animations API returns and sets the current time value of the animation in milliseconds, whether running or paused.
|
AnimationEffect |
effect
The Animation.effect property of the Web Animations API gets and sets the target effect of an animation.
|
java.lang.String |
id
The Animation.id property of the Web Animations API returns or sets a string used to identify the animation.
|
EventHandler |
oncancel
The oncancel property of the Web Animations API's Animation interface is the event handler for the cancel event.
|
EventHandler |
onfinish
The Animation interface's onfinish property (from the Web Animations API) is the event handler for the finish event.
|
EventHandler |
onremove
The Animation interface's onremove property (from the Web Animations API) is the event handler for the remove event.
|
double |
playbackRate
The Animation.playbackRate property of the Web Animations API returns or sets the playback rate of the animation.
|
java.lang.Double |
startTime
The Animation.startTime property of the Animation interface is a double-precision floating-point value which indicates the scheduled time when an animation's playback should begin.
|
AnimationTimeline |
timeline
The Animation.timeline property of the Animation interface returns or sets the timeline associated with this animation.
|
| Constructor and Description |
|---|
Animation()
The Animation() constructor of the Web Animations API returns a new Animation object instance.
|
Animation(AnimationEffect effect)
The Animation() constructor of the Web Animations API returns a new Animation object instance.
|
Animation(AnimationEffect effect,
AnimationTimeline timeline)
The Animation() constructor of the Web Animations API returns a new Animation object instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
cancel()
The Web Animations API's cancel() method of the Animation interface clears all KeyframeEffects caused by this animation and aborts its playback.
|
void |
commitStyles()
None.
|
void |
finish()
The finish() method of the Web Animations API's Animation Interface sets the current playback time to the end of the animation corresponding to the current playback direction.
|
Promise<Animation> |
finished()
The Animation.finished read-only property of the Web Animations API returns a Promise which resolves once the animation has finished playing.
|
void |
pause()
The pause() method of the Web Animations API's Animation interface suspends playback of the animation.
|
boolean |
pending()
The read-only Animation.pending property of the Web Animations API indicates whether the animation is currently waiting for an asynchronous operation such as initiating playback or pausing a running animation.
|
void |
persist()
None.
|
void |
play()
The play() method of the Web Animations API's Animation Interface starts or resumes playing of an animation.
|
java.lang.String |
playState()
The Animation.playState property of the Web Animations API returns and sets an enumerated value describing the playback state of an animation.
|
Promise<Animation> |
ready()
The read-only Animation.ready property of the Web Animations API returns a Promise which resolves when the animation is ready to play.
|
java.lang.String |
replaceState()
The read-only Animation.replaceState property of the Web Animations API returns the replace state of the animation.
|
void |
reverse()
The Animation.reverse() method of the Animation Interface reverses the playback direction, meaning the animation ends at its beginning.
|
void |
updatePlaybackRate(double playbackRate)
The updatePlaybackRate() method of the Web Animations API's Animation Interface sets the speed of an animation after first synchronizing its playback position.
|
addEventListener, addEventListener, addEventListener, dispatchEvent, removeEventListener, removeEventListener, removeEventListenerassign, create, create, defineProperties, defineProperty, defineProperty, entries, freeze, fromEntries, getOwnPropertyDescriptor, getOwnPropertyDescriptor, getOwnPropertyDescriptors, getOwnPropertyNames, getOwnPropertySymbols, getPrototypeOf, is, isExtensible, isFrozen, isSealed, keys, preventExtensions, seal, setPrototypeOf, valueOf_, values@Nullable public java.lang.Double currentTime
@Nullable public AnimationEffect effect
@Nonnull public java.lang.String id
@Nullable public EventHandler oncancel
@Nullable public EventHandler onfinish
@Nullable public EventHandler onremove
public double playbackRate
@Nullable public java.lang.Double startTime
@Nullable public AnimationTimeline timeline
public Animation(@Nullable
AnimationEffect effect,
@Nullable
AnimationTimeline timeline)
public Animation(@Nullable
AnimationEffect effect)
public Animation()
@JsProperty(name="finished") @Nonnull public Promise<Animation> finished()
@JsProperty(name="pending") public boolean pending()
@JsProperty(name="playState") @Nonnull @AnimationPlayState public java.lang.String playState()
@JsProperty(name="ready") @Nonnull public Promise<Animation> ready()
@JsProperty(name="replaceState") @Nonnull @AnimationReplaceState public java.lang.String replaceState()
public void cancel()
public void commitStyles()
public void finish()
public void pause()
public void persist()
public void play()
public void reverse()
public void updatePlaybackRate(double playbackRate)