Claims
- 1. A method of processing data comprising:
defining an object with defined fields to support values in preallocated memory space and with an option data structure which supports references to option values without preallocation of memory space for the full option values; and accessing a field value and accessing an option value in the object using expressions of the same syntactic form.
- 2. A method as claimed in claim 1 wherein the option data structure identifies change handler code that is executed when an option value changes.
- 3. A method as claimed in claim 2 wherein change handler code for one option is defined in different classes within a class inheritance hierarchy and the change handler code from each class is executed when the option value changes.
- 4. A method as claimed in claim 1 wherein the option data structure includes a type description of the option value, the method further comprising:
during compilation, using the type description in the option data structure to process an operation on the option value.
- 5. A method as claimed in claim 1 wherein an option data structure includes a default value, the method further comprising, in a get operation to an instance of the class, if an option value which applies to the instance has been set, getting the set option value and, if no value which applies has been set, getting the default value for the class.
- 6. A method as claimed in claim 1 comprising:
defining a first class with a first option data structure of a first form which supports, in instances of the class, references to option values without preallocation of memory space for the full option values; defining a second class with a second option data structure of a second form which supports, in instances of the second class, references to option values without preallocation of memory space for the full option values, the second form being different from the first form; and during compilation, encoding an option operation as a method call to an object of the first class and to an object of the second class without regard to the form of the option data structure supported by the class.
- 7. A method as claimed in claim 1 further comprising:
notifying objects of a change in an option value through a change handler identified by an option binding, the option binding being located by first searching a mapping data structure for a previously computed mapping to the option binding and, if no mapping was previously computed, by then computing the mapping to the option binding and storing the mapping in the mapping data structure.
- 8. A method as claimed in claim 1 wherein the option data structure comprises a linked list of option items having option values.
- 9. A method as claimed in claim 1 wherein a nonlocal option value applies to other objects in a nonlocal option hierarchy.
- 10. A method as claimed in claim 9 wherein the nonlocal option hierarchy is a graphical hierarchy.
- 11. A data processing system including data objects, the data objects comprising:
defined fields to support values in preallocated memory space; an option data structure which supports references to option values without preallocation of memory space for the full option value, the field value and option value being accessed in the object with expressions of the same syntactic form.
- 12. A system as claimed in claim 11 wherein the option data structure identifies change handler code that is executed when an option value changes.
- 13. A system as claimed in claim 12 wherein change handler code for one option is defined in different classes within a class inheritance hierarchy and the change handler code from each class is executed when the option value changes.
- 14. A system as claimed in claim 11 wherein the option data structure includes a type description of the option value, the system further comprising a compiler which uses the type description in the option data structure to process an operation on the option value.
- 15. A system as claimed in claim 11 wherein an option data structure includes a default value which is obtained when no option value has been set in an applicable instance object.
- 16. A system as claimed in claim 11 comprising plural classes having data structures of different forms, and a compiler which encodes an option operation as a method call to an instance object of one of the classes without regard to the form of the option data structure supported by the class.
- 17. A system as claimed in claim 11 further comprising change handlers which notify objects of a change in an option value and a mapping data structure which maps an option name and class to an option binding which identifies a change handler.
- 18. A system as claimed in claim 11 wherein the option data structure comprises a linked list of option items having option values.
- 19. A system as claimed in claim 11 wherein a nonlocal option value applies to other objects in a nonlocal option hierarchy.
- 20. A system as claimed in claim 19 wherein the nonlocal option hierarchy is a graphical hierarchy.
- 21. A data processing system comprising:
means for defining an object with defined fields to support values in preallocated memory space and with an option data structure which supports references to option values without preallocation of memory space for the full option values; and means for accessing a field value and accessing an option value in the object using expressions of the same syntactic form.
- 22. A computer program product comprising:
a computer usable medium for storing data; and a set of computer program instructions embodied on the computer usable medium, including instructions to
define an object with defined fields to support values in preallocated memory space and with an option data structure which supports references to option values without preallocation of memory space for the full option values; and access a field value and access an option value in the object using expressions of the same syntactic form.
- 23. A product as claimed in claim 22 wherein the computer program instructions include instructions to notify objects of a change in an option value.
- 24. A product as claimed in claim 22 wherein the option data structure comprises a linked list of option items having option values.
- 25. A computer data signal comprising a code segment including instructions to:
define an object with defined fields to support values in preallocated memory space and with an option data structure which supports references to option values without preallocation of memory space for the full option values; and access a field value and access an option value in the object using expressions of the same syntactic form.
RELATED APPLICATION(S)
[0001] This application is a Continuation-in-Part application of U.S. application Ser. No. 09/672,562, filed Sep. 28, 2000, which claims priority to U.S. Provisional Application No. 60/162,825, filed Nov. 1, 1999, the entire teachings of which are incorporated herein by reference.
Provisional Applications (1)
|
Number |
Date |
Country |
|
60162825 |
Nov 1999 |
US |
Continuation in Parts (1)
|
Number |
Date |
Country |
Parent |
09672562 |
Sep 2000 |
US |
Child |
09760031 |
Jan 2001 |
US |