Book a Demo

Author Topic: Sequence Diagrams and .NET  (Read 5774 times)

datac0re

  • EA Novice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Sequence Diagrams and .NET
« on: May 23, 2005, 11:35:37 am »
How would you go about showing an event invocation in a sequence diagram that multiple subscribers of different types will be listening for?

For example, I have a Host that has an EventReceived event. I have classes called Agent and Plugin that the host has collections of.

I want to model the fact that when the Host calls the "OnEventReceived" method, it is going to raise the event against its collections of Agents and Plugins.

Also, how do you model a loop?

Thanks,
Brian

TrtnJohn

  • EA User
  • **
  • Posts: 176
  • Karma: +0/-0
    • View Profile
Re: Sequence Diagrams and .NET
« Reply #1 on: May 23, 2005, 04:19:10 pm »
I don't usually show all these interactions in one sequence diagram.  Instead, I create a diagram that shows the event is fired to the base class and then create a seperate sequence diagram for each derived class that handles the event.  You can use a diagram gate to branch into each derived classes implementation if you like.