Skip to content

Latest commit

 

History

History
27 lines (19 loc) · 1.36 KB

README.adoc

File metadata and controls

27 lines (19 loc) · 1.36 KB

M3uParser

M3uParser provides Java API around an (extended) M3U playlist. Based on ANTLR grammar.

Download Build Status Maintainability

Usage

Public API consists of: DefaultM3uParser which implements M3uParserWrapper and PlaylistEntry.

getPlaylistProperties() returns a map of properties from #EXTM3U section.

getPlaylistEntries() return a list of playlist entries, each represented by PlaylistEntry class. Its members are:

  • title — an entry title,

  • path — a path or a URL of a file,

  • length — file length (commonly -1 or 0 for streams),

  • group — group name from #EXTGRP (could be null),

  • properties — a map of entry-specific properties from #EXTINF section.

Format specification

There is no formal specification for M3U format (see https://en.wikipedia.org/wiki/M3U).

M3uParser supports "extended M3U", in particular #EXTM3U, #EXTINF and #EXTGRP directives. All other comments (starting with #) are ignored.