You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by tn...@apache.org on 2002/07/26 21:12:18 UTC

cvs commit: xml-xerces/c/doc program-others.xml program.xml

tng         2002/07/26 12:12:17

  Modified:    c/doc    program-others.xml program.xml
  Log:
  Documentation update: mention version macro in programming guide.
  
  Revision  Changes    Path
  1.5       +25 -2     xml-xerces/c/doc/program-others.xml
  
  Index: program-others.xml
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/doc/program-others.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- program-others.xml	15 Jul 2002 14:06:58 -0000	1.4
  +++ program-others.xml	26 Jul 2002 19:12:17 -0000	1.5
  @@ -2,6 +2,29 @@
   <!DOCTYPE s1 SYSTEM "sbk:/style/dtd/document.dtd">
   
   <s1 title="Programming Guide">
  +    <anchor name="Macro"/>
  +    <s2 title="Version Macro">
  +        <p>&XercesCName; has defined a numeric preprocessor macro, _XERCES_VERSION, for users to
  +           introduce into their code to perform conditional compilation where the
  +           version of Xerces is detected in order to enable or disable version
  +          specific capabilities. For example,
  +         </p>
  +<source>
  +       #if _XERCES_VERSION >= 20304
  +         // code specific to Xerces-C++ version 2.3.4
  +       #else
  +         // old code here...
  +       #endif
  +</source>
  +        <p>The minor and revision (patch level) numbers have two digits of resolution
  +           which means that '3' becomes '03' and '4' becomes '04' in this example.
  +        </p>
  +        <p>There are also other string macro, or constants to represent the Xerces-C++ version.
  +           Please refer to the header xercesc/util/XercesVersion.hpp for further details.
  +        </p>
  +    </s2>
  +
  +
       <anchor name="Schema"/>
       <s2 title="Schema Support">
           <p>&XercesCName; contains an implementation of the W3C XML Schema
  @@ -154,7 +177,7 @@
       parser.parse(xmlFile);
   
   // This will flush the grammar pool
  -parser.resetCachedGrammarPool(); 
  +parser.resetCachedGrammarPool();
   </source>
   
   <source>
  @@ -180,7 +203,7 @@
              <ul>
                 <li>When caching/reusing DTD grammars, no internal subset is allowed.</li>
                 <li>When preparsing grammars with caching option enabled, if a grammar, in the
  -              result set, already exists in the pool (same NS for schema or same system 
  +              result set, already exists in the pool (same NS for schema or same system
                 id for DTD), the entire set will not be cached.</li>
                 <li>When parsing an XML document with the grammar caching option enabled, the
                 reuse option is also automatically enabled. We will only parse a grammar if it
  
  
  
  1.30      +1 -0      xml-xerces/c/doc/program.xml
  
  Index: program.xml
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/doc/program.xml,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -r1.29 -r1.30
  --- program.xml	12 Jul 2002 14:50:29 -0000	1.29
  +++ program.xml	26 Jul 2002 19:12:17 -0000	1.30
  @@ -72,6 +72,7 @@
       <p>Read the <jump href="program-others.html">&XercesCName; Programming Guide</jump> document
         or jump directly to:</p>
       <ul>
  +      <li><jump href="program-others.html#Macro">Version Macros</jump></li>
         <li><jump href="program-others.html#Schema">Schema Support</jump></li>
         <li><jump href="program-others.html#Progressive">Progressive Parsing</jump></li>
         <li><jump href="program-others.html#GrammarCache">Preparsing Grammar and Grammar Caching</jump></li>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org