Integrating rules into object-oriented programming systems
First Claim
1. An apparatus implemented in a computer system for producing executable code for a system wherein a rule responds to a change in data belonging to the system, the apparatus comprising:
- a rule definition stored in the computer system as at least one member of a class having path-based rules, the rule definition for specifying a collection of data structures in which the change occurs; and
code generation means responsive to the rule definition for producing executable code associated with the data structures, wherein the executable code is an implementation of the rule and includes one or more instantiation functions which execute in response to the change and a triggering function which detects the change and invokes the instantiation function.
10 Assignments
0 Petitions
Accused Products
Abstract
Techniques for integrating rules into imperative object-oriented languages such as C++. C++ is extended to permit definition of rules as members of classes. When a rule is defined as a member of a class, a preprocessor receives the declaration of the rule'"'"'s class and of any other class involved in the rule and generates additional data members and member functions for the classes. The additional members of the classes permit a complete implementation of the rule. No additional rule interpreter or decision network is required. The rule definition defines collections of objects linked by interobject pointers to which the rule applies. A rule is evaluated only if there is a change in a value mentioned in the rule in an object belonging to a collection of objects for the rule. The rule'"'"'s condition is a sequence of bindings and tests. The bindings define a path through a collections of objects to which the rule applies, and the path is followed during evaluation. The rules thus implement access-limited logic.
65 Citations
20 Claims
-
1. An apparatus implemented in a computer system for producing executable code for a system wherein a rule responds to a change in data belonging to the system, the apparatus comprising:
-
a rule definition stored in the computer system as at least one member of a class having path-based rules, the rule definition for specifying a collection of data structures in which the change occurs; and code generation means responsive to the rule definition for producing executable code associated with the data structures, wherein the executable code is an implementation of the rule and includes one or more instantiation functions which execute in response to the change and a triggering function which detects the change and invokes the instantiation function. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18)
-
-
19. An apparatus implemented in a computer system for producing executable code for a system wherein a rule responds to a change in data belonging to the system, the apparatus comprising:
-
a rule definition stored in the computer system which specifies a collection of data structures in which the change occurs; and code generation means responsive to the rule definition for producing executable code associated with the data structures, wherein the executed code is an implementation of the rule and is based solely on a rule-definition code and an object-oriented code and includes one or more instantiation functions which execute in response to the change and a triggering function which detects the change and invokes the instantiation function.
-
-
20. An apparatus implemented in a computer system for producing executable code for a system wherein a rule responds to a change in data belonging to the system, the apparatus comprising:
-
a rule definition stored in the computer system which specifies a collection of data structures in which the change occurs; and code generation means responsive to the rule definition for producing executable code associated with the data structures, wherein the executable code is an implementation of the rule and includes executable code for at least one instantiation function which executes in response to the change and executable code for a triggering function which detects the change and invokes the at least one instantiation function, and said triggering function and said at least one instantiation function are embedded solely in a rule-definition code and an object-oriented code.
-
Specification