xml-extractors: Simple wrapper over xml to extract data from parsed xml

[ bsd3, library, xml ] [ Propose Tags ]

This is a library to simplify extraction of data from parsed xml.

See the Text.XML.Light.Extractors module for an example.

Motivation

The xml package provides functions to parse and get information from xml data. It will parse an xml string into a generic tree representation. Extracting information from such a tree while keeping track of location to handle errors is tricky. This library helps with that.

If there is an error during extraction (expected information is absent or wrong), it will return an error value with position information.

Some limitations

  • Only handles unqualified names.

  • No column number and sometimes no line number reference in error values.


[Skip to Readme]

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

Versions [RSS] 0.2.0.0, 0.2.1.0, 0.3.0.0, 0.4.0.0, 0.4.0.1, 0.4.0.2, 0.4.0.3
Dependencies base (>=4.6 && <4.8), mtl (>=2.1 && <2.2), safe (>=0.3 && <0.4), transformers (>=0.3 && <0.4), xml (>=1.3 && <1.4) [details]
License BSD-3-Clause
Author Johan Holmquist
Maintainer holmisen@gmail.com
Category XML
Home page https://github.com/holmisen/xml-extractors
Uploaded by holmisen at 2014-12-20T21:42:39Z
Distributions
Reverse Dependencies 2 direct, 0 indirect [details]
Downloads 3919 total (19 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs uploaded by user
Build status unknown [no reports yet]

Readme for xml-extractors-0.2.1.0

[back to package description]

xml-extractor

Simple wrapper over xml to extract data from parsed xml.

When parsing xml strings with XML.Light you get a list of Content. Then you can use functions from Text.XML.Light.Proc to extract data from that. It is however kind of tricky to deal with the potential errors -- we have a parsing problem again.

Instead of Text.XML.Light.Proc one can use this library. It simplifies the process of extracting data from Content while dealing with errors.