Class

ITLibrary

A class that serves as the entry point to the iTunesLibrary framework. The properties and methods of ITLibrary may be used to retrieve media items (tracks) and playlists from the user’s iTunes library. ITLibrary also provides methods for extracting artwork from a media file that may or may not be in the iTunes library. This functionality is provided to sandboxed and non-sandboxed applications wanting to reuse iTunes' ability to extract artwork.

Declaration

class ITLibrary : NSObject

Topics

Instance Properties

var allMediaItems: [ITLibMediaItem]

All media items (tracks) in the iTunes library.

var allPlaylists: [ITLibPlaylist]

All the playlists in the iTunes library.

var apiMajorVersion: Int

The major version number of the API exposed by the iTunesLibrary framework.

var apiMinorVersion: Int

The minor version number of the API exposed by the iTunesLibrary framework.

var applicationVersion: String

The version of iTunes that created or modified the iTunes library being accessed.

var musicFolderLocation: URL?

The location of the iTunes music folder.

var shouldShowContentRating: Bool

Whether to show content rating labels.

Instance Methods

func artwork(forMediaFile: URL) -> ITLibArtwork?

Retrieves the artwork from a media file that may or may not be in the iTunes library.

Relationships

Inherits From

Conforms To