All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.kvisco.xml.DOMReader

com.kvisco.xml.DOMReader

public class DOMReader
This class is a wrapper for whatever dom package is being used.

Author:
Keith Visco (kvisco@ziplink.net)

Constructor Index

 o DOMReader()
Creates a new DOMReader for the default DOM Package
 o DOMReader(String)
Creates a new DOMReader for the specified DOM Package

Method Index

 o createDocument()
Creates a DOM Document using the DOM Package of this DOMReader
 o getDefaultDOMPackageClassName()
Returns the class name of the default DOMPackage
 o getDOMPackage()
Returns the DOMPackage being used
 o getDOMPackageClassName()
Returns the class name of the DOMPackage being used
 o readDocument(InputStream, String, boolean)
Reads an XML Document from the given InputStream.
 o readDocument(InputStream, String, boolean, Writer)
Reads an XML Document from the given InputStream.

Constructors

 o DOMReader
 public DOMReader() throws Exception
Creates a new DOMReader for the default DOM Package

Throws: ClassNotFoundException
when the default DOMPackage could not be found.
 o DOMReader
 public DOMReader(String domPackageClassName) throws Exception
Creates a new DOMReader for the specified DOM Package

Throws: ClassNotFoundException
when the specified DOMPackage could not be found.

Methods

 o createDocument
 public Document createDocument()
Creates a DOM Document using the DOM Package of this DOMReader

Returns:
the new Document
 o getDefaultDOMPackageClassName
 public static String getDefaultDOMPackageClassName()
Returns the class name of the default DOMPackage

Returns:
the class name of the default DOMPackage
 o getDOMPackage
 public DOMPackage getDOMPackage()
Returns the DOMPackage being used

Returns:
the DOMPackage being used
 o getDOMPackageClassName
 public String getDOMPackageClassName()
Returns the class name of the DOMPackage being used

Returns:
the class name of the DOMPackage being used
 o readDocument
 public Document readDocument(InputStream xmlInput,
                              String filename,
                              boolean validate)
Reads an XML Document from the given InputStream.

Parameters:
xmlInput - the XML InputStream
filename - the filename to use during error reporting.
 o readDocument
 public Document readDocument(InputStream xmlInput,
                              String filename,
                              boolean validate,
                              Writer errorWriter)
Reads an XML Document from the given InputStream.

Parameters:
xmlInput - the XML InputStream
filename - the filename to use during error reporting.
errorOuput - is a Writer used for reporting errors

All Packages  Class Hierarchy  This Package  Previous  Next  Index