R. Plösch: Contracts, Scenarios and Prototypes - An Integrated Approach to High Quality Software, Springer-Verlag Berlin Heidelberg New-York, 2004, ISBN 3-540-43486-0


What is this Book About?
At the beginning of the 21st century, computer systems – and especially software – play an important role in our society. Software is contained in virtually every technical device that we use in everyday life (e.g., cellular phones and cars). Furthermore, computers and their software are used for leisure purposes at home (the Internet and computer games), at the office (e.g., writing letters and order processing), and for more complicated tasks such as controlling steel plants or insuring flight safety. Therefore, the quality of software (e.g., its correctness, reliability, and efficiency) has become important not only in the context of critical systems (e.g., nuclear power plants) but also for our entire society, from business to leisure. Software engineering is the practical application of scientific knowledge for the economical production and use of high-quality software. The discipline aims at developing methods, techniques, tools, and standards to fulfill these aims. The number of methods and tools available to the software engineer nowadays is overwhelming; nevertheless, many software projects fail – that is, do not meet their schedules, are over budget, do not meet the user needs, or simply have considerable quality defects. The numerous possible explanations for this situation include poor project management, unsuitable methods and tools used in the project, and poorly developed skills of the participating software engineers. The challenge for researchers in this field is to provide methods and tools that can be applied by software engineers with average skill levels in average projects. Without defining precisely what “average” means in this context, it should be obvious that we do not mean a computer scientist verifying the correctness of the core real-time software of a safety-critical cardiac pacemaker. A number of methods and techniques contribute to the quality of software specifications (e.g., Z and state machines). Nevertheless, many of these techniques fail in the sense that they cannot be applied by average software engineers in average projects, as the mathematical skills needed are not available or the scope of the model is too narrow. This book emphasizes methods, techniques, and tools that can be used by average software engineers in average projects for the early phases (analysis and design) of the software life cycle. Therefore, the important requirements for the methods and techniques are simplicity, preciseness, generality, and expressiveness. Simplicity is perhaps the most important attribute. A complex method is unlikely to be applied throughout a project, as project members will always find reasonable-sounding excuses for not using them. On the other hand, simple approaches (with benefits that are transparent to the engineers) will be applied readily. Scenarios (use cases) are an example of a simple and yet powerful and widely applied technique. A method or technique is precise if the product of this method or technique (e.g., a specification) is less ambiguous and error-prone than it would have been had the method not been used. A number of mathematically based approaches (algebraic techniques, higher-order logic) support the specification of software to a level of preciseness that facilitates automatic code generation. However, the challenge here is to develop methods and techniques that maintain a balance between preciseness and simplicity. A method should be general in the sense that it is not only applicable in a specific domain but (in the best case) can be used productively for the three main classes of systems: information systems, embedded systems, and command and control systems. Expressiveness has much to do with notational issues of a method or technique. We consider a method or technique to be expressive if it is reasonable to use it for documenting the results of analysis and design. This important requirement means that even those low-level techniques that might fulfill the above three requirements do not prove adequate at the abstract level of analysis and design. The requirements discussed here are contradictory (e.g., simplicity versus preciseness) and the challenge is to develop methods and techniques that are balanced in the sense that all four requirements are fairly equally fulfilled. This book deals with an approach that combines assertion and scenario techniques into a consistent methodology that can be used for analysis and design tasks. The technique developed can be combined with a prototyping-oriented software development approach. Assertion techniques are theoretically well founded and are available in some programming languages. At the level of analysis and design, little work has yet been done. Due to the popularity of the Unified Modeling Language (UML), scenarios are widely used to document requirements or to express design ideas. A number of published reports and the author’s own experience show that prototyping enhances the quality of software. Each of these techniques and methods (assertions, scenarios, and prototyping) fulfill the requirements stated above: this is discussed in depth throughout the book.

What is in this Book?
In the first part of this book (Chapters 1-4) we present the concepts of assertions and scenarios. In this part, assertions are dealt with in the tradition of Hoare triples and their predecessors, without taking into consideration other interesting streams of research in the field of type theory or behavioral specifications (these are postponed until the third part). Nevertheless, this part builds a sound basis by providing the theoretic foundations and limitations of assertion techniques. Currently, assertion techniques are more widely used in late design and implementation phases, but hardly at all in analysis. We therefore present the role of assertion techniques in analysis. As the popular UML contains an assertion language called Object Constraint Language (OCL), this language is presented and compared with other currently available assertion techniques. Best practices to be considered when applying assertion techniques throughout analysis and early design are discussed. Scenarios are introduced in a similar way, beginning with basic concepts, terminology, kinds of notation, and so on. As scenarios play an important role in UML too, we describe the scenario approach as defined by UML in the context of the general concepts and principles. The part about scenarios concludes with best practices for using scenarios in analysis. The second part of this book (Chapters 5-7) focuses on a prototyping-oriented software development approach and presents general terminology, concepts, and success stories of prototyping-oriented software development. Assertion and scenario techniques are combined into a single methodological framework, and an approach model, as well as methodological issues, is presented. A case study shows the application of the approach. Because prototyping without adequate tool support is a difficult undertaking, we discuss general requirements for prototyping tools as well as prototyping tools that have been developed specifically for supporting the combined assertion/scenario approach. The toolkit that we present is suitable for prototyping tasks in the analysis and design phase, and its capabilities are presented by means of a case study. One important aspect of a prototyping-oriented approach is how the products of the prototyping process are used for design, implementation, or testing. The book presents a tool-centered approach that facilitates a smooth transformation of our prototyping results into implementation or test products. The assertion techniques presented in the first part are basic. In the third part of this book (Chapters 8), details of assertion techniques are explored and related techniques are presented, all striving for enhanced interface or even behavioral specification of code blocks.

Who Should Read this Book?

The first two parts of this book are targeted at the software engineer in industry who is interested in modern techniques for enhancing software quality. In order to enhance the usability of the book, the approaches presented are always compared with popular techniques that are available in the realm of UML. This means that even when the techniques presented cannot be applied directly, these parts of the book should also show how the techniques that are available in UML could be better used. On its own, the first part will interest practitioners and students who want to understand scenario concepts and OCL concepts of UML (i.e., their foundations) more deeply. This part is also suitable for students who are interested in assertion and scenario techniques, as it does not merely present a single method, but it relates general concepts found in the literature to popular concepts found in UML. The third part the book is targeted at graduate students or scientists who want to gain a deeper understanding of assertion techniques and related approaches, or who are interested in assertion issues in the context of emerging component technologies.

Contracts, Scenarios and Prototypes – An Integrated Approach to High Quality Software