hxt-filter-8.1.0: A collection of tools for processing XML with Haskell (Filter variant).Source codeContentsIndex
MaintainerUwe Schmidt (uwe@fh-wedel.de)
DTD processing function for including external parts of a DTD parameter entity substitution and general entity substitution
getWellformedDoc :: XmlStateFilter state
checkWellformedDoc :: XmlStateFilter state
processDTD :: XmlStateFilter a
processGeneralEntities :: XmlStateFilter a
getWellformedDoc :: XmlStateFilter stateSource

monadic filter for reading, parsing and checking a wellformed document. the input tree must consist of a root node with a source attribute in its attribute list.

All attributes from the document root are copied into the system state, and may be queried by the monadic filters, e.g. trace options.

Result is the single element list containing the well-formed document tree or, in case of errors, the document root with an empty list as children and attributes a_status and a_module for error level and the module, where the error occured.

this is a shortcut for getXmlContents .>> checkWellformedDoc

example for a main program:

 main =
   run' $
   res  <- getWellformedDoc $ newDocument "myfile.xml"
checkWellformedDoc :: XmlStateFilter stateSource
parses a text node with parseXmlDoc, processes the DTD and general entities and transforms all char references into characters
processDTD :: XmlStateFilter aSource

a filter for DTD processing

inclusion of external parts of DTD, parameter entity substitution conditional section evaluation

input tree must represent a complete document including root node

processGeneralEntities :: XmlStateFilter aSource

substitution of general entities

input: a complete document tree including root node

Produced by Haddock version 2.3.0