In aspect-orientedprogramming, pointcuts are used to describe crosscutting structure. Pointcuts that abstract over irrelevant implementation details are clearly desired to better support maintainability and modular r...
详细信息
ISBN:
(纸本)354027992X
In aspect-orientedprogramming, pointcuts are used to describe crosscutting structure. Pointcuts that abstract over irrelevant implementation details are clearly desired to better support maintainability and modular reasoning. We present an analysis which shows that current pointcut languages support localization of crosscutting concerns but are problematic with respect to information hiding. To cope with the problem, we present a pointcut language that exploits information from different models of program semantics, such as the execution trace, the syntax tree, the heap, static type system, etc., and supports abstraction mechanisms analogous to functional abstraction. We show how this raises the abstraction level and modularity of pointcuts and present first steps toward an efficient implementation by means of a static analysis technique.
In this article we introduce a comprehensive set of algebraic laws for ROOL, a language similar to sequential Java but with a copy semantics. We present a few laws of commands, but focus on the object-oriented feature...
详细信息
ISBN:
(纸本)3540405313
In this article we introduce a comprehensive set of algebraic laws for ROOL, a language similar to sequential Java but with a copy semantics. We present a few laws of commands, but focus on the object-oriented features of the language. We show that this set of laws is complete in the sense that it is sufficient to reduce an arbitrary ROOL program to a normal form expressed in a restricted subset of the ROOL operators. We also propose a law for data refinement that generalises the technique from traditional modules to class hierarchies. Together, these laws are expressive enough to derive more elaborate rules that can be useful, for example, to formalize object-oriented design practices;this is illustrated through the systematic derivation of a refactoring from the proposed laws.
Support for modular evolution of objects is required in many application areas. However, existing mechanisms for incremental behavior composition either do not support evolving objects at all, or do not satisfactorily...
详细信息
ISBN:
(纸本)3540630899
Support for modular evolution of objects is required in many application areas. However, existing mechanisms for incremental behavior composition either do not support evolving objects at all, or do not satisfactorily solve the encapsulation and name collision problems associated with them. In this paper, a new approach to behavior composition in a class-based environment is presented. It is based on the encapsulated object model of class-based inheritance, but introduces an additional abstraction layer between objects and classes. By being responsible for the compositional aspects of the behavior of objects, this layer provides support for the evolution of behavior while at the same time solving the name conflicts that may occur. A formal description of the approach is provided and its feasibility is demonstrated by implementing it as a metalevel extension of Smalltalk-80.
This paper presents a formal system based on the notion of objects and asynchronous communication. Built on Milner’s work on π-calculus, the communication primitive of the formal system is purely based on asynchrono...
详细信息
We describe support for modularity in Newspeak, a programming language descended from Smalltalk [33] and Self [69]. Like Self, all computation even an object's own access to its internal structure is performed by ...
详细信息
ISBN:
(纸本)9783642141065
We describe support for modularity in Newspeak, a programming language descended from Smalltalk [33] and Self [69]. Like Self, all computation even an object's own access to its internal structure is performed by invoking methods on objects. However, like Smalltalk, Newspeak is class-based. Classes can be nested arbitrarily, as in Beta [44]. Since all names denote method invocations, all classes are virtual;in particular, superclasses are virtual, so all classes act as mixins. Unlike its predecessors, there is no static state in Newspeak, nor is there a global namespace. Modularity in Newspeak is based exclusively on class nesting. There are no separate modularity constructs such as packages. Top level classes act as module definitions, which are independent, immutable, self-contained parametric namespaces. They can be instantiated into modules which may be stateful and mutually recursive.
One of the problems facing developers is the constant evolution of components that are used to build applications. This evolution is typical of any multi-person or multi-site software project. How can we program in th...
详细信息
ISBN:
(纸本)9783540705918
One of the problems facing developers is the constant evolution of components that are used to build applications. This evolution is typical of any multi-person or multi-site software project. How can we program in this environment? More precisely, how can language design address Such evolution? In this paper we attack two significant issues that arise from constant component evolution: we propose language-level extensions that permit Multiple, co-existing versions of classes and the ability to dynamically upgrade from one version of a class to another, whilst still maintaining type safety guarantees and requiring only lightweight extensions to the runtime infrastructure. We show how our extensions, whilst intuitive, provide a great deal of power by giving a number of examples. Given the subtlety of the problem, we formalize a core fragment of our language and prove a number of important safety properties.
Context-orientedprogramming can be regarded as a technique aiming for an improved (multi-dimensional) separation of concerns (MDSOC). The delMDSOC (virtual) machine model describes a common target platform for a rang...
详细信息
In objectorientedprogramming, it is sometimes necessary to copy objects and to compare them for equality or inequality. We discuss some of the issues involved in copying and comparing objects and we address the prob...
详细信息
ISBN:
(纸本)3540676600
In objectorientedprogramming, it is sometimes necessary to copy objects and to compare them for equality or inequality. We discuss some of the issues involved in copying and comparing objects and we address the problem of generating appropriate copying and comparing operations automatically, a service that is not provided by most objectoriented languages and environments. Automatic generation appears to be not only desirable, because hand-coding these methods is mechanical and yet error-prone, but also feasible, because the form of the code is simple and largely predictable. Some languages and some object models presented in the literature do support generic copying and comparing, typically defining separate "shallow" and "deep" versions of both operations. A close examination of these definitions reveals inadequacies. Ii the objects involved are simple, copying and comparing them is straightforward. However, there are at least three areas in which insufficient attention has been given to copying and comparing complex objects: (1) values are not distinguished from objects;(2) aggregation is not distinguished from association;and (3) the correct handling of linked structures other than trees is neglected. Solving the third problem requires a mechanism built into the language, such as exists in Eiffel. Building such a mechanism without modifying the language requires a language with sufficient reflexive facilities, such as Smalltalk. Even then, the task is difficult and the result is likely to be insecure. We show that fully automatic generation of copying and comparing operations is not feasible because compilers and other software tools have access only to the structure of the objects and not to their semantics. Nevertheless, it is possible to provide default methods that do most of the work correctly and can be fine-tuned with a small additional amount of hand-coding. We include an example that illustrates the application of our proposals to C++. It is based on
While context-orientedprogramming technology so far has focused mostly on behavioral adaptation, context-oriented data management has received much less attention. In this paper we make a case for the problem of cont...
详细信息
Shared mutable objects pose grave challenges in reasoning, especially for data abstraction and modularity. This paper presents a novel logic for error-avoiding partial correctness of programs Featuring shared Mutable ...
详细信息
ISBN:
(纸本)9783540705918
Shared mutable objects pose grave challenges in reasoning, especially for data abstraction and modularity. This paper presents a novel logic for error-avoiding partial correctness of programs Featuring shared Mutable objects. Using a first order assertion language, the logic provides heap-local reasoning about mutation and separation, via ghost fields and variables of type 'region' (finite sets of object references). A new form of modifies clause specifies write, read, and allocation effects using region expressions;this supports effect masking and a frame rule that allows a command to read state on which the framed predicate depends. Soundness is proved using a standard program semantics. The logic facilitates heap-local reasoning about object invariants: disciplines such as ownership are expressible but not hard-wired in the logic.
暂无评论