<!--
{
  "availability" : [
    "macOS: 14.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MediaExtension",
  "identifier" : "/documentation/MediaExtension/MESampleCursor/chunkDetails()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "MediaExtension"
    ],
    "preciseIdentifier" : "c:objc(pl)MESampleCursor(im)chunkDetailsReturningError:"
  },
  "title" : "chunkDetails()"
}
-->

# chunkDetails()

Returns information about the chunk that holds the sample indicated by the cursor.

```
optional func chunkDetails() throws -> MESampleCursorChunk
```

## Return Value

A sample cursor chunk.

## Discussion

If the sample resides in a contiguous chunk of the file among similar samples, this method returns information about that chunk.

> Note:
> If a cursor implements this method, it also needs to implement ``doc://com.apple.mediaextension/documentation/MediaExtension/MESampleCursor/sampleLocation()`` to get samples inside the chunk’s location.

It may not be practical to use this method with some media assets. In this case, or if the cursor doesn’t support this method, it returns [`MEError.Code.locationNotAvailable`](/documentation/MediaExtension/MEError-swift.struct/Code/locationNotAvailable), which indicates to use [`loadSampleBufferContainingSamples(to:completionHandler:)`](/documentation/MediaExtension/MESampleCursor/loadSampleBufferContainingSamples(to:completionHandler:)) to load the sample data instead.

---

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)