Re: [xml] SAX-like parsing of DTDs
- From: Daniel Veillard <veillard redhat com>
- To: Mark S Petrovic <petrovic corp earthlink net>
- Cc: xml gnome org
- Subject: Re: [xml] SAX-like parsing of DTDs
- Date: Thu, 27 Feb 2003 11:06:53 -0500
On Thu, Feb 27, 2003 at 07:51:25AM -0800, Mark S Petrovic wrote:
Good day.
Does libxml2 expose an API for performing basic parsing of a DTD -
specifically providing the ability to sense when an attribute declaration
appears in the input stream? I am looking for the DTD-equivalent of
SAX-based parsing of an XML stream. My goal is to assemble the logical
What about looking at it before asking ? Just laziness ?
include/libxml/parser.h
/**
* attributeDeclSAXFunc:
* @ctx: the user data (XML parser context)
* @elem: the name of the element
* @fullname: the attribute name
* @type: the attribute type
* @def: the type of default value
* @defaultValue: the attribute default value
* @tree: the tree of enumerated value set
*
* An attribute definition has been parsed.
*/
typedef void (*attributeDeclSAXFunc)(void *ctx,
const xmlChar *elem,
const xmlChar *fullname,
int type,
int def,
const xmlChar *defaultValue,
xmlEnumerationPtr tree);
struct _xmlSAXHandler {
...
attributeDeclSAXFunc attributeDecl;
...
};
where the attributeName_i are ordered in the order in which they are
declared in the DTD.
I already said it made no sense to try to build an order.
Daniel
--
Daniel Veillard | Red Hat Network https://rhn.redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]