'Gives metadata information about the entire playlist or a
single track, given by its index.'

def cmd_playlistinfo(self, conn, index=(-1)):

    index = cast_arg(int, index)
    if (index == (-1)):
        for track in self.playlist:
            (yield self._item_info(track))
    else:
        try:
            track = self.playlist[index]
        except IndexError:
            raise ArgumentIndexError()
        (yield self._item_info(track))
