Two approaches to teaching software components using Ada 95

  • Authors:
  • David S. Gibson

  • Affiliations:
  • United States Air Force Academy

  • Venue:
  • ACM SIGAda Ada Letters
  • Year:
  • 2000

Quantified Score

Hi-index 0.00

Visualization

Abstract

Abstract data types (ADTs) have been used for many years to teach the specification and implementation of software components. With the advent of object-oriented programming languages (OOPLs), many ADT specifications and implementations are now encoded in OOPLs as classes. OOPLs typically provide a variety of language mechanisms that support data abstraction and make classes convenient for encoding ADT specifications and implementations. In particular, the inheritance mechanism supported by OOPL classes provides useful ways of relating ADT specifications and implementations. The Ada programming language has always provided solid support for specification and implementation of ADTs with its package construct. The 1995 revision to Ada (Ada 95) added a variety of powerful new language mechanisms such as tagged types (full-fledged inheritance), abstract types, and hierarchical library units. Each of these new Ada language mechanisms, in addition to packages, can be used in various combinations to support the specification, implementation, and extension of ADTs. In this paper, we compare two approaches used to teach to second-year undergraduates specification and implementation of software components in Ada. The first approach is a traditional Ada approach relying solely on the package mechanism to support data abstraction. The second approach relies heavily on Ada's newer object-oriented language mechanisms in addition to hierarchical library units.