---
title: delegate
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/xmlparser/delegate
---

# delegate

A delegate object that receives messages about the parsing process.

## Declaration

```swift
unowned(unsafe) var delegate: (any XMLParserDelegate)? { get set }
```

## Discussion

Discussion For methods to be implemented by the delegate, see XMLParserDelegate.
