I'm working on a simply pretty printer application for an XML editor and
can't seem to find the correct API to use to solve one particular problem.
Whenever I encounter a <!DOCTYPE,, or similar entity in a document, my code,
which extends DefaultHandler and implements LexicalHandler can identify
certain portions of the DTD information via the startDTD() method.
However, when I was reformatting the web.xml file for my tomcat server, I
discovered that certain key elements of the DTD specification can't be
received by my classes.
Example:
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
"http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
When I catch the various strings via startDTD, all I get are "web-app", the
"-//Sun...... etc." string, and the URL. Neither the DOCTYPE or PUBLIC
terms are returned in my implementation.
Is there another method I'm ignoring here, or another API I need to use to
get the entire entity. I'm aware that DOM4J implements just about every XML
API, so someone on this list can probably answer my question.
Rob
_______________________________________________________________
Have big pipes? SourceForge.net is looking for download mirrors. We supply
the hardware. You get the recognition. Email Us: [EMAIL PROTECTED]
_______________________________________________
dom4j-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dom4j-user