'Returns a TrackInfo object for a Beatport Track object.'

def _get_track_info(self, track):

    title = track.name
    if (track.mix_name != u'Original    Mix'):
        title += u'    ({0})'.format(track.mix_name)
    (artist, artist_id) = self._get_artist(track.artists)
    length = track.length.total_seconds()
    return TrackInfo(title=title, track_id=track.beatport_id, artist=artist, artist_id=artist_id, length=length, index=track.track_number, medium_index=track.track_number, data_source=u'Beatport', data_url=track.url)
