<!--
{
  "availability" : [
    "macCatalyst: 14.0.0 -",
    "macOS: 10.13.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "iTunesLibrary",
  "identifier" : "/documentation/iTunesLibrary/ITLibMediaEntity/enumerateValues(forProperties:using:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "iTunes Library"
    ],
    "preciseIdentifier" : "c:objc(cs)ITLibMediaEntity(im)enumerateValuesForProperties:usingBlock:"
  },
  "title" : "enumerateValues(forProperties:using:)"
}
-->

# enumerateValues(forProperties:using:)

Executes a provided block with the fetched values for the item properties.

```
func enumerateValues(forProperties properties: Set<String>?, using block: @escaping (String, Any, UnsafeMutablePointer<ObjCBool>) -> Void)
```

## Parameters

`properties`

A set of keys for the properties to enumerate, or `nil` to enumerate all properties. Takes Media Item Properties and Playlist Properties from [`ITLibMediaItem`](/documentation/iTunesLibrary/ITLibMediaItem).

`block`

A block object that executes for each property in the properties set.

## Discussion

Use this method to get property values in a batch fashion. In some cases, enumerating over a set of property keys can be more efficient than fetching each individual property with [`value(forProperty:)`](/documentation/iTunesLibrary/ITLibMediaEntity/value(forProperty:)).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)