Partial Instances via Subclassing

نویسندگان

  • Kacper Bak
  • Zinovy Diskin
  • Michal Antkiewicz
  • Krzysztof Czarnecki
  • Andrzej Wasowski
چکیده

The traditional notion of instantiation in Object-Oriented Modeling (OOM) requires objects to be complete, i.e., be fully certain about their existence and attributes. This paper explores the notion of partial instantiation of class diagrams, which allows the modeler to omit some details of objects depending on modeler’s intention. Partial instantiation allows modelers to express optional existence of some objects and slots (links) as well as uncertainty of values in some slots. We show that partial instantiation is useful and natural in domain modeling and requirements engineering. It is equally useful in architecture modeling with uncertainty (for design exploration) and with variability (for modeling software product lines). Partial object diagrams can be (partially) completed by resolving (some of) optional objects and replacing (some of) unknown values with actual ones. Under the Closed World Assumption (CWA), completion reduces uncertainty of already existing objects, or deletes them if their existence is optional. Under the Open World Assumption (OWA), completion may additionally introduce new elements, perhaps uncertain. The paper presents a simple theory of partial instantiation and completion under the CWA. It shows that partial object diagrams can be modeled by subclassing and multiplicity constraints. As a result, class diagrams can implement partial instances with the well-known notions of subtyping

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Static Typing for Object-Oriented Programming

We develop a theory of statically typed object-oriented languages. It represents classes as labeled, regular trees, types as finite sets of classes, and subclassing as a partial order on trees. We show that our subclassing order strictly generalizes inheritance, and that a novel genericity mechanism arises as an order-theoretic complement. This mechanism, called class substitution, is pragmatic...

متن کامل

Type-Safe Covariant Specialization with Generalized Matching

Matching is a relation between object types originally designed to support type-safe subclassing with binary methods. In this paper we generalize it to deal with general covariance by allowing eld and method parameter types to change covariantly in matching types. The result is a signiicant increase in the exibility of subclassing. The generalization is in a diierent direction than the recent p...

متن کامل

Anomaly-free component adaptation with class overriding

Software components can be implemented and distributed as collections of classes, then adapted to the needs of specific applications by means of subclassing. Unfortunately, subclassing in collections of related classes may require re-implementation of otherwise valid classes just because they utilize outdated parent classes, a phenomenon that is referred to as the subclassing anomaly. The subcl...

متن کامل

Modularity in the Presence of Subclassing

Classes are harder to subclass than they need be. This report addresses this problem, showing how to design classes that are more modular and easier to subclass without sacrificing the extensibility that makes subclassing useful to begin with. We argue that a class should have two interfaces, an instance interface used by programmers manipulating instances of the class, and a specialization int...

متن کامل

Class Composition in FACE, a Framework Adaptive Composition Environment

Creating applications using object-oriented frameworks is often difficult, since subclassing plays a too important role. Subclassing is a “white-box” form of reuse, and thus requires the developer to understand the underlying implementation. In the approach described in this paper, class composition is introduced as a form of black-box class reuse. It may be seen to extend the concept of parame...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2013