1

In my application each user can create his own system and add team members to it. Each team member in scope of a system has a certain set of permissions, basing on which system decides if team member can access the functionality.

Some examples are:

  • Access to analytics board
  • Access to system configuration utility
  • Access to team management utility
  • Access to service handling utility

Each team member can have assigned any combination of these permissions.

I'd like to create an UML use case diagram, but i don't know how to represent use cases which are restricted only to team members that are allowed to use them.

gradle
  • 113
  • 2
  • 11

3 Answers3

1

Representing permission is like breaking the generalisation os UML use-case diagrams. You need to write them down in your use case scenario and for UML you can have separate section wise representation.

swemkg
  • 117
  • 1
  • 7
  • 1
    My first thought was to create different actors representing team members with different permissions. For example create Team Manager, System Manager, Analyst, Employee actors and then make them inherit from general Team Member actor. I'm not sure if this approach would be correct though. – gradle Mar 14 '17 at 20:00
  • Adding constraints to the use cases is also a possibility. – qwerty_so Mar 15 '17 at 10:17
1

I don't think that use case diagram is sufficient for your requirements. You are talking about a user who has set of permissions. These permission are variable in time. It doesn’t depend on position (what’s more, we are not talking about being a deputy for a boss who just left for holiday). In this case I always prepare use case such as Manage Permission and an actor is always a user. Then I make a class diagram where the user/permission model is. Then you have several possibilities how to work with permissions:

  • In every scenario the first step should be checking the permission to do this steps.
  • Every use case has a preconditions related to permissions.

Check the diagram where the simplest example is.

enter image description here

Slávek Rydval
  • 244
  • 2
  • 10
0

In the model part, I use actors inheritance to model right. For example, the most simple actor is "user" and it is linked to use case "login" only, it gets the minimum right.

Others actors inherit from it. Like that they all have the right to connect to the system.

The most powerful actor, let say Administrator, inherits from all actors like that it gets all rights.

After you can not translate this in code automatically ... :)

granier
  • 1,739
  • 13
  • 25