Skip to main content

A Library for Processing Ad hoc Data in Haskell

Embedding a Data Description Language

  • Conference paper
Implementation and Application of Functional Languages (IFL 2008)

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 5836))

Included in the following conference series:

  • 482 Accesses

Abstract

Ad hoc data formats, i.e. semistructured non-standard data formats, are pervasive in many domains that need software tools — bioinformatics, demographic surveys, geophysics and network software are just a few. Building tools becomes easier if parsing and other standard input-output processing can be automated. Modern approaches for dealing with ad hoc data formats consist of domain specific languages based on type systems. Compilers for these languages generate data structures and parsing functions in a target programming language in which tools and applications are then written. We present a monadic library in Haskell that implements a data description language. Using our library, Haskell programmers have access to data description primitives that can be used for parsing and that can be integrated with other libraries and application programs without the need of yet another compiler.

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

Access this chapter

Subscribe and save

Springer+ Basic
$34.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or eBook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Similar content being viewed by others

References

  1. Pads, http://www.padsproj.org ( [Online]; accessed June 22, 2008)

  2. Pcap, http://www.tcpdump.org/pcap.htm ( [Online]; accessed October 10, 2008)

  3. Back, G.: DataScript - A specification and scripting language for binary data. In: Batory, D., Blum, A., Taha, W. (eds.) GPCE 2002. LNCS, vol. 2487, pp. 66–77. Springer, Heidelberg (2002)

    Chapter  Google Scholar 

  4. Fernández, M.F., Fisher, K., Foster, J.N., Greenberg, M., Mandelbaum, Y.: A Generic Programming Toolkit for PADS/ML: First-Class Upgrades for Third-Party Developers. In: Hudak, P., Warren, D.S. (eds.) PADL 2008. LNCS, vol. 4902, pp. 133–149. Springer, Heidelberg (2008)

    Chapter  Google Scholar 

  5. Fisher, K., Gruber, R.: Pads: a domain-specific language for processing ad hoc data. In: PLDI 2005: Proceedings of the 2005 ACM SIGPLAN Conference on Programming Language Design and Implementation, pp. 295–304. ACM Press, New York (2005)

    Chapter  Google Scholar 

  6. Fisher, K., Mandelbaum, Y., Walker, D.: The next 700 data description languages. In: POPL 2006, pp. 2–15. ACM Press, New York (2006)

    Google Scholar 

  7. Fisher, K., Walker, D., Zhu, K.Q., White, P.: From dirt to shovels: fully automatic tool generation from ad hoc data. In: POPL 2008, pp. 421–434. ACM, New York (2008)

    Google Scholar 

  8. Hughes, J.: The design of a pretty-printing library. In: First International Spring School on Advanced Functional Programming Techniques-Tutorial Text, pp. 53–96. Springer, London (1995)

    Google Scholar 

  9. Hutton, G., Meijer, E.: Monadic parsing in Haskell. Journal of Functional Programming 8(4), 437–444 (1998)

    Google Scholar 

  10. Kennedy, A.J.: Pickler combinators. Journal of Functional Programming 14(6), 727–739 (2004)

    Google Scholar 

  11. Leijen, D., Meijer, E.: Parsec: Direct style monadic parser combinators for the real world. Tech. Rep. UU-CS-2001-27, Department of Computer Science, Universiteit Utrecht (2001)

    Google Scholar 

  12. McCann, P.J., Chandra, S.: Packet types: Abstract specification of network protocol messages. SIGCOMM Comput. Commun. Rev. 30(4), 321–333 (2000)

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2011 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Wang, Y., Gaspes, V. (2011). A Library for Processing Ad hoc Data in Haskell. In: Scholz, SB., Chitil, O. (eds) Implementation and Application of Functional Languages. IFL 2008. Lecture Notes in Computer Science, vol 5836. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-24452-0_10

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-24452-0_10

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-24451-3

  • Online ISBN: 978-3-642-24452-0

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics