Annotation of XML/valid.h, revision 1.6

1.1       daniel      1: /*
                      2:  * valid.h : interface to the DTD handling and the validity checking
                      3:  *
                      4:  * See Copyright for the status of this software.
                      5:  *
                      6:  * Daniel.Veillard@w3.org
                      7:  */
                      8: 
                      9: 
                     10: #ifndef __XML_VALID_H__
                     11: #define __XML_VALID_H__
                     12: #include "tree.h"
                     13: 
1.2       daniel     14: /*
1.5       daniel     15:  * ALl notation declarations are stored in a table
                     16:  * there is one table per DTD
                     17:  */
                     18: 
                     19: #define XML_MIN_NOTATION_TABLE 32
                     20: 
                     21: typedef struct xmlNotationTable {
                     22:     int nb_notations;          /* number of notations stored */
                     23:     int max_notations;         /* maximum number of notations */
                     24:     xmlNotationPtr table;      /* the table of attributes */
1.6     ! daniel     25: } xmlNotationTable;
        !            26: typedef xmlNotationTable *xmlNotationTablePtr;
1.5       daniel     27: 
                     28: /*
1.2       daniel     29:  * ALl element declarations are stored in a table
                     30:  * there is one table per DTD
                     31:  */
                     32: 
                     33: #define XML_MIN_ELEMENT_TABLE  32
                     34: 
                     35: typedef struct xmlElementTable {
                     36:     int nb_elements;           /* number of elements stored */
                     37:     int max_elements;          /* maximum number of elements */
1.4       daniel     38:     xmlElementPtr table;       /* the table of elements */
1.6     ! daniel     39: } xmlElementTable;
        !            40: typedef xmlElementTable *xmlElementTablePtr;
1.2       daniel     41: 
1.5       daniel     42: /*
                     43:  * ALl attribute declarations are stored in a table
                     44:  * there is one table per DTD
                     45:  */
                     46: 
1.4       daniel     47: #define XML_MIN_ATTRIBUTE_TABLE        32
                     48: 
                     49: typedef struct xmlAttributeTable {
                     50:     int nb_attributes;         /* number of attributes stored */
                     51:     int max_attributes;                /* maximum number of attributes */
                     52:     xmlAttributePtr table;     /* the table of attributes */
1.6     ! daniel     53: } xmlAttributeTable;
        !            54: typedef xmlAttributeTable *xmlAttributeTablePtr;
1.4       daniel     55: 
1.5       daniel     56: /* Notation */
1.6     ! daniel     57: xmlNotationPtr xmlAddNotationDecl(xmlDtdPtr dtd, CHAR *name,
1.5       daniel     58:               CHAR *PublicID, CHAR *SystemID);
1.6     ! daniel     59: xmlNotationTablePtr xmlCopyNotationTable(xmlNotationTablePtr table);
        !            60: void xmlFreeNotationTable(xmlNotationTablePtr table);
        !            61: void xmlDumpNotationTable(xmlNotationTablePtr table);
1.5       daniel     62: 
                     63: /* Element Content */
1.6     ! daniel     64: xmlElementContentPtr xmlNewElementContent(CHAR *name, int type);
        !            65: xmlElementContentPtr xmlCopyElementContent(xmlElementContentPtr content);
        !            66: void xmlFreeElementContent(xmlElementContentPtr cur);
1.2       daniel     67: 
1.5       daniel     68: /* Element */
1.6     ! daniel     69: xmlElementPtr xmlAddElementDecl(xmlDtdPtr dtd, CHAR *name, int type, 
1.5       daniel     70:                                        xmlElementContentPtr content);
1.6     ! daniel     71: xmlElementTablePtr xmlCopyElementTable(xmlElementTablePtr table);
        !            72: void xmlFreeElementTable(xmlElementTablePtr table);
        !            73: void xmlDumpElementTable(xmlElementTablePtr table);
1.5       daniel     74: 
                     75: /* Enumeration */
1.6     ! daniel     76: xmlEnumerationPtr xmlCreateEnumeration(CHAR *name);
        !            77: void xmlFreeEnumeration(xmlEnumerationPtr cur);
        !            78: xmlEnumerationPtr xmlCopyEnumeration(xmlEnumerationPtr cur);
1.5       daniel     79: 
                     80: /* Attribute */
1.6     ! daniel     81: xmlAttributePtr xmlAddAttributeDecl(xmlDtdPtr dtd, CHAR *elem,
1.4       daniel     82:               CHAR *name, int type, int def,
                     83:               CHAR *defaultValue, xmlEnumerationPtr tree);
1.6     ! daniel     84: xmlAttributeTablePtr xmlCopyAttributeTable(xmlAttributeTablePtr table);
        !            85: void xmlFreeAttributeTable(xmlAttributeTablePtr table);
        !            86: void xmlDumpAttributeTable(xmlAttributeTablePtr table);
1.5       daniel     87: 
1.1       daniel     88: #endif /* __XML_VALID_H__ */

Webmaster