Skip to main content

Module parser

Module parser 

Source
Expand description

XML 1.0 parser.

A hand-rolled recursive descent parser conforming to the W3C XML 1.0 (Fifth Edition) specification. The parser builds a Document tree and supports error recovery mode for processing malformed input.

The parser is hand-rolled (not combinator-based) because:

  1. libxml2’s parser is recursive descent and we need identical behavior
  2. Error recovery requires fine-grained control over parse state
  3. Push/incremental parsing requires suspendable state
  4. Performance — no abstraction overhead

Re-exports§

pub use push::PushParser;

Modules§

push
Push/incremental XML parser.

Structs§

ExternalEntityRequest
A request to resolve an external entity.
ParseOptions
Parse options controlling parser behavior and security limits.

Functions§

parse_str
Parses an XML string with default options.
parse_str_with_options
Parses an XML string with the given options.

Type Aliases§

EntityResolver
A callback for resolving external entities.