Behavioral contracts and behavioral subtyping

Robert Bruce Findler*, Mario Latendresse, Matthias Felleisen

*Corresponding author for this work

Research output: Chapter in Book/Report/Conference proceedingConference contribution

47 Scopus citations

Abstract

Component-based software manufacturing has the potential to bring division-of-labor benefits to the world of software engineering. In order to make a market of software components viable, however, producers and consumers must agree on enforceable software contracts. In this paper, we show how to enforce contracts if components are manufactured from class and interface hierarchies. In particular, we focus on one style of contract: pre- and post-conditions. Programmers annotate class and interface methods with pre- and post-conditions and the run-time system checks these conditions during evaluation. These contracts guarantee that methods are called properly and provide appropriate results. In procedural languages, the use of pre- and post-condition contracts is well-established and studies have demonstrated its value. In object-oriented languages, however, assigning blame for pre- and post-condition failures poses subtle and complex problems. Specifically, assigning blame for malformed class and interface hierarchies is so difficult that none of the existing contract monitoring tools correctly assign blame for these failures. In this paper, we show how to overcome these problems in the context of Java. Our work is based on the notion of behavioral subtyping.

Original languageEnglish (US)
Title of host publicationProceedings of the ACM SIGSOFT Symposium on the Foundations of Software Engineering
Pages229-236
Number of pages8
StatePublished - Dec 1 2001
Event8th Eiropean Engineering Conference (ESEC) and 9th ACM SIGSOFT Symposium on the Foundations of Software Engineering (FSE-9) - Vienna, Austria
Duration: Sep 10 2001Sep 14 2001

Other

Other8th Eiropean Engineering Conference (ESEC) and 9th ACM SIGSOFT Symposium on the Foundations of Software Engineering (FSE-9)
Country/TerritoryAustria
CityVienna
Period9/10/019/14/01

ASJC Scopus subject areas

  • Software

Fingerprint

Dive into the research topics of 'Behavioral contracts and behavioral subtyping'. Together they form a unique fingerprint.

Cite this