public static AlbumBrowse Create(SpotifySession session, Album album, AlbumBrowseComplete callback, object userdata) { IntPtr listenerToken = ListenerTable.PutUniqueObject(callback, userdata); IntPtr ptr = NativeMethods.sp_albumbrowse_create(session._handle, album._handle, AlbumBrowseCompleteDelegate, listenerToken); AlbumBrowse browse = BrowseTable.GetUniqueObject(ptr); browse.ListenerToken = listenerToken; return browse; }
void PrintAlbum(SpotifySession aSession, Album aAlbum) { Console.WriteLine(" Album \"{0}\" ({1})", aAlbum.Name(), aAlbum.Year()); }
void PrintAlbum(int aIndex, Album aAlbum) { Console.WriteLine(" Album {0,3}: \"{1}\" by \"{2}\"", aIndex, aAlbum.Name(), aAlbum.Artist().Name()); }