mmplaylist_open()

Open a session on a playlist

Synopsis:

#include <mm/mmplaylist.h>
mmplaylist_t* mmplaylist_open( 
                      const char *base_name, 
                      const char *playlist_name, 
                      mmplaylist_validation_mode_t validation_mode, 
                      mmplaylist_validation_fn_t *validate_fn, 
                      void *cbk_data )

Arguments:

base_name
A string containing the base directory of the mediastore on which the playlist is contained.
playlist_name
A string containing the full path to the playlist. This path can be an absolute filepath or a URL.
validation_mode
The method that libmmplaylist must use to resolve playlist entries (see mmplaylist_validation_mode_t for the list of acceptable values).
validate_fn
The callback function to use for validating playlist entries. This optional parameter can be set to NULL, in which case the library uses stat() to validate entries. Also, entry validation is done only when validation_mode is set to MMPLAYLIST_ENTRY_VALIDATE.
cbk_data
Data for the callback function. This data gets passed unmodified to the callback function. The data can be NULL.

Library:

libmmplaylist

Description:

This function opens a session on a playlist. The library creates and returns a handle to represent the new playlist session. Internally, the library queries the available plugins to identify which ones support this playlist format. If multiple plugins support the format, the highest-ranked one is selected for use with this session. The plugin selection is stored in the session handle.

Returns:

A pointer to the new playlist handle
Success (i.e., the playlist is supported).
NULL
Failure.