Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| 2 | <html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>valid</title><meta name="generator" content="DocBook XSL Stylesheets V1.58.1"><style xmlns="http://www.w3.org/TR/xhtml1/transitional" type="text/css"> |
| 3 | .synopsis, .classsynopsis { |
| 4 | background: #eeeeee; |
| 5 | border: solid 1px #aaaaaa; |
| 6 | padding: 0.5em; |
| 7 | } |
| 8 | .programlisting { |
| 9 | background: #eeeeff; |
| 10 | border: solid 1px #aaaaff; |
| 11 | padding: 0.5em; |
| 12 | } |
| 13 | .variablelist { |
| 14 | padding: 4px; |
| 15 | margin-left: 3em; |
| 16 | } |
| 17 | .navigation { |
| 18 | background: #ffeeee; |
| 19 | border: solid 1px #ffaaaa; |
| 20 | margin-top: 0.5em; |
| 21 | margin-bottom: 0.5em; |
| 22 | } |
| 23 | .navigation a { |
| 24 | color: #770000; |
| 25 | } |
| 26 | .navigation a:visited { |
| 27 | color: #550000; |
| 28 | } |
| 29 | .navigation .title { |
| 30 | font-size: 200%; |
| 31 | } |
| 32 | </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-entities.html" title="entities"><link rel="next" href="libxml-relaxng.html" title="relaxng"></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-entities.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-relaxng.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-valid"></a><div class="titlepage"></div><div class="refnamediv"><h2>valid</h2><p>valid — </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><pre class="synopsis"> |
Daniel Veillard | 3592547 | 1999-02-25 08:46:07 +0000 | [diff] [blame] | 33 | |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 34 | |
| 35 | |
| 36 | struct <a href="libxml-valid.html#xmlValidState">xmlValidState</a>; |
| 37 | typedef <a href="libxml-valid.html#xmlValidStatePtr">xmlValidStatePtr</a>; |
| 38 | void (<a href="libxml-valid.html#xmlValidityErrorFunc">*xmlValidityErrorFunc</a>) (void *ctx, |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 39 | const char *msg, |
| 40 | ...); |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 41 | void (<a href="libxml-valid.html#xmlValidityWarningFunc">*xmlValidityWarningFunc</a>) (void *ctx, |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 42 | const char *msg, |
| 43 | ...); |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 44 | struct <a href="libxml-valid.html#xmlValidCtxt">xmlValidCtxt</a>; |
| 45 | typedef <a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a>; |
| 46 | typedef <a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a>; |
| 47 | typedef <a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a>; |
| 48 | typedef <a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a>; |
| 49 | typedef <a href="libxml-valid.html#xmlIDTablePtr">xmlIDTablePtr</a>; |
| 50 | typedef <a href="libxml-valid.html#xmlRefTablePtr">xmlRefTablePtr</a>; |
| 51 | <a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> <a href="libxml-valid.html#xmlAddNotationDecl">xmlAddNotationDecl</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 52 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 53 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 54 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *PublicID, |
| 55 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *SystemID); |
| 56 | <a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> <a href="libxml-valid.html#xmlCopyNotationTable">xmlCopyNotationTable</a> (<a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> table); |
| 57 | void <a href="libxml-valid.html#xmlFreeNotationTable">xmlFreeNotationTable</a> (<a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> table); |
| 58 | void <a href="libxml-valid.html#xmlDumpNotationDecl">xmlDumpNotationDecl</a> (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 59 | <a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> nota); |
| 60 | void <a href="libxml-valid.html#xmlDumpNotationTable">xmlDumpNotationTable</a> (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 61 | <a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> table); |
| 62 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> <a href="libxml-valid.html#xmlNewElementContent">xmlNewElementContent</a> (<a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 63 | <a href="libxml-tree.html#xmlElementContentType">xmlElementContentType</a> type); |
| 64 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> <a href="libxml-valid.html#xmlCopyElementContent">xmlCopyElementContent</a> (<a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content); |
| 65 | void <a href="libxml-valid.html#xmlFreeElementContent">xmlFreeElementContent</a> (<a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> cur); |
| 66 | void <a href="libxml-valid.html#xmlSnprintfElementContent">xmlSnprintfElementContent</a> (char *buf, |
Daniel Veillard | e7ead2d | 2001-08-22 23:44:09 +0000 | [diff] [blame] | 67 | int size, |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 68 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content, |
Daniel Veillard | e7ead2d | 2001-08-22 23:44:09 +0000 | [diff] [blame] | 69 | int glob); |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 70 | void <a href="libxml-valid.html#xmlSprintfElementContent">xmlSprintfElementContent</a> (char *buf, |
| 71 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content, |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 72 | int glob); |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 73 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> <a href="libxml-valid.html#xmlAddElementDecl">xmlAddElementDecl</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 74 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 75 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 76 | <a href="libxml-tree.html#xmlElementTypeVal">xmlElementTypeVal</a> type, |
| 77 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content); |
| 78 | <a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> <a href="libxml-valid.html#xmlCopyElementTable">xmlCopyElementTable</a> (<a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> table); |
| 79 | void <a href="libxml-valid.html#xmlFreeElementTable">xmlFreeElementTable</a> (<a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> table); |
| 80 | void <a href="libxml-valid.html#xmlDumpElementTable">xmlDumpElementTable</a> (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 81 | <a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> table); |
| 82 | void <a href="libxml-valid.html#xmlDumpElementDecl">xmlDumpElementDecl</a> (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 83 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> elem); |
| 84 | <a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> <a href="libxml-valid.html#xmlCreateEnumeration">xmlCreateEnumeration</a> (<a href="libxml-tree.html#xmlChar">xmlChar</a> *name); |
| 85 | void <a href="libxml-valid.html#xmlFreeEnumeration">xmlFreeEnumeration</a> (<a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> cur); |
| 86 | <a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> <a href="libxml-valid.html#xmlCopyEnumeration">xmlCopyEnumeration</a> (<a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> cur); |
| 87 | <a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> <a href="libxml-valid.html#xmlAddAttributeDecl">xmlAddAttributeDecl</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 88 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 89 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *elem, |
| 90 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 91 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ns, |
| 92 | <a href="libxml-tree.html#xmlAttributeType">xmlAttributeType</a> type, |
| 93 | <a href="libxml-tree.html#xmlAttributeDefault">xmlAttributeDefault</a> def, |
| 94 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *defaultValue, |
| 95 | <a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> tree); |
| 96 | <a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> <a href="libxml-valid.html#xmlCopyAttributeTable">xmlCopyAttributeTable</a> (<a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> table); |
| 97 | void <a href="libxml-valid.html#xmlFreeAttributeTable">xmlFreeAttributeTable</a> (<a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> table); |
| 98 | void <a href="libxml-valid.html#xmlDumpAttributeTable">xmlDumpAttributeTable</a> (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 99 | <a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> table); |
| 100 | void <a href="libxml-valid.html#xmlDumpAttributeDecl">xmlDumpAttributeDecl</a> (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 101 | <a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> attr); |
| 102 | <a href="libxml-tree.html#xmlIDPtr">xmlIDPtr</a> <a href="libxml-valid.html#xmlAddID">xmlAddID</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 103 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 104 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value, |
| 105 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr); |
| 106 | void <a href="libxml-valid.html#xmlFreeIDTable">xmlFreeIDTable</a> (<a href="libxml-valid.html#xmlIDTablePtr">xmlIDTablePtr</a> table); |
| 107 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> <a href="libxml-valid.html#xmlGetID">xmlGetID</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 108 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ID); |
| 109 | int <a href="libxml-valid.html#xmlIsID">xmlIsID</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 110 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 111 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr); |
| 112 | int <a href="libxml-valid.html#xmlRemoveID">xmlRemoveID</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 113 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr); |
| 114 | <a href="libxml-tree.html#xmlRefPtr">xmlRefPtr</a> <a href="libxml-valid.html#xmlAddRef">xmlAddRef</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 115 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 116 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value, |
| 117 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr); |
| 118 | void <a href="libxml-valid.html#xmlFreeRefTable">xmlFreeRefTable</a> (<a href="libxml-valid.html#xmlRefTablePtr">xmlRefTablePtr</a> table); |
| 119 | int <a href="libxml-valid.html#xmlIsRef">xmlIsRef</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 120 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 121 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr); |
| 122 | int <a href="libxml-valid.html#xmlRemoveRef">xmlRemoveRef</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 123 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr); |
| 124 | <GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="xmlListPtr">xmlListPtr</GTKDOCLINK> <a href="libxml-valid.html#xmlGetRefs">xmlGetRefs</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 125 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ID); |
| 126 | int <a href="libxml-valid.html#xmlValidateRoot">xmlValidateRoot</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 127 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc); |
| 128 | int <a href="libxml-valid.html#xmlValidateElementDecl">xmlValidateElementDecl</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 129 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 130 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> elem); |
| 131 | <a href="libxml-tree.html#xmlChar">xmlChar</a>* <a href="libxml-valid.html#xmlValidNormalizeAttributeValue">xmlValidNormalizeAttributeValue</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 132 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 133 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 134 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 135 | <a href="libxml-tree.html#xmlChar">xmlChar</a>* <a href="libxml-valid.html#xmlValidCtxtNormalizeAttributeValue">xmlValidCtxtNormalizeAttributeValue</a> |
| 136 | (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 137 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 138 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 139 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 140 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 141 | int <a href="libxml-valid.html#xmlValidateAttributeDecl">xmlValidateAttributeDecl</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 142 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 143 | <a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> attr); |
| 144 | int <a href="libxml-valid.html#xmlValidateAttributeValue">xmlValidateAttributeValue</a> (<a href="libxml-tree.html#xmlAttributeType">xmlAttributeType</a> type, |
| 145 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 146 | int <a href="libxml-valid.html#xmlValidateNotationDecl">xmlValidateNotationDecl</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 147 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 148 | <a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> nota); |
| 149 | int <a href="libxml-valid.html#xmlValidateDtd">xmlValidateDtd</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 150 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 151 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd); |
| 152 | int <a href="libxml-valid.html#xmlValidateDtdFinal">xmlValidateDtdFinal</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 153 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc); |
| 154 | int <a href="libxml-valid.html#xmlValidateDocument">xmlValidateDocument</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 155 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc); |
| 156 | int <a href="libxml-valid.html#xmlValidateElement">xmlValidateElement</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 157 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 158 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem); |
| 159 | int <a href="libxml-valid.html#xmlValidateOneElement">xmlValidateOneElement</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 160 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 161 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem); |
| 162 | int <a href="libxml-valid.html#xmlValidateOneAttribute">xmlValidateOneAttribute</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 163 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 164 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 165 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr, |
| 166 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 167 | int <a href="libxml-valid.html#xmlValidateOneNamespace">xmlValidateOneNamespace</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 168 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 169 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 170 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *prefix, |
| 171 | <a href="libxml-tree.html#xmlNsPtr">xmlNsPtr</a> ns, |
| 172 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 173 | int <a href="libxml-valid.html#xmlValidateDocumentFinal">xmlValidateDocumentFinal</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 174 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc); |
| 175 | int <a href="libxml-valid.html#xmlValidateNotationUse">xmlValidateNotationUse</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 176 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 177 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *notationName); |
| 178 | int <a href="libxml-valid.html#xmlIsMixedElement">xmlIsMixedElement</a> (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 179 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name); |
| 180 | <a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> <a href="libxml-valid.html#xmlGetDtdAttrDesc">xmlGetDtdAttrDesc</a> (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 181 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *elem, |
| 182 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name); |
| 183 | <a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> <a href="libxml-valid.html#xmlGetDtdQAttrDesc">xmlGetDtdQAttrDesc</a> (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 184 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *elem, |
| 185 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 186 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *prefix); |
| 187 | <a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> <a href="libxml-valid.html#xmlGetDtdNotationDesc">xmlGetDtdNotationDesc</a> (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 188 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name); |
| 189 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> <a href="libxml-valid.html#xmlGetDtdQElementDesc">xmlGetDtdQElementDesc</a> (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 190 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 191 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *prefix); |
| 192 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> <a href="libxml-valid.html#xmlGetDtdElementDesc">xmlGetDtdElementDesc</a> (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 193 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name); |
| 194 | int <a href="libxml-valid.html#xmlValidGetValidElements">xmlValidGetValidElements</a> (<a href="libxml-tree.html#xmlNode">xmlNode</a> *prev, |
| 195 | <a href="libxml-tree.html#xmlNode">xmlNode</a> *next, |
| 196 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> **list, |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 197 | int max); |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 198 | int <a href="libxml-valid.html#xmlValidGetPotentialChildren">xmlValidGetPotentialChildren</a> (<a href="libxml-tree.html#xmlElementContent">xmlElementContent</a> *ctree, |
| 199 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> **list, |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 200 | int *len, |
Daniel Veillard | a7084cd | 2002-04-15 17:12:47 +0000 | [diff] [blame] | 201 | int max); |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 202 | int <a href="libxml-valid.html#xmlValidateNameValue">xmlValidateNameValue</a> (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 203 | int <a href="libxml-valid.html#xmlValidateNamesValue">xmlValidateNamesValue</a> (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 204 | int <a href="libxml-valid.html#xmlValidateNmtokenValue">xmlValidateNmtokenValue</a> (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 205 | int <a href="libxml-valid.html#xmlValidateNmtokensValue">xmlValidateNmtokensValue</a> (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value); |
| 206 | int <a href="libxml-valid.html#xmlValidBuildContentModel">xmlValidBuildContentModel</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 207 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> elem); |
| 208 | int <a href="libxml-valid.html#xmlValidatePushElement">xmlValidatePushElement</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 209 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 210 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 211 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *qname); |
| 212 | int <a href="libxml-valid.html#xmlValidatePushCData">xmlValidatePushCData</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 213 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *data, |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 214 | int len); |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 215 | int <a href="libxml-valid.html#xmlValidatePopElement">xmlValidatePopElement</a> (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 216 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 217 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 218 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *qname); |
| 219 | </pre></div><div class="refsect1" lang="en"><h2>Description</h2><p> |
| 220 | |
| 221 | </p></div><div class="refsect1" lang="en"><h2>Details</h2><div class="refsect2" lang="en"><h3><a name="xmlValidState"></a>struct xmlValidState</h3><pre class="programlisting">struct xmlValidState;</pre><p> |
| 222 | |
| 223 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidStatePtr"></a>xmlValidStatePtr</h3><pre class="programlisting">typedef xmlValidState *xmlValidStatePtr; |
| 224 | </pre><p> |
| 225 | |
| 226 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidityErrorFunc"></a>xmlValidityErrorFunc ()</h3><pre class="programlisting">void (*xmlValidityErrorFunc) (void *ctx, |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 227 | const char *msg, |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 228 | ...);</pre><p> |
| 229 | Callback called when a validity error is found. This is a message |
| 230 | oriented function similar to an *printf function.</p><p> |
| 231 | |
| 232 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctx</tt></i> :</span></td><td> an xmlValidCtxtPtr validity error context |
| 233 | </td></tr><tr><td><span class="term"><i><tt>msg</tt></i> :</span></td><td> the string to format *printf like vararg |
| 234 | </td></tr><tr><td><span class="term"><i><tt>...</tt></i> :</span></td><td> remaining arguments to the format |
| 235 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidityWarningFunc"></a>xmlValidityWarningFunc ()</h3><pre class="programlisting">void (*xmlValidityWarningFunc) (void *ctx, |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 236 | const char *msg, |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 237 | ...);</pre><p> |
| 238 | Callback called when a validity warning is found. This is a message |
| 239 | oriented function similar to an *printf function.</p><p> |
| 240 | |
| 241 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctx</tt></i> :</span></td><td> an xmlValidCtxtPtr validity error context |
| 242 | </td></tr><tr><td><span class="term"><i><tt>msg</tt></i> :</span></td><td> the string to format *printf like vararg |
| 243 | </td></tr><tr><td><span class="term"><i><tt>...</tt></i> :</span></td><td> remaining arguments to the format |
| 244 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidCtxt"></a>struct xmlValidCtxt</h3><pre class="programlisting">struct xmlValidCtxt { |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 245 | void *userData; /* user specific data block */ |
| 246 | xmlValidityErrorFunc error; /* the callback in case of errors */ |
| 247 | xmlValidityWarningFunc warning; /* the callback in case of warning */ |
| 248 | |
| 249 | /* Node analysis stack used when validating within entities */ |
| 250 | xmlNodePtr node; /* Current parsed Node */ |
| 251 | int nodeNr; /* Depth of the parsing stack */ |
| 252 | int nodeMax; /* Max depth of the parsing stack */ |
| 253 | xmlNodePtr *nodeTab; /* array of nodes */ |
| 254 | |
| 255 | int finishDtd; /* finished validating the Dtd ? */ |
Daniel Veillard | 29a11cc | 2000-10-25 13:32:39 +0000 | [diff] [blame] | 256 | xmlDocPtr doc; /* the document */ |
| 257 | int valid; /* temporary validity check result */ |
Daniel Veillard | a41123c | 2001-04-22 19:31:20 +0000 | [diff] [blame] | 258 | |
| 259 | /* state state used for non-determinist content validation */ |
| 260 | xmlValidState *vstate; /* current state */ |
| 261 | int vstateNr; /* Depth of the validation stack */ |
| 262 | int vstateMax; /* Max depth of the validation stack */ |
| 263 | xmlValidState *vstateTab; /* array of validation states */ |
Daniel Veillard | 2ace195 | 2002-09-26 12:28:02 +0000 | [diff] [blame] | 264 | |
| 265 | #ifdef LIBXML_REGEXP_ENABLED |
| 266 | xmlAutomataPtr am; /* the automata */ |
| 267 | xmlAutomataStatePtr state; /* used to build the automata */ |
| 268 | #else |
| 269 | void *am; |
| 270 | void *state; |
| 271 | #endif |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 272 | }; |
| 273 | </pre><p> |
| 274 | </p><p> |
| 275 | |
| 276 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidCtxtPtr"></a>xmlValidCtxtPtr</h3><pre class="programlisting">typedef xmlValidCtxt *xmlValidCtxtPtr; |
| 277 | </pre><p> |
| 278 | |
| 279 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlNotationTablePtr"></a>xmlNotationTablePtr</h3><pre class="programlisting">typedef xmlNotationTable *xmlNotationTablePtr; |
| 280 | </pre><p> |
| 281 | |
| 282 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlElementTablePtr"></a>xmlElementTablePtr</h3><pre class="programlisting">typedef xmlElementTable *xmlElementTablePtr; |
| 283 | </pre><p> |
| 284 | |
| 285 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlAttributeTablePtr"></a>xmlAttributeTablePtr</h3><pre class="programlisting">typedef xmlAttributeTable *xmlAttributeTablePtr; |
| 286 | </pre><p> |
| 287 | |
| 288 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlIDTablePtr"></a>xmlIDTablePtr</h3><pre class="programlisting">typedef xmlIDTable *xmlIDTablePtr; |
| 289 | </pre><p> |
| 290 | |
| 291 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlRefTablePtr"></a>xmlRefTablePtr</h3><pre class="programlisting">typedef xmlRefTable *xmlRefTablePtr; |
| 292 | </pre><p> |
| 293 | |
| 294 | </p></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlAddNotationDecl"></a>xmlAddNotationDecl ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> xmlAddNotationDecl (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 295 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 296 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 297 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *PublicID, |
| 298 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *SystemID);</pre><p> |
| 299 | Register a new notation declaration</p><p> |
| 300 | |
| 301 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 302 | </td></tr><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> pointer to the DTD |
| 303 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the entity name |
| 304 | </td></tr><tr><td><span class="term"><i><tt>PublicID</tt></i> :</span></td><td> the public identifier or NULL |
| 305 | </td></tr><tr><td><span class="term"><i><tt>SystemID</tt></i> :</span></td><td> the system identifier or NULL |
| 306 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not, otherwise the entity |
| 307 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlCopyNotationTable"></a>xmlCopyNotationTable ()</h3><pre class="programlisting"><a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> xmlCopyNotationTable (<a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> table);</pre><p> |
| 308 | Build a copy of a notation table.</p><p> |
| 309 | |
| 310 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> A notation table |
| 311 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the new xmlNotationTablePtr or NULL in case of error. |
| 312 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlFreeNotationTable"></a>xmlFreeNotationTable ()</h3><pre class="programlisting">void xmlFreeNotationTable (<a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> table);</pre><p> |
| 313 | Deallocate the memory used by an entities hash table.</p><p> |
| 314 | |
| 315 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An notation table |
| 316 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlDumpNotationDecl"></a>xmlDumpNotationDecl ()</h3><pre class="programlisting">void xmlDumpNotationDecl (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 317 | <a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> nota);</pre><p> |
| 318 | This will dump the content the notation declaration as an XML DTD definition</p><p> |
| 319 | |
| 320 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> the XML buffer output |
| 321 | </td></tr><tr><td><span class="term"><i><tt>nota</tt></i> :</span></td><td> A notation declaration |
| 322 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlDumpNotationTable"></a>xmlDumpNotationTable ()</h3><pre class="programlisting">void xmlDumpNotationTable (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 323 | <a href="libxml-valid.html#xmlNotationTablePtr">xmlNotationTablePtr</a> table);</pre><p> |
| 324 | This will dump the content of the notation table as an XML DTD definition</p><p> |
| 325 | |
| 326 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> the XML buffer output |
| 327 | </td></tr><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> A notation table |
| 328 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlNewElementContent"></a>xmlNewElementContent ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> xmlNewElementContent (<a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 329 | <a href="libxml-tree.html#xmlElementContentType">xmlElementContentType</a> type);</pre><p> |
| 330 | Allocate an element content structure.</p><p> |
| 331 | |
| 332 | </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 subelement name or NULL |
| 333 | </td></tr><tr><td><span class="term"><i><tt>type</tt></i> :</span></td><td> the type of element content decl |
| 334 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not, otherwise the new element content structure |
| 335 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlCopyElementContent"></a>xmlCopyElementContent ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> xmlCopyElementContent (<a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content);</pre><p> |
| 336 | Build a copy of an element content description.</p><p> |
| 337 | |
| 338 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>content</tt></i> :</span></td><td> |
| 339 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the new xmlElementContentPtr or NULL in case of error. |
| 340 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlFreeElementContent"></a>xmlFreeElementContent ()</h3><pre class="programlisting">void xmlFreeElementContent (<a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> cur);</pre><p> |
| 341 | Free an element content structure. This is a recursive call !</p><p> |
| 342 | |
| 343 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>cur</tt></i> :</span></td><td> the element content tree to free |
| 344 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSnprintfElementContent"></a>xmlSnprintfElementContent ()</h3><pre class="programlisting">void xmlSnprintfElementContent (char *buf, |
Daniel Veillard | e7ead2d | 2001-08-22 23:44:09 +0000 | [diff] [blame] | 345 | int size, |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 346 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content, |
| 347 | int glob);</pre><p> |
| 348 | This will dump the content of the element content definition |
| 349 | Intended just for the debug routine</p><p> |
| 350 | |
| 351 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> an output buffer |
| 352 | </td></tr><tr><td><span class="term"><i><tt>size</tt></i> :</span></td><td> the buffer size |
| 353 | </td></tr><tr><td><span class="term"><i><tt>content</tt></i> :</span></td><td> An element table |
| 354 | </td></tr><tr><td><span class="term"><i><tt>glob</tt></i> :</span></td><td> 1 if one must print the englobing parenthesis, 0 otherwise |
| 355 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlSprintfElementContent"></a>xmlSprintfElementContent ()</h3><pre class="programlisting">void xmlSprintfElementContent (char *buf, |
| 356 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content, |
| 357 | int glob);</pre><p> |
| 358 | Deprecated, unsafe, use xmlSnprintfElementContent</p><p> |
| 359 | |
| 360 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> an output buffer |
| 361 | </td></tr><tr><td><span class="term"><i><tt>content</tt></i> :</span></td><td> An element table |
| 362 | </td></tr><tr><td><span class="term"><i><tt>glob</tt></i> :</span></td><td> 1 if one must print the englobing parenthesis, 0 otherwise |
| 363 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlAddElementDecl"></a>xmlAddElementDecl ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> xmlAddElementDecl (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 364 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 365 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 366 | <a href="libxml-tree.html#xmlElementTypeVal">xmlElementTypeVal</a> type, |
| 367 | <a href="libxml-tree.html#xmlElementContentPtr">xmlElementContentPtr</a> content);</pre><p> |
| 368 | Register a new element declaration</p><p> |
| 369 | |
| 370 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 371 | </td></tr><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> pointer to the DTD |
| 372 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the entity name |
| 373 | </td></tr><tr><td><span class="term"><i><tt>type</tt></i> :</span></td><td> the element type |
| 374 | </td></tr><tr><td><span class="term"><i><tt>content</tt></i> :</span></td><td> the element content tree or NULL |
| 375 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not, otherwise the entity |
| 376 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlCopyElementTable"></a>xmlCopyElementTable ()</h3><pre class="programlisting"><a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> xmlCopyElementTable (<a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> table);</pre><p> |
| 377 | Build a copy of an element table.</p><p> |
| 378 | |
| 379 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An element table |
| 380 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the new xmlElementTablePtr or NULL in case of error. |
| 381 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlFreeElementTable"></a>xmlFreeElementTable ()</h3><pre class="programlisting">void xmlFreeElementTable (<a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> table);</pre><p> |
| 382 | Deallocate the memory used by an element hash table.</p><p> |
| 383 | |
| 384 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An element table |
| 385 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlDumpElementTable"></a>xmlDumpElementTable ()</h3><pre class="programlisting">void xmlDumpElementTable (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 386 | <a href="libxml-valid.html#xmlElementTablePtr">xmlElementTablePtr</a> table);</pre><p> |
| 387 | This will dump the content of the element table as an XML DTD definition</p><p> |
| 388 | |
| 389 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> the XML buffer output |
| 390 | </td></tr><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An element table |
| 391 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlDumpElementDecl"></a>xmlDumpElementDecl ()</h3><pre class="programlisting">void xmlDumpElementDecl (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 392 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> elem);</pre><p> |
| 393 | This will dump the content of the element declaration as an XML |
| 394 | DTD definition</p><p> |
| 395 | |
| 396 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> the XML buffer output |
| 397 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> An element table |
| 398 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlCreateEnumeration"></a>xmlCreateEnumeration ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> xmlCreateEnumeration (<a href="libxml-tree.html#xmlChar">xmlChar</a> *name);</pre><p> |
| 399 | create and initialize an enumeration attribute node.</p><p> |
| 400 | |
| 401 | </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 enumeration name or NULL |
| 402 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the xmlEnumerationPtr just created or NULL in case |
| 403 | of error. |
| 404 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlFreeEnumeration"></a>xmlFreeEnumeration ()</h3><pre class="programlisting">void xmlFreeEnumeration (<a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> cur);</pre><p> |
| 405 | free an enumeration attribute node (recursive).</p><p> |
| 406 | |
| 407 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>cur</tt></i> :</span></td><td> the tree to free. |
| 408 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlCopyEnumeration"></a>xmlCopyEnumeration ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> xmlCopyEnumeration (<a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> cur);</pre><p> |
| 409 | Copy an enumeration attribute node (recursive).</p><p> |
| 410 | |
| 411 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>cur</tt></i> :</span></td><td> the tree to copy. |
| 412 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the xmlEnumerationPtr just created or NULL in case |
| 413 | of error. |
| 414 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlAddAttributeDecl"></a>xmlAddAttributeDecl ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> xmlAddAttributeDecl (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 415 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 416 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *elem, |
| 417 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 418 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ns, |
| 419 | <a href="libxml-tree.html#xmlAttributeType">xmlAttributeType</a> type, |
| 420 | <a href="libxml-tree.html#xmlAttributeDefault">xmlAttributeDefault</a> def, |
| 421 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *defaultValue, |
| 422 | <a href="libxml-tree.html#xmlEnumerationPtr">xmlEnumerationPtr</a> tree);</pre><p> |
| 423 | Register a new attribute declaration |
| 424 | Note that <i><tt>tree</tt></i> becomes the ownership of the DTD</p><p> |
| 425 | |
| 426 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 427 | </td></tr><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> pointer to the DTD |
| 428 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> the element name |
| 429 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the attribute name |
| 430 | </td></tr><tr><td><span class="term"><i><tt>ns</tt></i> :</span></td><td> the attribute namespace prefix |
| 431 | </td></tr><tr><td><span class="term"><i><tt>type</tt></i> :</span></td><td> the attribute type |
| 432 | </td></tr><tr><td><span class="term"><i><tt>def</tt></i> :</span></td><td> the attribute default type |
| 433 | </td></tr><tr><td><span class="term"><i><tt>defaultValue</tt></i> :</span></td><td> the attribute default value |
| 434 | </td></tr><tr><td><span class="term"><i><tt>tree</tt></i> :</span></td><td> if it's an enumeration, the associated list |
| 435 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not new, otherwise the attribute decl |
| 436 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlCopyAttributeTable"></a>xmlCopyAttributeTable ()</h3><pre class="programlisting"><a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> xmlCopyAttributeTable (<a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> table);</pre><p> |
| 437 | Build a copy of an attribute table.</p><p> |
| 438 | |
| 439 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An attribute table |
| 440 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the new xmlAttributeTablePtr or NULL in case of error. |
| 441 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlFreeAttributeTable"></a>xmlFreeAttributeTable ()</h3><pre class="programlisting">void xmlFreeAttributeTable (<a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> table);</pre><p> |
| 442 | Deallocate the memory used by an entities hash table.</p><p> |
| 443 | |
| 444 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An attribute table |
| 445 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlDumpAttributeTable"></a>xmlDumpAttributeTable ()</h3><pre class="programlisting">void xmlDumpAttributeTable (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 446 | <a href="libxml-valid.html#xmlAttributeTablePtr">xmlAttributeTablePtr</a> table);</pre><p> |
| 447 | This will dump the content of the attribute table as an XML DTD definition</p><p> |
| 448 | |
| 449 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> the XML buffer output |
| 450 | </td></tr><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An attribute table |
| 451 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlDumpAttributeDecl"></a>xmlDumpAttributeDecl ()</h3><pre class="programlisting">void xmlDumpAttributeDecl (<a href="libxml-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, |
| 452 | <a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> attr);</pre><p> |
| 453 | This will dump the content of the attribute declaration as an XML |
| 454 | DTD definition</p><p> |
| 455 | |
| 456 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>buf</tt></i> :</span></td><td> the XML buffer output |
| 457 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> An attribute declaration |
| 458 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlAddID"></a>xmlAddID ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlIDPtr">xmlIDPtr</a> xmlAddID (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 459 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 460 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value, |
| 461 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr);</pre><p> |
| 462 | Register a new id declaration</p><p> |
| 463 | |
| 464 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 465 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> pointer to the document |
| 466 | </td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the value name |
| 467 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> the attribute holding the ID |
| 468 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not, otherwise the new xmlIDPtr |
| 469 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlFreeIDTable"></a>xmlFreeIDTable ()</h3><pre class="programlisting">void xmlFreeIDTable (<a href="libxml-valid.html#xmlIDTablePtr">xmlIDTablePtr</a> table);</pre><p> |
| 470 | Deallocate the memory used by an ID hash table.</p><p> |
| 471 | |
| 472 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An id table |
| 473 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlGetID"></a>xmlGetID ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> xmlGetID (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 474 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ID);</pre><p> |
| 475 | Search the attribute declaring the given ID</p><p> |
| 476 | |
| 477 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> pointer to the document |
| 478 | </td></tr><tr><td><span class="term"><i><tt>ID</tt></i> :</span></td><td> the ID value |
| 479 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not found, otherwise the xmlAttrPtr defining the ID |
| 480 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlIsID"></a>xmlIsID ()</h3><pre class="programlisting">int xmlIsID (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 481 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 482 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr);</pre><p> |
| 483 | Determine whether an attribute is of type ID. In case we have DTD(s) |
Daniel Veillard | 80ce373 | 2002-10-07 17:39:30 +0000 | [diff] [blame] | 484 | then this is done if DTD loading has been requested. In the case |
| 485 | of HTML documents parsed with the HTML parser, then ID detection is |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 486 | done systematically.</p><p> |
| 487 | |
| 488 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 489 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> the element carrying the attribute |
| 490 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> the attribute |
| 491 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>0 or 1 depending on the lookup result |
| 492 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlRemoveID"></a>xmlRemoveID ()</h3><pre class="programlisting">int xmlRemoveID (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 493 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr);</pre><p> |
| 494 | Remove the given attribute from the ID table maintained internally.</p><p> |
| 495 | |
| 496 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 497 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> the attribute |
| 498 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>-1 if the lookup failed and 0 otherwise |
| 499 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlAddRef"></a>xmlAddRef ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlRefPtr">xmlRefPtr</a> xmlAddRef (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 500 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 501 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value, |
| 502 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr);</pre><p> |
| 503 | Register a new ref declaration</p><p> |
| 504 | |
| 505 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 506 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> pointer to the document |
| 507 | </td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the value name |
| 508 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> the attribute holding the Ref |
| 509 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not, otherwise the new xmlRefPtr |
| 510 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlFreeRefTable"></a>xmlFreeRefTable ()</h3><pre class="programlisting">void xmlFreeRefTable (<a href="libxml-valid.html#xmlRefTablePtr">xmlRefTablePtr</a> table);</pre><p> |
| 511 | Deallocate the memory used by an Ref hash table.</p><p> |
| 512 | |
| 513 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>table</tt></i> :</span></td><td> An ref table |
| 514 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlIsRef"></a>xmlIsRef ()</h3><pre class="programlisting">int xmlIsRef (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 515 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 516 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr);</pre><p> |
| 517 | Determine whether an attribute is of type Ref. In case we have DTD(s) |
Daniel Veillard | 7f7d111 | 1999-09-22 09:46:25 +0000 | [diff] [blame] | 518 | then this is simple, otherwise we use an heuristic: name Ref (upper |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 519 | or lowercase).</p><p> |
| 520 | |
| 521 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 522 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> the element carrying the attribute |
| 523 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> the attribute |
| 524 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>0 or 1 depending on the lookup result |
| 525 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlRemoveRef"></a>xmlRemoveRef ()</h3><pre class="programlisting">int xmlRemoveRef (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 526 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr);</pre><p> |
| 527 | Remove the given attribute from the Ref table maintained internally.</p><p> |
| 528 | |
| 529 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 530 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> the attribute |
| 531 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>-1 if the lookup failed and 0 otherwise |
| 532 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlGetRefs"></a>xmlGetRefs ()</h3><pre class="programlisting"><GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="xmlListPtr">xmlListPtr</GTKDOCLINK> xmlGetRefs (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 533 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *ID);</pre><p> |
| 534 | Find the set of references for the supplied ID.</p><p> |
| 535 | |
| 536 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> pointer to the document |
| 537 | </td></tr><tr><td><span class="term"><i><tt>ID</tt></i> :</span></td><td> the ID value |
| 538 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>NULL if not found, otherwise node set for the ID. |
| 539 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateRoot"></a>xmlValidateRoot ()</h3><pre class="programlisting">int xmlValidateRoot (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 540 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc);</pre><p> |
| 541 | Try to validate a the root element |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 542 | basically it does the following check as described by the |
| 543 | XML-1.0 recommendation: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 544 | - [ VC: Root Element Type ] |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 545 | it doesn't try to recurse or apply other check to the element</p><p> |
| 546 | |
| 547 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 548 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 549 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 550 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateElementDecl"></a>xmlValidateElementDecl ()</h3><pre class="programlisting">int xmlValidateElementDecl (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 551 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 552 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> elem);</pre><p> |
| 553 | Try to validate a single element definition |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 554 | basically it does the following checks as described by the |
| 555 | XML-1.0 recommendation: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 556 | - [ VC: One ID per Element Type ] |
| 557 | - [ VC: No Duplicate Types ] |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 558 | - [ VC: Unique Element Type Declaration ]</p><p> |
| 559 | |
| 560 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 561 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 562 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element definition |
| 563 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 564 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidNormalizeAttributeValue"></a>xmlValidNormalizeAttributeValue ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlChar">xmlChar</a>* xmlValidNormalizeAttributeValue (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 565 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 566 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 567 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 568 | Does the validation related extra step of the normalization of attribute |
| 569 | values: |
| 570 | </p><p> |
| 571 | If the declared value is not CDATA, then the XML processor must further |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 572 | process the normalized attribute value by discarding any leading and |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 573 | trailing space (<GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="x20">x20</GTKDOCLINK>) characters, and by replacing sequences of space |
| 574 | (<GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="x20">x20</GTKDOCLINK>) characters by single space (<GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="x20">x20</GTKDOCLINK>) character.</p><p> |
| 575 | |
| 576 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 577 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> the parent |
| 578 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the attribute name |
| 579 | </td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the attribute value |
| 580 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>a new normalized string if normalization is needed, NULL otherwise |
| 581 | the caller must free the returned value. |
| 582 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidCtxtNormalizeAttributeValue"></a>xmlValidCtxtNormalizeAttributeValue ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlChar">xmlChar</a>* xmlValidCtxtNormalizeAttributeValue |
| 583 | (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 584 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 585 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 586 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 587 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 588 | Does the validation related extra step of the normalization of attribute |
| 589 | values: |
| 590 | </p><p> |
| 591 | If the declared value is not CDATA, then the XML processor must further |
Daniel Veillard | 5f4b599 | 2002-02-20 10:22:49 +0000 | [diff] [blame] | 592 | process the normalized attribute value by discarding any leading and |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 593 | trailing space (<GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="x20">x20</GTKDOCLINK>) characters, and by replacing sequences of space |
| 594 | (<GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="x20">x20</GTKDOCLINK>) characters by single space (<GTKDOCLINK xmlns="http://www.w3.org/TR/xhtml1/transitional" HREF="x20">x20</GTKDOCLINK>) character. |
| 595 | </p><p> |
| 596 | Also check VC: Standalone Document Declaration in P32, and update |
| 597 | ctxt->valid accordingly</p><p> |
| 598 | |
| 599 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 600 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 601 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> the parent |
| 602 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the attribute name |
| 603 | </td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the attribute value |
| 604 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>a new normalized string if normalization is needed, NULL otherwise |
| 605 | the caller must free the returned value. |
| 606 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateAttributeDecl"></a>xmlValidateAttributeDecl ()</h3><pre class="programlisting">int xmlValidateAttributeDecl (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 607 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 608 | <a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> attr);</pre><p> |
| 609 | Try to validate a single attribute definition |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 610 | basically it does the following checks as described by the |
| 611 | XML-1.0 recommendation: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 612 | - [ VC: Attribute Default Legal ] |
| 613 | - [ VC: Enumeration ] |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 614 | - [ VC: ID Attribute Default ] |
| 615 | </p><p> |
| 616 | The ID/IDREF uniqueness and matching are done separately</p><p> |
| 617 | |
| 618 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 619 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 620 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> an attribute definition |
| 621 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 622 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateAttributeValue"></a>xmlValidateAttributeValue ()</h3><pre class="programlisting">int xmlValidateAttributeValue (<a href="libxml-tree.html#xmlAttributeType">xmlAttributeType</a> type, |
| 623 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 624 | Validate that the given attribute value match the proper production |
| 625 | </p><p> |
| 626 | [ VC: ID ] |
| 627 | Values of type ID must match the Name production.... |
| 628 | </p><p> |
| 629 | [ VC: IDREF ] |
Daniel Veillard | 6bd26dc | 1999-09-03 14:28:40 +0000 | [diff] [blame] | 630 | Values of type IDREF must match the Name production, and values |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 631 | of type IDREFS must match Names ... |
| 632 | </p><p> |
| 633 | [ VC: Entity Name ] |
Daniel Veillard | 6bd26dc | 1999-09-03 14:28:40 +0000 | [diff] [blame] | 634 | Values of type ENTITY must match the Name production, values |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 635 | of type ENTITIES must match Names ... |
| 636 | </p><p> |
| 637 | [ VC: Name Token ] |
Daniel Veillard | 6bd26dc | 1999-09-03 14:28:40 +0000 | [diff] [blame] | 638 | Values of type NMTOKEN must match the Nmtoken production; values |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 639 | of type NMTOKENS must match Nmtokens.</p><p> |
| 640 | |
| 641 | </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> an attribute type |
| 642 | </td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> an attribute value |
| 643 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 644 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateNotationDecl"></a>xmlValidateNotationDecl ()</h3><pre class="programlisting">int xmlValidateNotationDecl (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 645 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 646 | <a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> nota);</pre><p> |
| 647 | Try to validate a single notation definition |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 648 | basically it does the following checks as described by the |
| 649 | XML-1.0 recommendation: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 650 | - it seems that no validity constraint exists on notation declarations |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 651 | But this function get called anyway ...</p><p> |
| 652 | |
| 653 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 654 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 655 | </td></tr><tr><td><span class="term"><i><tt>nota</tt></i> :</span></td><td> a notation definition |
| 656 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 657 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateDtd"></a>xmlValidateDtd ()</h3><pre class="programlisting">int xmlValidateDtd (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 658 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 659 | <a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd);</pre><p> |
| 660 | Try to validate the document against the dtd instance |
| 661 | </p><p> |
| 662 | basically it does check all the definitions in the DtD.</p><p> |
| 663 | |
| 664 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 665 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 666 | </td></tr><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> a dtd instance |
| 667 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 668 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateDtdFinal"></a>xmlValidateDtdFinal ()</h3><pre class="programlisting">int xmlValidateDtdFinal (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 669 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc);</pre><p> |
| 670 | Does the final step for the dtds validation once all the |
| 671 | subsets have been parsed |
| 672 | </p><p> |
| 673 | basically it does the following checks described by the XML Rec |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 674 | - check that ENTITY and ENTITIES type attributes default or |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 675 | possible values matches one of the defined entities. |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 676 | - check that NOTATION type attributes default or |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 677 | possible values matches one of the defined notations.</p><p> |
| 678 | |
| 679 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 680 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 681 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 if invalid and -1 if not well-formed |
| 682 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateDocument"></a>xmlValidateDocument ()</h3><pre class="programlisting">int xmlValidateDocument (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 683 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc);</pre><p> |
| 684 | Try to validate the document instance |
| 685 | </p><p> |
| 686 | basically it does the all the checks described by the XML Rec |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 687 | i.e. validates the internal and external subset (if present) |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 688 | and validate the document tree.</p><p> |
| 689 | |
| 690 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 691 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 692 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 693 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateElement"></a>xmlValidateElement ()</h3><pre class="programlisting">int xmlValidateElement (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 694 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 695 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem);</pre><p> |
| 696 | Try to validate the subtree under an element</p><p> |
| 697 | |
| 698 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 699 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 700 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element instance |
| 701 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 702 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateOneElement"></a>xmlValidateOneElement ()</h3><pre class="programlisting">int xmlValidateOneElement (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 703 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 704 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem);</pre><p> |
| 705 | Try to validate a single element and it's attributes, |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 706 | basically it does the following checks as described by the |
| 707 | XML-1.0 recommendation: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 708 | - [ VC: Element Valid ] |
| 709 | - [ VC: Required Attribute ] |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 710 | Then call <a href="libxml-valid.html#xmlValidateOneAttribute">xmlValidateOneAttribute</a>() for each attribute present. |
| 711 | </p><p> |
| 712 | The ID/IDREF checkings are done separately</p><p> |
| 713 | |
| 714 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 715 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 716 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element instance |
| 717 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 718 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateOneAttribute"></a>xmlValidateOneAttribute ()</h3><pre class="programlisting">int xmlValidateOneAttribute (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 719 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 720 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 721 | <a href="libxml-tree.html#xmlAttrPtr">xmlAttrPtr</a> attr, |
| 722 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 723 | Try to validate a single attribute for an element |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 724 | basically it does the following checks as described by the |
Daniel Veillard | b05deb7 | 1999-08-10 19:04:08 +0000 | [diff] [blame] | 725 | XML-1.0 recommendation: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 726 | - [ VC: Attribute Value Type ] |
| 727 | - [ VC: Fixed Attribute Default ] |
| 728 | - [ VC: Entity Name ] |
| 729 | - [ VC: Name Token ] |
| 730 | - [ VC: ID ] |
| 731 | - [ VC: IDREF ] |
| 732 | - [ VC: Entity Name ] |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 733 | - [ VC: Notation Attributes ] |
| 734 | </p><p> |
| 735 | The ID/IDREF uniqueness and matching are done separately</p><p> |
| 736 | |
| 737 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 738 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 739 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element instance |
| 740 | </td></tr><tr><td><span class="term"><i><tt>attr</tt></i> :</span></td><td> an attribute instance |
| 741 | </td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the attribute value (without entities processing) |
| 742 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 743 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateOneNamespace"></a>xmlValidateOneNamespace ()</h3><pre class="programlisting">int xmlValidateOneNamespace (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 744 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 745 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 746 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *prefix, |
| 747 | <a href="libxml-tree.html#xmlNsPtr">xmlNsPtr</a> ns, |
| 748 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 749 | Try to validate a single namespace declaration for an element |
Daniel Veillard | 5ede35e | 2002-10-01 11:37:35 +0000 | [diff] [blame] | 750 | basically it does the following checks as described by the |
| 751 | XML-1.0 recommendation: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 752 | - [ VC: Attribute Value Type ] |
| 753 | - [ VC: Fixed Attribute Default ] |
| 754 | - [ VC: Entity Name ] |
| 755 | - [ VC: Name Token ] |
| 756 | - [ VC: ID ] |
| 757 | - [ VC: IDREF ] |
| 758 | - [ VC: Entity Name ] |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 759 | - [ VC: Notation Attributes ] |
| 760 | </p><p> |
| 761 | The ID/IDREF uniqueness and matching are done separately</p><p> |
| 762 | |
| 763 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 764 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 765 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element instance |
| 766 | </td></tr><tr><td><span class="term"><i><tt>prefix</tt></i> :</span></td><td> the namespace prefix |
| 767 | </td></tr><tr><td><span class="term"><i><tt>ns</tt></i> :</span></td><td> an namespace declaration instance |
| 768 | </td></tr><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> the attribute value (without entities processing) |
| 769 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 770 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateDocumentFinal"></a>xmlValidateDocumentFinal ()</h3><pre class="programlisting">int xmlValidateDocumentFinal (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 771 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc);</pre><p> |
| 772 | Does the final step for the document validation once all the |
| 773 | incremental validation steps have been completed |
| 774 | </p><p> |
| 775 | basically it does the following checks described by the XML Rec |
| 776 | </p><p> |
| 777 | Check all the IDREF/IDREFS attributes definition for validity</p><p> |
| 778 | |
| 779 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 780 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 781 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 782 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateNotationUse"></a>xmlValidateNotationUse ()</h3><pre class="programlisting">int xmlValidateNotationUse (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 783 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 784 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *notationName);</pre><p> |
| 785 | Validate that the given name match a notation declaration. |
| 786 | - [ VC: Notation Declared ]</p><p> |
| 787 | |
| 788 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 789 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 790 | </td></tr><tr><td><span class="term"><i><tt>notationName</tt></i> :</span></td><td> the notation name to check |
| 791 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 792 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlIsMixedElement"></a>xmlIsMixedElement ()</h3><pre class="programlisting">int xmlIsMixedElement (<a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 793 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name);</pre><p> |
| 794 | Search in the DtDs whether an element accept Mixed content (or ANY) |
| 795 | basically if it is supposed to accept text childs</p><p> |
| 796 | |
| 797 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> the document |
| 798 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the element name |
| 799 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>0 if no, 1 if yes, and -1 if no element description is available |
| 800 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlGetDtdAttrDesc"></a>xmlGetDtdAttrDesc ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> xmlGetDtdAttrDesc (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 801 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *elem, |
| 802 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name);</pre><p> |
| 803 | Search the DTD for the description of this attribute on |
| 804 | this element.</p><p> |
| 805 | |
| 806 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> a pointer to the DtD to search |
| 807 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> the element name |
| 808 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the attribute name |
| 809 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the xmlAttributePtr if found or NULL |
| 810 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlGetDtdQAttrDesc"></a>xmlGetDtdQAttrDesc ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlAttributePtr">xmlAttributePtr</a> xmlGetDtdQAttrDesc (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 811 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *elem, |
| 812 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 813 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *prefix);</pre><p> |
| 814 | Search the DTD for the description of this qualified attribute on |
| 815 | this element.</p><p> |
| 816 | |
| 817 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> a pointer to the DtD to search |
| 818 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> the element name |
| 819 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the attribute name |
| 820 | </td></tr><tr><td><span class="term"><i><tt>prefix</tt></i> :</span></td><td> the attribute namespace prefix |
| 821 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the xmlAttributePtr if found or NULL |
| 822 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlGetDtdNotationDesc"></a>xmlGetDtdNotationDesc ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlNotationPtr">xmlNotationPtr</a> xmlGetDtdNotationDesc (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 823 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name);</pre><p> |
| 824 | Search the DTD for the description of this notation</p><p> |
| 825 | |
| 826 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> a pointer to the DtD to search |
| 827 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the notation name |
| 828 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the xmlNotationPtr if found or NULL |
| 829 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlGetDtdQElementDesc"></a>xmlGetDtdQElementDesc ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> xmlGetDtdQElementDesc (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 830 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name, |
| 831 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *prefix);</pre><p> |
| 832 | Search the DTD for the description of this element</p><p> |
| 833 | |
| 834 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> a pointer to the DtD to search |
| 835 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the element name |
| 836 | </td></tr><tr><td><span class="term"><i><tt>prefix</tt></i> :</span></td><td> the element namespace prefix |
| 837 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the xmlElementPtr if found or NULL |
| 838 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlGetDtdElementDesc"></a>xmlGetDtdElementDesc ()</h3><pre class="programlisting"><a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> xmlGetDtdElementDesc (<a href="libxml-tree.html#xmlDtdPtr">xmlDtdPtr</a> dtd, |
| 839 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *name);</pre><p> |
| 840 | Search the DTD for the description of this element</p><p> |
| 841 | |
| 842 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>dtd</tt></i> :</span></td><td> a pointer to the DtD to search |
| 843 | </td></tr><tr><td><span class="term"><i><tt>name</tt></i> :</span></td><td> the element name |
| 844 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the xmlElementPtr if found or NULL |
| 845 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidGetValidElements"></a>xmlValidGetValidElements ()</h3><pre class="programlisting">int xmlValidGetValidElements (<a href="libxml-tree.html#xmlNode">xmlNode</a> *prev, |
| 846 | <a href="libxml-tree.html#xmlNode">xmlNode</a> *next, |
| 847 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> **list, |
| 848 | int max);</pre><p> |
| 849 | This function returns the list of authorized children to insert |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 850 | within an existing tree while respecting the validity constraints |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 851 | forced by the Dtd. The insertion point is defined using <i><tt>prev</tt></i> and |
| 852 | <i><tt>next</tt></i> in the following ways: |
Daniel Veillard | aec6356 | 2003-03-23 20:42:17 +0000 | [diff] [blame] | 853 | to insert before 'node': xmlValidGetValidElements(node->prev, node, ... |
| 854 | to insert next 'node': xmlValidGetValidElements(node, node->next, ... |
| 855 | to replace 'node': xmlValidGetValidElements(node->prev, node->next, ... |
| 856 | to prepend a child to 'node': xmlValidGetValidElements(NULL, node->childs, |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 857 | to append a child to 'node': xmlValidGetValidElements(node->last, NULL, ... |
| 858 | </p><p> |
| 859 | pointers to the element names are inserted at the beginning of the array |
| 860 | and do not need to be freed.</p><p> |
| 861 | |
| 862 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>prev</tt></i> :</span></td><td> an element to insert after |
| 863 | </td></tr><tr><td><span class="term"><i><tt>next</tt></i> :</span></td><td> an element to insert next |
| 864 | </td></tr><tr><td><span class="term"><i><tt>list</tt></i> :</span></td><td> an array to store the list of child names |
| 865 | </td></tr><tr><td><span class="term"><i><tt>max</tt></i> :</span></td><td> the size of the array |
| 866 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the number of element in the list, or -1 in case of error. If |
| 867 | the function returns the value <i><tt>max</tt></i> the caller is invited to grow the |
| 868 | receiving array and retry. |
| 869 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidGetPotentialChildren"></a>xmlValidGetPotentialChildren ()</h3><pre class="programlisting">int xmlValidGetPotentialChildren (<a href="libxml-tree.html#xmlElementContent">xmlElementContent</a> *ctree, |
| 870 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> **list, |
Daniel Veillard | 3f6f7f6 | 2000-06-30 17:58:25 +0000 | [diff] [blame] | 871 | int *len, |
Daniel Veillard | d433046 | 2003-04-29 12:40:16 +0000 | [diff] [blame^] | 872 | int max);</pre><p> |
| 873 | Build/extend a list of potential children allowed by the content tree</p><p> |
| 874 | |
| 875 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctree</tt></i> :</span></td><td> an element content tree |
| 876 | </td></tr><tr><td><span class="term"><i><tt>list</tt></i> :</span></td><td> an array to store the list of child names |
| 877 | </td></tr><tr><td><span class="term"><i><tt>len</tt></i> :</span></td><td> a pointer to the number of element in the list |
| 878 | </td></tr><tr><td><span class="term"><i><tt>max</tt></i> :</span></td><td> the size of the array |
| 879 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>the number of element in the list, or -1 in case of error. |
| 880 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateNameValue"></a>xmlValidateNameValue ()</h3><pre class="programlisting">int xmlValidateNameValue (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 881 | Validate that the given value match Name production</p><p> |
| 882 | |
| 883 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> an Name value |
| 884 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 885 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateNamesValue"></a>xmlValidateNamesValue ()</h3><pre class="programlisting">int xmlValidateNamesValue (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 886 | Validate that the given value match Names production</p><p> |
| 887 | |
| 888 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> an Names value |
| 889 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 890 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateNmtokenValue"></a>xmlValidateNmtokenValue ()</h3><pre class="programlisting">int xmlValidateNmtokenValue (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 891 | Validate that the given value match Nmtoken production |
| 892 | </p><p> |
| 893 | [ VC: Name Token ]</p><p> |
| 894 | |
| 895 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> an Nmtoken value |
| 896 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 897 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidateNmtokensValue"></a>xmlValidateNmtokensValue ()</h3><pre class="programlisting">int xmlValidateNmtokensValue (const <a href="libxml-tree.html#xmlChar">xmlChar</a> *value);</pre><p> |
| 898 | Validate that the given value match Nmtokens production |
| 899 | </p><p> |
| 900 | [ VC: Name Token ]</p><p> |
| 901 | |
| 902 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>value</tt></i> :</span></td><td> an Nmtokens value |
| 903 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if valid or 0 otherwise |
| 904 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidBuildContentModel"></a>xmlValidBuildContentModel ()</h3><pre class="programlisting">int xmlValidBuildContentModel (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 905 | <a href="libxml-tree.html#xmlElementPtr">xmlElementPtr</a> elem);</pre><p> |
| 906 | (Re)Build the automata associated to the content model of this |
| 907 | element</p><p> |
| 908 | |
| 909 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> a validation context |
| 910 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element declaration node |
| 911 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 in case of success, 0 in case of error |
| 912 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidatePushElement"></a>xmlValidatePushElement ()</h3><pre class="programlisting">int xmlValidatePushElement (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 913 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 914 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 915 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *qname);</pre><p> |
| 916 | Push a new element start on the validation stack.</p><p> |
| 917 | |
| 918 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 919 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 920 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element instance |
| 921 | </td></tr><tr><td><span class="term"><i><tt>qname</tt></i> :</span></td><td> the qualified name as appearing in the serialization |
| 922 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if no validation problem was found or 0 otherwise |
| 923 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidatePushCData"></a>xmlValidatePushCData ()</h3><pre class="programlisting">int xmlValidatePushCData (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 924 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *data, |
| 925 | int len);</pre><p> |
| 926 | check the CData parsed for validation in the current stack</p><p> |
| 927 | |
| 928 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 929 | </td></tr><tr><td><span class="term"><i><tt>data</tt></i> :</span></td><td> some character data read |
| 930 | </td></tr><tr><td><span class="term"><i><tt>len</tt></i> :</span></td><td> the lenght of the data |
| 931 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if no validation problem was found or 0 otherwise |
| 932 | </td></tr></tbody></table></div></div><hr xmlns="http://www.w3.org/TR/xhtml1/transitional"></hr><div class="refsect2" lang="en"><h3><a name="xmlValidatePopElement"></a>xmlValidatePopElement ()</h3><pre class="programlisting">int xmlValidatePopElement (<a href="libxml-valid.html#xmlValidCtxtPtr">xmlValidCtxtPtr</a> ctxt, |
| 933 | <a href="libxml-tree.html#xmlDocPtr">xmlDocPtr</a> doc, |
| 934 | <a href="libxml-tree.html#xmlNodePtr">xmlNodePtr</a> elem, |
| 935 | const <a href="libxml-tree.html#xmlChar">xmlChar</a> *qname);</pre><p> |
| 936 | Pop the element end from the validation stack.</p><p> |
| 937 | |
| 938 | </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i> :</span></td><td> the validation context |
| 939 | </td></tr><tr><td><span class="term"><i><tt>doc</tt></i> :</span></td><td> a document instance |
| 940 | </td></tr><tr><td><span class="term"><i><tt>elem</tt></i> :</span></td><td> an element instance |
| 941 | </td></tr><tr><td><span class="term"><i><tt>qname</tt></i> :</span></td><td> the qualified name as appearing in the serialization |
| 942 | </td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td>1 if no validation problem was found or 0 otherwise |
| 943 | </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-entities.html"><b><< entities</b></a></td><td align="right"><a accesskey="n" href="libxml-relaxng.html"><b>relaxng >></b></a></td></tr></table></body></html> |