Package org.gnome.gtk
Class MediaStream.Builder<B extends MediaStream.Builder<B>>
java.lang.Object
org.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gtk.MediaStream.Builder<B>
- Type Parameters:
B- the type of the Builder that is returned
- All Implemented Interfaces:
BuilderInterface
- Direct Known Subclasses:
MediaFile.Builder
- Enclosing class:
MediaStream
public static class MediaStream.Builder<B extends MediaStream.Builder<B>>
extends GObject.Builder<B>
Inner class implementing a builder pattern to construct a GObject with
properties.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Finish building theMediaStreamobject.setLoop(boolean loop) Try to restart the media from the beginning once it ended.setMuted(boolean muted) Whether the audio stream should be muted.setPlaying(boolean playing) Whether the stream is currently playing.setVolume(double volume) Volume of the audio stream.Methods inherited from class org.gnome.gobject.GObject.Builder
onNotifyMethods inherited from class org.javagi.gobject.Builder
addBuilderProperty, connect, connect, connectSignals, getArena, getNames, getValues
-
Constructor Details
-
Builder
protected Builder()Default constructor for aBuilderobject.
-
-
Method Details
-
build
Finish building theMediaStreamobject. This will callGObject.withProperties(org.gnome.glib.Type, java.lang.String[], org.gnome.gobject.Value[])to create a new GObject instance, which is then cast toMediaStream.- Overrides:
buildin classGObject.Builder<B extends MediaStream.Builder<B>>- Returns:
- a new instance of
MediaStreamwith the properties that were set in the Builder object.
-
setLoop
Try to restart the media from the beginning once it ended.- Parameters:
loop- the value for theloopproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setMuted
Whether the audio stream should be muted.- Parameters:
muted- the value for themutedproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setPlaying
Whether the stream is currently playing.- Parameters:
playing- the value for theplayingproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setVolume
Volume of the audio stream.- Parameters:
volume- the value for thevolumeproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-