From 594f73c626eba7d52847409fad94986070b3b133 Mon Sep 17 00:00:00 2001 From: Andrzej Rybczak Date: Sun, 2 Sep 2012 21:14:38 +0200 Subject: [PATCH] proxy song list: add class description --- src/proxy_song_list.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/proxy_song_list.h b/src/proxy_song_list.h index 33644270..f814ab73 100644 --- a/src/proxy_song_list.h +++ b/src/proxy_song_list.h @@ -24,6 +24,16 @@ #include "menu.h" #include "song.h" +/// This fancy class provides a way to use NC::Menu template instantiations +/// with different Ts in a uniform manner. Note that since it provides methods +/// such as getSong or currentSong, it's biased towards menus that somehow +/// contain songs. +/// +/// Dependent types are T and F. T is type of items stored inside Menu, whereas +/// F is a function that takes Menu::Item and converts it into MPD::Song pointer. +/// For Menu this is just taking address of given MPD::Song, but e.g. +/// Menu returns not null pointer only if requested position actually +/// contains a song and not directory or playlist. class ProxySongList { struct Interface