for a software design project I have to do, I chose the Eclipse Platform as a framework. Meaning I have lots of extension points to implement.
However, I have trouble specifying these extension points in my UML class diagram. So how do I model the fact that a class belongs to an extension point in my class diagram?
Or is the class diagram the wrong place to do this anyway? If so, where is the best place to specify the extension points I implement?
For reference, I am doing the UML modeling with Papyrus. I already have a working prototype of the application, so it is just about creating the diagram.
Cheers
An eclipse extension point is like an interface: it declares a set of properties that must be implemented.
For example, the org.eclipse.ui.editors
extension point declares that to implement this extension point you have to provide:
There is no EXACT way to say this in UML since an extension point is neither an interface nor an object, but you could model it by adding a stereotype to your model, say <<extension_point>>
(you can read more about stereotypes here), and create a class in your diagram (for example org.eclipse.ui.editors
) that has all of these attributes, with their required types (in this example all attributes are strings, except class
which is of type org.eclipse.ui.IEditorPart
).
After this you can create another stereotype, say <<extension_point_implementation>>
and a new class that has this stereotype. This class you connect with a realization link from the <<extension_point>>
class, and then you set the values of all of the attributes to what you are implementing.
Note that this is not "pure" UML since you are defining a new domain with added semantics, but I think that this would be a good and easy to understand way to model what you want.