xerces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From leh...@apache.org
Subject cvs commit: xml-xerces/java/src/org/apache/xerces/parsers DOMParser.java
Date Wed, 21 Feb 2001 00:30:32 GMT
lehors      01/02/20 16:30:32

  Modified:    java/src/org/apache/xerces/parsers DOMParser.java
  Log:
  throw a Runtime exception instead of silently failing when the
  application specified class cannot be instantiated
  
  Revision  Changes    Path
  1.40      +5 -5      xml-xerces/java/src/org/apache/xerces/parsers/DOMParser.java
  
  Index: DOMParser.java
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/src/org/apache/xerces/parsers/DOMParser.java,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -r1.39 -r1.40
  --- DOMParser.java	2001/02/13 17:26:35	1.39
  +++ DOMParser.java	2001/02/21 00:30:31	1.40
  @@ -109,7 +109,7 @@
    * DOMParser provides a parser which produces a W3C DOM tree as its output
    *
    * 
  - * @version $Id: DOMParser.java,v 1.39 2001/02/13 17:26:35 lehors Exp $
  + * @version $Id: DOMParser.java,v 1.40 2001/02/21 00:30:31 lehors Exp $
    */
   public class DOMParser
       extends XMLParser
  @@ -937,10 +937,10 @@
                           fDocument = (Document)documentClass.newInstance();
                       }
                       catch (Exception e) {
  -                        // REVISIT: We've already checked the type of the factory
  -                        //          in the setDocumentClassName() method. The only
  -                        //          exception that can occur here is if the class
  -                        //          doesn't have a zero-arg constructor. -Ac
  +                        // REVISIT: Localize this message.
  +                        throw new RuntimeException(
  +                                 "Failed to create document object of class: "
  +                                 + documentClassName);
                       }
                   }
                   fCurrentElementNode = fDocument;
  
  
  

Mime
View raw message