com.japisoft.xmlpad.xml.validator
Class XMLPadSAXParserFactory
java.lang.Object
com.japisoft.xmlpad.xml.validator.XMLPadSAXParserFactory
- public class XMLPadSAXParserFactory
- extends java.lang.Object
Here a factory for getting a parser for validating the edited document. The
default implementation is based on JAXP. You can create a subclass and
delegate the creation of a new parser. This is useful for very particular
cases like loading a remote parser or controlling some default parsing
properties...
- Version:
- 1.0
- Author:
- (c) 2004 JAPISoft / http://www.japisoft.com
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XMLPadSAXParserFactory
public XMLPadSAXParserFactory()
setDelegate
public static void setDelegate(XMLPadSAXParserFactory factory)
- This is a way to override this factory by creating a subclass
getNewSAXParser
public static javax.xml.parsers.SAXParser getNewSAXParser(boolean validating)
throws javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException
- Returns:
- a new SAX Parser. It uses JAXP as default
- Throws:
javax.xml.parsers.ParserConfigurationException
org.xml.sax.SAXException
getNewDocumentBuilder
public static javax.xml.parsers.DocumentBuilder getNewDocumentBuilder(boolean validating,
boolean schemaAware)
throws javax.xml.parsers.ParserConfigurationException
- Returns:
- a new DocumentBuilder. This is used for formatting the document
- Throws:
javax.xml.parsers.ParserConfigurationException
getNonStaticNewDocumentBuilder
protected javax.xml.parsers.DocumentBuilder getNonStaticNewDocumentBuilder(boolean validating,
boolean schemaAware)
throws javax.xml.parsers.ParserConfigurationException
- Throws:
javax.xml.parsers.ParserConfigurationException
getNonStaticNewSAXParser
protected javax.xml.parsers.SAXParser getNonStaticNewSAXParser(boolean validating)
throws javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException
- Throws:
javax.xml.parsers.ParserConfigurationException
org.xml.sax.SAXException
Copyright © 2006 JAPISoft. All Rights Reserved.