elena       2003/03/03 14:17:17

  Modified:    java/src/org/apache/xerces/impl XMLDTDScannerImpl.java
                        XMLDocumentFragmentScannerImpl.java XMLScanner.java
                        XMLVersionDetector.java
               java/src/org/apache/xerces/parsers DTDConfiguration.java
                        IntegratedParserConfiguration.java
                        StandardParserConfiguration.java
                        XML11Configuration.java
                        org.apache.xerces.xni.parser.XMLParserConfiguration
  Log:
  Improve performance of XML11Configuration and make it the default one.
  The XMLVersionDetector is now only responsible for parsing the XML decl and
  reporting the version back to the configuration. The configuration job is to reset
  a pipeline in the case the document is XML1.1 document. The XMLVersionDetector
  is then called to reset the entity manager's scanner and start parsing of the 
document.
  
  Revision  Changes    Path
  1.38      +3 -2      
xml-xerces/java/src/org/apache/xerces/impl/XMLDTDScannerImpl.java
  
  Index: XMLDTDScannerImpl.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/impl/XMLDTDScannerImpl.java,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -r1.37 -r1.38
  --- XMLDTDScannerImpl.java    10 Feb 2003 15:16:16 -0000      1.37
  +++ XMLDTDScannerImpl.java    3 Mar 2003 22:17:16 -0000       1.38
  @@ -355,7 +355,8 @@
       public boolean scanDTDInternalSubset(boolean complete, boolean standalone,
                                            boolean hasExternalSubset)
           throws IOException, XNIException {
  -
  +        // reset entity scanner
  +        fEntityScanner = fEntityManager.getEntityScanner();
           fEntityManager.setEntityHandler(this);
           fStandalone = standalone;
           if (fScannerState == SCANNER_STATE_TEXT_DECL) {
  
  
  
  1.29      +4 -3      
xml-xerces/java/src/org/apache/xerces/impl/XMLDocumentFragmentScannerImpl.java
  
  Index: XMLDocumentFragmentScannerImpl.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/impl/XMLDocumentFragmentScannerImpl.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -r1.28 -r1.29
  --- XMLDocumentFragmentScannerImpl.java       31 Jan 2003 21:58:15 -0000      1.28
  +++ XMLDocumentFragmentScannerImpl.java       3 Mar 2003 22:17:16 -0000       1.29
  @@ -341,7 +341,9 @@
        */
       public boolean scanDocument(boolean complete) 
           throws IOException, XNIException {
  -
  +        
  +        // reset entity scanner
  +        fEntityScanner = fEntityManager.getEntityScanner();
           // keep dispatching "events"
           fEntityManager.setEntityHandler(this);
           do {
  @@ -1457,7 +1459,6 @@
            */
           public boolean dispatch(boolean complete) 
               throws IOException, XNIException {
  -
               try {
                   boolean again;
                   do {
  
  
  
  1.26      +5 -5      xml-xerces/java/src/org/apache/xerces/impl/XMLScanner.java
  
  Index: XMLScanner.java
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/src/org/apache/xerces/impl/XMLScanner.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- XMLScanner.java   10 Feb 2003 15:14:51 -0000      1.25
  +++ XMLScanner.java   3 Mar 2003 22:17:17 -0000       1.26
  @@ -1109,6 +1109,8 @@
   
           // keep track of the entity depth
           fEntityDepth++;
  +        // must reset entity scanner
  +        fEntityScanner = fEntityManager.getEntityScanner();
   
       } // startEntity(String,XMLResourceIdentifier,String)
   
  @@ -1310,10 +1312,8 @@
       }
   
       // private methods
  -    private void init() {
  -        // initialize scanner
  -        fEntityScanner = fEntityManager.getEntityScanner();
  -        
  +    private void init() { 
  +        fEntityScanner = null;       
           // initialize vars
           fEntityDepth = 0;
           fReportEntity = true;
  
  
  
  1.5       +44 -476   
xml-xerces/java/src/org/apache/xerces/impl/XMLVersionDetector.java
  
  Index: XMLVersionDetector.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/impl/XMLVersionDetector.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- XMLVersionDetector.java   10 Feb 2003 21:37:53 -0000      1.4
  +++ XMLVersionDetector.java   3 Mar 2003 22:17:17 -0000       1.5
  @@ -49,7 +49,7 @@
    *
    * This software consists of voluntary contributions made by many
    * individuals on behalf of the Apache Software Foundation and was
  - * originally based on software copyright (c) 1999, International
  + * originally based on software copyright (c) 2003, International
    * Business Machines, Inc., http://www.apache.org.  For more
    * information on the Apache Software Foundation, please see
    * <http://www.apache.org/>.
  @@ -57,53 +57,25 @@
   
   package org.apache.xerces.impl;
   
  -import java.io.EOFException;
   import java.io.IOException;
   
  -import org.apache.xerces.impl.XMLEntityScanner;
  -import org.apache.xerces.impl.XMLErrorReporter;
  -import org.apache.xerces.impl.Constants;
  -import org.apache.xerces.impl.dtd.XMLDTDValidator;
  -import org.apache.xerces.impl.dtd.XML11DTDValidator;
  -import org.apache.xerces.impl.dtd.XMLDTDProcessor;
  -import org.apache.xerces.impl.dtd.XML11DTDProcessor;
  -import org.apache.xerces.impl.msg.XMLMessageFormatter;
   import org.apache.xerces.util.SymbolTable;
  -import org.apache.xerces.util.XMLStringBuffer;
  -import org.apache.xerces.util.XMLResourceIdentifierImpl;
  -import org.apache.xerces.xni.XMLAttributes;
  -import org.apache.xerces.xni.XMLResourceIdentifier;
   import org.apache.xerces.xni.XMLString;
  -import org.apache.xerces.xni.XNIException;
  -import org.apache.xerces.xni.XMLDocumentHandler;
  -import org.apache.xerces.xni.XMLDTDHandler;
  -import org.apache.xerces.xni.XMLDTDContentModelHandler;
  -import org.apache.xerces.xni.parser.XMLComponent;
   import org.apache.xerces.xni.parser.XMLComponentManager;
  -import org.apache.xerces.xni.parser.XMLDocumentScanner;
  -import org.apache.xerces.xni.parser.XMLDTDScanner;
  -import org.apache.xerces.xni.parser.XMLInputSource;
   import org.apache.xerces.xni.parser.XMLConfigurationException;
  -import org.apache.xerces.xni.parser.XMLDocumentFilter;
  -import org.apache.xerces.xni.parser.XMLDTDFilter;
  -import org.apache.xerces.xni.parser.XMLDTDContentModelFilter;
  +import org.apache.xerces.xni.parser.XMLInputSource;
   
   /**
  - * This is not a full-function scanner; its sole job
  - * is to figure out the version of the document we're
  - * scanning, and create the correct
  - * document scanner, DTD scanner and entity scanner to deal with it.  
  - * Any configuration that may parse documents from different versions of XML should
  - * place this object first in both the maqin and DTD pipelines, and take care
  - * to reset it in that position when it initiates
  - * a new parse.  
  + * This class scans the version of the document to determine
  + * which scanner to use: XML 1.1 or XML 1.0.
  + * The version is scanned using XML 1.1. scanner.  
    * 
  - * @author Neil Graham, IBM
  + * @author Neil Graham, IBM 
  + * @author Elena Litani, IBM
    * @version $Id$
    */
   
  -public class XMLVersionDetector
  -    implements XMLComponent, XMLDocumentScanner, XMLDTDScanner {
  +public class XMLVersionDetector {
   
       //
       // Constants
  @@ -113,9 +85,6 @@
       private final static char [] EXPECTED_VERSION_STRING = {'<', '?', 'x', 'm', 
'l', ' ', 'v', 'e', 'r', 's', 
                       'i', 'o', 'n', '=', ' ', ' ', ' ', ' ', ' '};
   
  -    // this class doesn't do anything that would affect events
  -    // further down the pipeline; therefore, it doesn't
  -    // recognize any features.
   
       // property identifiers
   
  @@ -131,39 +100,15 @@
       protected static final String ENTITY_MANAGER = 
           Constants.XERCES_PROPERTY_PREFIX + Constants.ENTITY_MANAGER_PROPERTY;
   
  -    /** Property identifier: DTD scanner. */
  -    protected static final String DTD_SCANNER_PROPERTY = 
  -        Constants.XERCES_PROPERTY_PREFIX + Constants.DTD_SCANNER_PROPERTY;
  -
  -    /** Property identifier: DTD validator. */ 
  -    protected static final String DTD_VALIDATOR_PROPERTY = 
  -        Constants.XERCES_PROPERTY_PREFIX + Constants.DTD_VALIDATOR_PROPERTY;
  -
  -    /** Property identifier: DTD processor. */ 
  -    protected static final String DTD_PROCESSOR_PROPERTY = 
  -        Constants.XERCES_PROPERTY_PREFIX + Constants.DTD_PROCESSOR_PROPERTY;
  -
  -    /** Property identifier: namespace binder. */ 
  -    protected static final String NAMESPACE_BINDER_PROPERTY = 
  -        Constants.XERCES_PROPERTY_PREFIX + Constants.NAMESPACE_BINDER_PROPERTY;
  -
  -    // recognized properties
  -    private static final String[] RECOGNIZED_PROPERTIES = {
  -        SYMBOL_TABLE, 
  -        ERROR_REPORTER, 
  -        ENTITY_MANAGER,
  -        DTD_SCANNER_PROPERTY, 
  -        DTD_VALIDATOR_PROPERTY, 
  -        DTD_PROCESSOR_PROPERTY,
  -        NAMESPACE_BINDER_PROPERTY,
  -    };
  -    private static final String[] PROPERTY_DEFAULTS = {null, null, null, null, 
null, null, null};
  -
       //
       // Data
       //
   
  -    // properties
  +    /** Symbol: "version". */
  +    protected final static String fVersionSymbol = "version".intern();
  +
  +    // symbol:  [xml]:
  +    protected static final String fXMLSymbol = "[xml]".intern();
   
       /** Symbol table. */
       protected SymbolTable fSymbolTable;
  @@ -174,63 +119,10 @@
       /** Entity manager. */
       protected XMLEntityManager fEntityManager;
   
  -    // protected data
  -
  -    // the current componentManager; so that we can use it to
  -    // properly reset any scanners we create
  -    protected XMLComponentManager fComponentManager = null;
  -
  -    // next guy in the main pipeline
  -    protected XMLDocumentHandler fDocumentHandler = null;
  -
  -    // next guy in the DTD pipeline
  -    protected XMLDTDHandler fDTDHandler = null;
  -
  -    // next guy in the DTD content model pipeline
  -    protected XMLDTDContentModelHandler fDTDContentModelHandler = null;
  -
  -    // the scanner that will actually scan the document
  -    protected XMLDocumentScannerImpl fRealDocumentScanner = null;
  -
  -    // the scanner that will actually scan the DTD
  -    protected XMLDTDScannerImpl fRealDTDScanner = null;
  -
  -    // the XML 1.0 document scanner
  -    protected XMLDocumentScannerImpl fXML10DocScanner = null;
  -    
  -    // the XML 1.0 DTD scanner
  -    protected XMLDTDScannerImpl fXML10DTDScanner = null;
  -    
  -    // the XML 1.1 document scanner
  -    protected XML11DocumentScannerImpl fXML11DocScanner = null;
  -    
  -    // the XML 1.1 DTD scanner
  -    protected XML11DTDScannerImpl fXML11DTDScanner = null;
  -
  -    // the XML 1.1 DTD validator
  -    protected XML11DTDValidator fXML11DTDValidator = null;
  -    
  -    // the XML 1.1 DTD processor
  -    protected XML11DTDProcessor fXML11DTDProcessor = null;
  -    
  -    // the XML 1.1 namespace binder
  -    protected XML11NamespaceBinder fXML11NamespaceBinder = null;
  -    
  -    // symbols
  -
  -    /** Symbol: "version". */
  -    protected final static String fVersionSymbol = "version".intern();
  +    protected String fEncoding = null;
   
  -    // symbol:  [xml]:
  -    protected static final String fXMLSymbol = "[xml]".intern();
  -
  -    // temporary variables
       private XMLString fVersionNum = new XMLString();
   
  -    //
  -    // XMLComponent methods
  -    //
  -
       /**
        * 
        * 
  @@ -246,254 +138,45 @@
           fSymbolTable = (SymbolTable)componentManager.getProperty(SYMBOL_TABLE);
           fErrorReporter = 
(XMLErrorReporter)componentManager.getProperty(ERROR_REPORTER);
           fEntityManager = 
(XMLEntityManager)componentManager.getProperty(ENTITY_MANAGER);
  -        
  -        // keep a reference around so we can correctly
  -        // initialize new scanners we need to instantiate
  -        fComponentManager = componentManager;
           for(int i=14; i<EXPECTED_VERSION_STRING.length; i++ )
               EXPECTED_VERSION_STRING[i] = ' ';
       } // reset(XMLComponentManager)
   
  -    /**
  -     * Sets the value of a property during parsing.
  -     * 
  -     * @param propertyId 
  -     * @param value 
  -     */
  -    public void setProperty(String propertyId, Object value)
  -        throws XMLConfigurationException {
  -        
  -        // Xerces properties
  -        if (propertyId.startsWith(Constants.XERCES_PROPERTY_PREFIX)) {
  -            String property =
  -               propertyId.substring(Constants.XERCES_PROPERTY_PREFIX.length());
  -            if (property.equals(Constants.SYMBOL_TABLE_PROPERTY)) {
  -                fSymbolTable = (SymbolTable)value;
  -            }
  -            else if (property.equals(Constants.ERROR_REPORTER_PROPERTY)) {
  -                fErrorReporter = (XMLErrorReporter)value;
  -            }
  -            else if (property.equals(Constants.ENTITY_MANAGER_PROPERTY)) {
  -                fEntityManager = (XMLEntityManager)value;
  -            }
  -        }
  -
  -    } // setProperty(String,Object)
  -
  -    /*
  -     * Sets the feature of the scanner.
  -     */
  -    public void setFeature(String featureId, boolean value)
  -        throws XMLConfigurationException {
  -    }
  -    
  -    /*
  -     * Gets the state of the feature of the scanner.
  -     */
  -    public boolean getFeature(String featureId)
  -        throws XMLConfigurationException {
  -            
  -        throw new 
XMLConfigurationException(XMLConfigurationException.NOT_RECOGNIZED, featureId);
  -    }
  -
  -    /**
  -     * Returns a list of feature identifiers that are recognized by
  -     * this component. This method may return null if no features
  -     * are recognized by this component.
  -     */
  -    public String[] getRecognizedFeatures() {
  -        return null;
  -    } // getRecognizedFeatures():String[]
  +     /**
  +      * Reset the reference to the appropriate scanner given the version of the
  +     * document and start document scanning.
  +      * @param scanner - the scanner to use
  +      * @param version - the version of the document (XML 1.1 or XML 1.0).
  +      */
  +    public void startDocumentParsing(XMLEntityHandler scanner, short version){
   
  -    /**
  -     * Returns a list of property identifiers that are recognized by
  -     * this component. This method may return null if no properties
  -     * are recognized by this component.
  -     */
  -    public String[] getRecognizedProperties() {
  -        return (String[])(RECOGNIZED_PROPERTIES.clone());
  -    } // getRecognizedProperties():String[]
  -
  -    /** 
  -     * Returns the default state for a feature, or null if this
  -     * component does not want to report a default value for this
  -     * feature.
  -     *
  -     * @param featureId The feature identifier.
  -     *
  -     * @since Xerces 2.2.0
  -     */
  -    public Boolean getFeatureDefault(String featureId) {
  -        return null;
  -    } // getFeatureDefault(String):Boolean
  -
  -    /** 
  -     * Returns the default state for a property, or null if this
  -     * component does not want to report a default value for this
  -     * property. 
  -     *
  -     * @param propertyId The property identifier.
  -     *
  -     * @since Xerces 2.2.0
  -     */
  -    public Object getPropertyDefault(String propertyId) {
  -        for (int i = 0; i < RECOGNIZED_PROPERTIES.length; i++) {
  -            if (RECOGNIZED_PROPERTIES[i].equals(propertyId)) {
  -                return PROPERTY_DEFAULTS[i];
  -            }
  +        if (version == Constants.XML_VERSION_1_0){
  +            fEntityManager.setScannerVersion(Constants.XML_VERSION_1_0);
           }
  -        return null;
  -    } // getPropertyDefault(String):Object
  -
  -    //
  -    // XMLDocumentScanner methods
  -    //
  -
  -    // the setSource method.  We simply do what we
  -    // need to to the passed-in XMLResourceIdentifier
  -    // to open the document, determine a provisional
  -    // encoding (if necessary), and determine what version
  -    // it is.  Then we put the right scanner into the pipeline
  -    // and call the *real* scanDocument
  -    // method on the real scanner, which takes care of
  -    // business (that is, actually makes callbacks,
  -    // throws errors, etc.)
  -    // We finally clean up the mess we've made of 
  -    // the pipeline for the benefit of any unwary configuration
  -    
  -    /**
  -     * Sets the input source.
  -     *
  -     * @param inputSource The input source.
  -     *
  -     * @throws IOException Thrown on i/o error.
  -     */
  -    public void setInputSource(XMLInputSource inputSource) throws IOException {
  -        // create the entity for the document, recover its
  -        // encoding so that we can make the appropriate call to
  -        // initialize the right scanner
  -        String encoding = fEntityManager.setupCurrentEntity(fXMLSymbol, 
inputSource, false, true);
  -        // do what's needed to determine the version
  -        reinitializePipelines(determineDocVersion());
  -        // pass this call on to the real scanner
  -        fEntityManager.setEntityHandler(fRealDocumentScanner);
  -        fRealDocumentScanner.startEntity(fXMLSymbol, 
fEntityManager.getCurrentResourceIdentifier(), encoding);
  -    } // setInputSource(XMLInputSource)
  -
  -    /** 
  -     * Scans a document.
  -     *
  -     * @param complete True if the scanner should scan the document
  -     *                 completely, pushing all events to the registered
  -     *                 document handler. A value of false indicates that
  -     *                 that the scanner should only scan the next portion
  -     *                 of the document and return. A scanner instance is
  -     *                 permitted to completely scan a document if it does
  -     *                 not support this "pull" scanning model.
  -     *
  -     * @returns True if there is more to scan, false otherwise.
  -     */
  -    public boolean scanDocument(boolean complete) 
  -        throws IOException, XNIException {
  -
  -        // send this off to the right scanner
  -        return fRealDocumentScanner.scanDocument(complete);
  -
  -        // REVISIT:  should we bother to return pipeline to its original state
  -
  -    } // scanDocument(boolean):boolean
  -
  -    //
  -    // XMLDocumentSource methods
  -    //
  -
  -    /**
  -     * setDocumentHandler
  -     * 
  -     * @param documentHandler 
  -     */
  -    public void setDocumentHandler(XMLDocumentHandler documentHandler) {
  -        fDocumentHandler = documentHandler;
  -    } // setDocumentHandler(XMLDocumentHandler)
  -
  -
  -    /** Returns the document handler */
  -    public XMLDocumentHandler getDocumentHandler(){
  -        return fDocumentHandler;
  -    }
  -
  -    //
  -    // XMLDTDScanner methods 
  -    //
  -
  -    /** Sets the DTD content model handler. */
  -    public void setDTDContentModelHandler(XMLDTDContentModelHandler handler) {
  -        fDTDContentModelHandler = handler;
  -    } 
  -
  -    /** Returns the DTD content model handler. */
  -    public XMLDTDContentModelHandler getDTDContentModelHandler() {
  -        return fDTDContentModelHandler;
  -    } 
  -
  -    /** Sets the DTD handler. */
  -    public void setDTDHandler(XMLDTDHandler handler) {
  -        fDTDHandler = handler;
  -    }
  -
  -    /** Returns the DTD handler. */
  -    public XMLDTDHandler getDTDHandler() {
  -        return fDTDHandler;
  -    }
  -
  -    /** 
  -     * Scans the internal subset of the document.
  -     *
  -     * @param complete True if the scanner should scan the document
  -     *                 completely, pushing all events to the registered
  -     *                 document handler. A value of false indicates that
  -     *                 that the scanner should only scan the next portion
  -     *                 of the document and return. A scanner instance is
  -     *                 permitted to completely scan a document if it does
  -     *                 not support this "pull" scanning model.
  -     * @param standalone True if the document was specified as standalone.
  -     *                   This value is important for verifying certain
  -     *                   well-formedness constraints.
  -     * @param hasExternalDTD True if the document has an external DTD.
  -     *                       This allows the scanner to properly notify
  -     *                       the handler of the end of the DTD in the
  -     *                       absence of an external subset.
  -     *
  -     * @returns True if there is more to scan, false otherwise.
  -     */
  -    public boolean scanDTDInternalSubset(boolean complete, boolean standalone,
  -                                         boolean hasExternalSubset)
  -        throws IOException, XNIException {
  -        // place holder
  -        return false;
  +        else {
  +            fEntityManager.setScannerVersion(Constants.XML_VERSION_1_1);
  +        }
  +        // Note: above we reset fEntityScanner in the entity manager, thus in 
startEntity
  +        // in each scanner fEntityScanner field must be reset to reflect the change.
  +        // 
  +        fEntityManager.setEntityHandler(scanner);
  +        
  +        scanner.startEntity(fXMLSymbol, 
fEntityManager.getCurrentResourceIdentifier(), fEncoding);        
       }
   
  -    /**
  -     * Scans the external subset of the document.
  -     *
  -     * @param complete True if the scanner should scan the document
  -     *                 completely, pushing all events to the registered
  -     *                 document handler. A value of false indicates that
  -     *                 that the scanner should only scan the next portion
  -     *                 of the document and return. A scanner instance is
  -     *                 permitted to completely scan a document if it does
  -     *                 not support this "pull" scanning model.
  -     *
  -     * @returns True if there is more to scan, false otherwise.
  -     */
  -    public boolean scanDTDExternalSubset(boolean complete) 
  -        throws IOException, XNIException {
  -        // no-op place holder
  -        return false;
  -    }
   
  +     /**
  +      * This methods scans the XML declaration to find out the version 
  +     * (and provisional encoding)  of the document.
  +     * The scanning is doing using XML 1.1 scanner.
  +      * @param inputSource
  +      * @return short - Constants.XML_VERSION_1_1 if document version 1.1, 
  +     *                  otherwise Constants.XML_VERSION_1_0 
  +      * @throws IOException
  +      */
  +    public short determineDocVersion(XMLInputSource inputSource) throws IOException 
{
  +        fEncoding = fEntityManager.setupCurrentEntity(fXMLSymbol, inputSource, 
false, true);
   
  -    private short determineDocVersion() throws IOException {
           // must assume 1.1 at this stage so that whitespace
           // handling is correct in the XML decl...
           fEntityManager.setScannerVersion(Constants.XML_VERSION_1_1);
  @@ -532,121 +215,6 @@
               return Constants.XML_VERSION_1_1;
           return Constants.XML_VERSION_1_0;
   
  -    }
  -
  -    private void reinitializePipelines(short pipelineType) {
  -        if (pipelineType == Constants.XML_VERSION_1_1) {
  -            fEntityManager.setScannerVersion(Constants.XML_VERSION_1_1);
  -            if(fXML11DocScanner == null) {
  -                fXML11DocScanner = new XML11DocumentScannerImpl();
  -            }
  -            fRealDocumentScanner = fXML11DocScanner;
  -            if(fXML11DTDScanner == null) {
  -                fXML11DTDScanner = new XML11DTDScannerImpl();
  -            }
  -            fRealDTDScanner = fXML11DTDScanner;
  -            // is there a dtd validator in the pipeline?
  -            // if so, it'll be XML 1.0; need to replace
  -            // it...
  -            XMLDocumentFilter val = null;
  -            if((val = (XMLDocumentFilter 
)fComponentManager.getProperty(DTD_VALIDATOR_PROPERTY)) != null) {
  -                // do we need to new up a replacement? 
  -                if(fXML11DTDValidator == null) {
  -                    fXML11DTDValidator = new XML11DTDValidator();
  -                }
  -                fXML11DTDValidator.reset(fComponentManager);
  -                // now take val out of the picture...
  -                if(val.getDocumentSource() != null) {
  -                    val.getDocumentSource().setDocumentHandler(fXML11DTDValidator);
  -                    fXML11DTDValidator.setDocumentSource(val.getDocumentSource());
  -                }
  -                if(val.getDocumentHandler() != null) {
  -                    val.getDocumentHandler().setDocumentSource(fXML11DTDValidator);
  -                    fXML11DTDValidator.setDocumentHandler(val.getDocumentHandler());
  -                }
  -            }
  -            // is there a namespace binder in the pipeline?
  -            // if so, it'll be XML 1.0; need to replace
  -            // it... (REVISIT:  does it make more sense here just to
  -            // have a feature???)
  -            XMLDocumentFilter nsb = null;
  -            if((nsb = (XMLDocumentFilter 
)fComponentManager.getProperty(NAMESPACE_BINDER_PROPERTY)) != null) {
  -                // do we need to new up a replacement? 
  -                if(fXML11NamespaceBinder == null) {
  -                    fXML11NamespaceBinder = new XML11NamespaceBinder();
  -                }
  -                fXML11NamespaceBinder.reset(fComponentManager);
  -                // now take nsb out of the picture...
  -                if(nsb.getDocumentSource() != null) {
  -                    
nsb.getDocumentSource().setDocumentHandler(fXML11NamespaceBinder);
  -                    
fXML11NamespaceBinder.setDocumentSource(nsb.getDocumentSource());
  -                }
  -                if(nsb.getDocumentHandler() != null) {
  -                    
nsb.getDocumentHandler().setDocumentSource(fXML11NamespaceBinder);
  -                    
fXML11NamespaceBinder.setDocumentHandler(nsb.getDocumentHandler());
  -                }
  -            }
  -            // now do the same to the DTD pipeline.
  -            // Since a full-featured DTD processor will always 
  -            // be an XMLDTDFilter and an XMLDTDContentModelFilter,
  -            // we explicitly make this assumption here...
  -            XMLDTDFilter proc = null;
  -            if((proc = (XMLDTDFilter 
)fComponentManager.getProperty(DTD_PROCESSOR_PROPERTY)) != null) {
  -                // do we need to new up a replacement? 
  -                if(fXML11DTDProcessor == null) {
  -                    fXML11DTDProcessor = new XML11DTDProcessor();
  -                }
  -                fXML11DTDProcessor.reset(fComponentManager);
  -                // now take proc out of the picture...
  -                if(proc.getDTDSource() != null) {
  -                    proc.getDTDSource().setDTDHandler(fXML11DTDProcessor);
  -                    fXML11DTDProcessor.setDTDSource(proc.getDTDSource());
  -                }
  -                if(proc.getDTDHandler() != null) {
  -                    proc.getDTDHandler().setDTDSource(fXML11DTDProcessor);
  -                    fXML11DTDProcessor.setDTDHandler(proc.getDTDHandler());
  -                }
  -                // and last but not least:  same with DTDContentModels...
  -                // perhaps dangerously, we'll assume the DTD_Processor property
  -                // will give this to us; this may not
  -                // be true for some pipelines!
  -                XMLDTDContentModelFilter cmProc = 
(XMLDTDContentModelFilter)fComponentManager.getProperty(DTD_PROCESSOR_PROPERTY);
  -                if(cmProc.getDTDContentModelSource() != null) {
  -                    
cmProc.getDTDContentModelSource().setDTDContentModelHandler(fXML11DTDProcessor);
  -                    
fXML11DTDProcessor.setDTDContentModelSource(cmProc.getDTDContentModelSource());
  -                }
  -                if(cmProc.getDTDContentModelHandler() != null) {
  -                    
cmProc.getDTDContentModelHandler().setDTDContentModelSource(fXML11DTDProcessor);
  -                    
fXML11DTDProcessor.setDTDContentModelHandler(cmProc.getDTDContentModelHandler());
  -                }
  -            }
  -        } else {
  -            // must be a 1.0 pipeline, or it'll be a fatal error later on...
  -            fEntityManager.setScannerVersion(Constants.XML_VERSION_1_0);
  -            if(fXML10DocScanner == null) {
  -                fXML10DocScanner = new XMLDocumentScannerImpl();
  -            }
  -            fRealDocumentScanner = fXML10DocScanner;
  -            if(fXML10DTDScanner == null) {
  -                fXML10DTDScanner = new XMLDTDScannerImpl();
  -            }
  -            fRealDTDScanner = fXML10DTDScanner;
  -        }
  -
  -        // set up main pipeline
  -        fRealDocumentScanner.reset(fComponentManager);
  -        fRealDocumentScanner.setDocumentHandler(fDocumentHandler);
  -        fDocumentHandler.setDocumentSource(fRealDocumentScanner);
  -
  -        // set up DTD pipeline
  -        fRealDTDScanner.reset(fComponentManager);
  -        fRealDTDScanner.setDTDHandler(fDTDHandler);
  -        fDTDHandler.setDTDSource(fRealDTDScanner);
  -        fRealDTDScanner.setDTDContentModelHandler(fDTDContentModelHandler);
  -        fDTDContentModelHandler.setDTDContentModelSource(fRealDTDScanner);
  -
  -        // and link the two (note this must be done after reset...):
  -        fRealDocumentScanner.setProperty(DTD_SCANNER_PROPERTY, fRealDTDScanner);
       }
   
       // This method prepends "length" chars from the char array,
  
  
  
  1.11      +62 -50    
xml-xerces/java/src/org/apache/xerces/parsers/DTDConfiguration.java
  
  Index: DTDConfiguration.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/parsers/DTDConfiguration.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- DTDConfiguration.java     11 Dec 2002 16:14:31 -0000      1.10
  +++ DTDConfiguration.java     3 Mar 2003 22:17:17 -0000       1.11
  @@ -220,7 +220,7 @@
       // debugging
   
       /** Set to true and recompile to print exception stack trace. */
  -    private static final boolean PRINT_EXCEPTION_STACK_TRACE = false;
  +    protected static final boolean PRINT_EXCEPTION_STACK_TRACE = false;
   
       //
       // Data
  @@ -638,59 +638,71 @@
           // configure the pipeline and initialize the components
           configurePipeline();
           super.reset();
  -
  -
       } // reset()
   
       /** Configures the pipeline. */
  -    protected void configurePipeline() {
  -
  -        // REVISIT: This should be better designed. In other words, we
  -        //          need to figure out what is the best way for people to
  -        //          re-use *most* of the standard configuration but do 
  -        //          things common things such as remove a component (e.g.
  -        //          the validator), insert a new component (e.g. XInclude), 
  -        //          etc... -Ac
  -
  -        // setup document pipeline
  -        if (fDTDValidator != null) {
  -            fScanner.setDocumentHandler(fDTDValidator);
  -            // filters
  -            fDTDValidator.setDocumentHandler(fNamespaceBinder);
  -            fDTDValidator.setDocumentSource(fScanner);
  -            fNamespaceBinder.setDocumentHandler(fDocumentHandler);
  -            fNamespaceBinder.setDocumentSource(fDTDValidator);
  -        }
  -        else {
  -            fScanner.setDocumentHandler(fNamespaceBinder);
  -            fNamespaceBinder.setDocumentHandler(fDocumentHandler);
  -            fNamespaceBinder.setDocumentSource(fDTDValidator);
  -        }
  +     protected void configurePipeline() {
   
  -        fLastComponent = fNamespaceBinder;
  -
  -        // setup dtd pipeline
  -        if (fDTDScanner != null) {
  -            if (fDTDProcessor != null) {
  -                fDTDScanner.setDTDHandler(fDTDProcessor);
  -                fDTDProcessor.setDTDSource(fDTDScanner);
  -                fDTDProcessor.setDTDHandler(fDTDHandler);
  -                fDTDHandler.setDTDSource(fDTDProcessor);
  -                
  -                fDTDScanner.setDTDContentModelHandler(fDTDProcessor);
  -                fDTDProcessor.setDTDContentModelSource(fDTDScanner);
  -                fDTDProcessor.setDTDContentModelHandler(fDTDContentModelHandler);
  -                fDTDContentModelHandler.setDTDContentModelSource(fDTDProcessor);
  -            }
  -            else {
  -                fDTDScanner.setDTDHandler(fDTDHandler);
  -                fDTDHandler.setDTDSource(fDTDScanner);
  -                fDTDScanner.setDTDContentModelHandler(fDTDContentModelHandler);
  -                fDTDContentModelHandler.setDTDContentModelSource(fDTDScanner);
  -            }
  -        }
  +             // REVISIT: This should be better designed. In other words, we
  +             //          need to figure out what is the best way for people to
  +             //          re-use *most* of the standard configuration but do 
  +             //          things common things such as remove a component (e.g.
  +             //          the validator), insert a new component (e.g. XInclude), 
  +             //          etc... -Ac
  +
  +             // setup document pipeline
  +             if (fDTDValidator != null) {
  +                     fScanner.setDocumentHandler(fDTDValidator);
  +                     if (fFeatures.get(NAMESPACES) == Boolean.TRUE) {
  +
  +                             // filters
  +                             fDTDValidator.setDocumentHandler(fNamespaceBinder);
  +                             fDTDValidator.setDocumentSource(fScanner);
  +                             fNamespaceBinder.setDocumentHandler(fDocumentHandler);
  +                             fNamespaceBinder.setDocumentSource(fDTDValidator);
  +                             fLastComponent = fNamespaceBinder;
  +                     }
  +                     else {
  +                             fDTDValidator.setDocumentHandler(fDocumentHandler);
  +                             fDTDValidator.setDocumentSource(fScanner);
  +                             fLastComponent = fDTDValidator;
  +                     }
  +             }
  +             else {
  +                     if (fFeatures.get(NAMESPACES) == Boolean.TRUE) {
  +                             fScanner.setDocumentHandler(fNamespaceBinder);
  +                             fNamespaceBinder.setDocumentHandler(fDocumentHandler);
  +                             fNamespaceBinder.setDocumentSource(fScanner);
  +                             fLastComponent = fNamespaceBinder;
  +                     }
  +                     else {
  +                             fScanner.setDocumentHandler(fDocumentHandler);
  +                             fLastComponent = fScanner;
  +                     }
  +             }
  +
  +             // setup dtd pipeline
  +             if (fDTDScanner != null) {
  +                     if (fDTDProcessor != null) {
  +                             fDTDScanner.setDTDHandler(fDTDProcessor);
  +                             fDTDProcessor.setDTDSource(fDTDScanner);
  +                             fDTDProcessor.setDTDHandler(fDTDHandler);
  +                             fDTDHandler.setDTDSource(fDTDProcessor);
  +
  +                             fDTDScanner.setDTDContentModelHandler(fDTDProcessor);
  +                             fDTDProcessor.setDTDContentModelSource(fDTDScanner);
  +                             
fDTDProcessor.setDTDContentModelHandler(fDTDContentModelHandler);
  +                             
fDTDContentModelHandler.setDTDContentModelSource(fDTDProcessor);
  +                     }
  +                     else {
  +                             fDTDScanner.setDTDHandler(fDTDHandler);
  +                             fDTDHandler.setDTDSource(fDTDScanner);
  +                             
fDTDScanner.setDTDContentModelHandler(fDTDContentModelHandler);
  +                             
fDTDContentModelHandler.setDTDContentModelSource(fDTDScanner);
  +                     }
  +             }
   
  -    } // configurePipeline()
  +     } // configurePipeline()
   
       // features and properties
   
  
  
  
  1.9       +7 -1      
xml-xerces/java/src/org/apache/xerces/parsers/IntegratedParserConfiguration.java
  
  Index: IntegratedParserConfiguration.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/parsers/IntegratedParserConfiguration.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- IntegratedParserConfiguration.java        19 Feb 2003 18:07:38 -0000      1.8
  +++ IntegratedParserConfiguration.java        3 Mar 2003 22:17:17 -0000       1.9
  @@ -194,9 +194,15 @@
       
       /** Configures the pipeline. */
        protected void configurePipeline() {
  +        
  +        // use XML 1.0 datatype library
  +         setProperty(DATATYPE_VALIDATOR_FACTORY, fDatatypeValidatorFactory);
  +         
                // setup dtd pipeline
                if (fDTDScanner != null) {
  +            fProperties.put(DTD_SCANNER, fDTDScanner);
                        if (fDTDProcessor != null) {
  +                fProperties.put(DTD_PROCESSOR, fDTDProcessor);
                                fDTDScanner.setDTDHandler(fDTDProcessor);
                                fDTDProcessor.setDTDHandler(fDTDHandler);
                                fDTDScanner.setDTDContentModelHandler(fDTDProcessor);
  
  
  
  1.30      +1 -7      
xml-xerces/java/src/org/apache/xerces/parsers/StandardParserConfiguration.java
  
  Index: StandardParserConfiguration.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/parsers/StandardParserConfiguration.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -r1.29 -r1.30
  --- StandardParserConfiguration.java  8 Jan 2003 23:01:27 -0000       1.29
  +++ StandardParserConfiguration.java  3 Mar 2003 22:17:17 -0000       1.30
  @@ -148,12 +148,6 @@
       protected static final String SCHEMA_NONS_LOCATION =
       Constants.XERCES_PROPERTY_PREFIX + Constants.SCHEMA_NONS_LOCATION;
   
  -
  -    // debugging
  -
  -    /** Set to true and recompile to print exception stack trace. */
  -    private static final boolean PRINT_EXCEPTION_STACK_TRACE = false;
  -
       //
       // Data
       //
  
  
  
  1.4       +198 -32   
xml-xerces/java/src/org/apache/xerces/parsers/XML11Configuration.java
  
  Index: XML11Configuration.java
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/parsers/XML11Configuration.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- XML11Configuration.java   8 Jan 2003 23:01:27 -0000       1.3
  +++ XML11Configuration.java   3 Mar 2003 22:17:17 -0000       1.4
  @@ -2,7 +2,7 @@
    * The Apache Software License, Version 1.1
    *
    *
  - * Copyright (c) 2001, 2002 The Apache Software Foundation.  
  + * Copyright (c) 2001 - 2003 The Apache Software Foundation.  
    * All rights reserved.
    *
    * Redistribution and use in source and binary forms, with or without
  @@ -49,7 +49,7 @@
    *
    * This software consists of voluntary contributions made by many
    * individuals on behalf of the Apache Software Foundation and was
  - * originally based on software copyright (c) 1999, International
  + * originally based on software copyright (c) 2002, International
    * Business Machines, Inc., http://www.apache.org.  For more
    * information on the Apache Software Foundation, please see
    * <http://www.apache.org/>.
  @@ -57,17 +57,24 @@
   
   package org.apache.xerces.parsers;
   
  +import java.io.IOException;
  +
   import org.apache.xerces.impl.Constants;
  +import org.apache.xerces.impl.XML11DTDScannerImpl;
  +import org.apache.xerces.impl.XML11DocumentScannerImpl;
  +import org.apache.xerces.impl.XML11NamespaceBinder;
  +import org.apache.xerces.impl.XMLEntityHandler;
   import org.apache.xerces.impl.XMLVersionDetector;
  -import org.apache.xerces.impl.XMLEntityManager;
  +import org.apache.xerces.impl.dtd.XML11DTDProcessor;
  +import org.apache.xerces.impl.dtd.XML11DTDValidator;
   import org.apache.xerces.impl.dv.DTDDVFactory;
  -
  +import org.apache.xerces.impl.xs.XMLSchemaValidator;
  +import org.apache.xerces.impl.xs.XSMessageFormatter;
   import org.apache.xerces.util.SymbolTable;
  -import org.apache.xerces.xni.grammars.XMLGrammarPool;
   import org.apache.xerces.xni.XNIException;
  +import org.apache.xerces.xni.grammars.XMLGrammarPool;
  +import org.apache.xerces.xni.parser.XMLComponent;
   import org.apache.xerces.xni.parser.XMLComponentManager;
  -import org.apache.xerces.xni.parser.XMLDocumentScanner;
  -import org.apache.xerces.xni.parser.XMLDTDScanner;
   
   /**
    * This class is the configuration used to parse XML 1.1 documents.
  @@ -81,7 +88,7 @@
    * @version $Id$
    */
   public class XML11Configuration
  -    extends StandardParserConfiguration {
  +    extends IntegratedParserConfiguration {
   
       //
       // Constants
  @@ -92,8 +99,27 @@
       // Data
       //
   
  -    protected XMLVersionDetector fVersionDetector = null;
  -
  +    protected XMLVersionDetector fVersionDetector = new XMLVersionDetector();
  +    
  +    // the XML 1.1 document scanner
  +    protected XML11DocumentScannerImpl fXML11DocScanner = null;
  +    
  +    // the XML 1.1 DTD scanner
  +    protected XML11DTDScannerImpl fXML11DTDScanner = null;
  +
  +    // the XML 1.1 DTD validator
  +    protected XML11DTDValidator fXML11DTDValidator = null;
  +    
  +    // the XML 1.1 DTD processor
  +    protected XML11DTDProcessor fXML11DTDProcessor = null;
  +    
  +    // the XML 1.1 namespace binder
  +    protected XML11NamespaceBinder fXML11NamespaceBinder = null;
  +    
  +    // the XML 1.1. datatype factory
  +    protected DTDDVFactory  fXML11DatatypeFactory = null;
  +    
  +    
       //
       // Constructors
       //
  @@ -150,27 +176,167 @@
       //
       // Public methods
       //
  +    public boolean parse(boolean complete) throws XNIException, IOException {
  +        
  +        //
  +        // reset and configure pipeline and set InputSource.
  +        if (fInputSource !=null) {
  +            try {
  +                fVersionDetector.reset(this);
  +                reset();
  +
  +                short version = fVersionDetector.determineDocVersion(fInputSource);
  +                if (version == Constants.XML_VERSION_1_1){
  +                    // XML 1.1 pipeline
  +                    configureXML11Pipeline();
  +                }
  +                // resets and sets the pipeline.
  +                fVersionDetector.startDocumentParsing((XMLEntityHandler)fScanner, 
version);
  +                fInputSource = null;
  +            } 
  +            catch (XNIException ex) {
  +                if (PRINT_EXCEPTION_STACK_TRACE)
  +                    ex.printStackTrace();
  +                throw ex;
  +            } 
  +            catch (IOException ex) {
  +                if (PRINT_EXCEPTION_STACK_TRACE)
  +                    ex.printStackTrace();
  +                throw ex;
  +            } 
  +            catch (RuntimeException ex) {
  +                if (PRINT_EXCEPTION_STACK_TRACE)
  +                    ex.printStackTrace();
  +                throw ex;
  +            }
  +            catch (Exception ex) {
  +                if (PRINT_EXCEPTION_STACK_TRACE)
  +                    ex.printStackTrace();
  +                throw new XNIException(ex);
  +            }
  +        }
  +
  +        try {
  +            return fScanner.scanDocument(complete);
  +        } 
  +        catch (XNIException ex) {
  +            if (PRINT_EXCEPTION_STACK_TRACE)
  +                ex.printStackTrace();
  +            throw ex;
  +        } 
  +        catch (IOException ex) {
  +            if (PRINT_EXCEPTION_STACK_TRACE)
  +                ex.printStackTrace();
  +            throw ex;
  +        } 
  +        catch (RuntimeException ex) {
  +            if (PRINT_EXCEPTION_STACK_TRACE)
  +                ex.printStackTrace();
  +            throw ex;
  +        }
  +        catch (Exception ex) {
  +            if (PRINT_EXCEPTION_STACK_TRACE)
  +                ex.printStackTrace();
  +            throw new XNIException(ex);
  +        }
  +
  +    } // parse(boolean):boolean
  +
  +     /** Configures the XML 1.1 pipeline. 
  +     *  Note: this method also resets the new XML11 components
  +     */
  +     protected void configureXML11Pipeline() {
  +        
  +        // create datatype factory
  +        if (fXML11DatatypeFactory == null) {
  +            fXML11DatatypeFactory= 
DTDDVFactory.getInstance(XML11_DATATYPE_VALIDATOR_FACTORY);
  +        }
  +        setProperty(DATATYPE_VALIDATOR_FACTORY, fXML11DatatypeFactory);
  +        
  +
  +             if (fXML11DTDScanner == null) {
  +                     fXML11DTDScanner = new XML11DTDScannerImpl();
  +             }
  +             // setup dtd pipeline
  +             if (fXML11DTDProcessor == null) {
  +                     fXML11DTDProcessor = new XML11DTDProcessor();
  +             }
  +             fProperties.put(DTD_SCANNER, fXML11DTDScanner);
  +             fProperties.put(DTD_PROCESSOR, fXML11DTDProcessor);
  +
  +             fXML11DTDScanner.setDTDHandler(fXML11DTDProcessor);
  +             fXML11DTDProcessor.setDTDHandler(fDTDHandler);
  +             fXML11DTDScanner.setDTDContentModelHandler(fXML11DTDProcessor);
  +             fXML11DTDProcessor.setDTDContentModelHandler(fDTDContentModelHandler);
  +
  +             if (fXML11DocScanner == null) {
  +                     fXML11DocScanner = new XML11DocumentScannerImpl();
  +             }
  +        
  +        if(fXML11DTDValidator == null) {
  +            fXML11DTDValidator = new XML11DTDValidator();
  +        }
  +                
  +             fScanner = fXML11DocScanner;
  +        ((XMLComponent)fScanner).reset(this);
  +             fProperties.put(DOCUMENT_SCANNER, fXML11DocScanner);
  +             fProperties.put(DTD_VALIDATOR, fXML11DTDValidator);
  +             if (fFeatures.get(NAMESPACES) == Boolean.TRUE) {
  +                     if (fXML11NamespaceBinder == null) {
  +                             fXML11NamespaceBinder = new XML11NamespaceBinder();
  +                     }
  +                     fProperties.put(NAMESPACE_BINDER, fXML11NamespaceBinder);
  +
  +                     fScanner.setDocumentHandler(fXML11DTDValidator);
  +                     fXML11DTDValidator.setDocumentSource(fScanner);
  +
  +                     fXML11DTDValidator.setDocumentHandler(fXML11NamespaceBinder);
  +                     fXML11NamespaceBinder.setDocumentSource(fXML11DTDValidator);
  +
  +                     fXML11NamespaceBinder.setDocumentHandler(fDocumentHandler);
  +                     fDocumentHandler.setDocumentSource(fXML11NamespaceBinder);
  +                     fLastComponent = fXML11NamespaceBinder;
  +            fXML11NamespaceBinder.reset(this);
  +             }
  +             else {
  +                     fScanner.setDocumentHandler(fXML11DTDValidator);
  +                     fXML11DTDValidator.setDocumentSource(fScanner);
  +                     fXML11DTDValidator.setDocumentHandler(fDocumentHandler);
  +                     fDocumentHandler.setDocumentSource(fXML11DTDValidator);
  +                     fLastComponent = fXML11DTDValidator;
  +             }
  +             // reset all 1.1 components
  +
  +             fXML11DTDProcessor.reset(this);
  +             fXML11DTDScanner.reset(this);
  +             fXML11DTDValidator.reset(this);
  +
  +        
  +                // setup document pipeline
  +        if (fFeatures.get(XMLSCHEMA_VALIDATION) == Boolean.TRUE) {
  +            // If schema validator was not in the pipeline insert it.
  +            if (fSchemaValidator == null) {
  +                fSchemaValidator = new XMLSchemaValidator();
  +
  +                // add schema component
  +                fProperties.put(SCHEMA_VALIDATOR, fSchemaValidator);
  +                addComponent(fSchemaValidator);
  +                // add schema message formatter
  +                if 
(fErrorReporter.getMessageFormatter(XSMessageFormatter.SCHEMA_DOMAIN) == null) {
  +                    XSMessageFormatter xmft = new XSMessageFormatter();
  +                    
fErrorReporter.putMessageFormatter(XSMessageFormatter.SCHEMA_DOMAIN, xmft);
  +                }
  +
  +            }
  +
  +            fLastComponent.setDocumentHandler(fSchemaValidator);
  +            fSchemaValidator.setDocumentSource(fLastComponent);
  +            fSchemaValidator.setDocumentHandler(fDocumentHandler);
  +            fLastComponent = fSchemaValidator;
  +        }
  +     } // configurePipeline()
  +
  +
   
  -    // factory methods
   
  -    /** Create a document scanner. */
  -    protected XMLDocumentScanner createDocumentScanner() {
  -        if(fVersionDetector == null) {
  -            fVersionDetector = new XMLVersionDetector();
  -        }
  -        return fVersionDetector;
  -    } // createDocumentScanner():XMLDocumentScanner
  -
  -    /** Create a DTD scanner. */
  -    protected XMLDTDScanner createDTDScanner() {
  -        if(fVersionDetector == null) {
  -            fVersionDetector = new XMLVersionDetector();
  -        }
  -        return fVersionDetector;
  -    } // createDTDScanner():XMLDTDScanner
  -
  -    /** Create a datatype validator factory. */
  -    protected DTDDVFactory createDatatypeValidatorFactory() {
  -        return DTDDVFactory.getInstance(XML11_DATATYPE_VALIDATOR_FACTORY);
  -    } // createDatatypeValidatorFactory():DatatypeValidatorFactory
   } // class XML11Configuration
  
  
  
  1.5       +1 -1      
xml-xerces/java/src/org/apache/xerces/parsers/org.apache.xerces.xni.parser.XMLParserConfiguration
  
  Index: org.apache.xerces.xni.parser.XMLParserConfiguration
  ===================================================================
  RCS file: 
/home/cvs/xml-xerces/java/src/org/apache/xerces/parsers/org.apache.xerces.xni.parser.XMLParserConfiguration,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- org.apache.xerces.xni.parser.XMLParserConfiguration       23 Jan 2003 19:39:13 
-0000      1.4
  +++ org.apache.xerces.xni.parser.XMLParserConfiguration       3 Mar 2003 22:17:17 
-0000       1.5
  @@ -1 +1 @@
  -org.apache.xerces.parsers.IntegratedParserConfiguration
  +org.apache.xerces.parsers.XML11Configuration
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to