xmltree-parse_with_config

Crates.ioxmltree-parse_with_config
lib.rsxmltree-parse_with_config
version0.10.3
sourcesrc
created_at2022-01-16 12:54:37.751996
updated_at2022-01-16 12:54:37.751996
descriptionParse an XML file into a simple tree-like structure
homepage
repositoryhttps://github.com/eminence/xmltree-rs
max_upload_size
id514831
size38,663
Jannes (思明) (jannes)

documentation

https://docs.rs/xmltree/

README

xmltree-rs

THIS IS A FORK WITH A SINGLE ADDITIONAL PATCH

THE BELOW README IS FROM THE ORIGINAL REPO

Documention

A small library for parsing an XML file into an in-memory tree structure.

Not recommended for large XML files, as it will load the entire file into memory.

https://crates.io/crates/xmltree

Usage

Add the following to your Cargo.toml file:

[dependencies]
xmltree = "0.10"

Feature-flags

  • attribute-order - change the data structure that stores attributes to one that uses insertion order. This changes the type definition and adds another dependency.

  • attribute-sorted - change the data structure that stores attributes to one that uses sorted order. This changes the type definition.

Compatability with xml-rs

This crate will export some types from the xml-rs crate. If your own crate also uses the xml-rs crate, but with a different version, the types may be incompatible. One way to solve this is to only use the exported types, but sometimes that is not always possible. In those cases you should use a version of xmltree that matches the version of xml-rs you are using:

xml-rs version xmltree version
0.8 0.10
0.7 0.8
0.6 0.6

Example

See the documentation for some examples:

https://docs.rs/xmltree/

Commit count: 91

cargo fmt