Path: blob/master/venv/Lib/site-packages/lxml/includes/libxml/uri.h
811 views
/**1* Summary: library of generic URI related routines2* Description: library of generic URI related routines3* Implements RFC 23964*5* Copy: See Copyright for the status of this software.6*7* Author: Daniel Veillard8*/910#ifndef __XML_URI_H__11#define __XML_URI_H__1213#include <libxml/xmlversion.h>14#include <libxml/tree.h>1516#ifdef __cplusplus17extern "C" {18#endif1920/**21* xmlURI:22*23* A parsed URI reference. This is a struct containing the various fields24* as described in RFC 2396 but separated for further processing.25*26* Note: query is a deprecated field which is incorrectly unescaped.27* query_raw takes precedence over query if the former is set.28* See: http://mail.gnome.org/archives/xml/2007-April/thread.html#0012729*/30typedef struct _xmlURI xmlURI;31typedef xmlURI *xmlURIPtr;32struct _xmlURI {33char *scheme; /* the URI scheme */34char *opaque; /* opaque part */35char *authority; /* the authority part */36char *server; /* the server part */37char *user; /* the user part */38int port; /* the port number */39char *path; /* the path string */40char *query; /* the query string (deprecated - use with caution) */41char *fragment; /* the fragment identifier */42int cleanup; /* parsing potentially unclean URI */43char *query_raw; /* the query string (as it appears in the URI) */44};4546/*47* This function is in tree.h:48* xmlChar * xmlNodeGetBase (xmlDocPtr doc,49* xmlNodePtr cur);50*/51XMLPUBFUN xmlURIPtr XMLCALL52xmlCreateURI (void);53XMLPUBFUN xmlChar * XMLCALL54xmlBuildURI (const xmlChar *URI,55const xmlChar *base);56XMLPUBFUN xmlChar * XMLCALL57xmlBuildRelativeURI (const xmlChar *URI,58const xmlChar *base);59XMLPUBFUN xmlURIPtr XMLCALL60xmlParseURI (const char *str);61XMLPUBFUN xmlURIPtr XMLCALL62xmlParseURIRaw (const char *str,63int raw);64XMLPUBFUN int XMLCALL65xmlParseURIReference (xmlURIPtr uri,66const char *str);67XMLPUBFUN xmlChar * XMLCALL68xmlSaveUri (xmlURIPtr uri);69XMLPUBFUN void XMLCALL70xmlPrintURI (FILE *stream,71xmlURIPtr uri);72XMLPUBFUN xmlChar * XMLCALL73xmlURIEscapeStr (const xmlChar *str,74const xmlChar *list);75XMLPUBFUN char * XMLCALL76xmlURIUnescapeString (const char *str,77int len,78char *target);79XMLPUBFUN int XMLCALL80xmlNormalizeURIPath (char *path);81XMLPUBFUN xmlChar * XMLCALL82xmlURIEscape (const xmlChar *str);83XMLPUBFUN void XMLCALL84xmlFreeURI (xmlURIPtr uri);85XMLPUBFUN xmlChar* XMLCALL86xmlCanonicPath (const xmlChar *path);87XMLPUBFUN xmlChar* XMLCALL88xmlPathToURI (const xmlChar *path);8990#ifdef __cplusplus91}92#endif93#endif /* __XML_URI_H__ */949596