public object Get(GetInstantMixFromArtist request)
        {
            var user = _userManager.GetUserById(request.UserId.Value);

            var items = _musicManager.GetInstantMixFromArtist(request.Name, user);

            return(GetResult(items, user, request));
        }
        public object Get(GetInstantMixFromArtist request)
        {
            var user = _userManager.GetUserById(request.UserId.Value);

            var items = _musicManager.GetInstantMixFromArtist(request.Name, user);

            return GetResult(items, user, request);
        }
Beispiel #3
0
        public Task <object> Get(GetInstantMixFromArtist request)
        {
            var user   = _userManager.GetUserById(request.UserId);
            var artist = _libraryManager.GetArtist(request.Name);

            var items = _musicManager.GetInstantMixFromArtist(artist, user);

            return(GetResult(items, user, request));
        }
Beispiel #4
0
        public Task <object> Get(GetInstantMixFromArtist request)
        {
            var user   = _userManager.GetUserById(request.UserId);
            var artist = _libraryManager.GetArtist(request.Name, new DtoOptions(false));

            var dtoOptions = GetDtoOptions(_authContext, request);

            var items = _musicManager.GetInstantMixFromArtist(artist, user, dtoOptions);

            return(GetResult(items, user, request, dtoOptions));
        }
Beispiel #5
0
        public object Get(GetInstantMixFromArtist request)
        {
            var artist = GetArtist(request.Name, _libraryManager);

            var genres = _libraryManager.RootFolder
                         .RecursiveChildren
                         .OfType <Audio>()
                         .Where(i => i.HasArtist(artist.Name))
                         .SelectMany(i => i.Genres)
                         .Concat(artist.Genres)
                         .Distinct(StringComparer.OrdinalIgnoreCase);

            var result = GetInstantMixResult(request, genres);

            return(ToOptimizedSerializedResultUsingCache(result));
        }
Beispiel #6
0
        public Task<object> Get(GetInstantMixFromArtist request)
        {
            var user = _userManager.GetUserById(request.UserId);
            var artist = _libraryManager.GetArtist(request.Name);

            var items = _musicManager.GetInstantMixFromArtist(artist, user);

            return GetResult(items, user, request);
        }
        public object Get(GetInstantMixFromArtist request)
        {
            var artist = GetArtist(request.Name, _libraryManager);

            var genres = _libraryManager.RootFolder
                .RecursiveChildren
                .OfType<Audio>()
                .Where(i => i.HasArtist(artist.Name))
                .SelectMany(i => i.Genres)
                .Concat(artist.Genres)
                .Distinct(StringComparer.OrdinalIgnoreCase);

            var result = GetInstantMixResult(request, genres);

            return ToOptimizedSerializedResultUsingCache(result);
        }