<!--
{
  "availability" : [
    "iOS: 4.0.0 -",
    "iPadOS: 4.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.8.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "ImageIO",
  "identifier" : "/documentation/ImageIO/CGImageMetadataTagBlock",
  "metadataVersion" : "0.1.0",
  "role" : "Type Alias",
  "symbol" : {
    "kind" : "Type Alias",
    "modules" : [
      "Image I/O"
    ],
    "preciseIdentifier" : "c:@T@CGImageMetadataTagBlock"
  },
  "title" : "CGImageMetadataTagBlock"
}
-->

# CGImageMetadataTagBlock

The block to execute when enumerating the tags of a metadata object.

```
typealias CGImageMetadataTagBlock = (CFString, CGImageMetadataTag) -> Bool
```

## Parameters

`path`

The full path to the tag in the metadata container.

`tag`

The [`CGImageMetadataTag`](/documentation/ImageIO/CGImageMetadataTag) object that contains the tag information. Never modify this object from your block. If you want to change the tag, save a reference to it and make your changes later.

## Return Value

`true` to continue enumerating the tags, or `false` to stop.

---

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)