---
title: "QLPreviewRequestGetDocumentObject(_:)"
framework: quicklook
role: symbol
role_heading: Function
path: "quicklook/qlpreviewrequestgetdocumentobject(_:)"
---

# QLPreviewRequestGetDocumentObject(_:)

Returns the object that’s stored as part of a preview request.

## Declaration

```swift
func QLPreviewRequestGetDocumentObject(_ preview: QLPreviewRequest!) -> UnsafeRawPointer!
```

## Parameters

- `preview`: The preview request object.

## Return Value

Return Value The object that’s stored as part of the preview request.

## Discussion

Discussion Use this method to get the object that you stored previously with the preview request using QLPreviewRequestSetDocumentObject(_:_:_:).

## See Also

### Requesting previews

- [QLPreviewRequestCopyContentUTI(_:)](quicklook/qlpreviewrequestcopycontentuti(_:).md)
- [QLPreviewRequestCopyOptions(_:)](quicklook/qlpreviewrequestcopyoptions(_:).md)
- [QLPreviewRequestCopyURL(_:)](quicklook/qlpreviewrequestcopyurl(_:).md)
- [QLPreviewRequestCreateContext(_:_:_:_:)](quicklook/qlpreviewrequestcreatecontext(_:_:_:_:).md)
- [QLPreviewRequestCreatePDFContext(_:_:_:_:)](quicklook/qlpreviewrequestcreatepdfcontext(_:_:_:_:).md)
- [QLPreviewRequestFlushContext(_:_:)](quicklook/qlpreviewrequestflushcontext(_:_:).md)
- [QLPreviewRequestSetDocumentObject(_:_:_:)](quicklook/qlpreviewrequestsetdocumentobject(_:_:_:).md)
- [QLPreviewRequestGetGeneratorBundle(_:)](quicklook/qlpreviewrequestgetgeneratorbundle(_:).md)
- [QLPreviewRequestGetTypeID()](quicklook/qlpreviewrequestgettypeid().md)
- [QLPreviewRequestIsCancelled(_:)](quicklook/qlpreviewrequestiscancelled(_:).md)
- [QLPreviewRequestSetDataRepresentation(_:_:_:_:)](quicklook/qlpreviewrequestsetdatarepresentation(_:_:_:_:).md)
- [QLPreviewRequestSetURLRepresentation(_:_:_:_:)](quicklook/qlpreviewrequestseturlrepresentation(_:_:_:_:).md)
