<!--
{
  "availability" : [
    "macCatalyst: 13.0.0 -",
    "macOS: 10.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Foundation",
  "identifier" : "/documentation/Foundation/XMLDTD/predefinedEntityDeclaration(forName:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "Foundation"
    ],
    "preciseIdentifier" : "c:objc(cs)NSXMLDTD(cm)predefinedEntityDeclarationForName:"
  },
  "title" : "predefinedEntityDeclaration(forName:)"
}
-->

# predefinedEntityDeclaration(forName:)

Returns a DTD node representing the predefined entity declaration with the specified name.

```
class func predefinedEntityDeclaration(forName name: String) -> XMLDTDNode?
```

## Parameters

`name`

A string identifying a predefined entity declaration.

## Return Value

An autoreleased [`XMLDTDNode`](/documentation/Foundation/XMLDTDNode) object, or `nil` if there is no match for `name`.

## Discussion

The five predefined entity references (or character references) are “<” (less-than sign), “>” (greater-than sign), “&” (ampersand), “"” (quotation mark), and “'” (apostrophe).

---

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)