Save This Page
Home » spring-framework-2.5.6-with-dependencies » org.springframework » beans » factory » xml » [javadoc | source]
org.springframework.beans.factory.xml
public class: DefaultDocumentLoader [javadoc | source]
java.lang.Object
   org.springframework.beans.factory.xml.DefaultDocumentLoader

All Implemented Interfaces:
    DocumentLoader

Spring's default DocumentLoader implementation.

Simply loads documents using the standard JAXP-configured XML parser. If you want to change the DocumentBuilder that is used to load documents, then one strategy is to define a corresponding Java system property when starting your JVM. For example, to use the Oracle DocumentBuilder , you might start your application like as follows:

java -Djavax.xml.parsers.DocumentBuilderFactory=oracle.xml.jaxp.JXDocumentBuilderFactory MyMainClass
Method from org.springframework.beans.factory.xml.DefaultDocumentLoader Summary:
createDocumentBuilder,   createDocumentBuilderFactory,   loadDocument
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.springframework.beans.factory.xml.DefaultDocumentLoader Detail:
 protected DocumentBuilder createDocumentBuilder(DocumentBuilderFactory factory,
    EntityResolver entityResolver,
    ErrorHandler errorHandler) throws ParserConfigurationException 
    Create a JAXP DocumentBuilder that this bean definition reader will use for parsing XML documents. Can be overridden in subclasses, adding further initialization of the builder.
 protected DocumentBuilderFactory createDocumentBuilderFactory(int validationMode,
    boolean namespaceAware) throws ParserConfigurationException 
 public Document loadDocument(InputSource inputSource,
    EntityResolver entityResolver,
    ErrorHandler errorHandler,
    int validationMode,
    boolean namespaceAware) throws Exception