class M3U8::DiscontinuityItem
- M3U8::DiscontinuityItem
- Reference
- Object
Overview
DiscontinuityItem represents an EXT-X-DISCONTINUITY tag used in HLS playlists.
According to RFC 8216, Section 4.3.2.4,
the EXT-X-DISCONTINUITY tag signals that a discontinuity exists between Media Segment items.
This break in continuity can occur due to changes in encoding parameters, stream content,
or other reasons that require the client to reset its decoding process.
For example, an HLS playlist might include the following tag to indicate a discontinuity:
#EXT-X-DISCONTINUITY
When the client parses this tag, it understands that the next Media Segment should be treated as starting from a new point, independent of the segments that came before.
Included Modules
- M3U8::Concern
Extended Modules
- M3U8::Concern
Defined in:
m3u8/discontinuity_item.crInstance Method Summary
-
#to_s
Returns the
EXT-X-DISCONTINUITYtag as a string, followed by a newline.
Instance Method Detail
Returns the EXT-X-DISCONTINUITY tag as a string, followed by a newline.
Example:
DiscontinuityItem.new.to_s
# => "#EXT-X-DISCONTINUITY\n"
The newline character ensures that when concatenated in a Playlist, the tag is correctly terminated as a separate line.