ReactOS 0.4.16-dev-205-g7b2bb7e
|
#include "libxml.h"
#include <string.h>
#include <stdlib.h>
#include <libxml/xmlmemory.h>
#include <libxml/hash.h>
#include <libxml/uri.h>
#include <libxml/valid.h>
#include <libxml/parser.h>
#include <libxml/parserInternals.h>
#include <libxml/xmlerror.h>
#include <libxml/list.h>
#include <libxml/globals.h>
Go to the source code of this file.
Classes | |
struct | xmlRemoveMemo_t |
struct | xmlValidateMemo_t |
Macros | |
#define | IN_LIBXML |
#define | TODO |
Functions | |
static void | xmlVErrMemory (xmlValidCtxtPtr ctxt, const char *extra) |
static void | LIBXML_ATTR_FORMAT (3, 0) |
: the element name | |
xmlIsMixedElement: @doc: the document Search in the DtDs whether an element accept Mixed content (or ANY) basically if it is supposed to accept text childs returns 0 if no, 1 if yes, and -1 if no element description is available | |
static xmlElementPtr | xmlGetDtdElementDesc2 (xmlDtdPtr dtd, const xmlChar *name, int create) |
xmlElementPtr | xmlGetDtdElementDesc (xmlDtdPtr dtd, const xmlChar *name) |
xmlElementPtr | xmlGetDtdQElementDesc (xmlDtdPtr dtd, const xmlChar *name, const xmlChar *prefix) |
int | xmlIsMixedElement (xmlDocPtr doc, const xmlChar *name) |
: the subelement name or NULL | |
xmlNewElementContent: @type: the type of element content decl Allocate an element content structure. Deprecated in favor of xmlNewDocElementContent Returns NULL if not, otherwise the new element content structure | |
xmlElementContentPtr | xmlNewDocElementContent (xmlDocPtr doc, const xmlChar *name, xmlElementContentType type) |
xmlElementContentPtr | xmlNewElementContent (const xmlChar *name, xmlElementContentType type) |
xmlElementContentPtr | xmlCopyDocElementContent (xmlDocPtr doc, xmlElementContentPtr cur) |
xmlElementContentPtr | xmlCopyElementContent (xmlElementContentPtr cur) |
void | xmlFreeDocElementContent (xmlDocPtr doc, xmlElementContentPtr cur) |
void | xmlFreeElementContent (xmlElementContentPtr cur) |
void | xmlSnprintfElementContent (char *buf, int size, xmlElementContentPtr content, int englob) |
static void | xmlFreeElement (xmlElementPtr elem) |
: the enumeration name or NULL | |
xmlCreateEnumeration: create and initialize an enumeration attribute node. Returns the xmlEnumerationPtr just created or NULL in case of error. | |
xmlEnumerationPtr | xmlCreateEnumeration (const xmlChar *name) |
void | xmlFreeEnumeration (xmlEnumerationPtr cur) |
static void | xmlFreeAttribute (xmlAttributePtr attr) |
: the attribute name | |
xmlGetDtdQAttrDesc: @dtd: a pointer to the DtD to search @elem: the element name @prefix: the attribute namespace prefix Search the DTD for the description of this qualified attribute on this element. returns the xmlAttributePtr if found or NULL | |
xmlAttributePtr | xmlAddAttributeDecl (xmlValidCtxtPtr ctxt, xmlDtdPtr dtd, const xmlChar *elem, const xmlChar *name, const xmlChar *ns, xmlAttributeType type, xmlAttributeDefault def, const xmlChar *defaultValue, xmlEnumerationPtr tree) |
static void | xmlFreeAttributeTableEntry (void *attr, const xmlChar *name ATTRIBUTE_UNUSED) |
void | xmlFreeAttributeTable (xmlAttributeTablePtr table) |
static void | xmlFreeNotation (xmlNotationPtr nota) |
xmlAttributePtr | xmlGetDtdAttrDesc (xmlDtdPtr dtd, const xmlChar *elem, const xmlChar *name) |
xmlAttributePtr | xmlGetDtdQAttrDesc (xmlDtdPtr dtd, const xmlChar *elem, const xmlChar *name, const xmlChar *prefix) |
: the notation name | |
xmlGetDtdNotationDesc: @dtd: a pointer to the DtD to search Search the DTD for the description of this notation returns the xmlNotationPtr if found or NULL | |
xmlNotationPtr | xmlGetDtdNotationDesc (xmlDtdPtr dtd, const xmlChar *name) |
DICT_FREE: @str: a string
Free a string if it is not owned by the "dict" dictionary in the current scope
#define TODO |
typedef struct xmlRemoveMemo_t xmlRemoveMemo |
typedef xmlRemoveMemo* xmlRemoveMemoPtr |
typedef struct xmlValidateMemo_t xmlValidateMemo |
typedef xmlValidateMemo* xmlValidateMemoPtr |
|
static |
xmlErrValid: @ctxt: an XML validation parser context @error: the error number @extra: extra information
Handle a validation error
Definition at line 92 of file valid.c.
xmlAttributePtr xmlAddAttributeDecl | ( | xmlValidCtxtPtr | ctxt, |
xmlDtdPtr | dtd, | ||
const xmlChar * | elem, | ||
const xmlChar * | name, | ||
const xmlChar * | ns, | ||
xmlAttributeType | type, | ||
xmlAttributeDefault | def, | ||
const xmlChar * | defaultValue, | ||
xmlEnumerationPtr | tree | ||
) |
Definition at line 1967 of file valid.c.
Referenced by xmlSAX2AttributeDecl().
xmlElementPtr xmlAddElementDecl | ( | xmlValidCtxtPtr | ctxt, |
xmlDtdPtr | dtd, | ||
const xmlChar * | name, | ||
xmlElementTypeVal | type, | ||
xmlElementContentPtr | content | ||
) |
Definition at line 1418 of file valid.c.
Referenced by xmlSAX2ElementDecl().
xmlIDPtr xmlAddID | ( | xmlValidCtxtPtr | ctxt, |
xmlDocPtr | doc, | ||
const xmlChar * | value, | ||
xmlAttrPtr | attr | ||
) |
xmlAddID: @ctxt: the validation context @doc: pointer to the document @value: the value name @attr: the attribute holding the ID
Register a new id declaration
Returns NULL if not, otherwise the new xmlIDPtr
Definition at line 2672 of file valid.c.
Referenced by xmlSAX2AttributeNs(), xsltAttribute(), and xsltAttrListTemplateProcess().
xmlNotationPtr xmlAddNotationDecl | ( | xmlValidCtxtPtr | ctxt, |
xmlDtdPtr | dtd, | ||
const xmlChar * | name, | ||
const xmlChar * | PublicID, | ||
const xmlChar * | SystemID | ||
) |
Definition at line 2394 of file valid.c.
Referenced by xmlSAX2NotationDecl().
xmlRefPtr xmlAddRef | ( | xmlValidCtxtPtr | ctxt, |
xmlDocPtr | doc, | ||
const xmlChar * | value, | ||
xmlAttrPtr | attr | ||
) |
xmlAddRef: @ctxt: the validation context @doc: pointer to the document @value: the value name @attr: the attribute holding the Ref
DEPRECATED, do not use. This function will be removed from the public API.
Register a new ref declaration
Returns NULL if not, otherwise the new xmlRefPtr
Definition at line 3003 of file valid.c.
Referenced by xmlSAX2AttributeNs().
xmlElementContentPtr xmlCopyDocElementContent | ( | xmlDocPtr | doc, |
xmlElementContentPtr | cur | ||
) |
xmlCopyDocElementContent: @doc: the document owning the element declaration @cur: An element content pointer.
Build a copy of an element content description.
Returns the new xmlElementContentPtr or NULL in case of error.
Definition at line 995 of file valid.c.
Referenced by xmlAddElementDecl(), xmlCopyDocElementContent(), and xmlCopyElementContent().
xmlElementContentPtr xmlCopyElementContent | ( | xmlElementContentPtr | cur | ) |
xmlCopyElementContent: @cur: An element content pointer.
Build a copy of an element content description. Deprecated, use xmlCopyDocElementContent instead
Returns the new xmlElementContentPtr or NULL in case of error.
xmlEnumerationPtr xmlCreateEnumeration | ( | const xmlChar * | name | ) |
Definition at line 1795 of file valid.c.
Referenced by xmlParseEnumerationType(), and xmlParseNotationType().
|
static |
xmlDummyCompare @data0: Value supplied by the user @data1: Value supplied by the user
Do nothing, return 0. Used to create unordered lists.
Definition at line 2983 of file valid.c.
Referenced by xmlAddRef().
|
static |
xmlFreeAttribute: @elem: An attribute
Deallocate the memory used by an attribute definition
Definition at line 1914 of file valid.c.
Referenced by xmlAddAttributeDecl(), and xmlFreeAttributeTableEntry().
void xmlFreeAttributeTable | ( | xmlAttributeTablePtr | table | ) |
xmlFreeAttributeTable: @table: An attribute table
Deallocate the memory used by an entities hash table.
Definition at line 2193 of file valid.c.
Definition at line 2182 of file valid.c.
Referenced by xmlFreeAttributeTable().
void xmlFreeDocElementContent | ( | xmlDocPtr | doc, |
xmlElementContentPtr | cur | ||
) |
xmlFreeDocElementContent: @doc: the document owning the element declaration @cur: the element content tree to free
Free an element content structure. The whole subtree is removed.
Definition at line 1089 of file valid.c.
Referenced by xmlFreeElement(), xmlFreeElementContent(), xmlParseElementChildrenContentDeclPriv(), xmlParseElementDecl(), and xmlParseElementMixedContentDecl().
|
static |
xmlFreeElement: @elem: An element
Deallocate the memory used by an element definition
Definition at line 1389 of file valid.c.
Referenced by xmlAddElementDecl(), and xmlFreeElementTableEntry().
void xmlFreeElementContent | ( | xmlElementContentPtr | cur | ) |
xmlFreeElementContent: @cur: the element content tree to free
Free an element content structure. The whole subtree is removed. Deprecated, use xmlFreeDocElementContent instead
void xmlFreeElementTable | ( | xmlElementTablePtr | table | ) |
xmlFreeElementTable: @table: An element table
Deallocate the memory used by an element hash table.
Definition at line 1641 of file valid.c.
Definition at line 1630 of file valid.c.
Referenced by xmlFreeElementTable().
void xmlFreeEnumeration | ( | xmlEnumerationPtr | cur | ) |
xmlFreeEnumeration: @cur: the tree to free.
free an enumeration attribute node (recursive).
Definition at line 1817 of file valid.c.
Referenced by attributeDeclDebug(), xmlAddAttributeDecl(), xmlFreeAttribute(), xmlFreeEnumeration(), xmlParseAttributeListDecl(), xmlParseEnumerationType(), xmlParseNotationType(), and xmlSAX2AttributeDecl().
xmlFreeID: @not: A id
Deallocate the memory used by an id definition
Definition at line 2644 of file valid.c.
Referenced by xmlAddID(), and xmlFreeIDTableEntry().
void xmlFreeIDTable | ( | xmlIDTablePtr | table | ) |
xmlFreeIDTable: @table: An id table
Deallocate the memory used by an ID hash table.
Definition at line 2756 of file valid.c.
Referenced by xsltReleaseRVT().
Definition at line 2745 of file valid.c.
Referenced by xmlFreeIDTable(), and xmlRemoveID().
|
static |
xmlFreeNotation: @not: A notation
Deallocate the memory used by an notation definition
Definition at line 2369 of file valid.c.
Referenced by xmlAddNotationDecl(), and xmlFreeNotationTableEntry().
void xmlFreeNotationTable | ( | xmlNotationTablePtr | table | ) |
xmlFreeNotationTable: @table: An notation table
Deallocate the memory used by an entities hash table.
Definition at line 2471 of file valid.c.
Definition at line 2460 of file valid.c.
Referenced by xmlFreeNotationTable().
|
static |
xmlFreeRef: @lk: A list link
Deallocate the memory used by a ref definition
Definition at line 2931 of file valid.c.
Referenced by xmlAddRef().
void xmlFreeRefTable | ( | xmlRefTablePtr | table | ) |
xmlFreeRefTable: @table: An ref table
DEPRECATED, do not use. This function will be removed from the public API.
Deallocate the memory used by an Ref hash table.
Definition at line 3103 of file valid.c.
xmlFreeRefTableEntry: @list_ref: A list of references.
Deallocate the memory used by a list of references
Definition at line 2948 of file valid.c.
Referenced by xmlFreeRefTable(), and xmlRemoveRef().
Definition at line 3379 of file valid.c.
Referenced by xmlIsID(), xmlIsRef(), xsltGetCNsProp(), and xsltGetNsProp().
xmlElementPtr xmlGetDtdElementDesc | ( | xmlDtdPtr | dtd, |
const xmlChar * | name | ||
) |
Definition at line 3257 of file valid.c.
Referenced by xmlIsMixedElement().
|
static |
Definition at line 3287 of file valid.c.
Referenced by xmlAddAttributeDecl().
xmlNotationPtr xmlGetDtdNotationDesc | ( | xmlDtdPtr | dtd, |
const xmlChar * | name | ||
) |
xmlAttributePtr xmlGetDtdQAttrDesc | ( | xmlDtdPtr | dtd, |
const xmlChar * | elem, | ||
const xmlChar * | name, | ||
const xmlChar * | prefix | ||
) |
xmlAttrPtr xmlGetID | ( | xmlDocPtr | doc, |
const xmlChar * | ID | ||
) |
xmlGetID: @doc: pointer to the document @ID: the ID value
Search the attribute declaring the given ID
Returns NULL if not found, otherwise the xmlAttrPtr defining the ID
Definition at line 2874 of file valid.c.
Referenced by xsltLoadStylesheetPI(), and xsltTestStepMatch().
xmlListPtr xmlGetRefs | ( | xmlDocPtr | doc, |
const xmlChar * | ID | ||
) |
xmlGetRefs: @doc: pointer to the document @ID: the ID value
DEPRECATED, do not use. This function will be removed from the public API.
Find the set of references for the supplied ID.
Returns NULL if not found, otherwise node set for the ID.
int xmlIsID | ( | xmlDocPtr | doc, |
xmlNodePtr | elem, | ||
xmlAttrPtr | attr | ||
) |
xmlIsID: @doc: the document @elem: the element carrying the attribute @attr: the attribute
Determine whether an attribute is of type ID. In case we have DTD(s) then this is done if DTD loading has been requested. In the case of HTML documents parsed with the HTML parser, then ID detection is done systematically.
Returns 0 or 1 depending on the lookup result
Definition at line 2774 of file valid.c.
Referenced by xmlSAX2AttributeNs(), xsltAttribute(), and xsltAttrListTemplateProcess().
The public function calls related to validity checking.
Definition at line 3494 of file valid.c.
Referenced by areBlanks().
int xmlIsRef | ( | xmlDocPtr | doc, |
xmlNodePtr | elem, | ||
xmlAttrPtr | attr | ||
) |
xmlIsRef: @doc: the document @elem: the element carrying the attribute @attr: the attribute
DEPRECATED, do not use. This function will be removed from the public API.
Determine whether an attribute is of type Ref. In case we have DTD(s) then this is simple, otherwise we use an heuristic: name Ref (upper or lowercase).
Returns 0 or 1 depending on the lookup result
Definition at line 3122 of file valid.c.
Referenced by xmlSAX2AttributeNs().
|
static |
Definition at line 2626 of file valid.c.
Referenced by xmlAddID(), and xmlAddRef().
xmlElementContentPtr xmlNewDocElementContent | ( | xmlDocPtr | doc, |
const xmlChar * | name, | ||
xmlElementContentType | type | ||
) |
Definition at line 908 of file valid.c.
Referenced by xmlNewElementContent(), xmlParseElementChildrenContentDeclPriv(), and xmlParseElementMixedContentDecl().
xmlElementContentPtr xmlNewElementContent | ( | const xmlChar * | name, |
xmlElementContentType | type | ||
) |
Definition at line 981 of file valid.c.
int xmlRemoveID | ( | xmlDocPtr | doc, |
xmlAttrPtr | attr | ||
) |
xmlRemoveID: @doc: the document @attr: the attribute
Remove the given attribute from the ID table maintained internally.
Returns -1 if the lookup failed and 0 otherwise
Definition at line 2835 of file valid.c.
int xmlRemoveRef | ( | xmlDocPtr | doc, |
xmlAttrPtr | attr | ||
) |
xmlRemoveRef: @doc: the document @attr: the attribute
DEPRECATED, do not use. This function will be removed from the public API.
Remove the given attribute from the Ref table maintained internally.
Returns -1 if the lookup failed and 0 otherwise
Definition at line 3164 of file valid.c.
void xmlSnprintfElementContent | ( | char * | buf, |
int | size, | ||
xmlElementContentPtr | content, | ||
int | englob | ||
) |
xmlSnprintfElementContent: @buf: an output buffer @size: the buffer size @content: An element table @englob: 1 if one must print the englobing parenthesis, 0 otherwise
This will dump the content of the element content definition Intended just for the debug routine
Definition at line 1285 of file valid.c.
Referenced by xmlSnprintfElementContent().
xmlValidNormalizeString: @str: a string
Normalize a string in-place.
Definition at line 2603 of file valid.c.
Referenced by xmlRemoveID().
|
static |
xmlVErrMemory: @ctxt: an XML validation parser context @extra: extra information
Handle an out of memory error
Definition at line 55 of file valid.c.
Referenced by xmlAddAttributeDecl(), xmlAddElementDecl(), xmlAddID(), xmlAddNotationDecl(), xmlAddRef(), xmlCopyDocElementContent(), xmlCreateEnumeration(), xmlGetDtdElementDesc2(), and xmlNewDocElementContent().
xmlWalkRemoveRef: @data: Contents of current link @user: Value supplied by the user
Returns 0 to abort the walk or 1 to continue
Definition at line 2962 of file valid.c.
Referenced by xmlRemoveRef().