mrglavas    2004/01/29 18:53:01

  Modified:    java/docs faq-dom.xml faq-grammars.xml faq-xs.xml
                        releases.xml
  Log:
  Fixing some typos and formatting of code samples.
  
  Revision  Changes    Path
  1.12      +19 -14    xml-xerces/java/docs/faq-dom.xml
  
  Index: faq-dom.xml
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/docs/faq-dom.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- faq-dom.xml       29 Jan 2004 23:33:43 -0000      1.11
  +++ faq-dom.xml       30 Jan 2004 02:53:01 -0000      1.12
  @@ -184,42 +184,47 @@
   
   
     <faq title="XML Schema API and DOM">
  -  <q>How do I retrieve PSVI from the DOM</q>
  +  <q>How do I retrieve PSVI from the DOM?</q>
   <a> <anchor name="xsdom"/>
   <p>By default Xerces does not store the PSVI information in the DOM tree. </p>
   <p>
  -The following source shows you how to parse an XML document (using JAXP) and and 
retrieve PSVI (using <jump 
href="http://www.w3.org/Submission/2004/SUBM-xmlschema-api-20040122/";>XML Schema 
API</jump>):
  +The following source shows you how to parse an XML document (using JAXP) and how to 
retrieve PSVI (using the <jump 
href="http://www.w3.org/Submission/2004/SUBM-xmlschema-api-20040122/";>XML Schema 
API</jump>):
   <source>
   //<code>dbf</code> is JAXP DocumentBuilderFactory
   
   // all of the following features must be set:
   dbf.setNamespaceAware(true);
   dbf.setValidating(true);
  -dbf.setAttribute("http://apache.org/xml/features/validation/schema";, Boolean.TRUE);
  +dbf.setAttribute("http://apache.org/xml/features/validation/schema";, 
  +    Boolean.TRUE);
   
  -// you also must specify Xerces PSVI DOM implementation 
"org.apache.xerces.dom.PSVIDocumentImpl"
  -dbf.setAttribute("http://apache.org/xml/properties/dom/document-class-name";, 
"org.apache.xerces.dom.PSVIDocumentImpl");
  +// you also must specify Xerces PSVI DOM implementation
  +// "org.apache.xerces.dom.PSVIDocumentImpl"
  +dbf.setAttribute("http://apache.org/xml/properties/dom/document-class-name";, 
  +    "org.apache.xerces.dom.PSVIDocumentImpl");
   
   ...            
   Document doc = db.parse(args[0]);
  -if (doc.getDocumentElement().isSupported("psvi", "1.0")){              ElementPSVI 
psviElem = (ElementPSVI)doc.getDocumentElement();
  -        XSElementDeclaration decl = psviElem.getElementDeclaration();
  -        ...
  +if (doc.getDocumentElement().isSupported("psvi", "1.0")){
  +    ElementPSVI psviElem = (ElementPSVI)doc.getDocumentElement();
  +    XSElementDeclaration decl = psviElem.getElementDeclaration();
  +    ...
   }</source>
   </p>
  -<p>If you want to build the DOM tree in memory and be able to access the PSVI 
information you need to start by instantiating org.apache.xerces.dom.PSVIDocumentImpl 
or use DOM Level 3 API as shown in the following example:</p>
  +<p>If you want to build the DOM tree in memory and be able to access the PSVI 
information you need to start by instantiating org.apache.xerces.dom.PSVIDocumentImpl 
or you need to use the DOM Level 3 API as shown in the following example:</p>
   <source>
   System.setProperty(DOMImplementationRegistry.PROPERTY,
  -                "org.apache.xerces.dom.DOMXSImplementationSourceImpl");
  +    "org.apache.xerces.dom.DOMXSImplementationSourceImpl");
      
   DOMImplementationRegistry registry = DOMImplementationRegistry.newInstance();
   
  -DOMImplementation impl = (DOMImplementation) registry.getDOMImplementation("psvi");
  +DOMImplementation impl = 
  +    (DOMImplementation) registry.getDOMImplementation("psvi");
   </source>
   
  -The PSVI information will not be added or modified as you modify the tree in 
memory. Instead, you if you want to get updated PSVI information, you need validate 
your DOM in memory using <jump 
href="http://www.w3.org/TR/2003/CR-DOM-Level-3-Core-20031107/core.html#Document3-normalizeDocument";>normalizeDocument</jump>
 method as described in the <jump href="#xsrevalidate">next question</jump>.
  +The PSVI information will not be added or modified as you modify the tree in 
memory. Instead, if you want to get updated PSVI information, you need to validate 
your DOM in memory using the <jump 
href="http://www.w3.org/TR/2003/CR-DOM-Level-3-Core-20031107/core.html#Document3-normalizeDocument";>normalizeDocument</jump>
 method as described in the <jump href="#xsrevalidate">next question</jump>.
   
  -<p>You can find more information about how to use the XML Schema API <jump 
href="faq-xs.html">here</jump></p>
  +<p>You can find more information about how to use the XML Schema API <jump 
href="faq-xs.html">here</jump>.</p>
   </a>
   </faq>
   
  @@ -298,7 +303,7 @@
     </faq>
   
     <faq title='Handling Errors in DOM'>
  -    <q>How do handle errors?</q>
  +    <q>How do I handle errors?</q>
       <a>
         <p>
        You should register an error handler with the parser by supplying
  
  
  
  1.11      +4 -2      xml-xerces/java/docs/faq-grammars.xml
  
  Index: faq-grammars.xml
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/docs/faq-grammars.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- faq-grammars.xml  29 Jan 2004 23:33:43 -0000      1.10
  +++ faq-grammars.xml  30 Jan 2004 02:53:01 -0000      1.11
  @@ -372,10 +372,12 @@
       </ol>
     </a>
    </faq>
  - <faq title="Using XSLoader to get an XSModel">
  + <faq title="Alternative method for getting an XSModel">
     <q>Is there an alternative method for getting an XSModel?</q>
     <a>
      <p>
  -       Yes, for more information see <jump href="faq-xs.html">XML Schema 
FAQ</jump></p>  </a>
  +    Yes, for more information see the <jump href="faq-xs.html">XML Schema 
FAQ</jump>.
  +   </p>
  +  </a>
    </faq>
   </faqs>
  
  
  
  1.10      +1 -1      xml-xerces/java/docs/faq-xs.xml
  
  Index: faq-xs.xml
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/docs/faq-xs.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- faq-xs.xml        29 Jan 2004 23:33:43 -0000      1.9
  +++ faq-xs.xml        30 Jan 2004 02:53:01 -0000      1.10
  @@ -190,7 +190,7 @@
     </faq>
   
    <faq title="Using XSLoader to get an XSModel">
  -  <q>Can I parse and query XML Schema component in memory</q>
  +  <q>Can I parse and query XML Schema components in memory?</q>
     <a>
      <p>
          Yes, the <jump 
href="http://www.w3.org/Submission/2004/SUBM-xmlschema-api-20040122/";>XML Schema 
API</jump>
  
  
  
  1.176     +2 -2      xml-xerces/java/docs/releases.xml
  
  Index: releases.xml
  ===================================================================
  RCS file: /home/cvs/xml-xerces/java/docs/releases.xml,v
  retrieving revision 1.175
  retrieving revision 1.176
  diff -u -r1.175 -r1.176
  --- releases.xml      30 Jan 2004 00:33:21 -0000      1.175
  +++ releases.xml      30 Jan 2004 02:53:01 -0000      1.176
  @@ -33,7 +33,7 @@
       </fix>
       <update>
        <note>
  -      Implemented the well-formness checking for LSSerializer (DOM Level 3)
  +      Implemented well-formedness checking for LSSerializer (DOM Level 3).
        </note>
        <submitter name='Elena Litani'/>
       </update>
  
  
  

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

Reply via email to