View Source HLS.Playlist.Media (HTTP Live Streaming (HLS) library v2.0.0)

Summary

Types

@type t() :: %HLS.Playlist.Media{
  finished: boolean(),
  media_sequence_number: pos_integer(),
  segments: [HLS.Segment.t()],
  target_segment_duration: pos_integer(),
  type: HLS.Playlist.Tag.PlaylistType.type() | nil,
  uri: URI.t() | nil,
  version: pos_integer()
}

Functions

Link to this function

build_segment_uri(media_uri, segment_uri)

View Source
@spec build_segment_uri(media :: URI.t(), segment :: URI.t()) :: URI.t()

Builds segment absolute uri.

Link to this function

compute_playlist_duration(media)

View Source
@spec compute_playlist_duration(t()) :: float()
Link to this function

new(uri, target_segment_duration)

View Source
@spec new(URI.t(), pos_integer()) :: t()
@spec segments(t()) :: [HLS.Segment.t()]

Returns the segments for this playlist.