M3U Parser

License Crates.io Documentation

A versatile library for parsing and manipulating M3U playlists.

Features

Installation

Add the m3u-parser crate to your Cargo.toml file:

toml [dependencies] m3u-parser = "0.1"

Import the M3uParser struct and use it to parse M3U playlists:

```rust use m3u_parser::M3uParser;

[tokio::main]

async fn main() { let mut parser = M3uParser::new(None); parser.parse_m3u("path/to/playlist.m3u", false, true).await; // Perform operations on the parsed stream information } ```

For more examples and detailed documentation, see the API documentation.

Examples

Parse an M3U playlist file and print the stream information:

```rust use m3u_parser::M3uParser;

[tokio::main]

async fn main() { let mut parser = M3uParser::new(None); parser.parsem3u("path/to/playlist.m3u", false, true).await; for streaminfo in parser.streamsinfo { println!("{:?}", streaminfo); } } ```

Author

👤 Pawan Paudel

🤝 Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page.

Show your support

Give a ⭐️ if this project helped you!

Copyright © 2023 Pawan Paudel.