The Entity Interface

The Entity interface represents a parsed or unparsed general entity declared in a document's DTD. (DOM does not expose parameter entities.) A map of the entities declared in a document is available from the getEntities() method of the DocumentType interface. However, entities are not part of the tree structure, and the parent of an entity is always null.

An Entity object represents the actual storage unit. It does not represent the entity reference such as Ω or &copyright; that appears in the instance document, but rather the replacement text to which that reference points. For parsed entities that the XML parser has resolved, the descendants of the Entity object form a read-only tree containing the XML markup for which ...

Get Processing XML with Java™: A Guide to SAX, DOM, JDOM, JAXP, and TrAX now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.