Is there a mean to specify specialization-genralization (inheritance) of actors in UML?
I am just starting to use UML and have came to the following question:
Some actors clearly are specialized versions of a natural entity. For exam开发者_StackOverflowple I've got Administrator and User actors which are clearly nothing but different roles of a user, Authorizer and Dispatcher which are services (and are going to be implemented this way). Should I just ignore these facts while modelling actors and use cases or specify it some way? I think I could make good use of such a specification to facilitate code generation.
First of all, you have to understand, that actors are not part of your system. Actor is a role or a system interacting with your system. Usually you can see that actors are not part of your system by observing the system boundary - rectangle around use cases. After we have this sorted out, let us look at actor generalization. The reason for it is by best practice to simplify use case diagrams, when more actors have associations to same use cases, where by generalizing them you centralize those associations to that one generalized actor. The notation for actor generalization is the same as for use case generalization or any other classifier generalization.
精彩评论