Categories:
Audio (13)
Biotech (29)
Bytecode (35)
Database (77)
Framework (7)
Game (7)
General (512)
Graphics (53)
I/O (32)
IDE (2)
JAR Tools (86)
JavaBeans (16)
JDBC (89)
JDK (337)
JSP (20)
Logging (103)
Mail (54)
Messaging (8)
Network (71)
PDF (94)
Report (7)
Scripting (83)
Security (32)
Server (119)
Servlet (17)
SOAP (24)
Testing (50)
Web (19)
XML (301)
Other Resources:
Show XML Parsing Flow with sax\DocumentTracer.java
How to show the XML parsing flow with sax\DocumentTracer.java provided in the Apache Xerces package?
✍: FYIcenter
You can show the XML parsing flow with the sax\DocumentTracer.java program
provided in the Apache Xerces package as shown below.
Compile and run sax\DocumentTracer.java program on the sample XML file User.xml:
\fyicenter\xerces-2_11_0\samples>\fyicenter\jdk-1.8.0\bin\javac sax\DocumentTracer.java Note: sax\DocumentTracer.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for details. \fyicenter\xerces-2_11_0\samples>\fyicenter\jdk-1.8.0\bin\java -cp .;..\xercesImpl.jar sax.DocumentTracer User.xml setDocumentLocator(locator=org.apache.xerces.parsers.AbstractSAXParser$LocatorProxy@69663380) startDocument() comment(text=" Copyright (c) 2017 FYIcenter.com ") startElement(uri="",localName="User",qname="User",attributes={}) characters(text="\n ") startElement(uri="",localName="ID",qname="ID",attributes={}) characters(text="101") endElement(uri="",localName="ID",qname="ID") characters(text="\n ") startElement(uri="",localName="BirthDate",qname="BirthDate",attributes={}) characters(text="1970-01-01+00:01") endElement(uri="",localName="BirthDate",qname="BirthDate") characters(text="\n ") startElement(uri="",localName="Name",qname="Name",attributes={}) characters(text="Frank Y. Ivy") endElement(uri="",localName="Name",qname="Name") characters(text="\n ") startElement(uri="",localName="Sex",qname="Sex",attributes={}) characters(text=" Male") endElement(uri="",localName="Sex",qname="Sex") characters(text="\n") endElement(uri="",localName="User",qname="User") endDocument()
Â
2017-10-08, 15753👍, 0💬
Popular Posts:
Commons Pool provides an Object-pooling API, with three major aspects: 1. A generic object pool inte...
JRE 8 rt.jar is the JAR file for JRE 8 RT (Runtime) libraries. JRE (Java Runtime) 8 is the runtime e...
Apache Log4j IOStreams is a Log4j API extension that provides numerous classes from java.io that can...
JDK 11 java.desktop.jmod is the JMOD file for JDK 11 Desktop module. JDK 11 Desktop module compiled ...
What Is poi-contrib-3.5.jar? poi-contrib-3.5.jar is one of the JAR files for Apache POI 3.5, which p...