You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by er...@locus.apache.org on 2000/12/15 23:58:37 UTC

cvs commit: xml-xerces/java/samples/dom DOMCount.java

ericye      00/12/15 14:58:37

  Modified:    java/samples/dom Tag: xerces_j_2 DOMCount.java
  Log:
  misc fix from Neil Graham
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.1.1.4.4 +5 -2      xml-xerces/java/samples/dom/DOMCount.java
  
  Index: DOMCount.java
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/samples/dom/DOMCount.java,v
  retrieving revision 1.1.1.1.4.3
  retrieving revision 1.1.1.1.4.4
  diff -u -r1.1.1.1.4.3 -r1.1.1.1.4.4
  --- DOMCount.java	2000/12/12 19:07:23	1.1.1.1.4.3
  +++ DOMCount.java	2000/12/15 22:58:37	1.1.1.1.4.4
  @@ -122,9 +122,9 @@
               (DOMParserWrapper)Class.forName(parserWrapperName).newInstance();
               DOMCount counter = new DOMCount();
               long before = System.currentTimeMillis();
  -            parser.setFeature( "http://apache.org/xml/features/dom/defer-node-expansion",
  +//            parser.setFeature( "http://apache.org/xml/features/dom/defer-node-expansion",
   
  -                               setDeferredDOM );
  +//                               setDeferredDOM );
               parser.setFeature( "http://xml.org/sax/features/validation", 
                                  setValidation );
               parser.setFeature( "http://xml.org/sax/features/namespaces",
  @@ -137,8 +137,11 @@
               long after = System.currentTimeMillis();
               counter.printResults(uri, after - before);
           } catch (org.xml.sax.SAXParseException spe) {
  +		spe.printStackTrace();
           } catch (org.xml.sax.SAXNotRecognizedException ex ){
  +		System.out.println("The DOM parser does not recognize one of the features you specified.");
           } catch (org.xml.sax.SAXNotSupportedException ex ){
  +		System.out.println("The DOM parser does not support one of the features you specified...");
           } catch (org.xml.sax.SAXException se) {
               if (se.getException() != null)
                   se.getException().printStackTrace(System.err);