Reconciling Logic and Objects
暂无分享,去创建一个
Logic and objects can be combined and reconciled in at least three main ways. The simplest and most conservative way is to use logic to describe OO systems. This is useful for specifying and proving properties of OO systems. A more ambitious, but also straight-forward way is to use logic to implement OO methods. Used in this way, logic can implement both condition-action rules and goal-reduction rules. In this combination of logic and objects, objects can be viewed as agents embedded in an object-oriented world, which use logic to represent and reason about the world, as well as to generate actions to change the world. This second way reconciles logic and objects by allocating them separate areas of concern: Objects provide semantic structure, and logic provides their syntactic representation. Unfortunately, this second way leaves a major conflict, concerning their different views of atomic facts, unresolved.