From: Gerd M. <ge...@sm...> - 2001-06-29 10:25:55
|
> C is only an association of type B. B is an instance of the class A, but A > is not a superclass of C. Sounds confusing ? :) > > The <instanceOf> element (which translates to the type or types attribute) > specifies a class-instance relationship. Topic maps are a powerful > information modelling tool because they allow a topic to be both a class and > an instance of a class. > > You can model the subclass-superclass relationship by using an association > with the XTM-defined PSIs which you will find declared as constants in > com.techquila.topicmap.PSI. To get the supertypes of a topic, you need to > first go to its type(s) and then for each of them, traverse the > subclass-superclass association to find superclasses. Okay, sound reasonable. Interesting point: What happens with cyclic dependencies ? E.g. A instanceof B, B instanceof C, C instanceof A. Nobody bars you to model this, but it could cause problems while processing. Best Regards, Gerd -- ________________________________________________________________ Gerd Mueller ge...@sm... SMB GmbH http://www.smb-tec.com |