net.dpml.util
Class DOM3DocumentBuilder

java.lang.Object
  extended bynet.dpml.util.DOM3DocumentBuilder

public class DOM3DocumentBuilder
extends Object

Utility class that creates a schema validating DOM3 parser.


Constructor Summary
DOM3DocumentBuilder()
          Creation of a new DOM3 document builder.
DOM3DocumentBuilder(Logger logger)
          Creation of a new DOM3 document builder.
DOM3DocumentBuilder(Logger logger, Map map)
          Creation of a new DOM3 document builder.
 
Method Summary
 Document parse(URI uri)
          Parse an xml schema document.
 void write(Document doc, OutputStream output)
          Write a document to an output stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DOM3DocumentBuilder

public DOM3DocumentBuilder()
Creation of a new DOM3 document builder.


DOM3DocumentBuilder

public DOM3DocumentBuilder(Logger logger)
Creation of a new DOM3 document builder.

Parameters:
logger - the assigned logging channel

DOM3DocumentBuilder

public DOM3DocumentBuilder(Logger logger,
                           Map map)
Creation of a new DOM3 document builder.

Parameters:
logger - the assigned logging channel
map - namespace to builder uri map
Method Detail

parse

public Document parse(URI uri)
               throws IOException
Parse an xml schema document.

Parameters:
uri - the document uri
Returns:
the validated document
Throws:
IOException - if an IO error occurs

write

public void write(Document doc,
                  OutputStream output)
           throws Exception
Write a document to an output stream.

Parameters:
doc - the document to write
output - the output stream
Throws:
Exception - if an error occurs