

Lester Flatt and Earl Scruggs could pass themselves since they are specializations of Bluegrass Player, Jimi Hendrix could not pass himself, he would fail the type check. Maybe it would be possible to use it for your situation.Īn alternate method than OCL would be to have Bluegrass Bands Operation take an argument of type Bluegrass Player.


There is Call from Foreign Classifier validation rule in the UML correctness constraints validation suite which is also based on OCL, and checks if the private operation is not called from foreign classifier. The modeler should prevent this situation. In such cases if :Jimi Hendrix would try to send the message "I_Play_Bluegrass()" the message would be marked as error in the model. You may create your own OCL constraint and use it as validation rule. The basic idea how Magic Draw proposes to handle such situations is by using validation constraints, which show when some model elements are used inappropriately. changing visibility option to private, when there are some messages which require public access).

Basically it would be quite hard to edit the model if there would be very strict connection rules (e.g. Unfortunately Magic Draw does not provide strict rules with regards to Message relationship connection rules. I have not, however, been able to control the "tail" end of the message. The myriad options of MagicDraw hint that it may have something to do with Visibility, Stereotypes, or Constraints. I'm sure that the answer is out there somewhere. I want to prevent :Jimi Hendrix from sending the message "I_Play_Bluegrass()" to :Bluegrass Band I can also use the same message from :Jimi Hendrix to :Bluegrass Band :Bluegrass Band owns the message at the "tip" end of the message I use that message again from :Earl Scruggs to :Bluegrass Band I create a message from :Lester Flatt to :Bluegrass Band :Earl Scruggs (Generalization points to :Bluegrass Player) :Lester Flatt (Generalization points to :Bluegrass Player) Then on a Sequence Diagram objects with lifelines are created for: :Lester Flatt -|> :Bluegrass Player (isAbstract = true) Over in a Class Diagram, I set the Generalizations: See the attached image of a sequence diagram that demonstrates the issue I'm trying to solve. I'd appreciate a little nudge in the right direction for what I'm doing. It's been a while since I've used UML for anything and my searches here on the forum and through Google have not found me an answer yet. I have tried to find a simple solution to this problem, and I'm stuck.
