Efficient and Type-Safe Generic Data Storage

  • Authors:
  • Sjaak Smetsers;Arjen van Weelden;Rinus Plasmeijer

  • Affiliations:
  • Institute for Computing and Information Sciences, Radboud University Nijmegen, The Netherlands;Institute for Computing and Information Sciences, Radboud University Nijmegen, The Netherlands;Institute for Computing and Information Sciences, Radboud University Nijmegen, The Netherlands

  • Venue:
  • Electronic Notes in Theoretical Computer Science (ENTCS)
  • Year:
  • 2009

Quantified Score

Hi-index 0.00

Visualization

Abstract

In this paper we present an elegant method for sequentializing arbitrary data using the generic language extension of the functional programming language Clean. We show how the proposed operations can be used to store values of any concrete data type in several kinds of IO containers (such as files or arrays of characters), and how to manipulate stored data efficiently. Moreover, by extending stored data with encoded type information, data manipulation will be type-safe. Defining these operations generically has the advantage that specific instances for user defined data types can be generated fully automatically. Compared to traditional sequentialization methods (or to common data manipulation, using relational data bases) our operations are an order of magnitude faster.