摘要 |
A method, system and computer program product are disclosed for morphing an object from one class to another in an object oriented computing environment implemented by a relational database. Object morphing functionality is provided by first defining object classes, class attributes, class relationships, objects, object attributes and object relationships as tables of data in the relational database. In response to user input representing a request to reassign one of the objects from one class to another, a class identifier corresponding to the object in the database tables is changed. The object's edge relationships with other objects are then checked for continued validity and an error message is generated if any such edge relationships are no longer valid. If the object's edge relationships are valid, the attributes of the object are modified to reflect the new class assignment. This includes maintaining existing attributes that are carried over from the old class to the new class (or superclasses thereof), adding new object attributes defined in the new class but not in the old class (or superclasses thereof), and deleting old object attributes defined in the old class but not in the new class (or superclasses thereof).
|