Portability | unknown |
---|---|
Maintainer | ruben.astud@gmail.com |
Safe Haskell | Safe-Infered |
A basic parser for .srt files (subtitles) based on Attoparsec
and Text
Terminology of the module
All the sections of a Line have their corresponding ADT in Text.Subtitles.Datatypes
2 00:00:50,050 --> 00:00:52,217 Drama here
The whole Line is represented in the Line
ADT which constructors
represented by different ADTs
Re-exported Datatypes
module Text.Subtitles.Datatypes
Main parsers
parseSubtitles :: Parser SubtitlesSource
Main Parser, gives you a list of all the Lines of the subtitle. It fails if the subtitle doesn't have any Lines.
parseSingleLine :: Parser LineSource
The individual Line parser. given the upper example return the corresponding Line representation