DeleteTrack() public method

public DeleteTrack ( IModelReference trackReference ) : int
trackReference IModelReference
return int
コード例 #1
0
        /// <inheritdoc cref="IModelService.DeleteTrack"/>
        public void DeleteTrack(string trackId)
        {
            var track = TrackDao.ReadTrackById(trackId);

            if (track == null)
            {
                return;
            }

            var trackReference = track.TrackReference;

            SubFingerprintDao.DeleteSubFingerprintsByTrackReference(trackReference);
            TrackDao.DeleteTrack(trackReference);
        }
コード例 #2
0
        public int DeleteTrack(string trackId)
        {
            var track = TrackDao.ReadTrackById(trackId);

            if (track == null)
            {
                return(0);
            }

            var trackReference = track.TrackReference;

            return(SubFingerprintDao.DeleteSubFingerprintsByTrackReference(trackReference) + TrackDao.DeleteTrack(trackReference));
        }