We have many partial classes in our class hierarchy.
How do I avoid the split into two boxes when creating the class diagram?
Can both classes be merged?
Can both boxes be glued together? (automatically?)
Thank you in advance.
Hi again Oliver,
Actually, the Sparx solution makes a lot of sense. If you think about it, you will (generally) have two (or more as the case may be) 'parts' of partial class. I mean this in the sense that the actual code will occur in two (or more) files; each file corresponds to one partial class entity.
As far as your class hierarchy goes, I don't think you have a problem. The hierarchy itself only has a single instance of the class. The partial entities merely represent the way you have implemented implementation this single class in your code.
So, at the level of abstraction of your class hierarchy there
is only a single entity. This is a high-level design. At the (lower) level of abstraction of your implementation design you have one lower-level element for each code file you will produce.
Of course there is a relationship between the two levels of design as well, which you might want to explicitly model. This could be done via a trace relationships, composite structure diagrams, or (perhaps) collaborations; perhaps some combination of these and others. That would depend on what you need to show, your audience, and your corporate standards.
Hopefully I've not muddied the waters too much...
David
PS: And don't go trashing your current model if you want to do things as above. Just create the x-thousand-foot view model and trace back to it from the design you have now. If the current model is producing usable results then it's not broken.