This paper proposes an extension to the Object-Role Modeling approach to support formal declaration of dynamic rules. Dynamic rules differ from static rules by pertaining to properties of state transitions, rather than to the states themselves. In this paper, application of dynamic rules is restricted to so-called single-step transactions, with an old state (the input of the transaction) and a new state (the direct result of that transaction). Such restricted rules are easier to formulate (and enforce) than a constraint applying historically over all possible states. In our approach, dynamic rules specify an elementary transaction type indicating which kind of object or fact is being added, deleted or updated, and (optionally) pre-conditions relevant to the transaction, followed by a condition stating the properties of the new state, including the relation between the new state and the old state. These dynamic rules are formulated in a syntax designed to be easily validated by non-technical domain experts.
Consider a rst order typed language, with semantics ] ] for expressions and types. Adding subtyping means that a partial order on types is de ned and that the typing rules are extended to the e ect that expression e has type whenever e has type and . We s h o w h o w to adapt the semantics ] ] i n a simple set-theoretic way, obtaining a semantics f g ] that satis es, in addition to some obvious requirements, also the property: f g] f g], whenever .whether there exists a (mathematical) semantics for types (and subtyping). Let us denote the semantics of closed expressions e and types by e] ] and ] ], respectively. It would be nice if the semantics ] ] o f t ype is merely a set such t h a t e] ] 2 ] ] w h e n e v er e has type . However, only for simple (so-called rst order, non-recursive) types such a simple set-theoretic semantics seems possible. Most often one nds types interpreted as \domains" (continuous lattices or the like) and sometimes a set-theoretic interpretation is proved to beimpossible Reynolds 1984]. The semantics of subtyping is our prime concern in this paper.We set out to construct, by simple set-theoretic means, a semantics for types {in the presence of subtyping{ such t h a t
] ]] ] whenever This poses serious semantical problems. Consider for example the following situation: Assume that ( ! )] ] = some non-empty set of functions that have domain ] ] and co-domain ] ]Assume that int] ] real] ] Assume that int real, so that, as motivated in Section 3, (real! ) (int ! ) We then nd that the desire (real! )] ] (int ! )] ] c o n tradicts the following two observations:Functions f 2 (real! )] ] cannot belong to (int ! )] ] because the domain of f di ers from int] ] Our solution, on the contrary, is as simple as e ective, and can bestated in a single line. Given a semantics ] ] for the language without subtyping, we form a new semantics f g] when subtyping is added, by de ning f g] = ] ]For now w e h a ve, when , that f g] = S ] ] S ] ] (transitivity of , )Note that we have used only elementary, primary school set-theoretic constructions in the de nition of f g] for types. However, this still leaves us with the problem of de ning f g] for expressions in such a w ay that
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.