View RSS Feed

JAXP

Java API for XML Processing

  1. An Overview of the Packages

    by , 04-27-2012 at 06:08 PM
    The SAX and DOM APIs are defined by the XML-DEV group and by the W3C, respectively. The libraries that define those APIs are as follows:

    • javax.xml.parsers: The JAXP APIs, which provide a common interface for different vendors' SAX and DOM parsers
    • org.w3c.dom: Defines the Document class (a DOM) as well as classes for all the components of a DOM
    • org.xml.sax: Defines the basic SAX APIs
    • javax.xml.transform: Defines the XSLT APIs that let you transform XML into other forms
    ...
    Categories
    JAXP
  2. Sun's JAXP and Sun's parser

    by , 04-27-2012 at 06:07 PM
    A lot of the parser/API confusion results from how Sun packages JAXP and the parser that JAXP uses by default. In earlier versions of JAXP, Sun included the JAXP API (with those six classes I just mentioned and a few more used for transformations) and a parser, called Crimson. Crimson was part of the com.sun.xml package. In newer versions of JAXP -- included in the JDK -- Sun has repackaged the Apache Xerces parser . In both cases, though, the parser is part of the JAXP distribution, but not part ...
    Tags: sun's jaxp Add / Edit Tags
    Categories
    JAXP
  3. JAXP: API or abstraction?

    by , 04-27-2012 at 06:06 PM
    Strictly speaking, JAXP is an API, but it is more accurately called an abstraction layer. It doesn't provide a new means of parsing XML, nor does it add to SAX or DOM, or give new functionality to Java and XML handling. (If you're in disbelief at this point, you're reading the right article.) Instead, JAXP makes it easier to use DOM and SAX to deal with some difficult tasks. It also makes it possible to handle some vendor-specific tasks that you might encounter when using the DOM and SAX APIs, in ...
    Categories
    JAXP
  4. The JAXP APIs

    by , 04-27-2012 at 06:05 PM
    The main JAXP APIs are defined in the javax.xml.parsers package. That package contains vendor-neutral factory classes,SAXParserFactory, DocumentBuilderFactory, and TransformerFactory, which give you a SAXParser, aDocumentBuilder, and an XSLT transformer, respectively. DocumentBuilder, in turn, creates a DOM-compliant Documentobject.

    The factory APIs let you plug in an XML implementation offered by another vendor without changing your source code. The implementation you get depends ...
    Categories
    JAXP
  5. Introduction to JAXP

    by , 04-27-2012 at 06:04 PM
    The Java API for XML Processing (JAXP) is for processing XML data using applications written in the Java programming language. JAXP leverages the parser standards Simple API for XML Parsing (SAX) and Document Object Model (DOM) so that you can choose to parse your data as a stream of events or to build an object representation of it. JAXP also supports the Extensible Stylesheet Language Transformations (XSLT) standard, giving you control over the presentation of the data and enabling you to convert ...
    Tags: jaxp Add / Edit Tags
    Categories
    JAXP
  6. The Benefits of JAXP

    by , 11-29-2011 at 02:58 AM
    One of the most important technologies available in java is the APIs used to work with XML. There are basically two ways to work with XML documents. SAX involves an event driven means of processing XML using callbacks to handle the relevant events. DOM involves using an in-house tree structure of the XML document. Sun Microsystems created a Java API for XML Processing (JAXP) toolkit which makes XML manageable for all developers to use. It is a key component for exploiting all the possibilities with ...

    Updated 11-30-2011 at 03:01 PM by Java XML

    Categories
    JAXP , DOM , SAX.