Beispiel #1
0
 public void AddPlaylist(Playlist playlist)
 {
     using (var tran = _session.BeginTransaction())
     {
         try
         {
             _session.Save(playlist);
             tran.Commit();
             Logger.LogMediafileAdded(playlist.PlaylistName);
         }
         catch (Exception ex)
         {
             Logger.AddToLog("Failed to add media file.", ex);
             tran.Rollback();
         }
     }
 }
Beispiel #2
0
        public static Playlist CreatePlaylist(string name, string comment)
        {
            var playlist = new Playlist(name, comment);

            return playlist;
        }