The Karlsruhe Library of Algorithms and Data Structures (Karla)

The Karlsruhe Library of Algorithms and Data Structures (Karla) is an object-oriented library of data structures and algorithms designed for reuse. The main goal of this project is to design a reliable object-oriented library of algorithms and data structures. A library component is said to be reliable if it is both correct with respect to its specification and robust in the sense that no runtime errors point into the library. Therefore, a reliable component can only fail if the user violates the pre-condition on its use. The reliability of library components is considered to be the key factor to achieve large-scale reuse. Further design goals include flexibility and efficiency. There is a tradeoff between these goals that has to be balanced. For example, a flexible component that allows part of its implementation to be changed at runtime can in general not rely on implementation details of the flexible part. If, on the other hand, efficiency is an important issue, it is desirable to use implementation details. In this case, flexibility is traded for efficiency. In order to achieve the design goals, we constructed Karla by consequently using the mechanisms of refinement, specialization and genericity of classes. In the implementation phase, we identified and consequently employed several design patterns.

In addition to the library itself, we have designed a comprehensive information and configuration tool that allows for navigation in the library structure and the definition of projects. It provides information on the class and method level.

Karla currently contains more than 250 classes and is continuously being developed. It has been used in several medium-sized (>10KLOC) projects. In these projects, fractions of reused code of 40% and more have been observed.

Availability

The design of Karla is independent of a specific language. Our implementation is based on Sather-K, the Karlsruhe variant of Sather. The latest publicly available version of Karla is available for FTP download as follows:

Documentation

There are several sources of documentation: a quick overview, online descriptions of the classes, and links to advanced topics.

Overview

There are several papers outlining the design rationale, documentation rules etc.

Online documentation

NEW! This tool is experimental, as we are just switching from a Tcl/Tk-based tool to an HTML-based one. Therefore, it shows only part of the content of Karla at this time. You can start the Karla Information Tool

Karla is organized in groups of related classes. For robustness reasons, we distinguish two different types of relationship: conformance and specialization. While conformance allows for polymorphism, specialization does not.

Advanced topics


Arne Frick
Wolf Zimmermann
Last modified: Mon May 6 10:49:44 MDT 1996