|
|
|
|
|
| Description |
| HXQ is a fast and space-efficient compiler from XQuery (the standard
query language for XML) to embedded Haskell code. The translation is
based on Haskell templates. It also provides an interpreter for
evaluating ad-hoc XQueries read from input or from files
and optional database connectivity using HDBC.
For more information, look at http://lambda.uta.edu/HXQ/.
|
|
| Synopsis |
|
|
|
|
| The XML Data Representation
|
|
|
| Element tagname or attribute name
|
|
|
| Attribute list
|
|
|
| A rose tree representation of XML data.
An XML element is: XElem tagname atributes preorder parent children.
The preorder numbering is the document order of elements.
The parent is a cyclic reference to the parent element.
| | Constructors | | XElem !Name !AttList !Int XTree [XTree] | an XML tree node (element)
| | XAttr !Name !String | attribute construction
| | XText !String | an XML tree leaf (PCDATA)
| | XInt !Int | an XML tree leaf (int)
| | XFloat !Double | an XML tree leaf (double)
| | XBool !Bool | an XML tree leaf (boolean)
| | XPI Name String | processing instruction
| | XGERef String | general entity reference
| | XComment String | comment
| | XError String | error report
| | XNull | null value
| | XType Ast | type information
| | XNoPad | marker for no padding in XSeq
|
| Instances | |
|
|
|
| A sequence of XML fragments
|
|
|
| Print the XQuery result (which is a sequence of XML fragments) without buffering.
|
|
| The XQuery Compiler
|
|
|
| Compile an XQuery that may perform IO (such as reading an XML document or calling a user function).
When the compiled code is evaluated, it returns a value of type IO XSeq.
|
|
|
| Compile an XQuery expression that does not perform IO.
When the compiled code is evaluated, it returns a value of type XSeq.
|
|
| qx |
|
| The XQuery Interpreter
|
|
|
| Evaluate the XQuery using the interpreter.
|
|
|
| The XQuery interpreter as an XQuery function.
|
|
| The XQuery Compiler with Database Connectivity
|
|
|
| Compile an XQuery that may perform IO and/or queries a database.
When the compiled code is evaluated, it returns Connection -> IO XSeq.
|
|
| The XQuery Interpreter with Database Connectivity
|
|
|
| Evaluate the XQuery with database connectivity using the interpreter.
|
|
| Shredding and Publishing XML Documents Using a Relational Database
|
|
|
| :: Connection | database connection
| | -> FilePath | XML document pathname
| | -> String | schema name
| | -> IO Table | | | Create a schema for an XML document into the database under the given name.
|
|
|
|
| :: Connection | database connection
| | -> FilePath | XML document pathname
| | -> String | schema name
| | -> IO () | | | Store an XML document into the database under the given name.
|
|
|
|
| :: String | database name
| | -> FilePath | XML document pathname
| | -> String | schema name
| | -> Q Exp | | | Store an XML document into the database under the given name. Generates Haskell code.
|
|
|
|
| :: Connection | database connection
| | -> String | schema name
| | -> IO () | | | Print the relational schema of the XML document stored in the database under the given name
|
|
|
|
| :: Connection | database connection
| | -> String | schema name
| | -> String | the tag name of the elements to be indexed
| | -> IO () | | | Create a secondary index on tagname for the shredded document under the given name..
|
|
|
| Other Functions
|
|
|
| :: String | database name
| | -> IO Connection | | | Connect to a relational database
|
|
|
|
| :: Connection | database connection
| | -> IO () | | | Disconnect from the relational database
|
|
|
|
| :: Connection | database connection
| | -> IO () | | | commit the updates to the database
|
|
|
|
| :: Connection | database connection
| | -> IO () | | | rollback the updates from the database
|
|
|
| Produced by Haddock version 2.4.2 |