[jdom-interest] Automatic Character Escaping
Gordon Tyler
gordon.tyler at sitraka.com
Tue Apr 1 10:11:47 PST 2003
Jay Balunas wrote:
> I need to get " " into the text of some of my elements (for HTML
> decimal alignment and such) and the various outputters are automatically
> changing it to be " ". I have a .dtd defined that contains the
> entity listing for the " ", but it does not seem to be used. I have
The outputters have to escape it because the text elements in a JDOM
document are just text and thus any markup characters must be escaped to
produce well-formed XML.
> also tried to directly add an EntityRef object but that does not seem to be
> working.
The EntityRef is the correct way to do it. How did you try to use
EntityRef and what failed?
> I just need a way for JDOM to not do the automatic escaping for this
> character sequence.
Not possible. The EntityRef is the only way to insert an entity into a
JDOM object.
Ciao,
Gordon
--
Gordon Tyler (Software Developer)
Quest Software <http://java.quest.com/>
260 King Street East, Toronto, Ontario M5A 4L5, Canada
Voice: 416-643-4846 | Fax: 416-594-1919
More information about the jdom-interest
mailing list