Package extended

Source Code of extended.TracksOfArtistDemo

package extended;

import com.jitcaforwin.extended.JitcaiTunesController;
import com.jitcaforwin.extended.api.IJitcaITunesController;
import com.jitcaforwin.extended.api.UserLibrary;
import com.jitcaforwin.extended.api.artist.Artist;
import com.jitcaforwin.extended.api.track.Track;
import com.jitcaforwin.extended.collections.TrackCollection;

public class TracksOfArtistDemo {

  public static void main(String args[]) {
    IJitcaITunesController iTunes = new JitcaiTunesController(true);
    UserLibrary library = iTunes.getLibrary();

    Artist michaelJackson = library.getArtist("Michael Jackson");
    michaelJackson.loadAllTracks();
    TrackCollection tracks = michaelJackson.getTracks();

    System.out.println("The following tracks of \"" + michaelJackson.getName() + "\" are in your library:");
    for (Track track : tracks) {
      System.out.println("\"" + track.getTitle() + "\" (" + track.getAlbum() + ")");
    }

    iTunes.close();
  }
}
TOP

Related Classes of extended.TracksOfArtistDemo

TOP
Copyright © 2018 www.massapi.com. 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.