class M3U8::PlaybackStart

Overview

PlaybackStart represents a #EXT-X-START tag and attributes

Included Modules

Extended Modules

Defined in:

m3u8/playback_start.cr

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(params : NamedTuple = NamedTuple.new) #
options = {
  time_offset: -12.9,
  precise:     true,
}
PlaybackStart.new(options)

[View source]
def self.new(time_offset, precise : Bool | Nil = nil) #
time_offset = -12.9
precise = true
PlaybackStart.new(time_offset)
PlaybackStart.new(time_offset, precise)

[View source]

Class Method Detail

def self.parse(text) #
text = "#EXT-X-START:TIME-OFFSET=-12.9,PRECISE=YES"
PlaybackStart.parse(text)
# => #<M3U8::PlaybackStart......>

[View source]

Instance Method Detail

def precise : Bool | Nil #

[View source]
def precise=(precise : Bool | Nil) #

[View source]
def time_offset : Float64 #

[View source]
def time_offset=(time_offset : Float64) #

[View source]
def to_s #
options = {
  time_offset: -12.9,
  precise:     true,
}
PlaybackStart.new(options).to_s
# => "#EXT-X-START:TIME-OFFSET=-12.9,PRECISE=YES"

[View source]