Example usage for Java javafx.scene.media MediaPlayer fields, constructors, methods, implement or subclass
The text is from its open source code.
int | INDEFINITE A value representing an effectively infinite number of playback cycles. |
MediaPlayer(@NamedArg("media") Media media) Create a player for a specific media. |
ReadOnlyObjectProperty | currentTimeProperty() |
MediaException | getError() Retrieve the value of the #errorProperty error property or null if there is no error. |
Media | getMedia() Retrieves the Media instance being played. |
Duration | getStartTime() Retrieves the start time. |
Status | getStatus() Retrieves the current player status. |
Duration | getTotalDuration() Retrieves the total playback duration including all cycles (repetitions). |
void | pause() Pauses the player. |
void | play() Starts playing the media. |
void | seek(Duration seekTime) Seeks the player to a new playback time. |
void | setAutoPlay(boolean value) Sets the #autoPlayProperty autoPlay property value. |
void | setCycleCount(int value) Sets the cycle count. |
void | setOnEndOfMedia(Runnable value) Sets the end of media event handler. |
void | setOnError(Runnable value) Sets the event handler to be called when an error occurs. |
void | setOnMarker(EventHandler Sets the marker event handler. |
void | setOnPaused(Runnable value) Sets the Status#PAUSED event handler. |
void | setOnPlaying(Runnable value) Sets the Status#PLAYING event handler. |
void | setOnReady(Runnable value) Sets the Status#READY event handler. |
void | setVolume(double value) Sets the audio playback volume. |
ReadOnlyObjectProperty | statusProperty() |
ReadOnlyObjectProperty | totalDurationProperty() |
DoubleProperty | volumeProperty() |