ABSTRACT
We present two complementary approaches to writing XML document-processing applications in a functional language.In the first approach, the generic tree structure of XML documents is used as the basis for the design of a library of combinators for generic processing: selection, generation, and transformation of XML trees.The second approach is to use a type-translation framework for treating XML document type definitions (DTDs) as declarations of algebraic data types, and a derivation of the corresponding functions for reading and writing documents as typed values in Haskell.
- 1.Tim Bray, Jean Paoli, and C.M. Sperberg-Macqueen. Extensible Markup Language (XML) 1.0 (W3C Recommendation), http://wT~-~, w3. org/TR/REg-xml, W~ Consortium, February 1998.Google Scholar
- 2.W H Burge. Recursive Programming Techniques. Addison-Wesley, 1975.Google Scholar
- 3.James Clark (ed). XSL Transformations (Working Draft). http://~, w3. org/TR/WD-xslt, YVWW Consortium, April 1999.Google Scholar
- 4.don Fairbairn. Making form follow function: An exercise in functional programming style. Software - Practice and Experience, 17(6):379-386, June 1987. Google ScholarDigital Library
- 5.Benedict ROaster. Records, Variants, and Qualified Types. Dept of Computer Science, University of Nottingham, PhD Thesis, 1998.Google Scholar
- 6.John Hughes. Why functional programming matters. Computer Journal, 32(2), April 1989. Google ScholarDigital Library
- 7.John Hughes. The design of a pretty-printing library. In 1st Intl. School on Advanced Functional Programming, pages 53-96. Springer LNCS Vol. 925, 1995. Google ScholarDigital Library
- 8.Graham Hutton and Erik Meijer. Monadic parsing in Haskell. Journal of Functional Programming, 8(4), July 1998. Google ScholarDigital Library
- 9.Markus Mohnen. Context patterns in Haskell. In Workshop on Implementation of Functional Languages, pages 41-57. Springer LNCS Vol 1268, September 1996. Google ScholarDigital Library
- 10.Doaitse Swierstra and Luc Duponcheel. Deterministic error-correcting combinator parsers. In 2nd Intl. School on Advanced Functional Programming, pages 184-207. Springer LNCS Vot 1129, August 1996. Google ScholarDigital Library
- 11.David A Turner. A new implementation technique for applicative languages. Software - Practice and Experience, 9(1):31-50, January 1979.Google ScholarCross Ref
- 12.Unknown. Document Style Semantics and Specification Language (DSSSL) (Final Draft). http://occam, sjf. novell, com/dsssl/dss s196/, Novell Publications, 1996.Google Scholar
- 13.Eelco Visser, Zine el Abidine Benaissa, and Andrew Tolmach. Building program optimisers with rewrite strategies. In International Conference on Functional Programming, pages 13-26. ACM Press, September 1998. Google ScholarDigital Library
- 14.Philip Wadler. How to replace failure by a list of successes. In Functional Programming Languages and Computer Architecture, pages 113-128. Springer LNCS Vol 201, September 1985. Google ScholarDigital Library
- 15.Philip Wadler. A formal model of pattern matching in XSL. Technical Report http://w~;w, cs. bell-labs, com/~wadler/xsl/, Bell Labs, January 1999.Google Scholar
- 16.Noel Winstanley. Reflections on instance derivation. In 1997 Glasgow Functional Programming Workshop. BCS Workshops in Computer Science, September 1997.Google Scholar
Index Terms
- Haskell and XML: generic combinators or type-based translation?
Recommendations
Haskell and XML: generic combinators or type-based translation?
We present two complementary approaches to writing XML document-processing applications in a functional language.In the first approach, the generic tree structure of XML documents is used as the basis for the design of a library of combinators for ...
Comments