Crate srtparse [−] [src]
A library for reading SRT Subtitles.
Examples
Reading from string
use srtparse::parse; let subtitles = parse("1\n00:00:01,100 --> 00:00:02,120\nHello!").unwrap(); println!("{:?}", subtitles);
Reading from file
use srtparse::read_from_file; let subtitles = read_from_file("./data/underworld.srt").unwrap(); println!("{:?}", subtitles[0]);
Structs
Subtitle |
A subtitle item |
Enums
Error |
Describes all errors that may occur |
Functions
parse |
Read subtitles from a string |
read_from_file |
Read subtitles from a file |
Type Definitions
Result |
Alias for std result |