Composite objects: dynamic representation and encapsulation by static classification of object references

Schünemann, Ulf (2005) Composite objects: dynamic representation and encapsulation by static classification of object references. Doctoral (PhD) thesis, Memorial University of Newfoundland.

[img] [English] PDF - Accepted Version
Available under License - The author retains copyright ownership and moral rights in this thesis. Neither the thesis nor substantial extracts from it may be printed or otherwise reproduced without the author's permission.

Download (12Mb)

Abstract

The composition of several objects to one higher-level, composite object is a central technique in the construction of object-oriented software systems and for the management of their structural and dynamic complexity. Standard object-oriented programming languages, however, focus their support on the elementary objects and on class inheritance (the other central technique). They do not provide for the expression of objects' composition, and do not ensure any kind of encapsulation of composite objects. In particular, there is no guarantee that composite objects control the changes of their own state (state encapsulation). We propose to advance software quality by new program annotations that document the design with respect to object composition and, based on them, new static checks that exclude designs violating the encapsulation of composite objects' state. No significant restrictions are imposed on the composite objects' internal structure and dynamic construction. Common design patterns like Iterators and Abstract Factories are supported. We extend a subset of the Java language by mode annotations at all types of object references, and a user-specified classification of all methods into potentially state changing mutators and read-only observers. The modes superimpose composition relationships between objects connected by paths of references at run-time. The proposed mode system limits, orthogonally to the type system, the invocation of mutator methods (depending on the mode of the reference to the receiver object), the permissibility of reference passing (as parameter or result), and the compatibility between references of different modes. These restrictions statically guarantee state encapsulation relative to the mode-expressed object composition structure.

Item Type: Thesis (Doctoral (PhD))
URI: http://research.library.mun.ca/id/eprint/12304
Item ID: 12304
Additional Information: Includes bibliographical references (pages 246-251).
Department(s): Science, Faculty of > Computer Science
Date: June 2005
Date Type: Submission
Library of Congress Subject Heading: Object-oriented programming (Computer science)

Actions (login required)

View Item View Item

Downloads

Downloads per month over the past year

View more statistics