Hello, I’m testing the Object Model feature. It is possible to draw multiple inheritance here. E.G. Two classes A, and B, where class C inherits from both A and B. When looking at the attibutes for class C, I see both attributes from A and B. Now, I want to generate a XSD of this. But then, only one object can be inherited, and only the attribute for class A is visible in class C.
Is it possible to model multiple inheritance in Object Model, and generate a XSD for this?
Yes, multiple inheritance is not very common when it comes to progamming languages. However, my use is not about programming, it is about XML. I have a very complex XSD and I’m using UML to define it using generalization and association. I have only one class that a given class can inherit from, but I want to make use of a sort of interface to allow a given class to have a certain behavior or state with the attributes from the “interface” class. For example, in a complex product structure, I will define an interface (or super class) called “SellableItem”, that has one attribute: “price”. Any product classes that inherit (or “implements”) from this interface will also have an attribute “price” (in addition to the attibutes that it inherits from its super class).
Does this make sence?
There might be limitations for this in the XSD as well, I don’t know…
I would like to notify you that we enhanced to support multiple-inheritance for XSD, please download and install the patch from the following link. If you have any question, please feel free to ask.