Package com.github.hakko.musiccabinet.parser.lastfm

Examples of com.github.hakko.musiccabinet.parser.lastfm.UserLovedTracksParser


      List<Track> lovedTracks = new ArrayList<>();
      do {
        WSResponse wsResponse = userLovedTracksClient.getUserLovedTracks(user, page);
        if (wsResponse.wasCallAllowed() && wsResponse.wasCallSuccessful()) {
          StringUtil stringUtil = new StringUtil(wsResponse.getResponseBody());
          UserLovedTracksParser parser = new UserLovedTracksParserImpl(
              stringUtil.getInputStream());
          totalPages = parser.getTotalPages();
          lovedTracks.addAll(parser.getLovedTracks());
        }
      } while (++page < totalPages);
      addFinishedOperation();

      userLovedTracks.add(new UserLovedTracks(user.getLastFmUsername(), lovedTracks));
View Full Code Here

TOP

Related Classes of com.github.hakko.musiccabinet.parser.lastfm.UserLovedTracksParser

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.