7 CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+
10 TITLE="Gnome XML Library Reference Manual"
11 HREF="book1.html"><LINK
13 TITLE="Libxml Library Reference"
14 HREF="libxml-lib.html"><LINK
17 HREF="libxml-valid.html"><LINK
20 HREF="libxml-xmlerror.html"></HEAD
43 >Gnome XML Library Reference Manual</FONT
52 HREF="libxml-valid.html"
57 ><<< Previous Page</B
90 HREF="libxml-lib.html"
106 HREF="libxml-xmlerror.html"
111 >Next Page >>></B
120 NAME="LIBXML-URI">uri</H1
128 >uri -- </DIV
130 CLASS="REFSYNOPSISDIV"
146 HREF="libxml-uri.html#XMLURI"
150 HREF="libxml-uri.html#XMLURIPTR"
154 HREF="libxml-uri.html#XMLURIPTR"
157 HREF="libxml-uri.html#XMLCREATEURI"
161 HREF="libxml-tree.html#XMLCHAR"
164 HREF="libxml-uri.html#XMLBUILDURI"
167 HREF="libxml-tree.html#XMLCHAR"
171 HREF="libxml-tree.html#XMLCHAR"
175 HREF="libxml-uri.html#XMLURIPTR"
178 HREF="libxml-uri.html#XMLPARSEURI"
182 HREF="libxml-uri.html#XMLPARSEURIREFERENCE"
183 >xmlParseURIReference</A
185 HREF="libxml-uri.html#XMLURIPTR"
190 HREF="libxml-tree.html#XMLCHAR"
193 HREF="libxml-uri.html#XMLSAVEURI"
196 HREF="libxml-uri.html#XMLURIPTR"
200 HREF="libxml-uri.html#XMLPRINTURI"
207 HREF="libxml-uri.html#XMLURIPTR"
211 HREF="libxml-tree.html#XMLCHAR"
214 HREF="libxml-uri.html#XMLURIESCAPESTR"
217 HREF="libxml-tree.html#XMLCHAR"
221 HREF="libxml-tree.html#XMLCHAR"
225 HREF="libxml-uri.html#XMLURIUNESCAPESTRING"
226 >xmlURIUnescapeString</A
231 HREF="libxml-uri.html#XMLNORMALIZEURIPATH"
232 >xmlNormalizeURIPath</A
235 HREF="libxml-tree.html#XMLCHAR"
238 HREF="libxml-uri.html#XMLURIESCAPE"
241 HREF="libxml-tree.html#XMLCHAR"
245 HREF="libxml-uri.html#XMLFREEURI"
248 HREF="libxml-uri.html#XMLURIPTR"
290 CLASS="PROGRAMLISTING"
292 char *scheme; /* the URI scheme */
293 char *opaque; /* opaque part */
294 char *authority; /* the authority part */
295 char *server; /* the server part */
296 char *user; /* the user part */
297 int port; /* the port number */
298 char *path; /* the path string */
299 char *query; /* the query string */
300 char *fragment; /* the fragment identifier */
301 int cleanup; /* parsing potentially unclean URI */
307 >A parsed URI reference. This is a struct containing the various fields
308 as described in RFC 2396 but separated for further processing.</P
330 CLASS="PROGRAMLISTING"
331 >typedef xmlURI *xmlURIPtr;</PRE
356 CLASS="PROGRAMLISTING"
358 HREF="libxml-uri.html#XMLURIPTR"
360 > xmlCreateURI (void);</PRE
365 >Simply creates an empty xmlURI</P
369 CLASS="INFORMALTABLE"
397 >the new structure or NULL in case of error</TD
423 CLASS="PROGRAMLISTING"
425 HREF="libxml-tree.html#XMLCHAR"
427 >* xmlBuildURI (const <A
428 HREF="libxml-tree.html#XMLCHAR"
432 HREF="libxml-tree.html#XMLCHAR"
439 >Computes he final URI of the reference done by checking that
440 the given URI is valid, and building the final URI using the
441 base URI. This is processed according to section 5.2 of the
444 >5.2. Resolving Relative References to Absolute Form</P
448 CLASS="INFORMALTABLE"
475 > the URI instance found in the document</TD
510 >a new URI string (to be freed by the caller) or NULL in case
537 CLASS="PROGRAMLISTING"
539 HREF="libxml-uri.html#XMLURIPTR"
541 > xmlParseURI (const char *str);</PRE
548 >URI-reference = [ absoluteURI | relativeURI ] [ "#" fragment ]</P
552 CLASS="INFORMALTABLE"
579 > the URI string to analyze</TD
597 >a newly build xmlURIPtr or NULL in case of error</TD
612 NAME="XMLPARSEURIREFERENCE"
614 >xmlParseURIReference ()</H3
623 CLASS="PROGRAMLISTING"
624 >int xmlParseURIReference (<A
625 HREF="libxml-uri.html#XMLURIPTR"
628 const char *str);</PRE
633 >Parse an URI reference string and fills in the appropriate fields
641 >URI-reference = [ absoluteURI | relativeURI ] [ "#" fragment ]</P
645 CLASS="INFORMALTABLE"
672 > pointer to an URI structure</TD
689 > the string to analyze</TD
707 >0 or the error code</TD
733 CLASS="PROGRAMLISTING"
735 HREF="libxml-tree.html#XMLCHAR"
738 HREF="libxml-uri.html#XMLURIPTR"
745 >Save the URI as an escaped string</P
749 CLASS="INFORMALTABLE"
776 > pointer to an xmlURI</TD
794 >a new string (to be deallocated by caller)</TD
820 CLASS="PROGRAMLISTING"
821 >void xmlPrintURI (<GTKDOCLINK
826 HREF="libxml-uri.html#XMLURIPTR"
833 >Prints the URI in the stream <TT
842 CLASS="INFORMALTABLE"
869 > a FILE* for the output</TD
886 > pointer to an xmlURI</TD
901 NAME="XMLURIESCAPESTR"
903 >xmlURIEscapeStr ()</H3
912 CLASS="PROGRAMLISTING"
914 HREF="libxml-tree.html#XMLCHAR"
916 >* xmlURIEscapeStr (const <A
917 HREF="libxml-tree.html#XMLCHAR"
921 HREF="libxml-tree.html#XMLCHAR"
928 >This routine escapes a string to hex, ignoring reserved characters (a-z)
929 and the characters in the exception list.</P
933 CLASS="INFORMALTABLE"
960 > string to escape</TD
977 > exception list string of chars not to escape</TD
995 >a new escaped string or NULL in case of error.</TD
1010 NAME="XMLURIUNESCAPESTRING"
1012 >xmlURIUnescapeString ()</H3
1021 CLASS="PROGRAMLISTING"
1022 >char* xmlURIUnescapeString (const char *str,
1029 >Unescaping routine, does not do validity checks !
1030 Output is direct unsigned char translation of <TT
1033 > values (no encoding)</P
1037 CLASS="INFORMALTABLE"
1064 > the string to unescape</TD
1081 > the length in bytes to unescape (or <= 0 to indicate full string)</TD
1098 > optional destination buffer</TD
1116 >an copy of the string, but unescaped</TD
1131 NAME="XMLNORMALIZEURIPATH"
1133 >xmlNormalizeURIPath ()</H3
1142 CLASS="PROGRAMLISTING"
1143 >int xmlNormalizeURIPath (char *path);</PRE
1148 >Applies the 5 normalization steps to a path string--that is, RFC 2396
1149 Section 5.2, steps 6.c through 6.g.</P
1151 >Normalization occurs directly on the string, no new allocation is done</P
1155 CLASS="INFORMALTABLE"
1182 > pointer to the path string</TD
1200 >0 or an error code</TD
1217 >xmlURIEscape ()</H3
1226 CLASS="PROGRAMLISTING"
1228 HREF="libxml-tree.html#XMLCHAR"
1230 >* xmlURIEscape (const <A
1231 HREF="libxml-tree.html#XMLCHAR"
1238 >Escaping routine, does not do validity checks !
1239 It will try to escape the chars needing this, but this is heuristic
1240 based it's impossible to be sure.</P
1244 CLASS="INFORMALTABLE"
1271 > the string of the URI to escape</TD
1289 >an copy of the string, but escaped
1292 Uses xmlParseURI and xmlURIEscapeStr to try to escape correctly
1293 according to RFC2396.
1320 CLASS="PROGRAMLISTING"
1321 >void xmlFreeURI (<A
1322 HREF="libxml-uri.html#XMLURIPTR"
1329 >Free up the xmlURI struct</P
1333 CLASS="INFORMALTABLE"
1360 > pointer to an xmlURI</TD
1372 CLEAR="all"><BR><TABLE
1384 HREF="libxml-valid.html"
1389 ><<< Previous Page</B
1422 HREF="libxml-lib.html"
1438 HREF="libxml-xmlerror.html"
1443 >Next Page >>></B