1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2026-01-17 02:02:39 +03:00
Files
libxml2/doc/html/libxml-xmlschemastypes.html
Daniel Veillard 2fdbd32d51 new dictionary module to keep a single instance of the names used by the
* dict.c include/libxml/dict.h Makefile.am include/libxml/Makefile.am:
  new dictionary module to keep a single instance of the names used
  by the parser
* DOCBparser.c HTMLparser.c parser.c parserInternals.c valid.c:
  switched all parsers to use the dictionary internally
* include/libxml/HTMLparser.h include/libxml/parser.h
  include/libxml/parserInternals.h include/libxml/valid.h:
  Some of the interfaces changed as a result to receive or return
  "const xmlChar *" instead of "xmlChar *", this is either
  insignificant from an user point of view or when the returning
  value changed, those function are really parser internal methods
  that no user code should really change
* doc/libxml2-api.xml doc/html/*: the API interface changed and
  the docs were regenerated
Daniel
2003-08-18 12:15:38 +00:00

143 lines
16 KiB
HTML
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>xmlschemastypes</title><meta name="generator" content="DocBook XSL Stylesheets V1.58.1"><style xmlns="http://www.w3.org/TR/xhtml1/transitional" type="text/css">
.synopsis, .classsynopsis {
background: #eeeeee;
border: solid 1px #aaaaaa;
padding: 0.5em;
}
.programlisting {
background: #eeeeff;
border: solid 1px #aaaaff;
padding: 0.5em;
}
.variablelist {
padding: 4px;
margin-left: 3em;
}
.navigation {
background: #ffeeee;
border: solid 1px #ffaaaa;
margin-top: 0.5em;
margin-bottom: 0.5em;
}
.navigation a {
color: #770000;
}
.navigation a:visited {
color: #550000;
}
.navigation .title {
font-size: 200%;
}
</style><link rel="home" href="index.html" title="Gnome XML Library Reference Manual"><link rel="up" href="libxml-lib.html" title="Libxml Library Reference"><link rel="previous" href="libxml-xmlschemas.html" title="xmlschemas"><link rel="next" href="libxml-schemasInternals.html" title="schemasInternals"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><table xmlns="http://www.w3.org/TR/xhtml1/transitional" class="navigation" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"><tr valign="middle"><td><a accesskey="p" href="libxml-xmlschemas.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></img></a></td><td><a accesskey="u" href="libxml-lib.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></img></a></td><td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></img></a></td><th width="100%" align="center">Gnome XML Library Reference Manual</th><td><a accesskey="n" href="libxml-schemasInternals.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></img></a></td></tr></table><div class="refentry" lang="en"><a name="libxml-xmlschemastypes"></a><div class="titlepage"></div><div class="refnamediv"><h2>xmlschemastypes</h2><p>xmlschemastypes &#8212; </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><pre class="synopsis">
void <a href="libxml-xmlschemastypes.html#xmlSchemaInitTypes">xmlSchemaInitTypes</a> (void);
void <a href="libxml-xmlschemastypes.html#xmlSchemaCleanupTypes">xmlSchemaCleanupTypes</a> (void);
<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> <a href="libxml-xmlschemastypes.html#xmlSchemaGetPredefinedType">xmlSchemaGetPredefinedType</a> (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ns);
int <a href="libxml-xmlschemastypes.html#xmlSchemaValidatePredefinedType">xmlSchemaValidatePredefinedType</a> (<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> type,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> *val);
int <a href="libxml-xmlschemastypes.html#xmlSchemaValPredefTypeNode">xmlSchemaValPredefTypeNode</a> (<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> type,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> *val,
<a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> node);
int <a href="libxml-xmlschemastypes.html#xmlSchemaValidateFacet">xmlSchemaValidateFacet</a> (<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> base,
<a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> facet,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> val);
void <a href="libxml-xmlschemastypes.html#xmlSchemaFreeValue">xmlSchemaFreeValue</a> (<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> val);
<a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> <a href="libxml-xmlschemastypes.html#xmlSchemaNewFacet">xmlSchemaNewFacet</a> (void);
int <a href="libxml-xmlschemastypes.html#xmlSchemaCheckFacet">xmlSchemaCheckFacet</a> (<a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> facet,
<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> typeDecl,
<a href="libxml-xmlschemas.html#xmlSchemaParserCtxtPtr">xmlSchemaParserCtxtPtr</a> ctxt,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name);
void <a href="libxml-xmlschemastypes.html#xmlSchemaFreeFacet">xmlSchemaFreeFacet</a> (<a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> facet);
int <a href="libxml-xmlschemastypes.html#xmlSchemaCompareValues">xmlSchemaCompareValues</a> (<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> x,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> y);
</pre></div><div class="refsect1" lang="en"><h2>Description</h2><p>
</p></div><div class="refsect1" lang="en"><h2>Details</h2><div class="refsect2" lang="en"><h3><a name="xmlSchemaInitTypes"></a>xmlSchemaInitTypes ()</h3><pre class="programlisting">void xmlSchemaInitTypes (void);</pre><p>
</p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaCleanupTypes"></a>xmlSchemaCleanupTypes ()</h3><pre class="programlisting">void xmlSchemaCleanupTypes (void);</pre><p>
Cleanup the default XML Schemas type library</p><p>
</p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaGetPredefinedType"></a>xmlSchemaGetPredefinedType ()</h3><pre class="programlisting"><a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> xmlSchemaGetPredefinedType (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ns);</pre><p>
Lookup a type in the default XML Schemas type library</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the type name
</td></tr><tr><td><span class="term"><i><tt>ns</tt></i> :</span></td><td> the URI of the namespace usually "http://www.w3.org/2001/XMLSchema"
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the type if found, NULL otherwise
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaValidatePredefinedType"></a>xmlSchemaValidatePredefinedType ()</h3><pre class="programlisting">int xmlSchemaValidatePredefinedType (<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> type,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> *val);</pre><p>
Check that a value conforms to the lexical space of the predefined type.
if true a value is computed and returned in <i><tt>val</tt></i>.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>type</tt></i> :</span></td><td> the predefined type
</td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the value to check
</td></tr><tr><td><span class="term"><i><tt>val</tt></i> :</span></td><td> the return computed value
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>0 if this validates, a positive error code number otherwise
and -1 in case of internal or API error.
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaValPredefTypeNode"></a>xmlSchemaValPredefTypeNode ()</h3><pre class="programlisting">int xmlSchemaValPredefTypeNode (<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> type,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> *val,
<a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> node);</pre><p>
Check that a value conforms to the lexical space of the predefined type.
if true a value is computed and returned in <i><tt>val</tt></i>.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>type</tt></i> :</span></td><td> the predefined type
</td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the value to check
</td></tr><tr><td><span class="term"><i><tt>val</tt></i> :</span></td><td> the return computed value
</td></tr><tr><td><span class="term"><i><tt>node</tt></i> :</span></td><td> the node containing the value
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>0 if this validates, a positive error code number otherwise
and -1 in case of internal or API error.
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaValidateFacet"></a>xmlSchemaValidateFacet ()</h3><pre class="programlisting">int xmlSchemaValidateFacet (<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> base,
<a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> facet,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> val);</pre><p>
Check a value against a facet condition</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>base</tt></i> :</span></td><td> the base type
</td></tr><tr><td><span class="term"><i><tt>facet</tt></i> :</span></td><td> the facet to check
</td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the lexical repr of the value to validate
</td></tr><tr><td><span class="term"><i><tt>val</tt></i> :</span></td><td> the precomputed value
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>0 if the element is schemas valid, a positive error code
number otherwise and -1 in case of internal or API error.
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaFreeValue"></a>xmlSchemaFreeValue ()</h3><pre class="programlisting">void xmlSchemaFreeValue (<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> val);</pre><p>
Cleanup the default XML Schemas type library</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>val</tt></i> :</span></td><td>
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaNewFacet"></a>xmlSchemaNewFacet ()</h3><pre class="programlisting"><a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> xmlSchemaNewFacet (void);</pre><p>
Allocate a new Facet structure.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the newly allocated structure or NULL in case or error
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaCheckFacet"></a>xmlSchemaCheckFacet ()</h3><pre class="programlisting">int xmlSchemaCheckFacet (<a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> facet,
<a href="libxml-schemasInternals.html#xmlSchemaTypePtr">xmlSchemaTypePtr</a> typeDecl,
<a href="libxml-xmlschemas.html#xmlSchemaParserCtxtPtr">xmlSchemaParserCtxtPtr</a> ctxt,
const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name);</pre><p>
Checks the default values types, especially for facets</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>facet</tt></i> :</span></td><td> the facet
</td></tr><tr><td><span class="term"><i><tt>typeDecl</tt></i> :</span></td><td> the schema type definition
</td></tr><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the schema parser context or NULL
</td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> name of the type
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>0 if okay or -1 in cae of error
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaFreeFacet"></a>xmlSchemaFreeFacet ()</h3><pre class="programlisting">void xmlSchemaFreeFacet (<a href="libxml-schemasInternals.html#xmlSchemaFacetPtr">xmlSchemaFacetPtr</a> facet);</pre><p>
Deallocate a Schema Facet structure.</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>facet</tt></i> :</span></td><td> a schema facet structure
</td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSchemaCompareValues"></a>xmlSchemaCompareValues ()</h3><pre class="programlisting">int xmlSchemaCompareValues (<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> x,
<a href="libxml-schemasInternals.html#xmlSchemaValPtr">xmlSchemaValPtr</a> y);</pre><p>
Compare 2 values</p><p>
</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>x</tt></i> :</span></td><td> a first value
</td></tr><tr><td><span class="term"><i><tt>y</tt></i> :</span></td><td> a second value
</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>-1 if x &lt; y, 0 if x == y, 1 if x &gt; y, 2 if x &lt;&gt; y, and -2 in
case of error
</td></tr></tbody></table></div></div></div></div><table xmlns="http://www.w3.org/TR/xhtml1/transitional" class="navigation" width="100%" summary="Navigation footer" cellpadding="2" cellspacing="0"><tr valign="middle"><td align="left"><a accesskey="p" href="libxml-xmlschemas.html"><b>&lt;&lt; xmlschemas</b></a></td><td align="right"><a accesskey="n" href="libxml-schemasInternals.html"><b>schemasInternals &gt;&gt;</b></a></td></tr></table></body></html>