Skip to main content

Regular Object Types

  • Conference paper

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 2743))

Abstract

Regular types have been proposed as a foundation for statically typed processing of XML and other forms of tree-structured data. To date, however, regular types have only been explored in special-purpose languages (e.g., XDuce, CDuce, and XQuery) with type systems designed around regular types “from the ground up.” The goal of the Xtatic language is to bring regular types to a broad audience by offering them as a lightweight extension of a popular object-oriented language, C#.

We develop here the formal core of the Xtatic design-a combination of the tree-structured data model of XDuce and the classes-and-objects data model of a conventional object-oriented language. Our tool for this investigation is a tiny language called FX with features drawn from Featherweight Java (FJ) and from the core of XDuce. Points of interest include (1) a smooth interleaving of the two data models, in which XDuce’s tree structures are grafted into of FJ’s class hierarchy while objects and object types play the role of XDuce’s label values and label types; (2) an intuitive “semantic” definition of the subtype relation, inherited from XDuce and extended to objects; and (3) a natural encoding of XML documents and their schemas using a simple form of singleton classes.

An early version of this paper was presented at the 2003 workshop on Foundations of Object-Oriented Languages.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   109.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Aldrich, J., Kostadinov, V., Chambers, C.: Alias annotations for program understanding. In: ACM Symposium on Object Oriented Programming: Systems, Languages, and Applications, OOPSLA (November 2002)

    Google Scholar 

  2. Ancona, D., Lagorio, G., Zucca, E.: A core calculus for Java exceptions. In: ACM Symposium on Object Oriented Programming: Systems, Languages, and Applications (OOPSLA), pp. 16–30 (2001)

    Google Scholar 

  3. Ancona, D., Zucca, E.: True modules for Java-like languages: Design and foundations, Technical Report DISI-TR-00-12, Dipartimento di Informatica e Scienze dellInformazione, Universit‘a di Genova (August 2000)

    Google Scholar 

  4. Benzaken, V., Castagna, G., Frisch, A.: CDuce: a white paper. In: Workshop on Programming Language Technologies for XML, PLAN-X (2002), ftp://ftp.ens.fr/pub/di/users/castagna/cduce-wp.ps.gz

  5. Bracha, G., Odersky, M., Stoutamire, D., Wadler, P.: Making the future safe for the past: Adding genericity to the Java programming language. In: Chambers, C. (ed.) ACM Symposium on Object Oriented Programming: Systems, Languages, and Applications (OOPSLA), ACM SIGPLAN Notices, Vancouver, BC, October 1998, vol. 33(10), pp. 183–200 (1998)

    Google Scholar 

  6. Catell, R. (ed.): The Object Database Standard: ODMG-1993. Morgan Kaufmann, San Francisco (1994)

    Google Scholar 

  7. Christensen, A.S., Moller, A., Schwartzbach, M.I.: Extending Java for highlevel web service construction (2002), http://www.brics.dk/~mis/jwig.ps

  8. Clark, J.: TREX: Tree Regular Expressions for XML (2001), http://www.thaiopensource.com/trex/

  9. Clark, J., Murata, M.: RELAX NG (2001), http://www.relaxng.org

  10. Document Object Model (DOM) Level 3 validation specification, W3C working draft (2002), http://www.w3.org/TR/DOM-Level-3-Val

  11. Fernández, M.F., Siméon, J., Wadler, P.: A semi-monad for semi-structured data. In: Van den Bussche, J., Vianu, V. (eds.) ICDT 2001. LNCS, vol. 1973, pp. 263–300. Springer, Heidelberg (2000)

    Chapter  Google Scholar 

  12. Frisch, A., Castagna, G., Benzaken, V.: Semantic subtyping. In: IEEE Symposium on Logic in Computer Science (LICS) (2002)

    Google Scholar 

  13. Hosoya, H.: Regular Expression Types for XML. PhD thesis, The University of Tokyo, Japan (2000)

    Google Scholar 

  14. Hosoya, H.: Regular expression pattern matching - a simpler design. Technical Report 1397, RIMS, Kyoto University (2003)

    Google Scholar 

  15. Hosoya, H., Murata, M.: Validation and boolean operations for attributeelement constraints. In: Workshop on Programming Language Technologies for XML, PLAN-X (2002)

    Google Scholar 

  16. Hosoya, H., Pierce, B.: Regular expression pattern matching. In: ACM Symposium on Principles of Programming Languages (POPL), London, England (2001); Full version to appear in Journal of Functional Programming

    Google Scholar 

  17. Hosoya, H., Pierce, B.C.: XDuce: A typed XML processing language (preliminary report). In: Suciu, D., Vossen, G. (eds.) WebDB 2000. LNCS, vol. 1997, p. 226. Springer, Heidelberg (2001); Reprinted in The Web and Databases, Selected Papers. LNCS, vol. 1997. Springer, Heidelberg (2001)

    Chapter  Google Scholar 

  18. Hosoya, H., Pierce, B.C.: XDuce: A statically typed XML processing language. ACM Transactions on Internet Technology (2003) (to appear)

    Google Scholar 

  19. Hosoya, H., Vouillon, J., Pierce, B.C.: Regular expression types for XML. In: Proceedings of the International Conference on Functional Programming, ICFP (2000)

    Google Scholar 

  20. Igarashi, A., Pierce, B., Wadler, P.: Featherweight Java: A minimal core calculus for Java and GJ. In: ACM Symposium on Object Oriented Programming: Systems, Languages, and Applications, OOPSLA (October 1999); Full version in ACM Transactions on Programming Languages and Systems (TOPLAS) 23(3) (May 2001)

    Google Scholar 

  21. Igarashi, A., Pierce, B.C.: On inner classes. Information and Computation 177(1), 56–89 (2002); A special issue with papers from the 7th Workshop on Foundations of Object-Oriented Languages (FOOL); informal proceedings. An earlier version appeared in Proceedings of the 14th European Conference on Object- Oriented Programming (ECOOP). LNCS, vol. 1850, pp. 129–153. Springer, Heidelberg

    Article  MATH  MathSciNet  Google Scholar 

  22. Lahiri, T., Abiteboul, S., Widom, J.: Ozone: integrating structured and semistructured data. In: Connor, R.C.H., Mendelzon, A.O. (eds.) DBPL 1999. LNCS, vol. 1949, pp. 297–332. Springer, Heidelberg (2000)

    Chapter  Google Scholar 

  23. League, C., Shao, Z., Trifonov, V.: Type-preserving compilation of Featherweight Java. ACM Transactions on Programming Languages and Systems 24(2), 112–152 (2002)

    Article  Google Scholar 

  24. Meijer, E., Shields, M.: XMλ: A functional programming language for constructing and manipulating XML documents (1999) (submitted for publication)

    Google Scholar 

  25. Odersky, M.: Report on the programming language Scala (2002), http://lamp.epfl.ch/~odersky/scala/reference.ps

  26. Odersky, M., Wadler, P.: Pizza into Java: Translating theory into practice. In: ACM Symposium on Principles of Programming Languages (POPL), Paris, France (1997)

    Google Scholar 

  27. Papaconstantinou, Y., Garcia-Molina, H., Widom, J.: Object exchange across heterogeneous information sources. In: International Conference on Data Engineering (March 1995)

    Google Scholar 

  28. Relaxer, http://www.asahi-net.or.jp/~dp8t-asm/java/tools/Relaxer/index.html

  29. Schultz, U.P.: Partial evaluation for class-based object-oriented languages. In: Danvy, O., Filinski, A. (eds.) PADO 2001. LNCS, vol. 2053, pp. 173–197. Springer, Heidelberg (2001)

    Chapter  Google Scholar 

  30. Shields, M., Meijer, E.: Type-indexed rows. In: ACM Symposium on Principles of Programming Languages (POPL), London, England (2001)

    Google Scholar 

  31. Studer, T.: Constructive foundations for Featherweight Java. In: Kahle, R., Schroeder-Heister, P., Stärk, R.F. (eds.) PTCS 2001. LNCS, vol. 2183, p. 202. Springer, Heidelberg (2001)

    Chapter  Google Scholar 

  32. Sun Microsystems. The Java architecture for XML binding, JAXB (2001), http://java.sun.com/xml/jaxb

  33. Tabuchi, N., Sumii, E., Yonezawa, A.: Regular expression types for strings in a text processing language. In: Barthe, G., Thiemann, P. (eds.) Proceedings of Workshop on Types in Programming (TIP 2002). Electronic Notes in Theoretical Computer Science, vol. 75, pp. 1–19. Elsevier Science, Amsterdam (2002)

    Google Scholar 

  34. Tofte, M.: Type inference for polymorphic references. Information and Computation 89(1) (November 1990)

    Google Scholar 

  35. Wallace, M., Runciman, C.: Haskell and XML: Generic combinators or typebased translation? In: Proceedings of the Fourth ACM SIGPLAN International Conference on Functional Programming (ICFP‘99), ACM SIGPLAN Notices, vol. 34–9, pp. 148–159. ACM Press, New York (1999)

    Chapter  Google Scholar 

  36. Extensible Markup Language (XMLTM), XML 1.0, W3C Recommendation (February 1998), http://www.w3.org/XML/

  37. XQuery 1.0: An XML Query Language, W3C Working Draft (November 2002), http://www.w3.org/TR/xquery/

  38. XQuery 1.0 and XPath 2.0 Formal Semantics, W3C Working Draft (November 2002), http://www.w3c.org/TR/query-semantics/

  39. XML Schema Part 0: Primer, W3C Working Draft (2000), http://www.w3.org/TR/xmlschema-0/

  40. XSL Transformations (XSLT) (1999), http://www.w3.org/TR/xslt

  41. Zenger, M.: Type-safe prototype-based component evolution. In: Magnusson, B. (ed.) ECOOP 2002. LNCS, vol. 2374, p. 470. Springer, Heidelberg (2002)

    Chapter  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2003 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Gapeyev, V., Pierce, B.C. (2003). Regular Object Types. In: Cardelli, L. (eds) ECOOP 2003 – Object-Oriented Programming. ECOOP 2003. Lecture Notes in Computer Science, vol 2743. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-45070-2_8

Download citation

  • DOI: https://doi.org/10.1007/978-3-540-45070-2_8

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-40531-3

  • Online ISBN: 978-3-540-45070-2

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics