org.jdom.input
Class SAXBuilder

java.lang.Object
  |
  +--org.jdom.input.AbstractBuilder
        |
        +--org.jdom.input.SAXBuilder

public class SAXBuilder
extends AbstractBuilder

SAXBuilder builds a JDOM tree using SAX.

Version:
1.0
Author:
Brett McLaughlin, Jason Hunter

Constructor Summary
SAXBuilder()
           This creates a SAXBuilder with the default SAX driver and no validation.
SAXBuilder(boolean validate)
           This sets validation for the Builder.
SAXBuilder(java.lang.String saxDriverClass)
           This sets the SAX Driver class to use, and leaves validation off.
SAXBuilder(java.lang.String saxDriverClass, boolean validate)
           This allows the validation features to be turned on/off in the builder at creation, as well as set the DOM Adapter class to use.
 
Method Summary
 Document build(java.io.InputStream in)
           This builds a document from the supplied input stream.
 
Methods inherited from class org.jdom.input.AbstractBuilder
build, build
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SAXBuilder

public SAXBuilder(java.lang.String saxDriverClass,
                  boolean validate)

This allows the validation features to be turned on/off in the builder at creation, as well as set the DOM Adapter class to use.

Parameters:
saxDriverClass - String name of SAX Driver to use for parsing.
validate - boolean indicating if validation should occur.

SAXBuilder

public SAXBuilder(java.lang.String saxDriverClass)

This sets the SAX Driver class to use, and leaves validation off.

Parameters:
saxDriverClass - String name of SAX Driver to use for parsing.

SAXBuilder

public SAXBuilder(boolean validate)

This sets validation for the Builder.

Parameters:
validate - boolean indicating if validation should occur.

SAXBuilder

public SAXBuilder()

This creates a SAXBuilder with the default SAX driver and no validation.

Method Detail

build

public Document build(java.io.InputStream in)
               throws JDOMException

This builds a document from the supplied input stream.

Overrides:
build in class AbstractBuilder
Parameters:
in - InputStream to read from.
Returns:
Document - resultant Document object.
Throws:
JDOMException - when errors occur in parsing.


Copyright © 2000 Brett McLaughlin, Jason Hunter. All Rights Reserved.