Example #1
0
        public int DeleteTrack(Guid trackId)
        {
            TrackQueriesCommands TrackCQ = new TrackQueriesCommands();
            var track = TrackCQ.FindTrackById(trackId);

            if (track != null)
            {
                int trackDeleteResult = TrackCQ.DeleteTrack(track);
                if (trackDeleteResult == 1)
                {
                    //Operation done successfully
                    return(1);
                }
                else
                {
                    //Internal error
                    return(0);
                }
            }
            else
            {
                //track fetching failed
                return(3);
            }
        }
Example #2
0
        public SingleTrackDetail GetTrackById(Guid trackId)
        {
            TrackQueriesCommands TrackCQ = new TrackQueriesCommands();

            return(TrackCQ.FindTrackById(trackId));
        }