ABSTRACT
We show that an XML DTD (Document Type Definition) can be viewed as the fixed point of a parametric content model. Based on the parametric content model, we develop a model of modular transformation of XML documents. A fold operator is used to capture a class of functions that consume valid XML document trees in a bottom-up matter. Similarly, an unfold operator is used to generate valid XML document trees in a top-down fashion. We then show that DTD-aware XML document transformation, which consumes a document of one DTD and generates a document of another DTD, can be thought as both a fold operation and an unfold operation.
This leads us to model certain DTD-aware document transformations by mappings from the source content models to the target content models. From these mappings, we derive DTD-aware XML document transformational programs. Benefits of such derived programs include automatic validation of the target documents (no invalid document will be generated) and modular property in the composition of these programs (intermediate results from successive transformations can be eliminated).
- Document Object Model (DOM) Level 1 Specification. http://www.w3.org/TR/REC-DOM-Level-1/.]]Google Scholar
- RELAX NG Specification. http://www.oasis-open.org/committees/relax-ng/spec-20011203.html.]]Google Scholar
- The Caml Language. http://caml.inria.fr.]]Google Scholar
- XML Schema Part 0: Primer. http://www.w3.org/TR/xmlschema-0/.]]Google Scholar
- Extase Akpotsui, Vincent Quint, and Cécile Roisin. Type modelling for document transformation in structured editing systems. Mathematical and Computer Modelling, 25(4):1--19, 1997.]] Google ScholarDigital Library
- Roland Backhouse, Patrick Jansson, Johan Jeuring, and Lambert Meertens. Generic programming: An introduction. In Advanced Functional Programming, 3rd Int'l School. 1999.]]Google Scholar
- Richard Bird. An introduction to the theory of lists. In Logic of Programming and Calculi of Discrete Design. Springer--Verlag, 1987.]] Google ScholarDigital Library
- Richard Bird and Oege de Moor. Algebra of Programming. Prentice Hall, 1997.]] Google ScholarDigital Library
- Don Chamberlin, Jonathan Robie, and Daniela Florescu. Quilt: An XML query language for heterogeneous data source. In Proc. of the 3rd Int'l Workshop on the Web and Databases. 2000.]] Google ScholarDigital Library
- Tyng--Ruey Chuang. Generic validation of structural content with parametric modules. In Proc. of the 2001 ACM SIGPLAN Int'l Conference on Functional Programming. 2001.]] Google ScholarDigital Library
- Tyng--Ruey Chuang and Jan--Li Lin. On modular transformation of structural content. Technical Report TR-IIS-003-007, Institute of Information Science, Academia Sinica. 2003.]]Google Scholar
- Mary Fernandez, Jerome Simeon, and Philip Wadler. An algebra for XML query. In Foundations of Software Technology and Theoretical Computer Science: 20th Conference. 2000.]] Google ScholarDigital Library
- Haruo Hosoya and Benjamin C. Pierce. XDuce: A typed XML processing language. In Proc. of 3rd Int'l Workshop on the Web and Databases. 2000.]] Google ScholarDigital Library
- Haruo Hosoya, Jérôme Vouillon, and Benjamin C. Pierce. Regular expression types for XML. In Proc. of the Int'l Conference on Functional Programming. 2000.]] Google ScholarDigital Library
- Eila Kuikka, Paul Leinonen, and Martti Penttonen. Towards automating of document structure transformations. In 2nd ACM Int'l Conference on Document Engineering. 2002.]] Google ScholarDigital Library
- Eila Kuikka and Martti Penttonen. Transformation of structured documents. Technical Report CS-95-46, Department of Computer Science, University of Waterloo, Canada, 1995.]]Google Scholar
- Saunders Mac Lane. Categories for The Working Mathematician. Springer-Verlag, 1971.]]Google ScholarCross Ref
- Lambert Meertens. Algorithmics --- towards programming as a mathematical activity. In Proc. of the CWI Symposium on Mathematics and Computer Science. 1986.]]Google Scholar
- Erik Meijer, Maarten Fokkinga, and Ross Paterson. Functional programming with bananas, lenses, envelopes and bared wire. In Functional Programming Languages and Computer Architecture. 1991.]] Google ScholarDigital Library
- Tova Milo, Dan Suciu, and Victor Vianu. Typechecking for xml transformers. In Proc. of the 19th ACM SIGMOD-SIGACT-SIGART Symposium on Principles of Database Systems. 2000.]] Google ScholarDigital Library
- Makoto Murata. Transformation of documents and schemas by patterns and contextual conditions. In 3rd Int'l Workshop on Principles of Document Processing. 1996.]] Google ScholarDigital Library
- Makoto Murata. Data models for document transformation and assembly. In Workshop on Principles of Digital Document Processing. 1998.]] Google ScholarDigital Library
- Emmanuel Pietriga, Jean-Yves Vion-Dury, and Vincent Quint. VXT: A visual approach to xml transformations. In 1st ACM Int'l Conference on Document Engineering. 2001.]] Google ScholarDigital Library
- Philip Wadler. Theorems for free. In Functional Programming Languages and Computer Architecture. 1989.]] Google ScholarDigital Library
Index Terms
- On modular transformation of structural content
Recommendations
Generic validation of structural content with parametric modules
We demonstrate a natural mapping from XML element types to ML module expressions. The mapping is inductive and definitions of common XML operations can be derived as the module expressions are composed. We show how to derive, in a generic way, the ...
Generic validation of structural content with parametric modules
ICFP '01: Proceedings of the sixth ACM SIGPLAN international conference on Functional programmingWe demonstrate a natural mapping from XML element types to ML module expressions. The mapping is inductive and definitions of common XML operations can be derived as the module expressions are composed. We show how to derive, in a generic way, the ...
Constraint Preserving Transformation from Relational Schema to XML Schema
XML has become the standard for publishing and exchanging data on the Web. However, most business data is managed and will remain to be managed by relational database management systems. As such, there is an increasing need to efficiently and accurately ...
Comments