class Subtitles::JSON

Overview

A JSON representation of the internal intermediary format.

Defined in:

format/json.cr

Constant Summary

JSON_FT_REGEX = /^\s*\[\s*\{\s*"/

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from class Subtitles::Format

content : IO content, to_captions to_captions

Class methods inherited from class Subtitles::Format

detect detect, from_extension(extension string : String) : self.class? from_extension

Constructor Detail

def self.new(content : IO) #

initialize with the content


[View source]
def self.new(content string : String) #

initialize with the content


[View source]
def self.new(captions : Captions, eol = "\r\n") #

[View source]
def self.new(*, filepath : String) #

Read in a JSON-formatted subtitle from the given filepath.


[View source]

Class Method Detail

def self.detect(content : IO) #

[View source]

Instance Method Detail

def content : IO #

[View source]
def to_captions(eol = nil) #

[View source]