Share via


Implementing a Playlist Parser Plug-in

The following list identifies the interaction between a Windows Media server, a playlist parser plug-in, and a playlist parser object when a client requests a playlist file:

Note

   You must specify the URLSuffix property for your custom playlist parser plug-in to identify the file name extension that it supports. You can also specify the URLPrefix property. For more information on setting properties, see Registering Plug-in Properties.

  1. The server creates a buffer for the data in the playlist file and calls the data source plug-in to copy the data from the file into the buffer.

  2. The server calls CreatePlaylistParser on the IWMSPlaylistParserPlugin interface.

  3. The plug-in creates an IWMSPlaylistParser object and calls OnCreatePlaylistParser on the IWMSPlaylistParserPluginCallback interface.

  4. The server creates an IXMLDOMDocument playlist object.

  5. The server calls ReadPlaylist on the IWMSPlaylistParser interface to parse the playlist file that is stored in the buffer created in step 1. The plug-in reads the buffer and populates the IXMLDOMDocument playlist object created in step 4 with the appropriate playlist elements and attributes in the SMIL 2.0 format required by the server.

  6. The plug-in calls OnReadPlaylist on the IWMSPlaylistParserCallback interface to notify the server of the results of the ReadPlaylist call.

  7. The server uses the IXMLDOMDocument playlist object to find the physical location of the digital content referenced in the playlist and determine the temporal behavior of the content.

  8. The server streams the content to the client.

  9. The server can also call the WritePlaylist method on the IWMSPlaylistParser interface to write the playlist to a file. Implement and call this method if you want to be able to save the playlist.

  10. If the server calls WritePlaylist, the plug-in calls the OnWritePlaylist method on the IWMSPlaylistParserCallback interface to notify the server of the results of the WritePlaylist method call.

Steps 1 through 7 of the preceding discussion are illustrated by the following diagram.

Flow diagram illustrating operation of a playlist parser plug-in.

Dd873701.wms8_playlistparser_final(en-us,VS.85).gif

See Also (General)

See Also (Visual Basic .NET)

See Also (C#)

See Also (C++)

  • IWMSPlaylistParser::ReadPlaylist

  • IWMSPlaylistParser::WritePlaylist

  • IWMSPlaylistParserCallback::OnReadPlaylist

  • IWMSPlaylistParserCallback::OnWritePlaylist

  • IWMSPlaylistParserPlugin::CreatePlaylistParser

  • IWMSPlaylistParserPluginCallback::OnCreatePlaylistParser

  • IXMLDOMDocumentIXMLDOMDocument Interface