Пример #1
0
 /// <summary>
 /// Delete the specified TaggedAlbum from the storage and the collection
 /// </summary>
 /// <param name="taggedAlbumToDelete"></param>
 /// <returns></returns>
 public static void DeleteTaggedAlbum(TaggedAlbum taggedAlbumToDelete)
 {
     // No need to wait for the TaggedAlbum to be deleted from storage
     DbAccess.DeleteAsync(taggedAlbumToDelete);
     TaggedAlbumCollection.Remove(taggedAlbumToDelete);
 }
Пример #2
0
 /// <summary>
 /// Add a new TaggedAlbum to the storage and the local collections
 /// </summary>
 /// <param name="artistAlbumToAdd"></param>
 public static void AddTaggedAlbum(TaggedAlbum taggedAlbumToAdd)
 {
     // No need to wait for the TaggedAlbum to be added to storage
     DbAccess.InsertAsync(taggedAlbumToAdd);
     TaggedAlbumCollection.Add(taggedAlbumToAdd);
 }
Пример #3
0
 /// <summary>
 /// Add a playlist to the local and storage collections.
 /// Wait for the storage to complete in case the called requires access to the stored Id
 /// </summary>
 /// <param name="playlistToAdd"></param>
 public static async Task AddPlaylistAsync(Playlist playlistToAdd)
 {
     PlaylistCollection.Add(playlistToAdd);
     await DbAccess.InsertAsync(playlistToAdd);
 }