Platforms to show: All Mac Windows Linux Cross-Platform

MLMediaLibraryMBS class

Type Topic Plugin Version macOS Windows Linux iOS Targets
class MediaLibrary MBS Mac64bit Plugin 18.2 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The MLMediaLibrary class provides an interface for accessing a collection of media objects from various sources.

It serves as the initial access point of the Media Library framework.

The media library structure is defined by MLMediaSource, MLMediaGroup, and MLMediaObject classes. At the highest level, all content within a media library instance is categorized by media source. Conceptually, a media source represents a single app, such as iTunes or Aperture. Each source contains a hierarchy of media groups that originates from a root group. These groups consist of media objects—individual files containing a piece of media such as a photo, song, or movie. Only one copy of each object exists within a media library instance, but an object can be referenced by multiple groups from a single source. The structure of the group hierarchy is specific to each media source.

A media library is initialized using the Constructor. The options argument to this method serves as a filter. By specifying which folders or sources to include or exclude during load, you can view a particular subset of groups and objects from your collection. All objects provided are thread-safe. For descriptions of possible load options, see Load Options Keys.
The typical and most efficient use case is to create and use one instance of MLMediaLibrary for the lifetime of an app. When the underlying media files and metadata on the user’s system change, the corresponding data model objects (media groups and media objects) are automatically updated and KVO notifications are sent to notify the calling code of any changes. Multiple instances of MLMediaLibrary can be created and used, but their sources, groups, and objects will be independent of those provided by other instances of MLMediaLibrary.

This class has no sub classes.

Some properties using for this class:

Some examples using this class:

Blog Entries

Release notes


The items on this page are in the following plugins: MBS Mac64bit Plugin.


MLMediaGroupMBS   -   MLMediaObjectMBS


The biggest plugin in space...