ST package:hxt

Implementation of list arrows with a state
complete evaluation of an arrow result using DeepSeq this is sometimes useful for preventing space leaks, especially after reading and validation of a document, all DTD stuff is not longer in use and can be recycled by the GC.
find all positions where a string occurs within another string
escape XML chars <, >, ", and ampercent by transforming them into character references see also : attrEscapeXml
find the position of the first occurence of a string
find the position of the last occurence of a string
convert a string into a hexadecimal string applying charToHexString see also : charToHexString
convert string to lowercase with standard Haskell toLower function
convert string to uppercase with standard Haskell toUpper function
remove leading and trailing whitespace with standard Haskell predicate isSpace
The list arrow class This module defines the interface for list arrows. A list arrow is a function that gives a list of results for a given argument. A single element result represents a normal function. An empty list often indicates that the function is undefined for the given argument. The empty list may also represent False, non-empty lists True. A list with more than one element gives all results for a so called nondeterministic function.
The interface for list arrows Only mkA, isA (>>.) don't have default implementations
constructor for a const arrow: constA = arr . const
constructor for a const arrow: constL = arrL . const
combinator for converting an arrow into a determinstic version with all results collected in a single element list
listA af = af >>. (:[])
this is useful when the list of results computed by an arrow must be manipulated (e.g. sorted) example for sorting the results of a filter
collectAndSort         :: a b c -> a b c

collectAndSort collect = listA collect >>> arrL sort
the inverse of listA
listA af >>> unlistA = af
unlistA is defined as arrL id
XPath axis: ancestor
XPath axis: ancestor or self
Change the current subtree of a navigatable tree. The arrow for computing the changes should be deterministic. If it fails nothing is changed.
Substitute the current subtree of a navigatable tree by a given tree