ca.intelliware.amakihi.util.xml
Class DocumentFactory

java.lang.Object
  |
  +--ca.intelliware.amakihi.util.xml.DocumentFactory

public class DocumentFactory
extends java.lang.Object

This class provides a simple wrapper around the JAXP classes.

Version:
$Revision: 1.3 $
Author:
Intelliware Development

Inner Class Summary
 class DocumentFactory.ValidationErrorHandler
           
 
Constructor Summary
DocumentFactory()
           
 
Method Summary
protected  javax.xml.parsers.DocumentBuilder createDocumentBuilder(java.lang.Object schemas)
           
 org.w3c.dom.Document createDocumentFromFile(java.io.File xmlFile)
           
 org.w3c.dom.Document createDocumentFromStream(java.io.InputStream stream)
           
 org.w3c.dom.Document createDocumentFromString(java.lang.String xml)
           
 org.w3c.dom.Document createDocumentFromString(java.lang.String xml, java.lang.Object schemas)
           
 org.w3c.dom.Document createDocumentWithRoot(java.lang.String rootElementName)
           
 org.w3c.dom.Document createEmptyDocument()
           
 boolean isSchemaAware()
          Gets the schemaAware
 void setSchemaAware(boolean schemaAware)
          Sets the schemaAware
 void setValidating(boolean validating)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DocumentFactory

public DocumentFactory()
Method Detail

setValidating

public void setValidating(boolean validating)

createDocumentFromFile

public org.w3c.dom.Document createDocumentFromFile(java.io.File xmlFile)
                                            throws org.xml.sax.SAXException,
                                                   java.io.IOException

createDocumentWithRoot

public org.w3c.dom.Document createDocumentWithRoot(java.lang.String rootElementName)

createDocumentFromStream

public org.w3c.dom.Document createDocumentFromStream(java.io.InputStream stream)
                                              throws org.xml.sax.SAXException,
                                                     java.io.IOException

createDocumentFromString

public org.w3c.dom.Document createDocumentFromString(java.lang.String xml,
                                                     java.lang.Object schemas)
                                              throws org.xml.sax.SAXException

createDocumentFromString

public org.w3c.dom.Document createDocumentFromString(java.lang.String xml)
                                              throws org.xml.sax.SAXException

createDocumentBuilder

protected javax.xml.parsers.DocumentBuilder createDocumentBuilder(java.lang.Object schemas)

createEmptyDocument

public org.w3c.dom.Document createEmptyDocument()

isSchemaAware

public boolean isSchemaAware()
Gets the schemaAware
Returns:
Returns a boolean

setSchemaAware

public void setSchemaAware(boolean schemaAware)
Sets the schemaAware
Parameters:
schemaAware - The schemaAware to set


Copyright 2002 Intelliware Development. All Rights Reserved.