[Expat-checkins] CVS: expat/doc reference.html,1.3,1.4
Clark Cooper
coopercc@users.sourceforge.net
Sun, 24 Sep 2000 17:59:04 -0700
Update of /cvsroot/expat/expat/doc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv28081/doc
Modified Files:
reference.html
Log Message:
Changes for namespace triplets.
Index: reference.html
===================================================================
RCS file: /cvsroot/expat/expat/doc/reference.html,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** reference.html 2000/09/24 03:43:37 1.3
--- reference.html 2000/09/25 00:58:47 1.4
***************
*** 390,395 ****
<p>Element type and attribute names that belong to a given namespace are
! passed to the appropriate handler in expanded form. This expanded form
! is a concatenation of the namespace URI, the separator character (which
is the 2nd argument to <code>XML_ParserCreateNS</code>), and the local
name (i.e. the part after the colon). Names with undeclared prefixes are
--- 390,395 ----
<p>Element type and attribute names that belong to a given namespace are
! passed to the appropriate handler in expanded form. By default this expanded
! form is a concatenation of the namespace URI, the separator character (which
is the 2nd argument to <code>XML_ParserCreateNS</code>), and the local
name (i.e. the part after the colon). Names with undeclared prefixes are
***************
*** 399,402 ****
--- 399,408 ----
namespace.
+ <p>However if <a href="XML_SetReturnNSTriplet">XML_SetReturnNSTriplet</a>
+ has been called with a non-zero <code>do_nst</code> parameter, then the
+ expanded form for names with an explicit prefix is a concatenation of:
+ URI, separator, local name, separator, prefix.
+ </p>
+
<p>You can set handlers for the start of a namespace declaration and for
the end of a scope of a declaration with the
***************
*** 1434,1437 ****
--- 1440,1463 ----
<li>XML_PARAM_ENTITY_PARSING_ALWAYS
</ul>
+ </div>
+
+ <div class="fcndec"><a name="XML_SetReturnNSTriplet"><pre>
+ void
+ XML_SetReturnNSTriplet(XML_Parser parser,
+ int do_nst);
+ </pre></a></div>
+ <div class="fcndef">
+ <p>
+ This function only has an effect when using a parser created with
+ <a href="#XML_ParserCreateNS">XML_ParserCreateNS</a>, i.e. when namespace
+ processing is in effect. The <code>do_nst</code> sets whether or not prefixes
+ are returned with names qualified with a namespace prefix. If this function
+ is called with <code>do_nst</code> non-zero, then afterwards namespace
+ qualified names (that is qualified with a prefix as opposed to belonging
+ to a default namespace) are returned as a triplet with the three parts
+ separated by the namespace separator specified when the parser was created.
+ The order of returned parts is URI, local name, and prefix.</p>
+ <p>If <code>do_nst</code> is zero, then namespaces are reported in the
+ default manner, URI then local_name separated by the namespace separator.</p>
</div>