Type Method

albumsQuery

Creates a media query that matches music items and that groups and sorts collections by album name.

Declaration

+ (MPMediaQuery *)albumsQuery;

Return Value

A media query that matches media items of type MPMediaTypeMusic and has a grouping type of MPMediaGroupingAlbum.

Discussion

A media item can have more than one media type; for example, an item could be of types “music” and “podcast.” An albumsQuery query matches all MPMediaTypeMusic items, whether or not they are also of other media types.

See Also

Creating Media Queries

+ artistsQuery

Creates a media query that matches music items and that groups and sorts collections by artist name.

+ songsQuery

Creates a media query that matches music items and that groups and sorts collections by song name.

+ playlistsQuery

Creates a media query that matches the entire library and that groups and sorts collections by playlist name.

+ podcastsQuery

Creates a media query that matches podcast items and that groups and sorts collections by podcast name.

+ audiobooksQuery

Creates a media query that matches audio book items and that groups and sorts collections by audio book name.

+ compilationsQuery

Creates a media query that matches compilation items and that groups and sorts collections by album name.

+ composersQuery

Creates a media query that matches all media items and that groups and sorts collections by composer name.

+ genresQuery

Creates a media query that matches all media items and that groups and sorts collections by genre name.

- init

Initializes a generic media query.

- initWithFilterPredicates:

Initializes a media query with a set of media property predicates.