Package org.opencastproject.mediapackage
Interface Track
- All Superinterfaces:
Cloneable,Comparable<MediaPackageElement>,ManifestContributor,MediaPackageElement
- All Known Subinterfaces:
AdaptivePlaylist
- All Known Implementing Classes:
TrackImpl
This interface describes methods and fields for audio and video tracks as part of a media package.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.opencastproject.mediapackage.MediaPackageElement
MediaPackageElement.Type -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final MediaPackageElement.TypeMedia package element type. -
Method Summary
Modifier and TypeMethodDescriptionReturns the track's description with details about framerate, codecs etc.Returns the track duration in milliseconds ornullif the duration is not available.Returns logical name of the file which persists in spite of file name changesStream[]booleanhasAudio()Returnstrueif the track features an audio stream.booleanbooleanReturnstrueif the track features a subtitle stream.booleanhasVideo()Returnstrueif the track features a video stream.booleanisLive()Returnstrueif the track is a live track.isMaster()Returnstrueif the track is a master playlist (play this over other tracks).voidsetLogicalName(String name) Sets logical name of the file which persists in spite of file name changes to maintain referential integrity in the case of adaptive playlistsvoidSets master - it is an adaptive playlistMethods inherited from interface java.lang.Comparable
compareToMethods inherited from interface org.opencastproject.mediapackage.ManifestContributor
toManifestMethods inherited from interface org.opencastproject.mediapackage.MediaPackageElement
addTag, clearReference, clearTags, clone, containsTag, containsTag, generateIdentifier, getChecksum, getElementDescription, getElementType, getFlavor, getIdentifier, getMediaPackage, getMimeType, getReference, getSize, getTags, getURI, referTo, referTo, removeTag, setChecksum, setElementDescription, setFlavor, setIdentifier, setMimeType, setReference, setSize, setTags, setURI, verify
-
Field Details
-
TYPE
Media package element type.
-
-
Method Details
-
getStreams
Stream[] getStreams()- Returns:
- the streams that make up the track. Tracks consist of at least one stream.
-
hasAudio
boolean hasAudio()Returnstrueif the track features an audio stream.- Returns:
trueif the track has an audio stream
-
hasVideo
boolean hasVideo()Returnstrueif the track features a video stream.- Returns:
trueif the track has a video stream
-
hasSubtitle
boolean hasSubtitle()Returnstrueif the track features a subtitle stream.- Returns:
trueif the track has a subtitle stream
-
getDuration
Long getDuration()Returns the track duration in milliseconds ornullif the duration is not available.- Returns:
- the track duration
-
getDescription
String getDescription()Returns the track's description with details about framerate, codecs etc.- Returns:
- the track description.
-
isLive
boolean isLive()Returnstrueif the track is a live track.- Returns:
- true if live track; false otherwise
-
isMaster
Boolean isMaster()Returnstrueif the track is a master playlist (play this over other tracks).- Returns:
- true if it is a master playlist track; false otherwise
-
hasMaster
boolean hasMaster()- Returns:
- true if master playlist value is not null
-
setMaster
Sets master - it is an adaptive playlist- Parameters:
master- if true
-
getLogicalName
String getLogicalName()Returns logical name of the file which persists in spite of file name changes- Returns:
- logical name
-
setLogicalName
Sets logical name of the file which persists in spite of file name changes to maintain referential integrity in the case of adaptive playlists- Parameters:
name- as relative to manifest
-